TTS chunking support - #78
Closed
rasmus-z wants to merge 7 commits into
Closed
Conversation
…nd queued playback as well as highlighting of current playing chunk.
…t_completion Tauri command. On Android, Tauri’s IPC enters through the WebView JavaBridge thread, which has a much smaller stack than normal Rust/Tokio worker threads. The chat_completion async future is apparently too large and causes a stack overflow while Tauri is preparing/spawning the async IPC response.
I changed the Rust command wrappers so the IPC-facing future stays tiny, and the actual large chat flow is spawned onto Tauri’s async runtime. They now do this pattern:
Rust
tauri::async_runtime::spawn(async move {
super::flows::completion::CompletionFlow::new(app)
.execute(args)
.await
})
.await
.map_err(...)?
Instead of directly awaiting the large flow future inside the Tauri command wrapper. This should avoid overflowing the Android JavaBridge stack when pressing Send.
This reverts commit a04e1c5.
…o tts-chunking upstream merge
Contributor
|
I will complete my review soon, but in the meantime, please use the conventional commit message format for your future commits/PRs. If you haven't read CONTRIBUTING.md yet, I highly recommend checking it out. |
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.
Added TTS chunking support for the OpenAI compatible text-to-speech system, inspired by the Kokoro one. Highlights the currently speaking chunk.