Table of Contents
Fetching ...

Unlocking Implicit Experience: Synthesizing Tool-Use Trajectories from Text

Zhihao Xu, Rumei Li, Jiahuan Li, Rongxiang Weng, Jingang Wang, Xunliang Cai, Xiting Wang

TL;DR

This paper introduces GEM, a text-based paradigm for synthesizing multi-turn tool-use trajectories directly from large-scale text corpora to mitigate data scarcity for training autonomous agents. GEM comprises a four-stage synthesis pipeline (text filtering, workflow and tool extraction, trajectory generation, and refinement) plus a validation step and a dedicated Data Synthesizer for end-to-end generation. Empirical results show substantial gains on the BFCL V3 multi-turn benchmark (e.g., up to around 16.5% improvement) and competitive performance on τ^2-bench in out-of-domain settings, demonstrating strong generalization. The Trajectory Synthesizer further reduces cost while preserving data quality, validating the feasibility of end-to-end synthesis from text and highlighting the method's potential to scale up tool-use training data across domains.

Abstract

Enabling Large Language Models (LLMs) to effectively utilize tools in multi-turn interactions is essential for building capable autonomous agents. However, acquiring diverse and realistic multi-turn tool-use data remains a significant challenge. In this work, we propose a novel text-based paradigm. We observe that textual corpora naturally contain rich, multi-step problem-solving experiences, which can serve as an untapped, scalable, and authentic data source for multi-turn tool-use tasks. Based on this insight, we introduce GEM, a data synthesis pipeline that enables the generation and extraction of multi-turn tool-use trajectories from text corpora through a four-stage process: relevance filtering, workflow & tool extraction, trajectory grounding, and complexity refinement. To reduce the computational cost, we further train a specialized Trajectory Synthesizer via supervised fine-tuning. This model distills the complex generation pipeline into an efficient, end-to-end trajectory generator. Experiments demonstrate that our GEM-32B achieve a 16.5% improvement on the BFCL V3 Multi-turn benchmark. Our models partially surpass the performance of models trained on τ - bench (Airline and Retail) in-domain data, highlighting the superior generalization capability derived from our text-based synthesis paradigm. Notably, our Trajectory Synthesizer matches the quality of the full pipeline while significantly reducing inference latency and costs.

Unlocking Implicit Experience: Synthesizing Tool-Use Trajectories from Text

TL;DR

This paper introduces GEM, a text-based paradigm for synthesizing multi-turn tool-use trajectories directly from large-scale text corpora to mitigate data scarcity for training autonomous agents. GEM comprises a four-stage synthesis pipeline (text filtering, workflow and tool extraction, trajectory generation, and refinement) plus a validation step and a dedicated Data Synthesizer for end-to-end generation. Empirical results show substantial gains on the BFCL V3 multi-turn benchmark (e.g., up to around 16.5% improvement) and competitive performance on τ^2-bench in out-of-domain settings, demonstrating strong generalization. The Trajectory Synthesizer further reduces cost while preserving data quality, validating the feasibility of end-to-end synthesis from text and highlighting the method's potential to scale up tool-use training data across domains.

Abstract

Enabling Large Language Models (LLMs) to effectively utilize tools in multi-turn interactions is essential for building capable autonomous agents. However, acquiring diverse and realistic multi-turn tool-use data remains a significant challenge. In this work, we propose a novel text-based paradigm. We observe that textual corpora naturally contain rich, multi-step problem-solving experiences, which can serve as an untapped, scalable, and authentic data source for multi-turn tool-use tasks. Based on this insight, we introduce GEM, a data synthesis pipeline that enables the generation and extraction of multi-turn tool-use trajectories from text corpora through a four-stage process: relevance filtering, workflow & tool extraction, trajectory grounding, and complexity refinement. To reduce the computational cost, we further train a specialized Trajectory Synthesizer via supervised fine-tuning. This model distills the complex generation pipeline into an efficient, end-to-end trajectory generator. Experiments demonstrate that our GEM-32B achieve a 16.5% improvement on the BFCL V3 Multi-turn benchmark. Our models partially surpass the performance of models trained on τ - bench (Airline and Retail) in-domain data, highlighting the superior generalization capability derived from our text-based synthesis paradigm. Notably, our Trajectory Synthesizer matches the quality of the full pipeline while significantly reducing inference latency and costs.
Paper Structure (37 sections, 11 figures, 5 tables)

This paper contains 37 sections, 11 figures, 5 tables.

Figures (11)

  • Figure 1: We propose the "Text to Trajectory" paradigm, instead of relying on predefined tools to generate tasks and trajectories.
  • Figure 2: Distribution of the extracted task category from raw documents, showing the diversity of tasks covered in the text corpora.
  • Figure 3: Preliminary case study.
  • Figure 4: Overall Pipeline of GEM. The first phase extracts multi-step workflows from filtered text corpora and defines corresponding tools. The second phase generates and refines trajectories, incorporating diverse behavioral patterns and rigorous validation to produce high-quality training data.
  • Figure 5: Results on $\tau^2$-bench. We report avg@4 and pass@4 metrics for Airline and Retail domains.
  • ...and 6 more figures