Repository navigation
Dictation telemetry: time Cmd+V, the confirm wait, and the recorder - #2017
Merged
Merged
Conversation
stop_to_paste_latency_ms includes the paste confirmation wait (up to 0.35 s after the text has usually landed), and nothing says which recorder a take used, so slow mic stops can't be split by backend. dictation_stop_latency_measured now also carries: - stop_to_paste_dispatch_latency_ms: stop to Cmd+V sent (10 ms rounded) - paste_confirm_bucket, checkpoint_bucket, resample_bucket - mic_backend: pinned_ioproc or engine, read before the mic stops Registry, reviewed-properties list, privacy doc and the policy test move in lockstep. No behavior change. Claude-Session: https://claude.ai/code/session_01DEL5vVKCBRYCvxaT5GS1nA
A dictation during a meeting rides the meeting's mic, not the engine, so mic_backend now says shared_meeting_mic for those takes instead of engine. Claude-Session: https://claude.ai/code/session_01DEL5vVKCBRYCvxaT5GS1nA
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.
Requested by Justin · project thread
Why
Before:
dictation_stop_latency_measuredsendsstop_to_paste_latency_ms, which runs untilpaste()returns. That includes the up-to-0.35 s paste confirmation pump, so it overstates when the text actually shows. On 25% of takespaste_bucketis 250-499 ms, and we can't tell how much of that is the confirm wait. It also doesn't say which recorder the take used, and the USB-mic stop cost lives on the pinned recorder only.After: the same event also carries:
stop_to_paste_dispatch_latency_ms(stop to Cmd+V sent; the timing already exists asstop_to_paste_dispatch_ms, it just wasn't sent), rounded to 10 ms like the other reviewed raw timings.paste_confirm_bucket,checkpoint_bucket,resample_bucket: buckets for timings the controller already measures (paste_confirmation_wait_ms,recovery_checkpoint_ms,snapshot_resample_ms).mic_backend:pinned_ioproc,shared_meeting_micorengine, read before the mic stops.No UX change. This gives the speed work a true stop-to-text number before any ratchet is built on it.
Product Impact
dictationtelemetry onlydictation reliabilityWhat changed
DictationSessionDeliveryTypes.swift:DictationStopTiming.micBackend.DictationSessionController+Stop.swift: sets it fromParakeetEngine.dictationMicBackendNameright when the stop timing is created.ParakeetRecordingTeardown.swift:dictationMicBackendName(PinnedMicrophoneCapture.diagnosticBackendName,shared_meeting_micfor a dictation on the meeting's mic, elseengine).DictationSessionController+Telemetry.swift: three new bucket mappings, one new exact timing, andmic_backend.Resources/analytics-events.psv,Resources/analytics-reviewed-properties.psv(the raw ms key),docs/privacy-first-observability.md, andTests/AnalyticsEventPolicyTests.swift(the new keys survive the sanitizer).How I checked it
scripts/dev/agent-preflight.shbash scripts/dev/linux-checks.sh(runs without Swift): 65 passed, 0 failedpython3 scripts/dev/check-telemetry-keys.py: PASSpython3 scripts/dev/check-module-boundaries.py: OK.agents/test-matrix.yml(CI)bash build.sh --no-open(CI)bash run-tests.sh(CI)bash run-integration-smoke.sh(not touched)swift test(not touched)bash run-e2e-smoke.shChecks I could not run, and why:
Mac or hardware test still needed? No. After it ships, the PostHog event shows the new keys.
Risk Review
check-source-pins.py --changed-only: covered by linux-checks/mnt/project-files/reviews/next-release/2017.md). Its low finding (meeting-mic takes read asengine) is fixed in 8894a79. Open low: a pinned take that fell back mid-take also reads asengine.Notes
Item 3 in the dictation speed plan (
/mnt/project-files/speed/2026-10-05/dictation.md). Follows #2014.Agent handoff
COORD_DONE: BRIEF | this PR | dictation stop telemetry: Cmd+V timing, confirm/checkpoint/resample buckets, mic_backend | none | merge after 1.1.70 ships, Justin's word | linux-checks, telemetry keys, module boundaries, deep review READY | lanes used: Codex=n/a (cloud session); Claude=n/a (cloud session); Local=n/a; Windows=n/a | CI green, then ask Justin🤖 Generated with Claude Code
https://claude.ai/code/session_01DEL5vVKCBRYCvxaT5GS1nA