MermaidFlow: Redefining Agentic Workflow Generation via Safety-Constrained Evolutionary Programming
On the map: LLM agents and tool use → Software engineering coding agents
Abstract (arXiv)
Despite the promise of autonomous agentic reasoning, existing workflow generation methods frequently produce fragile, unexecutable plans due to unconstrained LLM-driven construction. We introduce MermaidFlow, a framework that redefines the agentic search space through safety-constrained graph evolution. At its core, MermaidFlow represent workflows as a verifiable intermediate representation using Mermaid, a structured and human-interpretable graph language. We formulate domain-aware evolutionary operators, i.e., crossover, mutation, insertion, and deletion, to preserve semantic correctness while promoting structural diversity, enabling efficient exploration of a high-quality, statically verifiable workflow space. Without modifying task settings or evaluation protocols, MermaidFlow achieves consistent improvements in success rates and faster convergence to executable plans on the agent reasoning benchmark. The experimental results demonstrate that safety-constrained graph evolution offers a scalable, modular foundation for robust and interpretable agentic reasoning systems.
Key facts. Cited by 14 papers in the map (data through 7 Oct 2026). Placed in Software engineering coding agents, one of 16 directions in LLM agents and tool use. Builds on 30 of its 35 references that are in the map. First posted on arXiv 29 May 2025.
Builds on
30 of 35 references.
Closest ancestors · 6
Same direction, newest first
- 2025Which Agent Causes Task Failures and When? On Automated Failure Attribution of LLM Multi-Agent Systems30 Apr
- 2025DebFlow: Automating Agent Creation via Agent Debate31 Mar
- 2025Why Do Multi-Agent LLM Systems Fail?17 Mar
- 2025EvoFlow: Evolving Diverse Agentic Workflows On The Fly11 Feb
- 2025ScoreFlow: Mastering LLM Agent Workflows via Score-based Preference Optimization6 Feb
- 2024AFlow: Automating Agentic Workflow Generation14 Oct
Other references · 24
- 2021Training Verifiers to Solve Math Word Problemscited by 9,743
- 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 8,355
- 2021Evaluating Large Language Models Trained on Codecited by 8,053
- 2022Self-Consistency Improves Chain of Thought Reasoning in Language Modelscited by 5,601
- 2021Measuring Mathematical Problem Solving With the MATH Datasetcited by 5,203
- 2022Large Language Models are Zero-Shot Reasonerscited by 4,323
- 2021Program Synthesis with Large Language Modelscited by 3,509
- 2023Self-Refine: Iterative Refinement with Self-Feedbackcited by 3,317
- 2023MetaGPT: Meta Programming for A Multi-Agent Collaborative Frameworkcited by 1,761
- 2023Improving Factuality and Reasoning in Language Models through Multiagent Debatecited by 1,739
- 2023Encouraging Divergent Thinking in Large Language Models through Multi-Agent Debatecited by 995
- 2024Large Language Model based Multi-Agents: A Survey of Progress and Challengescited by 752
12 more
- 2022Complexity-Based Prompting for Multi-Step Reasoningcited by 387
- 2024Automated Design of Agentic Systemscited by 360
- 2023A Dynamic LLM-Powered Agent Network for Task-Oriented Agent Collaborationcited by 281
- 2024Scaling Large Language Model-based Multi-Agent Collaborationcited by 235
- 2023AutoAgents: A Framework for Automatic Agent Generationcited by 211
- 2025Multi-agent Architecture Search via Agentic Supernetcited by 164
- 2024G-Designer: Architecting Multi-agent Communication Topologies via Graph Neural Networkscited by 110
- 2025Multi-Agent Design: Optimizing Agents with Better Prompts and Topologiescited by 106
- 2024Breaking Agents: Compromising Autonomous LLM Agents Through Malfunction Amplificationcited by 80
- 2024A Review of Prominent Paradigms for LLM-Based Agents: Tool Use (Including RAG), Planning, and Feedback Learningcited by 74
- 2025FlowReasoner: Reinforcing Query-Level Meta-Agentscited by 56
- 2025MAS-GPT: Training LLMs to Build LLM-based Multi-Agent Systemscited by 45
Built on by
Citing papers per year: 2025: 3; 2026: 11.
14 papers.
Sort:
By area:
- 2026Natural-Language Agent Harnessescited by 54
- 2026From Static Templates to Dynamic Runtime Graphs: A Survey of Workflow Optimization for LLM Agentscited by 22
- 2026HarnessForge: Joint Harness and Policy Evolution for Adaptive Agent Systemscited by 20
- 2025RobustFlow: Towards Robust Agentic Workflow Generationcited by 19
- 2026Lifting Traces to Logic: Programmatic Skill Induction with Neuro-Symbolic Learning for Long-Horizon Agentic Taskscited by 7
- 2025Compound AI Systems Optimization: A Survey of Methods, Challenges, and Future Directionscited by 4
- 2026JudgeFlow: Agentic Workflow Optimization via Block Judgecited by 2
- 2026FlowBank: Query-Adaptive Agentic Workflows Optimization through Precompute-and-Reusecited by 2
- 2025MAS2: Self-Generative, Self-Configuring, Self-Rectifying Multi-Agent Systemscited by 1
- 2026FlowEvo: Self-Evolving Agents through the Co-Evolution of Workflows and Executable Skillscited by 1
- 2026COVENANT: Natural-Language Workflow Compilation for Aligned Agent Executioncited by 1
- 2026FlowScout: From Execution Feedback to Reliable Tool-Using Agent Workflowscited by 1
- 2026Graph Engineering in the Era of LLM Agents: From Individual Intelligence to System Intelligence21 Aug 2026
- 2026FlowScout: From Execution Feedback to Reliable Tool-Using Agent Workflows10 Aug 2026
- 2026COVENANT: Natural-Language Workflow Compilation for Aligned Agent Execution28 Jul 2026
- 2026FlowBank: Query-Adaptive Agentic Workflows Optimization through Precompute-and-Reuse9 Jun 2026
- 2026HarnessForge: Joint Harness and Policy Evolution for Adaptive Agent Systems1 Jun 2026
- 2026Lifting Traces to Logic: Programmatic Skill Induction with Neuro-Symbolic Learning for Long-Horizon Agentic Tasks2 May 2026
- 2026FlowEvo: Self-Evolving Agents through the Co-Evolution of Workflows and Executable Skills18 Apr 2026
- 2026Natural-Language Agent Harnesses26 Mar 2026
- 2026From Static Templates to Dynamic Runtime Graphs: A Survey of Workflow Optimization for LLM Agents23 Mar 2026
- 2026HyEvo: Self-Evolving Hybrid Agentic Workflows for Efficient Reasoning20 Mar 2026
- 2026JudgeFlow: Agentic Workflow Optimization via Block Judge12 Jan 2026
- 2025MAS2: Self-Generative, Self-Configuring, Self-Rectifying Multi-Agent Systems29 Sep 2025
- 2026From Static Templates to Dynamic Runtime Graphs: A Survey of Workflow Optimization for LLM Agentscited by 22
- 2026HarnessForge: Joint Harness and Policy Evolution for Adaptive Agent Systemscited by 20
- 2025RobustFlow: Towards Robust Agentic Workflow Generationcited by 19
- 2026Lifting Traces to Logic: Programmatic Skill Induction with Neuro-Symbolic Learning for Long-Horizon Agentic Taskscited by 7
- 2026JudgeFlow: Agentic Workflow Optimization via Block Judgecited by 2
- 2026FlowBank: Query-Adaptive Agentic Workflows Optimization through Precompute-and-Reusecited by 2
- 2025MAS2: Self-Generative, Self-Configuring, Self-Rectifying Multi-Agent Systemscited by 1
- 2026FlowEvo: Self-Evolving Agents through the Co-Evolution of Workflows and Executable Skillscited by 1
- 2026COVENANT: Natural-Language Workflow Compilation for Aligned Agent Executioncited by 1
- 2026FlowScout: From Execution Feedback to Reliable Tool-Using Agent Workflowscited by 1
- 2026Graph Engineering in the Era of LLM Agents: From Individual Intelligence to System Intelligencecited by 1
- 2026Graph Engineering in the Era of LLM Agents: From Individual Intelligence to System Intelligence21 Aug 2026
- 2026FlowScout: From Execution Feedback to Reliable Tool-Using Agent Workflows10 Aug 2026
- 2026COVENANT: Natural-Language Workflow Compilation for Aligned Agent Execution28 Jul 2026
- 2026FlowBank: Query-Adaptive Agentic Workflows Optimization through Precompute-and-Reuse9 Jun 2026
- 2026HarnessForge: Joint Harness and Policy Evolution for Adaptive Agent Systems1 Jun 2026
- 2026Lifting Traces to Logic: Programmatic Skill Induction with Neuro-Symbolic Learning for Long-Horizon Agentic Tasks2 May 2026
- 2026FlowEvo: Self-Evolving Agents through the Co-Evolution of Workflows and Executable Skills18 Apr 2026
- 2026From Static Templates to Dynamic Runtime Graphs: A Survey of Workflow Optimization for LLM Agents23 Mar 2026
- 2026JudgeFlow: Agentic Workflow Optimization via Block Judge12 Jan 2026
- 2025MAS2: Self-Generative, Self-Configuring, Self-Rectifying Multi-Agent Systems29 Sep 2025
- 2025RobustFlow: Towards Robust Agentic Workflow Generation26 Sep 2025
Similar, not cited
Close in wording, no citation either way
- 2026Co-evolving Agent Architectures and Interpretable Reasoning for Automated Optimization
- 2026GraphBit: A Graph-based Agentic Framework for Non-Linear Agent Orchestration
- 2026Learning to Compose for Cross-domain Agentic Workflow Generation
- 2025DyFlow: Dynamic Workflow Framework for Agentic Reasoning
- 2025A2Flow: Automating Agentic Workflow Generation via Self-Adaptive Abstraction Operators
- 2026GraphFlow: A Graph-Based Workflow Management for Efficient LLM-Agent Serving
- 2026AgentXRay: White-Boxing Agentic Systems via Workflow Reconstruction
- 2026Tools as Continuous Flow for Evolving Agentic Reasoning