Repository navigation
Conversation
Member
|
Thank you so much for working on this, @Aafimalek, and for the effort you put into direct microphone recording for audio-input models! This is now superseded by #16976, which was just merged and covers the same feature from issue #16056 (the mic records a WAV clip and attaches it to the message when an audio-input model is loaded, behind an opt-in Voice setting). Closing this one in favour of that, but we really appreciate the contribution. |
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
Closes #16056.
Add a separate recording control to the chat composer for audio-input models. It captures a WAV from the selected microphone and attaches it using the existing audio attachment path, without sending the recording through speech-to-text. Dictation remains available separately.
Recording stops within five minutes and the existing audio size limit. Cancelling, closing the dialog, changing chats, or losing the active composer releases the microphone. A late permission or attachment result is discarded when its composer has gone away.
Verification
npm run typecheckandnpm run buildpassed on Windows.node --experimental-strip-types --test tests/pcm-recorder.test.ts tests/audio-source-input.test.ts: 36 passed.tests/studio/playwright_chat_audio_recording.pypassed with Chrome and its simulated microphone. It checks the WAV attachment, cancellation, Escape, a delayed microphone request, and chat-switch cleanup. The test runs in the existing UI CI shard.pytest -q tests/studio/test_playwright_suites_run_in_ci.py tests/studio/test_chat_ui_shards_cover_everything.py: 36 passed.The browser test exercises recording and the production attachment adapter; it does not run inference with a real audio model or GPU.