Slash Command Routing
Goal
- Treat Hermes slash commands as a first-class routing surface.
- When the user intent is really a slash command, prefer the slash command path over ad hoc tool behavior.
Use when
- The user asks for background execution, session control, queueing, plan mode, rollback, resume, status, model/provider toggles, or other Hermes command-surface actions.
- The user mentions words like
后台, slash, 斜杠命令, 用 /background, 先计划别执行, 恢复会话, 撤销刚才, 压缩上下文, 排队, 暂停提问, 快模式, reasoning, yolo, reload mcp, debug report.
Core rule
- If a built-in slash command matches the user intent well, route to that command surface first instead of approximating the behavior with ordinary tool calls.
- For long-running autonomous work that should continue outside the current turn, prefer
/background over only starting a raw background process.
Primary mappings
1. Background / asynchronous work
Trigger phrases:
后台
后台跑
后台监控
继续盯
跑完回报
必要时介入
先后台
/background
Route:
/background <self-contained prompt>
Rules:
- The prompt must be self-contained: goal, workdir, commands, state files, expected output, failure handling.
- Do not use
/background for trivial one-shot checks.
- If the user wants the current session free while work continues,
/background is the default.
2. Plan mode instead of execution
Trigger phrases:
先计划
别执行
写方案
plan mode
/plan
Route:
3. Queue next prompt
Trigger phrases:
Route:
Important:
- Prefer
/queue, not /q, because /q conflicts with /quit in practice.
4. Session reset / branch / resume / undo / retry
Trigger phrases and routes:
新开会话 / 重开 / 清空重来 -> /new or /clear
撤销刚才 -> /undo
重试上一条 -> /retry
恢复会话 / 继续之前那个 -> /resume [name]
分支试另一条路 / fork this -> /branch [name]
压缩上下文 / 对话太长 -> /compress [focus topic]
回滚 checkpoint / 恢复快照 -> /rollback or /snapshot
Guideline:
/rollback is for filesystem checkpoints.
/snapshot is for Hermes config/state snapshots.
- Distinguish them explicitly.
5. Status / usage / debug
Trigger phrases and routes:
状态 / 当前会话 -> /status
token 用量 / 费用 / 成本 -> /usage
debug report / 上传日志 -> /debug
近 30 天分析 -> /insights
6. Model / provider / speed / reasoning / personality
Trigger phrases and routes:
切模型 -> /model
看 provider -> /provider
快一点 / fast mode -> /fast
reasoning 高一点/低一点 -> /reasoning
换人格 -> /personality
7. Tools / browser / MCP / skills / cron / reload
Trigger phrases and routes:
开关工具 -> /tools
看 toolsets -> /toolsets
接浏览器 -> /browser
技能搜索/安装/审计 -> /skills
定时任务 -> /cron
重载 MCP -> /reload-mcp
重载 env -> /reload
插件状态 -> /plugins
8. High-risk explicit override
Trigger phrases:
Route:
Safety:
- Only route here when the user explicitly asks.
- Do not infer it from impatience alone.
9. Messaging-only commands
When operating in chat/gateway contexts, these are first-class and should be recognized:
/approve
/deny
/commands
/update
/restart
/sethome
Do not suggest them in pure CLI-only contexts unless relevant.
Source of truth
- Slash command reference:
~/.hermes/hermes-agent/website/docs/reference/slash-commands.md
- Central registry:
~/.hermes/hermes-agent/hermes_cli/commands.py
Router discipline
- First ask: is this really a slash-command intent?
- If yes, route to the slash command before generic tool use.
- If no, continue normal skill/tool routing.
- For slash-command routing updates, keep this skill and
.hermes/routing/slash-command-router.md in sync.
Pitfalls
- Do not approximate
/background with only a raw background process when the user wants autonomous monitoring.
- Do not use
/q; use /queue explicitly.
- Do not confuse
/rollback with /snapshot.
- Do not route to
/yolo without explicit user intent.
1---2name: slash-command-routing3description: Route user intent to Hermes slash commands before normal tool or skill execution. Use when the request is really a session-control, backgrounding, planning, queueing, resume, rollback, config, or gateway command trigger.4---56# Slash Command Routing78Goal9- Treat Hermes slash commands as a first-class routing surface.10- When the user intent is really a slash command, prefer the slash command path over ad hoc tool behavior.1112Use when13- The user asks for background execution, session control, queueing, plan mode, rollback, resume, status, model/provider toggles, or other Hermes command-surface actions.14- The user mentions words like `后台`, `slash`, `斜杠命令`, `用 /background`, `先计划别执行`, `恢复会话`, `撤销刚才`, `压缩上下文`, `排队`, `暂停提问`, `快模式`, `reasoning`, `yolo`, `reload mcp`, `debug report`.1516Core rule17- If a built-in slash command matches the user intent well, route to that command surface first instead of approximating the behavior with ordinary tool calls.18- For long-running autonomous work that should continue outside the current turn, prefer `/background` over only starting a raw background process.1920Primary mappings2122## 1. Background / asynchronous work23Trigger phrases:24- `后台`25- `后台跑`26- `后台监控`27- `继续盯`28- `跑完回报`29- `必要时介入`30- `先后台`31- `/background`3233Route:34- `/background <self-contained prompt>`3536Rules:37- The prompt must be self-contained: goal, workdir, commands, state files, expected output, failure handling.38- Do not use `/background` for trivial one-shot checks.39- If the user wants the current session free while work continues, `/background` is the default.4041## 2. Plan mode instead of execution42Trigger phrases:43- `先计划`44- `别执行`45- `写方案`46- `plan mode`47- `/plan`4849Route:50- `/plan [request]`5152## 3. Queue next prompt53Trigger phrases:54- `排队`55- `下一轮再做`56- `等当前完成后再问`57- `/queue`5859Route:60- `/queue <prompt>`6162Important:63- Prefer `/queue`, not `/q`, because `/q` conflicts with `/quit` in practice.6465## 4. Session reset / branch / resume / undo / retry66Trigger phrases and routes:67- `新开会话` / `重开` / `清空重来` -> `/new` or `/clear`68- `撤销刚才` -> `/undo`69- `重试上一条` -> `/retry`70- `恢复会话` / `继续之前那个` -> `/resume [name]`71- `分支试另一条路` / `fork this` -> `/branch [name]`72- `压缩上下文` / `对话太长` -> `/compress [focus topic]`73- `回滚 checkpoint` / `恢复快照` -> `/rollback` or `/snapshot`7475Guideline:76- `/rollback` is for filesystem checkpoints.77- `/snapshot` is for Hermes config/state snapshots.78- Distinguish them explicitly.7980## 5. Status / usage / debug81Trigger phrases and routes:82- `状态` / `当前会话` -> `/status`83- `token 用量` / `费用` / `成本` -> `/usage`84- `debug report` / `上传日志` -> `/debug`85- `近 30 天分析` -> `/insights`8687## 6. Model / provider / speed / reasoning / personality88Trigger phrases and routes:89- `切模型` -> `/model`90- `看 provider` -> `/provider`91- `快一点` / `fast mode` -> `/fast`92- `reasoning 高一点/低一点` -> `/reasoning`93- `换人格` -> `/personality`9495## 7. Tools / browser / MCP / skills / cron / reload96Trigger phrases and routes:97- `开关工具` -> `/tools`98- `看 toolsets` -> `/toolsets`99- `接浏览器` -> `/browser`100- `技能搜索/安装/审计` -> `/skills`101- `定时任务` -> `/cron`102- `重载 MCP` -> `/reload-mcp`103- `重载 env` -> `/reload`104- `插件状态` -> `/plugins`105106## 8. High-risk explicit override107Trigger phrases:108- `别再问审批`109- `全自动`110- `YOLO`111- `/yolo`112113Route:114- `/yolo`115116Safety:117- Only route here when the user explicitly asks.118- Do not infer it from impatience alone.119120## 9. Messaging-only commands121When operating in chat/gateway contexts, these are first-class and should be recognized:122- `/approve`123- `/deny`124- `/commands`125- `/update`126- `/restart`127- `/sethome`128129Do not suggest them in pure CLI-only contexts unless relevant.130131Source of truth132- Slash command reference: `~/.hermes/hermes-agent/website/docs/reference/slash-commands.md`133- Central registry: `~/.hermes/hermes-agent/hermes_cli/commands.py`134135Router discipline1361. First ask: is this really a slash-command intent?1372. If yes, route to the slash command before generic tool use.1383. If no, continue normal skill/tool routing.1394. For slash-command routing updates, keep this skill and `.hermes/routing/slash-command-router.md` in sync.140141Pitfalls142- Do not approximate `/background` with only a raw background process when the user wants autonomous monitoring.143- Do not use `/q`; use `/queue` explicitly.144- Do not confuse `/rollback` with `/snapshot`.145- Do not route to `/yolo` without explicit user intent.