fix: make Hindsight cloud client timeout configurable#9985
Closed
nightq wants to merge 1 commit into
Closed
Conversation
…IMEOUT Fixes NousResearch#9869 Root cause: Hindsight cloud client hardcoded 30s timeout, but hindsight_reflect operations can take much longer with larger memory banks Fix: Read timeout from HINDSIGHT_TIMEOUT env var with 300s default
5 tasks
nicoloboschi
left a comment
Contributor
There was a problem hiding this comment.
can you rename it HINDSIGHT_HTTP_TIMEOUT?
Collaborator
|
Likely duplicate of #10045 — same HINDSIGHT_TIMEOUT env var fix for the hardcoded 30s cloud client timeout. |
2 tasks
Contributor
|
Thanks for the contribution @nightq! This fix has already landed on Automated hermes-sweeper review.
The underlying issue (#9869) is resolved on current |
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
The
hindsight_reflecttool was failing intermittently because the Hindsight cloud client had a hardcoded 30-second HTTP timeout, while LLM synthesis across the memory graph routinely takes longer — especially with larger memory banks or slower providers.Root Cause
Line 461 of
plugins/memory/hindsight/__init__.pyhardcodedtimeout: 30.0when creating the Hindsight cloud client. The outer\_run_sync()wrapper has a 120s timeout, but the inner HTTP client enforces its own 30s limit, so requests never get a chance to complete.Fix
Made the timeout configurable via the
HINDSIGHT_TIMEOUTenvironment variable, with a default of 300 seconds to match the outer wrapper and other Hermes timeouts.Test Plan
Closes #9869