FGDM: Reasoning Aware Multi-Agentic Framework for Software Bug Detection using Chain of Thought and Tree of Thought Prompting
arXiv cs.LG / 4/29/2026
💬 OpinionDeveloper Stack & InfrastructureModels & Research
Key Points
- The paper argues that existing deep-learning approaches for software bug detection struggle with the “global” context of code, leading to performance drops on large, interconnected, or modular codebases.
- It proposes FGDM, a Flow-Graph-Driven Multi-Agent framework that converts code into a flow graph, detects erroneous segments, and generates repaired code using four sequential agents.
- FGDM relies on Chain-of-Thought and Tree-of-Thought prompting across its agents to improve reasoning over dependencies among modules.
- The system integrates FAISS to retrieve similar past bugs and their repairs, using retrieved examples to support the repair process.
- Experiments on 100+ programs across popular projects (e.g., Pandas, FastAPI, Matplotlib, Scrapy) show FGDM outperforming prior methods, achieving mean Levenshtein reductions of 24.33 (Python) and 8.37 (C) and high cosine similarity scores (0.951 Python, 0.974 C).
Related Articles

How I Use AI Agents to Maintain a Living Knowledge Base for My Team
Dev.to

An API testing tool built specifically for AI agent loops
Dev.to
IK_LLAMA now supports Qwen3.5 MTP Support :O
Reddit r/LocalLLaMA
OpenAI models, Codex, and Managed Agents come to AWS
Dev.to

Automatic Error Recovery in AI Agent Networks
Dev.to