Linguistic and Argument Diversity in Synthetic Data for Function-Calling Agents

arXiv:2601.17829 · cs.CL, cs.AI · Submitted 2026-01-25 · Read on arXiv

Listen

Radio episode about this paper

Transcript

Introduction to the show: ident: AI Radio. Generated commentary on the latest Artificial Intelligence papers.

Tom: We're looking at the paper: "Linguistic and Argument Diversity in Synthetic Data for Function-Calling Agents".

Paper summary: Tom: So, to recap this paper called "Linguistic and Argument Diversity in Synthetic Data for Function-Calling Agents," the main thesis is that prior work on function calling agents has focused too much on just making sure the functions themselves are diverse or how they are invoked >

Jane: Right, but they argue that linguistic diversity in those requests and coverage of arguments, like things like city names or stock tickers, remains underexplored in the field >

Tom: The paper proposes a method that generates synthetic datasets by optimizing general purpose diversity metrics across both the user queries and their arguments without needing any hand crafted rules or taxonomies for this diversity >

Lu: Their core contribution is a novel component that automatically generates a diverse collection of items by optimizing simple, general purpose diversity metrics, which makes the approach robust to new domains because it adapts to them automatically >

Meng: It claims they demonstrate effectiveness through both intrinsic and extrinsic testing when compared against state of the art data generation methods, showing superiority in diversity while keeping correctness comparable >

Tom: Plus they show a direct link between this increased diversity and superior model performance when fine tuned on this synthetic data, specifically noting an accuracy increase of roughly seven point four percent on the BFCL benchmark compared to similar counterparts >

Jane: So why does this matter for the field? It suggests that incorporating richer linguistic variation—things like lexical richness, syntactic complexity, and semantic framing—into training data is essential for building agents that can handle complex, real world requests effectively >

Conclusion: Tom: So looking at this whole paper, "Linguistic and Argument Diversity in Synthetic Data for Function-Calling Agents," the authors are arguing that we need to move beyond just increasing the number of functions available >

Jane: Right, they are pushing for a focus on how varied those functions can be requested through language and arguments simultaneously in the training data >

Tom: Essentially, they're proposing a way to generate this diverse data automatically by optimizing general purpose diversity metrics instead of relying on hand crafted rules or taxonomies >

Lu: The implication is that we can build more versatile agents because they are trained on a dataset that handles new domains without needing us to manually write new rules for each one >

Meng: For deployment, this means we might spend less time writing specific prompts and more time refining the diversity metrics themselves to ensure the generated data is useful >

Tom: It’s about moving toward a system that can automatically create the variation we need for robust function calling agents to handle real world complexity >

Technion Institute of Industrial and Technological Research Institute of Israel

cs.CL, cs.AI

Submitted: 2026-01-25

Updated: 2026-11-24

Project page: http://profile.example.jp/usershttp://example.com

License: http://creativecommons.org/licenses/by/4.0/

Importance score: 100/100

The gist: The construction of high-quality, diverse data remains a major challenge for training function-calling agents…

Key concepts

General-Purpose Diversity Metrics
These are simple mathematical measures used to assess how varied a set of data is without needing specific rules for every function. They are applied across both the user's question (query) and the specific details provided to the function (arguments), ensuring broad coverage.
Greedy Generation Procedure
This is an iterative process for creating diverse data. In each round, the system generates potential new items based on a diversity score, filters out any invalid ones using a set of rules, and adds the best candidates to the existing collection until the desired amount of diverse examples is reached.
Reciprocal Rank Fusion (RRF)
RRF is a technique used to combine different diversity scores from various sources. It helps create one comprehensive diversity score by intelligently merging metrics that measure different aspects of text, such as word variety and sentence structure, into a single, robust evaluation.
Out-of-Distribution (OOD) Performance
This refers to how well a model performs on tasks or data it hasn't seen during training. The paper shows that using this diverse synthetic data significantly improves the model's ability to handle new, unseen requests, leading to better real-world performance.

Terminology

Summary

The construction of high-quality, diverse data remains a major challenge for training function-calling agents, with existing work often focusing on function diversity or invocation patterns while neglecting linguistic variation in requests and argument coverage (e. p. 0

Where the paper says it

A major challenge for this task is obtaining high quality diverse data for training. Prior work emphasizes diversity in functions, invocation patterns, and interaction turns, yet linguistic diversity of requests and coverage of arguments (e.

g., city names or stock tickers). p. 5
Where the paper says it

Both metrics take as input a set of argument values of the same type (e. , city names) and output a diversity score.

This paper addresses this gap by proposing a novel method to generate synthetic datasets that optimizes general-purpose diversity metrics across both user queries and their arguments without relying on hand-crafted rules or taxonomies. p. 0
Where the paper says it

, city_name, stock_ticker) remain underexplored. We propose a method that generates synthetic datasets via optimizing generalpurpose diversity metrics across both queries and arguments, without relying on hand-crafted rules or taxonomies, making it robust to different usecases.

