refactor(stt): drop the unreachable /vad endpoint and stt:vad IPC - #919
Conversation
Nothing could reach them: the preload never exposed `stt:vad`, so the renderer had no way to call `detectSpeech`, and the helper's `/vad` endpoint only served that path. The VAD model and `--vad-model` stay: `/inference` uses them.
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (5)
💤 Files with no reviewable changes (2)
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 4 remain after this review. 📝 WalkthroughWalkthroughThe change removes VAD detection from the native Whisper HTTP server and Electron STT interfaces. The Whisper server manager no longer tracks VAD availability or provides VAD detection. Transcription and cancellation IPC handling remain. ChangesVAD support removal
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~12 minutes Change: Refactor Suggested reviewers: Merge Risk: ⚪ Minimal · up to The change removes an unused speech-detection interface while preserving transcription and inference VAD support. No actionable merge-blocking risk was identified; merge after normal checks pass. Security Architecture ReviewSecurity architecture risk: ⚪ Minimal · up to The change removes an unused speech-detection path while preserving transcription, local-only access, and existing startup and cleanup behavior. The reviewed changes do not widen access or weaken an existing security control. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Removes the speech-detection path added with the Silero VAD pre-pass (#639) that nothing could reach: the preload never exposed
stt:vad, so the renderer had no way to calldetectSpeech, and the helper's/vadendpoint only served that path.Removed:
POST /vad(helper),detectVadSegments/mergeVadIntervals/MAX_VAD_CHUNK_SAMPLESand thevadAvailabletracking (whisperServer.ts),detectSpeech/isVadAvailableand thestt:vadhandler (index.ts),STT_VAD_UNAVAILABLE/SttVadResponse(contract), and their tests.Kept: the VAD model download,
--vad-model, andSttVadSegment./inferenceuses the model, and #917 uses the type for its speech intervals.Related issue
Refs #626
Type of change
Release impact
Desktop impact
Testing
vitest electron/stt: 87 pass.tsc(app and tests), Biome: clean.build-whisper-stt.ymlcompiles the other platforms.release/v2.0.0. Independent of fix(stt): keep transcript words on the audio's clock when the VAD cuts silence #917 (no overlapping hunks); either can merge first.🤖 Generated with Claude Code
Summary by CodeRabbit