fix(tool-guardrails): detect content repetition across varying argument sets (#60084) - #60148
Closed
kyssta-exe wants to merge 1 commit into
Closed
fix(tool-guardrails): detect content repetition across varying argument sets (#60084)#60148kyssta-exe wants to merge 1 commit into
kyssta-exe wants to merge 1 commit into
Conversation
…nt sets (NousResearch#60084) Add a content-hash-only repetition tracker to ToolCallGuardrailController that catches loops where tool arguments vary but the result content stays the same — two loop shapes the existing signature-keyed trackers miss: 1. Varying-args / fixed-result: a non-idempotent tool (e.g. execute_code wrapping a web fetch) returning the same blocked/error-page body with different arguments on every call. 2. Repeated multimodal results: a vision tool that embeds a base64 payload (unique per call) but whose meaningful text caption is identical. New config: - same_content_warn_after: 3 (default) - same_content_block_after: 6 (default, requires hard_stop_enabled) The tracker is keyed by result content hash only (no args), so it operates independently of the existing signature-based failure and no-progress trackers, which are scoped to idempotent tools or exact argument matches.
Collaborator
Duplicate of #60087 (earliest open canonical for #60084). Both add a content-hash-only result-repetition tracker to |
This was referenced Jul 7, 2026
Contributor
Author
|
Stale — 7-8 days without merge activity. Can resubmit if still needed. |
1 task
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.
Add a content-hash-only repetition tracker to ToolCallGuardrailController that catches loops where tool arguments vary but the result content stays the same.
Two loop shapes detected:
New config options:
same_content_warn_after: 3 (default)same_content_block_after: 6 (default, requires hard_stop_enabled)Closes #60084