mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-06-23 10:42:00 +00:00
no-mistakes(review): guard token-delta status msg on actual compression in overflow handler
This commit is contained in:
parent
47b6b4cf85
commit
87b60ae49a
1 changed files with 1 additions and 1 deletions
|
|
@ -3170,7 +3170,7 @@ def run_conversation(
|
|||
if len(messages) < original_len or (new_tokens > 0 and new_tokens < original_tokens * 0.95) or (new_ctx and new_ctx < old_ctx):
|
||||
if len(messages) < original_len:
|
||||
agent._buffer_status(f"🗜️ Compressed {original_len} → {len(messages)} messages, retrying...")
|
||||
else:
|
||||
elif new_tokens > 0 and new_tokens < original_tokens * 0.95:
|
||||
agent._buffer_status(f"🗜️ Compressed ~{original_tokens:,} → ~{new_tokens:,} tokens, retrying...")
|
||||
time.sleep(2) # Brief pause between compression retries
|
||||
_retry.restart_with_compressed_messages = True
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue