Hey @MervinPraison and team,
Massive respect for the work you're doing with PraisonAI. Your native "Doom Loop Detection" (generic_repeat, poll_no_progress, ping_pong) is exactly what the ecosystem needs to stop agents from burning context windows.
I'm the maintainer of TokenCircuit (an open-source pre-model intervention engine). While building it, we solved a specific failure mode that exact-hash and structural detectors miss: paraphrased reasoning loops.
This happens when an LLM slightly alters its text or tool arguments on every turn, but repeats the exact same failing strategy. The transcript changes, so exact-hash misses it, but the agent is still stuck.
The Proposal
I'd love to contribute our semantic engine as an optional "Advanced Semantic Detector" that users can plug into PraisonAI's agent hook system alongside your existing detectors.
Why it fits PraisonAI
- Zero Dependencies: It uses pure Python stdlib (
regex + hashlib shingling). No tiktoken, no embeddings, no network calls. It won't bloat your dependency tree.
- Blazing Fast: Benchmarked at <5µs latency per turn.
- MIT Licensed: Fully compatible with PraisonAI's ecosystem.
I've already written the integration logic and the test suite. Would you be open to me opening a PR that adds this as an advanced, opt-in detector for your Doom Loop framework?
Cheers,
Tanmay
Maintainer, TokenCircuit (https://github.com/Devaretanmay/TokenCircut)
Hey @MervinPraison and team,
Massive respect for the work you're doing with PraisonAI. Your native "Doom Loop Detection" (
generic_repeat,poll_no_progress,ping_pong) is exactly what the ecosystem needs to stop agents from burning context windows.I'm the maintainer of TokenCircuit (an open-source pre-model intervention engine). While building it, we solved a specific failure mode that exact-hash and structural detectors miss: paraphrased reasoning loops.
This happens when an LLM slightly alters its text or tool arguments on every turn, but repeats the exact same failing strategy. The transcript changes, so exact-hash misses it, but the agent is still stuck.
The Proposal
I'd love to contribute our semantic engine as an optional "Advanced Semantic Detector" that users can plug into PraisonAI's agent hook system alongside your existing detectors.
Why it fits PraisonAI
regex+hashlibshingling). Notiktoken, no embeddings, no network calls. It won't bloat your dependency tree.I've already written the integration logic and the test suite. Would you be open to me opening a PR that adds this as an advanced, opt-in detector for your Doom Loop framework?
Cheers,
Tanmay
Maintainer, TokenCircuit (https://github.com/Devaretanmay/TokenCircut)