Repository navigation
Count a long pinned take with almost no audio as empty - #1882
Merged
Merged
Conversation
A pinned recorder that never delivers audio ends each take as "recording too short", which the speed-path scoring skipped as a tap. Past the 1.5 s mis-tap limit it now counts as empty, so two of those in a row move the mic back to the engine like two silent takes do. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016DYGa1i8HDv497ewpWgaCM
The held time now runs from the capture's start returning to Stop, so a queued start or a slow drain no longer counts as the recorder being open. A too-short take also needs under 0.5 s of audio, so a healthy mic that started slowly on a short hold is never scored as dead. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016DYGa1i8HDv497ewpWgaCM
r3dbars
marked this pull request as ready for review
September 27, 2026 18:53
Speech CLAUDE.md: keeps main's warmup sentence (#1874) and this branch's 0.5 s rule for empty takes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Sep 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Before: #1880 moves a mic off the pinned recorder after two empty held takes in a row. Empty means "no speech" or "signal but no words". A recorder that delivers no audio at all ends a take as "recording too short" instead. The scoring skipped those as taps, so a recorder that never delivers audio would never trip the fallback.
After: a "recording too short" take counts as empty when the recorder was open for at least 1.5 s and less than 0.5 s of audio arrived. The 1.5 s is the same line
isAccidentalStartalready draws between a mis-tap and a stalled mic. Taps under 1.5 s still aren't scored. A healthy mic that started slowly still delivers most of its hold, so it isn't scored either.This follows up the 1.1.66 empty-dictation reports. A PostHog check found 3 of 8 Macs with zero working dictations on 1.1.66:
pending_bucketlt_100ms/100_249ms), so the mic had nothing to do with it.This PR closes the one remaining gap that could hide a dead recorder.
Product Impact
dictationdictation reliabilityWhat changed
PinnedDictationSpeedPath.outcomegainsheldSecondsandaudioSeconds.recordingTooShortis.emptywhen held is at leastaccidentalStartMaximumPress(1.5 s) and audio is underdeadRecorderMaximumAudio(0.5 s). Otherwise it's nil.ParakeetPinnedDictationRecording.startedUptimeis reset once the capture's start returns. Stop reads the time before the drain, so neither a queued start nor the drain counts as time the recorder was open (deep-review S1).PinnedDictationSpeedPathTakecarriesheldSecondsandaudioSeconds.audioSecondsis the take'srecoveredRecordingTimeline.totalDurationSeconds(deep-review S2).How I checked it
bash scripts/dev/linux-checks.sh(runs without Swift): 48 passed, 0 failedpython3 scripts/dev/check-source-pins.py --changed-only: PASSbash build.sh --no-open(CIapp-build, green on c45538f)bash run-tests.sh(CIchecks, green on c45538f)bash run-integration-smoke.sh(CIspm-tests, green on c45538f; the Parakeet lifecycle smoke compiles this file)Checks I could not run, and why:
Mac or hardware test still needed? If yes: the steps, the log line or UI change each step should show, and whether each step fails on
main:Risk Review
.agent-review/visuals/evidence: not applicable, no UI changesNotes
Agent handoff
COORD_DONE: BRIEF | this PR | long pinned takes with almost no audio now count toward the fallback | none | merge for 1.1.67 on a person's go | linux-checks, source pins, CI green | deep review READY🤖 Generated with Claude Code
https://claude.ai/code/session_016DYGa1i8HDv497ewpWgaCM