APIGen: Automated Pipeline for Generating Verifiable and Diverse Function-Calling Datasets

Zuxin Liu, Thai Hoang, Jianguo Zhang, Ming Zhu, Tian Lan, Shirley Kokane, Juntao Tan, Weiran Yao, Zhiwei Liu, Yihao Feng, Rithesh Murthy, Liangwei Yang, Silvio Savarese, Juan Carlos Niebles, Huan Wang, Shelby Heinecke, Caiming Xiong

arXiv:2406.18518 · 2026-07-27 공개 · arXiv · PDF

large-language-models benchmarking llm-training dataset-generation function-calling verifiable-data xlam-function-calling api-gen

Abstract

The advancement of function-calling agent models requires diverse, reliable, and high-quality datasets. This paper presents APIGen, an automated data generation pipeline designed to synthesize verifiable high-quality datasets for function-calling applications. We leverage APIGen and collect 3,673 executable APIs across 21 different categories to generate diverse function-calling datasets in a scalable and structured manner. Each data in our dataset is verified through three hierarchical stages: format checking, actual function executions, and semantic verification, ensuring its reliability and correctness. We demonstrate that models trained with our curated datasets, even with only 7B parameters, can achieve state-of-the-art performance on the Berkeley Function-Calling Benchmark, outperforming multiple GPT-4 models. Moreover, our 1B model achieves exceptional performance, surpassing GPT-3.5-Turbo and Claude-3 Haiku. We release a dataset containing 60,000 high-quality entries, aiming to advance the field of function-calling agent domains. The dataset is available on Huggingface: https://huggingface.co/datasets/Salesforce/xlam-function-calling-60k and the project homepage: https://apigen-pipeline.github.io/

한국어 요약

한 줄 요약

APIGen은 검증된 60,000개의 함수 호출 데이터셋을 생성하는 자동화된 파이프라인으로, 7B 파라미터 모델이 GPT-4를 능가하는 성능을 보인다.

핵심 기여도

핵심 아이디어

기존 함수 호출 데이터셋은 정적이고 검증이 부족해 실제 응용 시 한계가 있었다. APIGen은 이 문제를 해결하기 위해 데이터 생성과 검증을 자동화한 파이프라인을 제안한다. 핵심 아이디어는 **다양한 API 소스와 쿼리 스타일을 활용한 데이터 생성**, **3단계 검증 프로세스**, 그리고 **고품질 학습 데이터로 소규모 모델도 강력한 성능을 발휘하게 하는 것**이다. 특히, 병렬 함수 호출(PARALLEL) 및 병렬 다중 함수 호출(PARALLEL MULTIPLE)과 같은 복잡한 시나리오를 포함한 데이터셋은 기존 공개 데이터셋에서는 거의 찾아볼 수 없으며, 이는 모델의 실용성 향상에 기여한다.

기술적 접근법

주요 결과

의의 및 한계

APIGen은 함수 호출 에이전트 모델의 학습 데이터 생성을 자동화하고, 검증 과정을 체계화함으로써 모델의 실용성과 신뢰성을 높인다. 특히, 병렬 함수 호출과 같은 복잡한 시나리오를 포함한 데이터셋은 기존 연구에서 부족했던 부분을 보완한다. 또한, 1.3B 파라미터 모델이 GPT-3.5-Turbo를 능가한 점은 소규모 모델에서도 고성능을 달성할 수 있음을 보여준다. 그러나 APIGen이 생성한 데이터가 모든 실제 API 환경을 포괄하지 못할 수 있으며, 특정 도메인에 대한 데이터 편향이 발생할 가능성도 존재한다.

실용적 활용

APIGen은 함수 호출 에이전트를 개발하는 연구자 및 엔지니어에게 고품질 학습 데이터를 제공함으로써, 금융, 의료, SaaS 플랫폼 등 다양한 산업 분야에서의 모델 개선에 활용될 수 있다. 특히, 병렬 API 호출이 필요한 실시간 시스템 개발에 유용하며, 소규모 모델에서도 높은 성능을 달성할 수 있어 리소스 제약이 있는 환경에서의 활용도가 높다.