超智能体:自我指涉、自我改进的智能体
HyperAgents: Self-referential self-improving agents

原始链接: https://github.com/facebookresearch/hyperagents

该仓库实现了“超智能体”,这是一个使用基础模型(OpenAI、Anthropic、Gemini)进行自主智能体交互和进化的实验框架。 **开始使用:** 1. **设置:** 安装依赖项(Python 3.12、Graphviz等)并创建虚拟环境。需要基础模型的API密钥,并应将其存储在`.env`文件中。 2. **构建和运行:** 构建Docker容器并使用`setup_initial.sh`初始化智能体。使用`generate_loop.py`运行实验,指定所需的``。 3. **分析:** 结果保存到`outputs/`目录,可能为需要使用`zip`和`unzip`解压的多部分ZIP压缩文件。 代码组织在`agent/`、`analysis/`、`domains/`和`utils/`目录中。关键脚本包括`run_meta_agent.py`、`meta_agent.py`和`task_agent.py`。 **重要安全提示:** 该项目执行模型生成的代码,并具有固有的安全风险。用户在使用该仓库时,应知晓并接受这些风险。对于觉得该项目有用的用户,提供引用信息。

## 超智能体:自我改进的AI 一种名为“超智能体”的AI自我改进新方法正在Hacker News上受到关注。由Facebook Research开发,超智能体旨在克服现有自我改进系统在预定义改进机制上的局限性。 核心思想是将一个“任务智能体”(解决特定问题)和一个“元智能体”(修改自身*和*任务智能体)结合到一个可编辑的程序中。这允许进行*元认知*自我修改——改进的不仅仅是性能,而是改进过程本身。 基于达尔文哥德尔机器(DGM),DGM-超智能体在各个领域展现出优于先前自我改进AI的性能。值得注意的是,这些改进不仅限于初始任务;对改进*过程*的增强可以迁移到不同的问题,并随着时间的推移而累积。这表明了一条通往能够不断完善自身学习和解决问题能力的AI系统的道路。 相关的项目Pi也展示了自我修改的能力。
相关文章

原文
# API keys, put these into .env file
OPENAI_API_KEY=...
ANTHROPIC_API_KEY=...
GEMINI_API_KEY=...
# Install things
sudo dnf install -y python3.12-devel
sudo dnf install -y graphviz graphviz-devel cmake ninja-build bzip2-devel zlib-devel ncurses-devel libffi-devel
# Create virtual environment
python3.12 -m venv venv_nat
source venv_nat/bin/activate
pip install -r requirements.txt
pip install -r requirements_dev.txt
# To build the docker container
docker build --network=host -t hyperagents .
# Setup initial agents
bash ./setup_initial.sh
# See the script for args, and baseline selections
python generate_loop.py --domains <domain>

By default, outputs will be saved in outputs/ directory.

  • agent/ code for using foundation models
  • analysis/ scripts used for plotting and analysis
  • domains/ code for each domain
  • utils/ common code used in the repo
  • run_meta_agent.py script to help run the meta agent and get the diffs
  • meta_agent.py main implementation of the meta agent
  • task_agent.py main implementation of the task agent
  • generate_loop.py entry point for running the algorithm

The experiment logs are stored as a multi-part ZIP archive. To extract them, ensure all .z01, .z02, etc., files are in the same directory as the .zip file, then run:

zip -s 0 outputs_os_parts.zip --out unsplit_logs.zip
unzip unsplit_outputs.zip

Warning

This repository involves executing untrusted, model-generated code. We strongly advise users to be aware of the associated safety risks. While it is highly unlikely that such code will perform overtly malicious actions under our current settings and with the models we use, it may still behave destructively due to limitations in model capability or alignment. By using this repository, you acknowledge and accept these risks.

If you find this project useful, please consider citing:

@misc{zhang2026hyperagents,
      title={Hyperagents}, 
      author={Jenny Zhang and Bingchen Zhao and Wannan Yang and Jakob Foerster and Jeff Clune and Minqi Jiang and Sam Devlin and Tatiana Shavrina},
      year={2026},
      eprint={2603.19461},
      archivePrefix={arXiv},
      primaryClass={cs.AI},
      url={https://arxiv.org/abs/2603.19461}, 
}
联系我们 contact @ memedata.com