TOUMAII: A 4.5M-Pair Tool-Calling Preference Dataset and Its Source-Agnostic Generator

Moritz Pötzsch, Andrea Gentilini, Lisa Rossgoderer, Tom Osterfeld, Kesava Prasad Sanjivi Arul, Swanand Ravindra KadhearXiv 2026

It’s late, your IDE is full of red squiggles, and you’re wondering why your "autonomous agent" just tried to call a weather API with a city name formatted as a JSON object containing a poem. We’ve all been there. The problem isn't just that the model doesn't know the right answer; it's that it doesn't know what a wrong answer looks like until it hits a runtime error.

The researchers at TUM.ai and IBM Research just dropped TOUMAII, a massive effort to fix this "blind spot" in tool-calling models.

TL;DR

TOUMAII is a gargantuan dataset of 4.5 million "preference pairs"—examples of a perfect tool call contrasted with a plausible, model-generated failure. By releasing both the data and TOUMAII-Gen ( a pipeline to turn any standard training set into a preference dataset), the authors provide the fuel needed for Direct Preference Optimization (DPO) to teach models exactly which formatting and logic traps to avoid.

What Problem Does This Paper Address?

Most AI models are trained using Supervised Fine-Tuning (SFT). Think of this as "imitation learning": we show the model a million examples of perfect tool calls and say, "Do this."

The catch? In the world of APIs and databases, a single misplaced comma or a case-sensitivity error (like USD vs usd) renders a call useless. SFT teaches the model to aim for the bullseye, but it doesn't teach it to avoid the "near-misses" that look right but break the system.

To fix this, researchers use Direct Preference Optimization (DPO), which shows the model two options—one "Chosen" and one "Rejected"—and tells it to widen the gap between them. However, high-quality preference data for complex, multi-turn tool interactions is incredibly rare. TOUMAII fills this massive void.

Methods

The authors created TOUMAII-Gen, a source-agnostic pipeline designed to "break" existing high-quality datasets in a useful way.

  1. Source Adapters: They take existing "gold standard" datasets and convert them into a canonical format.
  2. The Generator Pool: Instead of using a massive model like GPT-4 to generate errors, they intentionally use a "pool" of smaller models (like Granite-350M or Qwen-0.6B). Why? Because small models make "natural" mistakes—the kind of hallucinations and formatting blunders that a 3B or 7B model might actually make during inference.
  3. Validation & Scoring: The pipeline compares the small model's output to the ground truth. If it's different, it becomes a "Rejected" candidate. They then use a reward function called ToolRL to score exactly how "wrong" the mistake was, ranging from "total gibberish" to "almost right but used the wrong argument name."
Overview of the TOUMAII-Gen pipeline

Datasets

  • TOUMAII: The flagship dataset containing ~4.5M validated preference pairs. It’s derived from the Toucan-1.5M corpus and covers both single-turn and complex multi-turn conversations.
  • TOUMAII-ACE: A smaller "proof of concept" dataset (~100k pairs) derived from ToolACE to show that the pipeline works on different data sources.
  • Evaluation: The models were tested on the Berkeley Function Calling Leaderboard (BFCL) v4, a rigorous benchmark for real-world tool use.

Key Insights and Ideas

  • Small Models are Better Critics: One of the "aha" moments is that using tiny models to generate the "Rejected" responses creates a more effective training signal. These models fail in ways that are subtle and realistic, which is exactly what a larger model needs to learn to avoid.
  • The "Near-Miss" Value: The dataset includes many pairs where the error is tiny (e.g., a capitalization error in a currency code). Teaching a model that usd is right and USD is wrong for a specific API is the difference between a reliable agent and a broken one.
  • Source-Agnosticism: By using a canonical format, the researchers have essentially built a "factory" where you can plug in any SFT dataset and get a DPO dataset out the other side.

Key Results

To prove the data works, the authors fine-tuned a 3-billion-parameter model (Granite-4.1-3B).

  • Performance Parity: TOUMAII achieved performance parity with (and often exceeded) other high-quality preference datasets like ToolRM.
  • Memory and Live Accuracy: On the BFCL v4 benchmark, the TOUMAII-trained model showed significant gains in "Memory" (remembering state across turns) and "Live" accuracy (interacting with real APIs).
Comparison of BFCL v4 accuracy across different training sets

As seen in the results table, the addition of TOUMAII data consistently pushed the "Overall" and "Memory" scores higher than the base model or the previous state-of-the-art (ToolRM).

Limitations and Future Work

The authors are transparent about a few gaps:

  • Irrelevance: The current dataset doesn't focus on "abstention"—teaching the model when not to call a tool.
  • Reasoning: "Thinking" traces (Chain-of-Thought) were disabled during the generation of rejected responses to keep the focus on the tool calls themselves.
  • Reference-Based: The validation relies on matching a reference answer rather than executing the code. While this makes the pipeline faster and "source-agnostic," it means it might miss cases where there are two equally valid ways to call a tool.

In short, if you're building an agent that needs to be more than just a chatbot with a "search" button, TOUMAII is the massive, high-fidelity map of the "don't go here" zones you've been looking for.

Summary updated

Abstract

To autonomously execute multi-step tasks, enterprise agents must reliably interact with tools, call APIs, or query databases, making tool-calling a fundamental capability of AI models. Supervised fine-tuning (SFT) optimises for producing the correct call, but never contrasts it with a plausible incorrect one. In an environment where even a minor formatting error can invalidate a call and an incorrect decision can derail the interaction, direct preference optimisation (DPO) targets exactly this contrast. DPO, therefore, requires preference pairs rather than plain demonstrations. For tool-calling, such data, especially in realistic multi-turn settings, remains extremely scarce. To address this scarcity, we introduce TOUMAII, a large-scale tool-calling preference dataset containing ~4.5M validated preference pairs, derived from Agent-Ark/Toucan-1.5M (apache-2.0) conversations. The dataset consists of multi- and single-turn interactions and includes parallel and sequential function calls. Additionally, we release TOUMAII-Gen, a synthetic data generation pipeline that consumes tool-calling SFT datasets and generates a preference dataset with naturally occurring model-generated tool-calling failure modes. To validate the effectiveness of our DPO data, we fine-tune a 3-billion-parameter model, achieving performance parity with other high-quality tool-calling preference datasets. Furthermore, we release a second small preference dataset derived from ToolACE (apache-2.0), showcasing the source-agnostic nature of our pipeline. We release the complete code and datasets: https://github.com/tum-ai/toumaii-gen and https://huggingface.co/collections/tum-ai/toumaii-generated-datasets
BibTeX
@misc{potzsch2026toumaii,
  author = {Moritz Pötzsch and Andrea Gentilini and Lisa Rossgoderer and Tom Osterfeld and Kesava Prasad Sanjivi Arul and Swanand Ravindra Kadhe},
  title = {{TOUMAII: A 4.5M-Pair Tool-Calling Preference Dataset and Its Source-Agnostic Generator}},
  year = {2026},
  eprint = {2611.26722},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.26722},
}
Figure