QVAC-18410 test[skiplog]: add e2e coverage for transcribe metadata flag (PR-1701)#1883
Conversation
865eca4 to
af28af9
Compare
af28af9 to
11058c1
Compare
11058c1 to
bc0eec0
Compare
7cc16e6 to
70abedd
Compare
Tier-based Approval Status |
|
clean PR. tight scope: covers the three new code paths ( |
…t metadata (PR-1701) - transcription-metadata-batch / transcription-metadata-streaming: validate TranscribeSegment[] shape returned by Whisper when metadata: true - parakeet-tdt-metadata-rejected: assert metadata flag is rejected by non-Whisper engines (Parakeet) - shared validateSegments() helper, content-agnostic shape check - desktop + mobile executor parity for transcription and parakeet flows Also folds in a tooling fix surfaced while authoring these tests: tests-qvac/package.json gains clean:sdk-snapshot which wipes node_modules/@qvac/sdk plus the iOS/Android consumer build snapshots before reinstalling, so install:build:full no longer reuses a stale @qvac/sdk copy on any platform. Co-authored-by: Cursor <cursoragent@cursor.com>
70abedd to
52cb5ae
Compare
QVAC E2E —
|
QVAC E2E —
|
QVAC E2E —
|
QVAC E2E —
|
QVAC E2E —
|
Preview deployments for qvac-docs-staging ⚡️
Commit: Deployment ID: Static site name: |
|
/review |
Note: be concise and prefer bullet points.
🎯 What problem does this PR solve?
metadata: trueflag totranscribe()/transcribeStream()that returnsTranscribeSegment[]instead of the joined transcript. The new public boundary (shape + emission order + engine routing + duplex code path) had no e2e coverage.📝 How does it solve it?
transcription-tests.ts:transcription-metadata-batch—transcribe({ metadata: true })returnsTranscribeSegment[].transcription-metadata-streaming— drives the live bidirectionaltranscribeStream({ modelId, metadata: true })session: decodes a 16kHz mono WAV fixture to f32le, pumps it throughsession.write()in chunks plus a trailing silence pad, then iterates yielded segments. ExercisestranscribeStreamDuplexMetadata/processLineMetadata— not the deprecated upfront-audio overload.parakeet-tests.ts:parakeet-tdt-metadata-rejected—metadata: trueis whisper-only; parakeet engine must throw. PinserrorContains: "does not support metadata"so unrelated failures (model load, audio I/O) can't masquerade as a successful rejection.tests/shared/transcription-segments.ts:validateSegments()— asserts shape{ text, startMs, endMs, append, id }per segment, plus non-decreasingstartMsandidso emission stays in audio-time order (append: truerevisions may repeat astartMs). Content-agnostic — transcript correctness is already covered by existing transcription tests.runMetadataStreamDuplex()— shared driver for the live duplex metadata flow (WAV decode → f32le → chunkedwrite()→end()→ collect → validate). Used by both desktop and mobile executors.🧪 How was it tested?
npx qvac-test run:local:desktop --filter "transcription-metadata-|parakeet-tdt-metadata-rejected"→ 3/3 ✅.