The core contribution is a technique that automatically generates diverse items by optimizing simple, general-purpose diversity metrics, making the approach robust to new domains. p. 1
Where the paper says it

Instead, it automatically generates items by optimizing simple, general-purpose diversity metrics. A key advantage of this approach is its robustness to new domains and settings, as by definition, it adapts to them automatically.

The generation process involves a greedy procedure for diverse item creation. p. 3

Where the paper says it

1 Diverse Generation Our core component is a greedy procedure for diverse generation of items. The input to the procedure is (1) instructions I for what consists as a valid item, (2) examples of existing items E, (3) diversity contribution metric D, and (4) an automated filtering process F to eliminate invalid items.

This procedure operates in rounds: it takes instructions defining a valid item, examples of existing items, a diversity contribution metric (D), and an automated filtering process (F) to eliminate invalid items. p. 3
Where the paper says it

The input to the procedure is (1) instructions I for what consists as a valid item, (2) examples of existing items E, (3) diversity contribution metric D, and (4) an automated filtering process F to eliminate invalid items. The procedure operates in rounds.

In each round, candidate items are generated; the top b candidates based on D, after filtering by F, are added to the existing set of examples (E), allowing for iterative generation. p. 3
Where the paper says it

Vendi score (Friedman and Dieng, 2023)) is applied to a set, rather than an individual item; given such a set-metric, we define for a candidate item c and an existing set of chosen items E, D(c; E) = D˜(E ∪ {c}) − D˜(E), its marginal contribution to the diversity score (when E is clear from context we write D(c)). In round 1 we ask the LLM to generate candidates different than those in E (or a subsample of E if the set is too large), by constructing a prompt from I and E.

The process is structured into three main parts:

  1. Preprocessing: An embedding model generates a representative vector for each parameter (per function). Cosine similarity is used to identify semantically similar parameters, clustering them together (e. p. 3

    Where the paper says it

    We use cosine similarity to identify similar parameters, and cluster together all parameters of2 cos(E(p1), E(p2)) ≥ 0. Note that we have considered more sophisticated clustering methods such an agglomerative clustering algorithm3 but they yielded similar results.

    g., grouping 'city name' and 'file path').

  2. Response Generation: The system first selects a random function and then applies the diverse generation method to select argument values for its parameters. Value selection instructions detail the function definition and previously chosen parameter values to prevent mismatches (e. p. 4

    Where the paper says it

    build instructions (recall I) detailing the function and parameter definition and already chosen values for other parameters (to avoid mismatching values, e. , end-time earlier than start-time).

    g., ensuring an end-time is later than a start-time). p. 4
    Where the paper says it

    build instructions (recall I) detailing the function and parameter definition and already chosen values for other parameters (to avoid mismatching values, e. , end-time earlier than start-time).

  3. Request Generation: Given the required response, this stage generates a matching user request by applying the diverse generation method to create variations in query shape, including semantic, lexical, and syntactic properties. The diversity score D(c; E) combines several known metrics capturing lexical, semantic, and syntactic diversity (such as TTR—Type-Token Ratio—and Compression Ratio Diversity), which are fused using Reciprocal Rank Fusion (RRF) to create a comprehensive score for each candidate. p. 5

    Where the paper says it

    During generation, argument values are optimized using the Cluster Entropy metric §3, which measures the entropy of cluster assignments. Linguistic diversity is optimized using a set of lexical, syntactic, and semantic metrics: Type–Token Ratio (TTR) and Compression Ratio (lexical); Variance of FKGL (lexical/syntactic); Parse Tree Entropy and Variance of Text Length (syntactic); and Paraphrase Variety, Chamfer Distance Score, and Vendi Score (semantic).

    A tailored prompt filters out unrealistic or mismatched requests. p. 4
    Where the paper says it

    We merge these rankings using Reciprocal Rank Fusion (RRF)6 to fuse the rankings, and use the resulting rank as the score for each candidate. Filtering is done via a tailored prompt aimed to avoid both unrealistic requests and requests not matching the intended response.

The evaluation confirms the efficacy of this approach across multiple dimensions. p. 5

Where the paper says it

4 Analysis In this section, we analyze the diversification benefits of our approach in comparison to recently published methods for function-calling data generation. We evaluate diversity using multiple metrics that capture both linguistic variation and argument diversity.

