Agentes de Modelos de Linguagem de Auto-desafio
Self-Challenging Language Model Agents
June 2, 2025
Autores: Yifei Zhou, Sergey Levine, Jason Weston, Xian Li, Sainbayar Sukhbaatar
cs.AI
Resumo
Modelos de linguagem de grande escala estão rapidamente se tornando a base para agentes inteligentes capazes de utilizar ferramentas. No entanto, treinar esses agentes é desafiador, pois requer a criação e anotação humana de um conjunto diversificado de tarefas, ferramentas e critérios de avaliação. Neste artigo, propomos o framework Self-Challenging para treinar um agente em tarefas de alta qualidade geradas por ele mesmo. O agente primeiro assume o papel de desafiador e gera uma tarefa após interagir com as ferramentas fornecidas. As tarefas assumem a forma de uma nova classe geral de problemas denominada Code-as-Task, que são definidos por uma instrução, uma função de verificação e casos de solução e falha que servem como testes, permitindo filtrar apenas tarefas de alta qualidade. O agente então assume o papel de executor e treina nessas tarefas com aprendizado por reforço, utilizando o feedback de avaliação como recompensa. A avaliação em dois benchmarks existentes de agentes que utilizam ferramentas em múltiplas interações, M3ToolEval e TauBench, mostra que o framework Self-Challenging alcança uma melhoria de mais de duas vezes no modelo Llama-3.1-8B-Instruct, apesar de usar apenas dados de treinamento autogerados.
English
Large language models are quickly becoming the foundation for intelligent
agents that are capable of using tools. However, training such agents is
challenging because it requires human creation and annotation of a diverse set
of tasks, tools, and evaluation criteria. In this paper, we propose the
Self-Challenging framework for training an agent on high-quality tasks that are
generated by itself. The agent first plays the role of challenger and generates
a task after interacting with the given tools. The tasks take the form of a
novel general class of problems termed Code-as-Task, which are defined by an
instruction, a verification function and solution and failure cases which serve
as tests, allowing to filter only for high-quality tasks. The agent then takes
an executor role and trains on those tasks with reinforcement learning using
the evaluation feedback as a reward. Evaluation on two existing multi-turn
tool-use agent benchmarks, M3ToolEval and TauBench, shows the Self-Challenging
framework achieves over a two-fold improvement in Llama-3.1-8B-Instruct,
despite using only self-generated training data.