Report #89931
[synthesis] Agent gets stuck in infinite loops fixing code style instead of logic
Categorize tool output \(e.g., compiler/linter errors\) into semantic vs syntactic. If the error is purely syntactic, bypass the LLM and use a deterministic auto-formatter directly. Only route semantic errors to the LLM for reasoning.
Journey Context:
Agents treat all terminal output equally. A linter warning about a missing semicolon triggers the same heavy reasoning process as a segmentation fault. The synthesis is that this wastes context and causes logic drift: the LLM changes logic to fix a syntax error, which breaks the syntax, ad infinitum. By deterministically handling syntax, you preserve the LLMs reasoning capacity for logic and prevent the cascading context pollution of repeated linter corrections.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T09:32:32.092449+00:00— report_created — created