Empirically, when compared against state-of-the-art data generation methods like ToolAce and APIGen, the proposed dataset exhibits substantially higher diversity scores across nearly all metrics—both linguistic (measured by metrics like TTR, Parse Tree Entropy) and argument (measured by NCD Diversity and Cluster Entropy). p. 5
Where the paper says it

During generation, argument values are optimized using the Cluster Entropy metric §3, which measures the entropy of cluster assignments. Linguistic diversity is optimized using a set of lexical, syntactic, and semantic metrics: Type–Token Ratio (TTR) and Compression Ratio (lexical); Variance of FKGL (lexical/syntactic); Parse Tree Entropy and Variance of Text Length (syntactic); and Paraphrase Variety, Chamfer Distance Score, and Vendi Score (semantic).

Crucially, this increased diversity translates directly into superior downstream model performance. p. 7
Where the paper says it

We proposed a data generation technique, relying on a novel component generating diverse values, and evaluated the outcome of this process in the scenario of general purpose functions. Our evaluations demonstrate the utility of our methods, both directly via achieving superior diversity scores, according to standard metrics, and via its downstream impact, showing superior OOD performance of models trained on our data (roughly 4% − 7% accuracy improvement).

When fine-tuned on this synthetic data, the resulting models demonstrate significant improvements in out-of-distribution (OOD) performance; specifically, accuracy gains of roughly 4% to 7% are observed on benchmarks like BFCL when compared to models trained on baseline datasets. p. 7
Where the paper says it

We proposed a data generation technique, relying on a novel component generating diverse values, and evaluated the outcome of this process in the scenario of general purpose functions. Our evaluations demonstrate the utility of our methods, both directly via achieving superior diversity scores, according to standard metrics, and via its downstream impact, showing superior OOD performance of models trained on our data (roughly 4% − 7% accuracy improvement).

The findings strongly suggest that incorporating richer linguistic variation—including lexical richness, syntactic complexity, and semantic framing—into training data is essential for building robust and versatile function-calling agents capable of handling complex, real-world requests effectively.

Green — the paper says it, and the page is printed. Red — no passage carries it, so treat that sentence as unverified. The same check runs on your own text: check a summary against its source, $5.

Improvements for AI systems

  1. Data Generation Optimization for Diversity: The method generates synthetic datasets by optimizing generalpurpose diversity metrics across both queries and arguments, without relying on hand-crafted rules or taxonomies, which makes it robust to different usecases. This allows the AI system to create diverse training data without needing manual rules for linguistic or argument variety.

  2. Enhanced Out-of-Distribution Performance: The technique leads to superior performance compared to analogous models based on the baseline data generation methods in out-of-distribution performance, achieving a 7.4% increase in accuracy on the BFCL benchmark. This means the resulting AI model will generalize significantly better when faced with unseen inputs or domains.

  3. Multi-faceted Diversity Measurement: The system employs a comprehensive set of metrics, including lexical, syntactic, semantic, and readability diversity measures like Type-Token Ratio (TTR), Parse Tree Entropy, and Vendi Score across query dimensions. This allows the AI to produce queries that are not only diverse but also cover varied linguistic styles and structural complexities.

  4. Context-Aware Sequential Generation: For sequential calls, the system generates parameters by prioritizing context cohesion, using a System Prompt that instructs the model to generate parameters logically related to: (1) the return value this API will produce (highest priority), (2) parameters of the next API in the chain. This ensures generated parameter values maintain validity across chained function calls.

  5. Distractor Selection for Robustness: The system uses a process where it retrieves and scores candidate APIs as distractors based on relevance to a query, using an Elbow Method Filtering to select candidates up to the cutoff point. This helps train the AI model to distinguish between valid and invalid API calls, improving its ability to handle complex, real-world scenarios.

Abstract

The construction of function calling agents has emerged as a promising avenue for extending model capabilities. A major challenge for this task is obtaining high quality diverse data for training. Prior work emphasizes diversity in functions, invocation patterns, and interaction turns, yet linguistic diversity of requests and coverage of arguments (e.g., city_name, stock_ticker) remain underexplored. We propose a method that generates synthetic datasets via optimizing general-purpose diversity metrics across both queries and arguments, without relying on hand-crafted rules or taxonomies, making it robust to different usecases. We demonstrate the effectiveness of our technique via both intrinsic and extrinsic testing, comparing it to SoTA data generation methods. We show a superiority over baselines in terms of diversity, while keeping comparable correctness. Additionally, when used as a training set, the model resulting from our dataset exhibits superior performance compared to analogous models based on the baseline data generation methods in out-of-distribution performance. In particular, we achieve an 7.4% increase in accuracy on the BFCL benchmark compared to similar counterparts.

Sources

Related papers