开源项目 GitHub Topic ai 2026-07-06T12:02 正文 ok 1643 words

📦 NousResearch/hermes-agent:与你共同成长的AI代理

英文标题:📦 NousResearch/hermes-agent

Nous Research 发布了自我改进的 AI 代理 hermes-agent,拥有内置学习循环,能从经验中自动创建和改进技能,跨会话记忆和用户建模。该项目支持在 $5 VPS 到 GPU 集群上运行,提供终端 TUI 和 Telegram、Discord 等消息平台网关,无需代码改动即可切换任何模型。它通过 Nous Portal 聚合了 300+ 模型和工具网关,并具备定时任务、子代理并行等特性,对开发者和终端用户完全开源。
打开原文相关 6.3 · 机会 4
media12.0 KB media668 B media2.3 KB media595 B media623 B media579 B media579 B media590 B media69.5 KB

中文

Hermes Agent

Hermes Agent | Hermes Desktop

文档 Discord 许可证: MIT 由 Nous Research 构建 中文 اردو Español

由 Nous Research 打造的自我改进型 AI 代理。 它是唯一一个内置学习循环的代理——它从经验中创建技能,在使用中改进技能,自我提醒以持久化知识,搜索自己过去的对话,并在多个会话间构建关于你的深入模型。你可以在 $5 VPS、GPU 集群或空闲时几乎零成本的 serverless 基础设施上运行它。它不局限于你的笔记本——当它运行在云端虚拟机时,你可以通过 Telegram 与它对话。

使用任何你想要的模型——Nous Portal、OpenRouter、OpenAI、你自己部署的端点,以及更多其他。用 hermes model 切换——无需代码改动,无锁定。

真正的终端界面 全功能 TUI,支持多行编辑、斜杠命令自动补全、对话历史、中断重定向和流式工具输出。
与你同在的平台 Telegram、Discord、Slack、WhatsApp、Signal 和 CLI——全部通过单一的网关进程。语音备忘录转录、跨平台对话连续性。
闭环学习系统 代理维护的记忆并定期自我提示。复杂任务后自动创建技能。技能在使用中自我改良。FTS5 会话搜索与 LLM 摘要实现跨会话回忆。Honcho 辩证用户建模。兼容 agentskills.io 开放标准。
定时自动化 内置 cron 调度器,可投递到任何平台。日报、夜间备份、每周审计——全部用自然语言描述,无人值守运行。
委派与并行 生成隔离的子代理处理并行工作流。编写 Python 脚本通过 RPC 调用工具,将多步流水线折叠为零上下文成本的轮次。
随处运行,不止笔记本 六种终端后端——本地、Docker、SSH、Singularity、Modal 和 Daytona。Daytona 和 Modal 提供 serverless 持久化——你的代理环境空闲时休眠,按需唤醒,会话间成本几乎为零。在 $5 VPS 或 GPU 集群上运行。
面向研究准备 批量轨迹生成、轨迹压缩,用于训练下一代工具调用模型。

Linux、macOS、WSL2、Termux

curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash

Windows(原生,PowerShell)

注意: 原生 Windows 可不依赖 WSL 运行 Hermes——CLI、网关、TUI 和工具全部原生工作。如果你更想用 WSL2,上面的 Linux/macOS 一行命令同样适用。发现 bug?请提交 issue。

在 PowerShell 中运行:

