command-dispatch
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseCommand Dispatch
命令调度
Use this skill to identify user intent and dispatch the corresponding system or plugin command.
使用此Skill识别用户意图并调度对应的系统或插件命令。
When to Use
使用场景
- The user sends a slash command (execute directly)
/xxx - The user describes an action in natural language, for example:
- "Sync sites" →
/cookiecloud - "Show my subscriptions" →
/subscribes - "Refresh subscriptions" →
/subscribes refresh - "What's downloading?" →
/downloading - "Organize downloaded files" →
/transfer - "Clear cache" →
/clear_cache - "Restart the system" →
/restart - "Pause all QB tasks" → (plugin command)
/pause_torrents
- "Sync sites" →
- 用户发送格式的斜杠命令(直接执行)
/xxx - 用户用自然语言描述操作,例如:
- “同步站点” →
/cookiecloud - “显示我的订阅” →
/subscribes - “刷新订阅” →
/subscribes refresh - “正在下载什么?” →
/downloading - “整理已下载文件” →
/transfer - “清除缓存” →
/clear_cache - “重启系统” →
/restart - “暂停所有QB任务” → (插件命令)
/pause_torrents
- “同步站点” →
Tools
工具
- — List all available slash commands (system + plugin), returns command name, description, and category
list_slash_commands - — Query detailed plugin capabilities (commands, actions, scheduled services)
query_plugin_capabilities - — Execute a specified command (works for both system and plugin commands)
run_slash_command
- — 列出所有可用的斜杠命令(系统+插件),返回命令名称、描述和分类
list_slash_commands - — 查询插件的详细功能(命令、操作、定时服务)
query_plugin_capabilities - — 执行指定命令(支持系统和插件命令)
run_slash_command
Workflow
工作流程
Step 1: Identify User Intent
步骤1:识别用户意图
Determine whether the user's message is requesting the execution of a command:
- Direct command: Message starts with , e.g.
/,/sites→ skip to Step 3/subscribes - Natural language: The user describes an actionable request → continue to Step 2
判断用户消息是否请求执行命令:
- 直接命令:消息以/开头,例如/sites、/subscribes → 跳至步骤3
- 自然语言:用户描述可执行的请求 → 继续步骤2
Step 2: Find Matching Command
步骤2:查找匹配命令
Use to retrieve all available commands. Match the user's described intent against the and fields of each command.
list_slash_commandsdescriptioncategoryIf the user's description involves a specific plugin's functionality, additionally use to query that plugin's detailed capabilities.
query_plugin_capabilitiesMatching strategy:
- Prefer exact matches on command description
- Then narrow down by category and match
- If no matching command is found, inform the user that no corresponding function is available
使用获取所有可用命令。将用户描述的意图与每个命令的和字段进行匹配。
list_slash_commandsdescriptioncategory如果用户描述涉及特定插件的功能,额外使用查询该插件的详细功能。
query_plugin_capabilities匹配策略:
- 优先匹配命令描述的精确内容
- 其次按分类缩小范围进行匹配
- 若未找到匹配命令,告知用户无对应功能可用
Step 3: Extract Parameters and Execute
步骤3:提取参数并执行
Some commands support additional arguments (space-separated after the command), for example:
- — Manually re-organize a specific record
/redo <history_id> - — Disable one or more sites
/sites disable <site_id> - — Delete one or more subscriptions
/subscribes delete <subscribe_id>
Use to execute the command in the format .
run_slash_command/command_name arg1 arg2部分命令支持附加参数(命令后以空格分隔),例如:
- — 手动重新整理特定记录
/redo <history_id> - — 禁用一个或多个站点
/sites disable <site_id> - — 删除一个或多个订阅
/subscribes delete <subscribe_id>
使用以的格式执行命令。
run_slash_command/command_name arg1 arg2Step 4: Report Result
步骤4:反馈结果
Command execution is asynchronous. After triggering, inform the user that the command has started. If the command does not exist, list available commands for reference.
命令执行是异步的。触发执行后,告知用户命令已启动。若命令不存在,列出可用命令供参考。
Important Notes
重要注意事项
- Command execution requires admin privileges; the tool will automatically check permissions
- Both system and plugin commands are executed via the tool — no need to distinguish between them
run_slash_command - If you are unsure which command matches the user's intent, use first to look up before deciding
list_slash_commands - Never guess non-existent commands; always select from the available command list
- 命令执行需要管理员权限,工具会自动检查权限
- 系统命令和插件命令均通过工具执行——无需区分两者
run_slash_command - 若不确定哪个命令匹配用户意图,先使用查询后再做决定
list_slash_commands - 切勿猜测不存在的命令,务必从可用命令列表中选择