Tree-of-Code: A Hybrid Approach for Robust Complex Task Planning and Execution
Ziyi Ni, Yifan Li, Daxiang Dong

TL;DR
Tree-of-Code (ToC) is a novel hybrid framework that enhances complex task planning and execution in LLM agents by integrating tree-based exploration with code generation, improving robustness and solution quality.
Contribution
The paper introduces Tree-of-Code, combining Tree-of-Thought and CodeAct to improve exploration and robustness in complex reasoning tasks for LLM agents.
Findings
Enhanced solution exploration via tree-based search.
Improved robustness in complex reasoning tasks.
Voting mechanism improves final decision accuracy.
Abstract
The exceptional capabilities of large language models (LLMs) have substantially accelerated the rapid rise and widespread adoption of agents. Recent studies have demonstrated that generating Python code to consolidate LLM-based agents' actions into a unified action space (CodeAct) is a promising approach for developing real-world LLM agents. However, this step-by-step code generation approach often lacks consistency and robustness, leading to instability in agent applications, particularly for complex reasoning and out-of-domain tasks. In this paper, we propose a novel approach called Tree-of-Code (ToC) to tackle the challenges of complex problem planning and execution with an end-to-end mechanism. By integrating key ideas from both Tree-of-Thought and CodeAct, ToC combines their strengths to enhance solution exploration. In our framework, each final code execution result is treated as…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsSoftware Reliability and Analysis Research · AI-based Problem Solving and Planning · Advanced Software Engineering Methodologies