iex (irm https://hermes-agent.nousresearch.com/install.ps1)

安装程序处理一切:uv、Python 3.11、Node.js、ripgrep、ffmpeg,以及一个便携式 Git Bash(MinGit,解压到 %LOCALAPPDATA%\hermes\git——无需管理员权限,与任何系统 Git 安装完全隔离)。Hermes 使用这个捆绑的 Git Bash 运行 shell 命令。

如果你已经安装了 Git,安装程序会检测到并使用它。否则,只需一个约 45MB 的 MinGit 下载——不会触碰或干扰任何系统 Git。

Android / Termux: 经过测试的手动步骤记录在 Termux 指南中。在 Termux 上,Hermes 安装精选的 .[termux] 额外依赖,因为完整的 .[all] 额外依赖当前会拉入不兼容 Android 的语音依赖。

Windows: 原生 Windows 完全支持——上面的 PowerShell 一行命令安装一切。如果你更想用 WSL2,Linux 命令同样适用。原生 Windows 安装位于 %LOCALAPPDATA%\hermes;WSL2 安装与 Linux 一样在 ~/.hermes。

安装后:

source ~/.bashrc # 重新加载 shell(或:source ~/.zshrc) hermes # 开始聊天!

Windows Defender 或杀毒软件将 uv.exe 标记为恶意软件

如果你的杀毒软件(Bitdefender、Windows Defender 等)隔离了 Hermes bin 文件夹中的 uv.exe(%LOCALAPPDATA%\hermes\bin\uv.exe),这是误报。该文件是 Astral 的 uv——Hermes 捆绑的 Rust Python 包管理器,用于管理其 Python 环境。基于机器学习的杀毒引擎通常会标记签名未知的 Rust 二进制文件(它们会下载安装包)。

验证你的副本是正版的:

如果需要,安装 GitHub CLI

winget install --id GitHub.cli

登录 GitHub

gh auth login

运行验证

$uv = "$env:LOCALAPPDATA\hermes\bin\uv.exe" $ver = (& $uv --version).Split(' ')[1] [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 $zip = "$env:TEMP\uv.zip" Invoke-WebRequest "https://github.com/astral-sh/uv/releases/download/$ver/uv-x86_64-pc-windows-msvc.zip" -OutFile $zip -UseBasicParsing gh attestation verify $zip --repo astral-sh/uv Expand-Archive $zip "$env:TEMP\uv_x" -Force (Get-FileHash "$env:TEMP\uv_x\uv.exe").Hash -eq (Get-FileHash $uv).Hash

如果 attestation 显示“验证成功”且最后一行打印 True,就没问题。

将 Hermes 加入白名单:

  • Windows Defender: 以管理员身份运行 PowerShell → Add-MpPreference -ExclusionPath "$env:LOCALAPPDATA\hermes\bin"
  • Bitdefender: 在 Bitdefender 控制台添加例外(保护 > 防病毒 > 设置 > 管理例外)
  • 白名单文件夹,而不是文件哈希——Hermes 更新 uv 后哈希每次都会变化

更多背景信息,请参见上游 Astral 报告:astral-sh/uv#13553、astral-sh/uv#15011、astral-sh/uv#10079。


hermes # 交互式 CLI——开始对话 hermes model # 选择你的 LLM 提供商和模型 hermes tools # 配置启用哪些工具 hermes config set # 设置单独的配置值 hermes gateway # 启动消息网关(Telegram、Discord 等) hermes setup # 运行完整设置向导(一次性配置所有) hermes claw migrate # 从 OpenClaw 迁移(如果你来自 OpenClaw) hermes update # 更新到最新版本 hermes doctor # 诊断问题

📖 完整文档 →


跳过 API-key 收集——Nous Portal

Hermes 可以使用任何你想要的提供商——这点不会变。但如果你不想为模型、网页搜索、图像生成、TTS 和云浏览器分别获取五个不同的 API 密钥,Nous Portal 通过一个订阅覆盖了所有这些:

  • 300+ 模型——用 /model <name> 选择任何一个
  • 工具网关——网页搜索(Firecrawl)、图像生成(FAL)、文本转语音(OpenAI)、云浏览器(Browser Use),全部通过你的订阅路由。无需额外账号。

全新安装后一条命令:

hermes portal login

这会通过 OAuth 登录,将 Nous 设为你默认的提供商,并启用工具网关。随时用 hermes portal info 查看连接状况。详细信息见工具网关文档页。

你仍然可以在任何时候为单个工具提供自己的密钥——网关是按后端配置的,而非全有或全无。


CLI 与消息快速对照

Hermes 有两个入口:用 hermes 启动终端 UI,或运行网关并通过 Telegram、Discord、Slack、WhatsApp、Signal 或 Email 与之对话。进入对话后,许多斜杠命令在两个界面中通用。

操作 CLI 消息平台
开始对话 hermes 运行 hermes gateway setup + hermes gateway start,然后向 bot 发消息
开始新对话 /new 或 /reset /new 或 /reset
切换模型 /model [provider:model] /model [provider:model]
设置个性 /personality [name] /personality [name]
重试或撤销上一轮 /retry、/undo /retry、/undo
压缩上下文 / 查看用量 /compress、/usage、/insights [--days N] /compress、/usage、/insights [days]
浏览技能 /skills 或 /<skill-name> /<skill-name>
中断当前工作 Ctrl+C 或发送新消息 /stop 或发送新消息
平台特定状态 /platforms /status、/sethome

完整的命令列表,请参阅 CLI 指南 和消息网关指南。


所有文档位于 hermes-agent.nousresearch.com/docs:

章节 涵盖内容
快速入门 安装 → 设置 → 2 分钟内开始第一次对话
CLI 使用 命令、快捷键、个性、会话
配置 配置文件、提供商、模型、所有选项
消息网关 Telegram、Discord、Slack、WhatsApp、Signal、Home Assistant
安全 命令审批、私信配对、容器隔离
工具与工具集 40+ 工具,工具集系统,终端后端
技能系统 程序性记忆,技能中心,创建技能
记忆 持久化记忆,用户画像,最佳实践
MCP 集成 连接任何 MCP 服务器以扩展能力
Cron 调度 定时任务与平台投递
上下文文件 塑造每次对话的项目上下文
架构 项目结构,代理循环,关键类
贡献 开发环境设置,PR 流程,代码风格
CLI 参考 所有命令和参数
环境变量 完整的环境变量参考

如果你来自 OpenClaw,Hermes 可以自动导入你的设置、记忆、技能和 API 密钥。

在初次设置时: 设置向导(hermes setup)会自动检测 ~/.openclaw 并在配置开始前提供迁移选项。

安装后的任何时候:

hermes claw migrate # 交互式迁移(完整预设) hermes claw migrate --dry-run # 预览将要迁移的内容 hermes claw migrate --preset user-data # 迁移预设(用户数据)

English / 原文

Hermes Agent

Hermes Agent | Hermes Desktop

Documentation Discord License: MIT Built by Nous Research 中文 اردو Español

The self-improving AI agent built byNous Research. It's the only agent with a built-in learning loop — it creates skills from experience, improves them during use, nudges itself to persist knowledge, searches its own past conversations, and builds a deepening model of who you are across sessions. Run it on a $5 VPS, a GPU cluster, or serverless infrastructure that costs nearly nothing when idle. It's not tied to your laptop — talk to it from Telegram while it works on a cloud VM.

Use any model you want — Nous Portal, OpenRouter, OpenAI, your own endpoint, and many others. Switch with hermes model — no code changes, no lock-in.

A real terminal interface Full TUI with multiline editing, slash-command autocomplete, conversation history, interrupt-and-redirect, and streaming tool output.
Lives where you do Telegram, Discord, Slack, WhatsApp, Signal, and CLI — all from a single gateway process. Voice memo transcription, cross-platform conversation continuity.
A closed learning loop Agent-curated memory with periodic nudges. Autonomous skill creation after complex tasks. Skills self-improve during use. FTS5 session search with LLM summarization for cross-session recall. Honcho dialectic user modeling. Compatible with the agentskills.io open standard.
Scheduled automations Built-in cron scheduler with delivery to any platform. Daily reports, nightly backups, weekly audits — all in natural language, running unattended.
Delegates and parallelizes Spawn isolated subagents for parallel workstreams. Write Python scripts that call tools via RPC, collapsing multi-step pipelines into zero-context-cost turns.
Runs anywhere, not just your laptop Six terminal backends — local, Docker, SSH, Singularity, Modal, and Daytona. Daytona and Modal offer serverless persistence — your agent's environment hibernates when idle and wakes on demand, costing nearly nothing between sessions. Run it on a $5 VPS or a GPU cluster.
Research-ready Batch trajectory generation, trajectory compression for training the next generation of tool-calling models.

Linux, macOS, WSL2, Termux

curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash

Windows (native, PowerShell)

Heads up: Native Windows runs Hermes without WSL — CLI, gateway, TUI, and tools all work natively. If you'd rather use WSL2, the Linux/macOS one-liner above works there too. Found a bug? Please file issues.

Run this in PowerShell:

iex (irm https://hermes-agent.nousresearch.com/install.ps1)

The installer handles everything: uv, Python 3.11, Node.js, ripgrep, ffmpeg, and a portable Git Bash (MinGit, unpacked to %LOCALAPPDATA%\hermes\git — no admin required, completely isolated from any system Git install). Hermes uses this bundled Git Bash to run shell commands.

If you already have Git installed, the installer detects it and uses that instead. Otherwise a ~45MB MinGit download is all you need — it won't touch or interfere with any system Git.

Android / Termux: The tested manual path is documented in the Termux guide. On Termux, Hermes installs a curated .[termux] extra because the full .[all] extra currently pulls Android-incompatible voice dependencies.

Windows: Native Windows is fully supported — the PowerShell one-liner above installs everything. If you'd rather use WSL2, the Linux command works there too. Native Windows install lives under %LOCALAPPDATA%\hermes; WSL2 installs under ~/.hermes as on Linux.

After installation:

source ~/.bashrc    # reload shell (or: source ~/.zshrc)
hermes              # start chatting!

Windows Defender or antivirus flags uv.exe as malware

If your antivirus (Bitdefender, Windows Defender, etc.) quarantines uv.exe from the Hermes bin folder (%LOCALAPPDATA%\hermes\bin\uv.exe), this is a false positive. The file is Astral's uv — the Rust Python package manager Hermes bundles to manage its Python environment. ML-based antivirus engines commonly flag unsigned Rust binaries that download and install packages.

To verify your copy is authentic:

# Install GitHub CLI if needed
winget install --id GitHub.cli

# Login to GitHub
gh auth login

# Run verification
$uv = "$env:LOCALAPPDATA\hermes\bin\uv.exe"
$ver = (& $uv --version).Split(' ')[1]
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
$zip = "$env:TEMP\uv.zip"
Invoke-WebRequest "https://github.com/astral-sh/uv/releases/download/$ver/uv-x86_64-pc-windows-msvc.zip" -OutFile $zip -UseBasicParsing
gh attestation verify $zip --repo astral-sh/uv
Expand-Archive $zip "$env:TEMP\uv_x" -Force
(Get-FileHash "$env:TEMP\uv_x\uv.exe").Hash -eq (Get-FileHash $uv).Hash

If attestation says "Verification succeeded" and the last line prints True, you're good.

To whitelist Hermes:

  • Windows Defender: Run PowerShell as Admin → Add-MpPreference -ExclusionPath "$env:LOCALAPPDATA\hermes\bin"
  • Bitdefender: Add an exception in the Bitdefender console (Protection > Antivirus > Settings > Manage Exceptions)
  • Whitelist the folder , not the file hash — Hermes updates uv and the hash changes every version

For more context, see the upstream Astral reports: astral-sh/uv#13553, astral-sh/uv#15011, astral-sh/uv#10079.


hermes              # Interactive CLI — start a conversation
hermes model        # Choose your LLM provider and model
hermes tools        # Configure which tools are enabled
hermes config set   # Set individual config values
hermes gateway      # Start the messaging gateway (Telegram, Discord, etc.)
hermes setup        # Run the full setup wizard (configures everything at once)
hermes claw migrate # Migrate from OpenClaw (if coming from OpenClaw)
hermes update       # Update to the latest version
hermes doctor       # Diagnose any issues

📖 Full documentation →


Skip the API-key collection — Nous Portal

Hermes works with whatever provider you want — that's not changing. But if you'd rather not collect five separate API keys for the model, web search, image generation, TTS, and a cloud browser, Nous Portal covers all of them under one subscription:

  • 300+ models — pick any of them with /model <name>
  • Tool Gateway — web search (Firecrawl), image generation (FAL), text-to-speech (OpenAI), cloud browser (Browser Use), all routed through your sub. No extra accounts.

One command from a fresh install:

That logs you in via OAuth, sets Nous as your provider, and turns on the Tool Gateway. Check what's wired up any time with hermes portal info. Full details on the Tool Gateway docs page.

You can still bring your own keys per-tool whenever you want — the gateway is per-backend, not all-or-nothing.


CLI vs Messaging Quick Reference

Hermes has two entry points: start the terminal UI with hermes, or run the gateway and talk to it from Telegram, Discord, Slack, WhatsApp, Signal, or Email. Once you're in a conversation, many slash commands are shared across both interfaces.

Action CLI Messaging platforms
Start chatting hermes Run hermes gateway setup + hermes gateway start, then send the bot a message
Start fresh conversation /new or /reset /new or /reset
Change model /model [provider:model] /model [provider:model]
Set a personality /personality [name] /personality [name]
Retry or undo the last turn /retry, /undo /retry, /undo
Compress context / check usage /compress, /usage, /insights [--days N] /compress, /usage, /insights [days]
Browse skills /skills or /<skill-name> /<skill-name>
Interrupt current work Ctrl+C or send a new message /stop or send a new message
Platform-specific status /platforms /status, /sethome

For the full command lists, see the CLI guide and the Messaging Gateway guide.


All documentation lives at hermes-agent.nousresearch.com/docs :

Section What's Covered
Quickstart Install → setup → first conversation in 2 minutes
CLI Usage Commands, keybindings, personalities, sessions
Configuration Config file, providers, models, all options
Messaging Gateway Telegram, Discord, Slack, WhatsApp, Signal, Home Assistant
Security Command approval, DM pairing, container isolation
Tools & Toolsets 40+ tools, toolset system, terminal backends
Skills System Procedural memory, Skills Hub, creating skills
Memory Persistent memory, user profiles, best practices
MCP Integration Connect any MCP server for extended capabilities
Cron Scheduling Scheduled tasks with platform delivery
Context Files Project context that shapes every conversation
Architecture Project structure, agent loop, key classes
Contributing Development setup, PR process, code style
CLI Reference All commands and flags
Environment Variables Complete env var reference

If you're coming from OpenClaw, Hermes can automatically import your settings, memories, skills, and API keys.

During first-time setup: The setup wizard (hermes setup) automatically detects ~/.openclaw and offers to migrate before configuration begins.

Anytime after install:

hermes claw migrate              # Interactive migration (full preset)
hermes claw migrate --dry-run    # Preview what would be migrated
hermes claw migrate --preset user-data   # Migrate without secrets
hermes claw migrate --overwrite  # Overwrite existing conflicts

What gets imported:

  • SOUL.md — persona file
  • Memories — MEMORY.md and USER.md entries
  • Skills — user-created skills → ~/.hermes/skills/openclaw-imports/
  • Command allowlist — approval patterns
  • Messaging settings — platform configs, allowed users, working directory
  • API keys — allowlisted secrets (Telegram, OpenRouter, OpenAI, Anthropic, ElevenLabs)
  • TTS assets — workspace audio files
  • Workspace instructions — AGENTS.md (with --workspace-target)

See hermes claw migrate --help for all options, or use the openclaw-migration skill for an interactive agent-guided migration with dry-run previews.


We welcome contributions! See the Contributing Guide for development setup, code style, and PR process.

Quick start for contributors — use the standard installer, then work from the full git checkout it creates at $HERMES_HOME/hermes-agent (usually ~/.hermes/hermes-agent). This matches the layout used by hermes update, the managed venv, lazy dependencies, gateway, and docs tooling.

curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash
cd "${HERMES_HOME:-$HOME/.hermes}/hermes-agent"
uv pip install -e ".[all,dev]"
scripts/run_tests.sh

Manual clone fallback (for throwaway clones/CI where you intentionally do not want the managed install layout):

Create the venv outside the cloned source tree — a venv inside the directory the agent operates from can be wiped by a relative-path command the agent runs against its own checkout, destroying the running runtime mid-session.

curl -LsSf https://astral.sh/uv/install.sh | sh
uv venv ~/.hermes/venvs/hermes-dev --python 3.11
source ~/.hermes/venvs/hermes-dev/bin/activate
uv pip install -e ".[all,dev]"
scripts/run_tests.sh

Community

  • 💬 Discord
  • 📚 Skills Hub
  • 🐛 Issues
  • 🔌 computer-use-linux — Linux desktop-control MCP server for Hermes and other MCP hosts, with AT-SPI accessibility trees, Wayland/X11 input, screenshots, and compositor window targeting.
  • 🔌 HermesClaw — Community WeChat bridge: Run Hermes Agent and OpenClaw on the same WeChat account.

MIT — see LICENSE.

Built by Nous Research.