fix: debounce process notification events in TUI#71
Merged
Conversation
- add voice state management hook (useVoice) + key parsing (platform.ts)
- register voice.record_key from config as global keybinding (ctrl+b)
- handle voice.status / voice.transcript gateway events
- show recording indicator (recording/transcribing/ready) in composer bar
- extend /voice command to return record_key, support on/off/tts/status
- auto-send transcribed text on capture (CLI parity with upstream)
new files: src/voice/{types,platform,useVoice,Indicator}.tsx
modified: app.tsx, gatewayEvents.ts, useAppKeys.ts, gateway-types.ts
status.update/kind=process events fire per terminal(background=true)
completion. when many finish in quick succession (builds, parallel
tests), each dispatches a {kind:system} action that triggers a full
Chat re-render -- causing visible TUI lag.
route process events through a 500ms debounced accumulator. rapid
completions coalesce into one combined system message.
events.ts: add onProcessNotification to Side callback type
useStream.ts: procs ref accumulates texts, flushProcs batches + dispatches
02e83b6 to
cdb3e9e
Compare
Owner
|
Rebased on current dev after #74 and pushed a fixup.
|
Merged
Contributor
|
🎉 This PR is included in version 1.7.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Contributor
Author
|
my agent accidentally added my other fixups to herm into this commit, rather than opening the PR on my own fork, so the STT commit wasn't actually meant to be here and i've not properly tested it, was not even sure if it works 😅 |
Owner
|
I saw it and left it in because it LGTM. I don't use voice though, if there's an issue with it we can always address it later |
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.
status.update/kind=process events fire once per terminal(background=true) completion. when many processes finish in quick succession (builds, parallel tests), each generates a separate {kind:system} dispatch that triggers a full Chat re-render -- causing visible TUI lag.
route process events through a 500ms debounced accumulator in useStream. rapid completions coalesce into one combined system message:
"◆ 3 background processes completed"
events.ts: add onProcessNotification to Side callback type, route status.update/process through callback instead of direct dispatch
useStream.ts: procs ref accumulates notification texts, flushProcs batches and dispatches single system msg