Conversation
2f26f95 to
f9c6245
Compare
mehtarac
approved these changes
Nov 29, 2025
f9c6245 to
3654c15
Compare
3654c15 to
f6f653b
Compare
pgrayy
commented
Nov 29, 2025
| config_dict.update({k: v for k, v in self.config.items() if k != "audio"}) | ||
|
|
||
| # Override with any kwargs from start() | ||
| config_dict.update(kwargs) |
Collaborator
Author
There was a problem hiding this comment.
Removing as we will want to be explicit with what arguments we unpack from kwargs and place into config.
f6f653b to
67caf9b
Compare
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.
Description
Restart Gemini model connection after timeout.
Note, Gemini uses a live session handle id to restart connections, which means we do not need to seed the message history. Regardless, we do not have a message history recorded yet for Gemini because of googleapis/python-genai#1504. With that said, right now the Gemini connection cannot be Strands session persisted. We will address this in a follow up.
For additional context, the session handle id can be used to restart connections over a 24 hour period. This means if we were to go longer, we would at that point need to switch from the handle id to using a message history. In either case, we need to work on session managing both the live handle id and the message history.
Testing
hatch run bidi:prepare: Wrote new unit testsGemini successfully restarted. Additionally, Gemini remembered the conversation from the previous connection (restarts every 15 minutes). Gemini however was not able to remember the tool use requested in the previous connection. It has this weird behavior where it will continue to request the tool until it receives the result. We will be sure to document this odd behavior. Nothing much we can do on our end.