Agent-FLAN
收藏魔搭社区2026-01-06 更新2024-05-15 收录
下载链接:
https://modelscope.cn/datasets/AI-ModelScope/Agent-FLAN
下载链接
链接失效反馈官方服务:
资源简介:
# Agent-FLAN: Designing Data and Methods of Effective Agent Tuning for Large Language Models
This page holds the dataset proposed in Agent-FLAN, which consists of AgentInstruct, Toolbench, and customized negative agent samples as its source datasets.
## ✨ Introduction
[[🤗 HuggingFace](https://huggingface.co/internlm/Agent-FLAN-7b)]
[[📃 Paper](https://arxiv.org/abs/2403.12881)]
[[🌐 Project Page](https://internlm.github.io/Agent-FLAN/)]
> Open-sourced Large Language Models (LLMs) have achieved great success in various NLP tasks, however, they are still far inferior to API-based models when acting as agents. How to integrate agent ability into general LLMs becomes a crucial and urgent problem. This paper first delivers three key observations: (1) the current agent training corpus is entangled with both formats following and agent reasoning, which significantly shifts from the distribution of its pre-training data; (2) LLMs exhibit different learning speeds on the capabilities required by agent tasks; and (3) current approaches have side-effects when improving agent abilities by introducing hallucinations. Based on the above findings, we propose Agent-FLAN to effectively Fine-tune LANguage models for Agents. Through careful decomposition and redesign of the training corpus, Agent-FLAN enables Llama2-7B to outperform prior best works by 3.5% across various agent evaluation datasets. With comprehensively constructed negative samples, Agent-FLAN greatly alleviates the hallucination issues based on our established evaluation benchmark. Besides, it consistently improves the agent capability of LLMs when scaling model sizes while slightly enhancing the general capability of LLMs.
## ♟️ Agent-FLAN
Agent-FLAN series are finetuned on AgentInstruct and Toolbench by applying the data generation pipeline proposed in Agent-FLAN paper, which holds strong abilities on various agent tasks and tool utilization~
### 🤗 HuggingFace Dataset
Agent-FLAN is produced by mixed training on AgentInstruct, ToolBench, and ShareGPT datasets from the Llama2-chat series.
The models follow the conversation format of Llama-2-chat, with the template protocol as:
```python
dict(role='user', begin='<|Human|>െ', end='\n '),
dict(role='system', begin='<|Human|>െ', end='\n '),
dict(role='assistant', begin='<|Assistant|>െ', end='ി\n '),
```
## ❤️ Acknowledgements
Agent-FLAN is built with [Lagent](https://github.com/InternLM/lagent) and [T-Eval](https://github.com/open-compass/t-eval). Thanks for their awesome work!
## 🖊️ Citation
If you find this project useful in your research, please consider citing:
```
@article{chen2024agent,
title={Agent-FLAN: Designing Data and Methods of Effective Agent Tuning for Large Language Models},
author={Chen, Zehui and Liu, Kuikun and Wang, Qiuchen and Liu, Jiangning and Zhang, Wenwei and Lin, Dahua and Chen, Kai and Zhao, Feng},
journal={arXiv preprint arXiv:2403.12881},
year={2024}
}
```
## 💳 License
This project is released under the Apache 2.0 [license](./LICENSE).
# Agent-FLAN:面向大语言模型的高效智能体微调的数据与方法设计
本页面收录了Agent-FLAN论文中提出的数据集,其源数据集包括AgentInstruct、Toolbench以及定制化负向智能体样本。
## ✨ 简介
[[🤗 HuggingFace](https://huggingface.co/internlm/Agent-FLAN-7b)]
[[📃 论文](https://arxiv.org/abs/2403.12881)]
[[🌐 项目主页](https://internlm.github.io/Agent-FLAN/)]
> 开源大语言模型(Large Language Model, LLM)在各类自然语言处理(Natural Language Processing, NLP)任务中已取得显著进展,但作为智能体(Agent)时仍远落后于基于API的模型。如何将智能体能力融入通用大语言模型,成为一项至关重要且亟待解决的问题。本文首先提出三项关键观察结论:(1) 当前智能体训练语料同时混杂了格式遵循与智能体推理两类内容,其分布与预训练数据的分布存在显著偏移;(2) 大语言模型在智能体任务所需的各项能力上学习速度存在差异;(3) 现有通过引入幻觉(hallucination)来提升智能体能力的方法存在副作用。基于上述发现,我们提出Agent-FLAN方法,以实现面向智能体的语言模型高效微调。通过对训练语料库的精心分解与重新设计,Agent-FLAN使得Llama2-7B模型在各类智能体评估数据集上的表现超越此前最优成果3.5%。借助全面构建的负向样本,Agent-FLAN在我们搭建的评估基准上极大缓解了幻觉问题。此外,在扩展模型规模时,该方法能够持续提升大语言模型的智能体能力,同时小幅增强其通用能力。
## ♟️ Agent-FLAN
Agent-FLAN系列模型基于AgentInstruct与Toolbench数据集,结合Agent-FLAN论文中提出的数据生成流水线进行微调,在各类智能体任务与工具使用场景中具备优异性能~
### 🤗 HuggingFace 数据集
Agent-FLAN基于Llama2-chat系列模型,通过混合训练AgentInstruct、ToolBench与ShareGPT数据集生成。
该模型遵循Llama-2-chat的对话格式,模板协议如下:
python
dict(role='user', begin='<|Human|>െ', end='\n '),
dict(role='system', begin='<|Human|>െ', end='\n '),
dict(role='assistant', begin='<|Assistant|>െ', end='ി\n '),
## ❤️ 致谢
Agent-FLAN项目基于[Lagent](https://github.com/InternLM/lagent)与[T-Eval](https://github.com/open-compass/t-eval)开发,感谢二者的出色工作!
## 🖊️ 引用
若您在研究中使用本项目,请引用以下文献:
@article{chen2024agent,
title={Agent-FLAN: Designing Data and Methods of Effective Agent Tuning for Large Language Models},
author={Chen, Zehui and Liu, Kuikun and Wang, Qiuchen and Liu, Jiangning and Zhang, Wenwei and Lin, Dahua and Chen, Kai and Zhao, Feng},
journal={arXiv preprint arXiv:2403.12881},
year={2024}
}
## 💳 许可证
本项目采用Apache 2.0[许可证](./LICENSE)发布。
提供机构:
maas
创建时间:
2024-04-25



