feat(FN-882): add loop detection recovery with compact-and-resume
- Add ContextLimitDetector to detect agent loops via repeated tool call patterns - Implement compact-and-resume strategy: summarize conversation and restart agent from current step - Add loop recovery to StuckTaskDetector with configurable attempt tracking and retry limits - Extend executor with automatic loop recovery on context limit detection - Add loop recovery support to pi executor with same compact-and-resume pattern - Add comprehensive tests for context-limit-detector, stuck-task-detector loop detection, executor, and pi recovery - Add changeset for patch bump to @gsxdsm/fusion - Update README with loop detection and recovery documentation
This commit is contained in:
5
.changeset/fn-882-loop-recovery.md
Normal file
5
.changeset/fn-882-loop-recovery.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@gsxdsm/fusion": patch
|
||||
---
|
||||
|
||||
Add loop detection recovery with compact-and-resume for stuck agents. When the stuck task detector identifies a looping agent (active but not making step progress), it now attempts an in-process compact-and-resume before falling back to kill/requeue. Context-limit errors from LLM providers are also caught and trigger compaction.
|
||||
Reference in New Issue
Block a user