Simplify dictate to auto-start recording and exit after one utterance#206
Merged
Conversation
`assembly dictate` now always auto-starts recording and exits after one utterance — the old idle-prompt loop (idle until Enter, record, transcribe, repeat) is gone, so dictation behaves the same whether stdout is a tty or a pipe. `--once` is kept as a hidden, deprecated no-op that warns it can be dropped, so existing scripts don't break. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RFDkryY7tiJMLs93ednr1G
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.
Summary
Refactor
assembly dictateto always auto-start recording and exit after one utterance, removing the interactive idle-loop mode and the--onceflag's functional behavior. This simplifies the UX for the common case (pipe-friendly single utterance) and makes it the default.Key Changes
assembly dictate | assembly llm …)--once: The flag is now a hidden no-op that warns users it can be omitted; kept only for backward compatibility with existing scriptsTOGGLE_KEYS/QUIT_KEYSdistinction with unifiedSTOP_KEYS(Enter, Space, q, Esc, Ctrl-D all stop recording); removed the idle-prompt quit-key logic_session()function: Eliminated the branching logic that chose between single-shot and interactive modes;_capture_and_transcribe()is now called directlystdio.stdout_is_tty()check: No longer needed since single-utterance is always the behavior--oncefrom visible options and examplesImplementation Details
seamsfixture no longer patchesstdio.stdout_is_tty()since TTY detection is unused["\r", None, "\r", "q"]→[None, "\r"])Nonewaits for idle prompts)--oncedeprecation warning is suppressed by--quietto avoid noise in automated scriptshttps://claude.ai/code/session_01RFDkryY7tiJMLs93ednr1G