Skip to content
Tech News
← Back to articles

Procedural Graphs: Self-Evolving Execution Structures for LLM Agents

read original get O'Reilly "Hands-On Large Language Models" book → more articles
Why This Matters

As LLM agents take on longer, tool-heavy tasks, they often lose track of goals, misorder tool calls, and loop unproductively because their procedural knowledge stays implicit in a growing context. The Procedural Graph makes 'what to do next' explicit as a graph of procedure-relation-procedure triplets that guides, rather than dictates, each action, and it edits itself by comparing failed and successful runs. That points toward more reliable agents built with less hand-crafted prompt and workflow engineering.

Key Takeaways
Worth a Look

O'Reilly "Hands-On Large Language Models" book — If procedural graphs and self-evolving LLM agents caught your interest, this O'Reilly book is a practical way to build the underlying intuition for how language models plan, reason, and use tools. It walks through hands-on examples with clear visuals, making dense agent research much easier to follow.

See O'Reilly "Hands-On Large Language Models" book on Amazon → Affiliate link — we may earn a commission on purchases, at no extra cost to you. Product picked by AI based on this article; it is not a tested recommendation.

Agents

Key points

Abstract

Large language models are increasingly deployed as agents that plan over long horizons and act through external tools. Most agents select actions through unconstrained generation over an accumulating history, leaving implicit the procedural knowledge of what to do, in what order, and under which conditions. As trajectories lengthen, agents can lose track of their objectives, invoke tools out of order, and repeat unproductive actions. We introduce the Procedural Graph: just as a knowledge graph organizes factual knowledge into (entity, relation, entity) triplets for what-is questions, a Procedural Graph organizes procedural knowledge into (procedure, relation, procedure) triplets for what-to-do questions. At each decision step, the framework localizes the agent's active node, and a guidance model translates the surrounding subgraph into step-level situational guidance that biases the solver's next action without dictating it. The graph is self-evolving: an LLM refiner contrasts failed trajectories with successful ones and edits the graph's topology and attributes, committing edits that preserve or improve held-out validation performance while retaining rejected ones to discourage repetition. Starting from a minimal skeleton, the loop builds graphs that match or surpass hand-designed ones. It can also repair a flawed expert prior. Across multiple datasets, task types, and LLMs, the Procedural Graph delivers consistent gains over memory-based baselines, and self-evolution further improves performance without manual engineering.