EARDataset
收藏EARBench: Benchmarking Physical Risk Awareness of Embodied AI Agents
概述
EARBench 是首个专门为具身人工智能(EAI)场景设计的自动化物理风险评估框架。该框架通过利用基础模型的多智能体协作系统,解决了在物理环境中部署 AI 代理的关键安全问题。框架包括四个关键组件:
- 安全指南生成模块:使用大型语言模型(LLMs)创建 EAI 特定的安全指南。
- 风险场景生成模块:生成包含场景信息和任务指令的详细测试用例。
- 具身任务规划模块:模拟 EAI 代理生成高级计划。
- 计划评估模块:评估计划的既定安全性和有效性。
EARBench 还引入了 EARDataset,这是一个包含多个测试用例的综合数据集,涵盖 7 个领域和 28 个不同场景。数据集和框架共同为评估和改进 EAI 系统在多样物理环境中的安全性提供了坚实基础。
快速开始
安装
bash git clone https://github.com/zihao-ai/EARBench.git cd EARBench pip install -r requirements.txt
下载数据集
从 Google Drive 或 Hugging Face 下载 EARDataset 的图像并解压/重命名。数据集结构应如下:
EARDataset
- images
- <scene>
- <image_path>
- <scene>
- dataset.csv
评估
可以使用 OpenAI API 在 EARDataset 上快速评估任何基于 LLM 的 EAI 代理。评估结果将保存在 results 文件夹中。
bash
python evaluate.py --model <model> --api_key <api_key> --api_url <api_url>
创建自己的测试用例
安全提示生成
bash python safety_tip_generation.py --scene <scene> --output_dir <output_dir>
风险场景生成
bash python scene_generation.py --scene <scene> --safety_tip <safety_tip> --explanation <explanation>
场景图像生成
生成文本到图像模型的提示: bash python text2image_prompt_generation.py --scene <scene> --output_dir <output_dir>
生成图像: bash python scene_image_generation.py --prompt <prompt> --output <output>
评估图像: bash python image_judger.py --scene <scene> --img_path <img_path> --text_observation <text_observation>
文本观察生成
bash python text_observation_generation.py --scene <scene> --objects <objects> --object_positions <object_positions> --object_attributes <object_attributes>
引用
如果发现我们的工作有帮助,请引用: bibtex @article{zhu2024EARBench, title={EARBench: Towards Evaluating Physical Risk Awareness for Task Planning of Foundation Model-based Embodied AI Agents}, author={Zhu, Zihao and Wu, Bingzhe and Zhang, Zhengyou and Han, Lei and Liu, Qingshan and Wu, Baoyuan}, journal={arXiv preprint arXiv:2408.04449}, year={2024} }




