AIAny

Executable Code Actions Elicit Better LLM Agents

Lets language-model agents compose tools through executable Python and revise actions from interpreter feedback. Evaluates 17 models and releases 7,000 interaction trajectories for training agents that can debug their own code.

Introduction

An agent can know which tools to call yet struggle to combine their outputs. The central insight is to make action composition part of the language itself: variables, loops, and conditionals carry work that would otherwise require repeated model turns. Interpreter feedback then makes failed actions repairable.

Key Findings
  • Across 17 models, code actions are competitive on atomic API calls; the larger benefit appears when tasks require multiple tools and dependent steps.
  • On the 82-task M³ToolEval benchmark, the authors report gains of up to about 20 percentage points and up to 30% fewer actions, linking composability to fewer interactions.
  • About 7,000 CodeActInstruct trajectories teach interaction and self-debugging. Fine-tuned Llama-2 and Mistral agents improve agent tasks without sacrificing the general capabilities measured in the paper.
Who Should Read It

Great fit if you are choosing an action interface for tool-using agents or collecting interactive training data. Look elsewhere if you need proof that code always beats structured calls: results vary by model, the main benchmark has 82 tasks, and executing generated code requires careful sandboxing.

Information

  • Websitearxiv.org
  • OrganizationsUniversity of Illinois Urbana-Champaign, Apple
  • AuthorsXingyao Wang, Yangyi Chen, Lifan Yuan, Yizhe Zhang, Yunzhu Li, Hao Peng, Heng Ji
  • Published date2024/02/01

More Items

Lets language models move information between their context window and external storage. Memory editing, retrieval, and function chaining support conversations and document analysis beyond a single prompt's capacity.

Measures whether reusable skills improve agent task completion through paired tests. Across 87 tasks and 18 model–harness configurations, curated skills raise average pass rate by 16.6 percentage points; compact skill bundles work best.

Enforces output grammars during LLM decoding while reducing CPU validation overhead. Precomputed token masks and persistent stacks support nested formats without checking the full vocabulary at every step.