hire
Set up a new AI team member through a guided conversation. Not a config generator - a hiring process.
When to Use
User says something like:
- - "I want to hire a new agent"
- "I need help with X" (where X implies a new agent role)
- "Let's add someone to the team"
- INLINECODE0
The Interview
3 core questions, asked one at a time:
Q1: "What do you need help with?"
Let them describe the problem, not a job title. "I'm drowning in code reviews" beats "I need a code reviewer."
- - Listen for: scope, implied autonomy level, implied tools needed
Q2: "What's their personality? Formal, casual, blunt, cautious, creative?"
Or frame it as: "If this were a human colleague, what would they be like?"
- - Listen for: communication style, vibe, how they interact
Q3: "What should they never do?"
The red lines. This is where trust gets defined.
- - Listen for: boundaries, safety constraints, access limits
Q4: Dynamic (optional)
After Q1-Q3, assess whether anything is ambiguous or needs clarification. If so, ask ONE follow-up question tailored to what's unclear. Examples:
- - "You mentioned monitoring - should they alert you immediately or batch updates?"
- "They'll need access to your codebase - any repos that are off-limits?"
- "You said 'casual' - are we talking friendly-professional or meme-level casual?"
If Q1-Q3 were clear enough, skip Q4 entirely.
Summary Card
After the interview, present a summary:
CODEBLOCK0
Then ask: "Want to tweak anything, or are we good?"
Model Selection
Before finalizing, select an appropriate model for the agent.
Step 1: Discover available models
Run
openclaw models list or check the gateway config to see what's configured.
Step 2: Categorize by tier
Map discovered models to capability tiers:
| Tier | Models (examples) | Best for |
|---|
| reasoning | claude-opus-, gpt-5, gpt-4o, deepseek-r1 | Strategy, advisory, complex analysis, architecture |
| balanced |
claude-sonnet-*, gpt-4-turbo, gpt-4o-mini | Research, writing, general tasks |
|
fast | claude-haiku-
, gpt-3.5, local/ollama | High volume, simple tasks, drafts |
|
code | codex-
, claude-sonnet-, deepseek-coder | Coding, refactoring, tests |
Use pattern matching on model names - don't hardcode specific versions.
Step 3: Match role to tier
Based on the interview:
- - Heavy reasoning/advisory/strategy → reasoning tier
- Research/writing/creative → balanced tier
- Code-focused → code tier (or balanced if not available)
- High-volume/monitoring → fast tier
Step 4: Select and confirm
Pick the best available model for the role. In the summary card, add:
CODEBLOCK1
If multiple good options exist or you're unsure, ask:
"For a [role type] role, I'd suggest [model] (good balance of capability and cost). Or [alternative] if you want [deeper reasoning / faster responses / lower cost]. Preference?"
Notes
- - Don't assume any specific provider - work with what's available
- Cheaper is better when capability is sufficient
- The user's default model isn't always right for every agent
- If only one model is available, use it and note it in the summary
Optional Extras
After the summary is confirmed, offer:
- 1. "Want to set up periodic performance reviews?"
- If yes: ask preferred frequency (weekly, biweekly, monthly)
- Create a cron job that triggers a review conversation
- Review covers: what went well, what's not working, scope/permission adjustments
- At the end of each review, ask: "Want to keep this schedule, change frequency, or stop reviews?"
- 2. Onboarding assignment (if relevant to the role)
- Suggest a small first task to test the new agent
- Something real but low-stakes, so the user can see them in action
What to Generate
Create an agent directory at agents/<name>/ with:
Always unique (generated fresh):
- - AGENTS.md - Role definition, responsibilities, operational rules, what they do freely vs ask first
- IDENTITY.md - Name, emoji, creature type, vibe, core principles
Start from template, customize based on interview:
- - SOUL.md - Base from workspace SOUL.md template, customize vibe/boundaries sections
- TOOLS.md - Populated with inferred tools and access notes
- HEARTBEAT.md - Empty or with initial periodic tasks if relevant to role
Symlink to shared (default, opinionated):
- - USER.md →
../../USER.md (they need to know who they work for) - MEMORY.md →
../../MEMORY.md (shared team context)
Mention to the user: "I've linked USER.md and MEMORY.md so they know who you are and share team context. You can change this later if you want them more isolated."
Naming
Use craft/role-based names. Check TOOLS.md for the full naming taxonomy:
- - Research: Scout, Observer, Surveyor
- Writing: Scribe, Editor, Chronicler
- Code: Smith, Artisan, Engineer
- Analysis: Analyst, Assessor, Arbiter
- Creative: Muse, Artisan
- Oversight: Auditor, Reviewer, Warden
Check existing agents to avoid name conflicts. Suggest a name that fits the role, but let the user override.
Team Awareness
Before generating, check agents/ for existing team members. Note:
- - Potential overlaps with existing roles
- Gaps this new hire fills
- How they'll interact with existing agents
Mention any relevant observations: "You already have Scout for research - this new role would focus specifically on..."
After Setup
- 1. Tell the user what was created and where
- Automatically update the OpenClaw config via gateway
config.patch (do not ask the user to run a manual command). You must:
- Add the new agent entry to
agents.list using this format:
{
"id": "<name>",
"workspace": "/home/lars/clawd/agents/<name>",
"model": "<selected-model>"
}
- Add the new agent ID to the
main agent's subagents.allowAgents array
- Preserve all existing agents and fields (arrays replace on patch)
Required flow:
1) Fetch config + hash
openclaw gateway call config.get --params '{}'
2) Build the updated
agents.list array (existing entries + new agent) and update the
main agent's
subagents.allowAgents (existing list + new id).
3) Apply with
config.patch:
openclaw gateway call config.patch --params '{
"raw": "{\n agents: {\n list: [ /* full list with new agent + updated main allowAgents */ ]\n }\n}\n",
"baseHash": "<hash-from-config.get>",
"restartDelayMs": 1000
}'
- 3. If monthly reviews were requested, confirm the cron schedule
- Update any team roster if one exists
Important
- - This is a CONVERSATION, not a form. Be natural.
- Infer as much as possible from context. Don't ask what you can figure out.
- The user might not know what they want exactly. Help them figure it out.
- Keep the whole process under 5 minutes for the simple case.
hire
通过引导式对话设置新的AI团队成员。不是配置生成器——而是招聘流程。
使用时机
当用户说类似以下内容时:
- - 我想雇佣一个新代理
- 我需要X方面的帮助(其中X暗示需要新的代理角色)
- 让我们给团队加个人
- /hire
面试环节
3个核心问题,逐一提问:
问题1:你需要什么帮助?
让他们描述问题,而不是职位名称。我被代码审查淹没了比我需要一个代码审查员更好。
- - 关注:工作范围、隐含的自主程度、隐含所需的工具
问题2:他们应该有什么样的个性?正式、随意、直率、谨慎、创意?
或者这样表述:如果这是一个人类同事,他们会是什么样子?
问题3:他们绝对不应该做什么?
红线。这是定义信任的地方。
问题4:动态(可选)
在问题1-3之后,评估是否有任何模糊或需要澄清的地方。如果有,提出一个针对不清楚之处量身定制的后续问题。例如:
- - 你提到监控——他们应该立即提醒你还是批量更新?
- 他们需要访问你的代码库——有没有禁止访问的仓库?
- 你说随意——我们说的是友好专业型还是表情包级别的随意?
如果问题1-3已经足够清晰,完全跳过问题4。
摘要卡片
面试结束后,呈现一个摘要:
🎯 角色:[一行描述]
🧠 名称:[根据命名分类法建议的名称]
🤖 模型:[选定模型]([层级])
⚡ 个性:[2-3个词描述氛围]
🔧 工具:[从对话中推断]
🚫 边界:[关键红线]
🤝 自主程度:[推断级别:高/中/低]
然后询问:想要调整什么,还是就这样?
模型选择
在最终确定之前,为代理选择合适的模型。
第一步:发现可用模型
运行 openclaw models list 或检查网关配置以查看已配置的内容。
第二步:按层级分类
将发现的模型映射到能力层级:
| 层级 | 模型(示例) | 最佳用途 |
|---|
| 推理型 | claude-opus-, gpt-5, gpt-4o, deepseek-r1 | 策略、咨询、复杂分析、架构 |
| 均衡型 |
claude-sonnet-*, gpt-4-turbo, gpt-4o-mini | 研究、写作、通用任务 |
|
快速型 | claude-haiku-
, gpt-3.5, local/ollama | 高容量、简单任务、草稿 |
|
代码型 | codex-
, claude-sonnet-, deepseek-coder | 编码、重构、测试 |
对模型名称使用模式匹配——不要硬编码特定版本。
第三步:将角色匹配到层级
基于面试结果:
- - 重度推理/咨询/策略 → 推理型层级
- 研究/写作/创意 → 均衡型层级
- 代码为主 → 代码型层级(如果没有则用均衡型)
- 高容量/监控 → 快速型层级
第四步:选择并确认
为角色选择最佳的可用模型。在摘要卡片中,添加:
🤖 模型:[选定模型]([层级] - [简要原因])
如果有多个好的选项或你不确定,询问:
对于[角色类型]角色,我建议用[模型](能力和成本的良好平衡)。或者用[备选方案]如果你想要[更深入的推理/更快的响应/更低的成本]。偏好是?
备注
- - 不要假设任何特定的提供商——使用可用的资源
- 当能力足够时,更便宜更好
- 用户的默认模型并不总是适合每个代理
- 如果只有一个模型可用,使用它并在摘要中注明
可选附加功能
在摘要确认后,提供:
- 1. 想要设置定期绩效评估吗?
- 如果是:询问偏好的频率(每周、每两周、每月)
- 创建一个触发评估对话的cron任务
- 评估内容包括:做得好的是什么、什么不奏效、范围/权限调整
- 每次评估结束时,询问:想要保持这个计划、改变频率、还是停止评估?
- 2. 入职任务(如果与角色相关)
- 建议一个小型的第一项任务来测试新代理
- 真实但低风险的任务,这样用户可以看到他们的实际表现
需要生成的内容
在 agents// 目录下创建代理文件夹:
始终唯一(全新生成):
- - AGENTS.md - 角色定义、职责、操作规则、自由执行与需先询问的内容
- IDENTITY.md - 名称、表情符号、生物类型、氛围、核心原则
从模板开始,根据面试定制:
- - SOUL.md - 基于工作区SOUL.md模板,定制氛围/边界部分
- TOOLS.md - 填入推断的工具和访问说明
- HEARTBEAT.md - 空文件或包含与角色相关的初始定期任务
符号链接到共享文件(默认、有主见):
- - USER.md → ../../USER.md(他们需要知道为谁工作)
- MEMORY.md → ../../MEMORY.md(共享团队上下文)
向用户说明:我已经链接了USER.md和MEMORY.md,这样他们就知道你是谁并共享团队上下文。如果你希望他们更独立,以后可以更改。
命名
使用基于工艺/角色的名称。查看TOOLS.md获取完整的命名分类法:
- - 研究:Scout、Observer、Surveyor
- 写作:Scribe、Editor、Chronicler
- 代码:Smith、Artisan、Engineer
- 分析:Analyst、Assessor、Arbiter
- 创意:Muse、Artisan
- 监督:Auditor、Reviewer、Warden
检查现有代理以避免名称冲突。建议一个适合角色的名称,但让用户覆盖。
团队意识
在生成之前,检查 agents/ 目录中现有的团队成员。注意:
- - 与现有角色的潜在重叠
- 这个新成员填补的空白
- 他们将如何与现有代理互动
提及任何相关的观察:你已经有了Scout负责研究——这个新角色将专门专注于...
设置完成后
- 1. 告诉用户创建了什么以及在哪里
- 通过网关 config.patch 自动更新OpenClaw配置(不要要求用户运行手动命令)。你必须:
- 使用以下格式将新代理条目添加到 agents.list:
json
{
id: <名称>,
workspace: /home/lars/clawd/agents/<名称>,
model: <选定模型>
}
- 将新代理ID添加到主代理的 subagents.allowAgents 数组中
- 保留所有现有代理和字段(数组在补丁时替换)
必需流程:
1) 获取配置 + 哈希
bash
openclaw gateway call config.get --params {}
2) 构建更新后的 agents.list 数组(现有条目 + 新代理)并更新 main 代理的 subagents.allowAgents(现有列表 + 新ID)。
3) 使用 config.patch 应用:
bash
openclaw gateway call config.patch --params {
raw: {\n agents: {\n list: [ / 包含新代理和更新后的main allowAgents的完整列表 / ]\n }\n}\n,
baseHash: ,
restartDelayMs: 1000
}
- 3. 如果请求了月度评估,确认cron计划
- 如果存在团队名册,进行更新
重要提示
- - 这是对话,不是表单。要自然。
- 尽可能从上下文中推断。不要问你能弄清楚的事情。
- 用户可能不完全知道自己想要什么。帮助他们弄清楚。
- 对于简单情况,保持整个过程在5分钟以内。