mirror of
https://github.com/hanzoai/bot.git
synced 2026-10-30 17:24:26 +00:00
The docs said ~/.hanzo-bot/hanzo-bot.json (and ~/.hanzo-bot-<profile>, hanzo-bot.plugin.json), which nothing reads: src/config/paths.ts resolves ~/.bot, bot.json and ~/.bot-<profile>, and plugins ship bot.plugin.json. Every such path in docs/ now names what the code opens. Co-authored-by: Hanzo Dev <[email protected]>
1.9 KiB
1.9 KiB
read_when, summary, title, x-i18n
| read_when | summary | title | x-i18n | |||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
`hanzo-bot agents` 的 CLI 参考(列出/添加/删除/设置身份) | agents |
|
hanzo-bot agents
管理隔离的智能体(工作区 + 认证 + 路由)。
相关内容:
示例
hanzo-bot agents list
hanzo-bot agents add work --workspace ~/.bot/workspace-work
hanzo-bot agents set-identity --workspace ~/.bot/workspace --from-identity
hanzo-bot agents set-identity --agent main --avatar avatars/hanzo-bot.png
hanzo-bot agents delete work
身份文件
每个智能体工作区可以在工作区根目录包含一个 IDENTITY.md:
- 示例路径:
~/.bot/workspace/IDENTITY.md set-identity --from-identity从工作区根目录读取(或从显式指定的--identity-file读取)
头像路径相对于工作区根目录解析。
设置身份
set-identity 将字段写入 agents.list[].identity:
namethemeemojiavatar(工作区相对路径、http(s) URL 或 data URI)
从 IDENTITY.md 加载:
hanzo-bot agents set-identity --workspace ~/.bot/workspace --from-identity
显式覆盖字段:
hanzo-bot agents set-identity --agent main --name "HanzoBot" --emoji "🤖" --avatar avatars/hanzo-bot.png
配置示例:
{
agents: {
list: [
{
id: "main",
identity: {
name: "HanzoBot",
theme: "midnight",
emoji: "🤖",
avatar: "avatars/hanzo-bot.png",
},
},
],
},
}