feat: /btw now answers side questions with conversation context; /background renamed to /bg

/bg (formerly /background, which is retired) keeps the existing semantics:
spawn a fresh, independent agent session in the background.

/btw is now its own command matching the convention other harnesses use:
ask a quick side question ABOUT the current conversation without
interrupting it. A one-shot auxiliary LLM call (main model by default,
overridable via auxiliary.side_question.* in config.yaml) answers from a
read-only transcript snapshot — the live session's history, role
alternation, and prompt cache are untouched, and the current turn keeps
running.

Surfaces wired: CLI (inline mid-run dispatch), gateway (all messengers,
busy-dispatch table + idle dispatch, i18n across all 17 locales), TUI
(prompt.btw RPC + btw.complete event), Discord native slash, relay
command manifest, desktop exec routing, docs (EN + zh-Hans).
This commit is contained in:
Teknium
2026-08-29 07:14:17 -07:00
parent b6bd681e89
commit 74a95a3ddf
63 changed files with 966 additions and 169 deletions
+9 -1
View File
@@ -68,9 +68,17 @@ gateway:
always_plural: "✅ 指令已批准(永久允許該模式)({count} 條指令)。代理正在恢復…"
background:
usage: "用法:/background <提示>\n範例:/background 摘要今天 HN 上的熱門故事\n\n在獨立工作階段中執行該提示。你可以繼續聊天 — 完成後結果將顯示於此。"
usage: "用法:/bg <提示>\n範例:/bg 摘要今天 HN 上的熱門故事\n\n在獨立工作階段中執行該提示。你可以繼續聊天 — 完成後結果將顯示於此。"
started: "🔄 背景任務已啟動:「{preview}」\n任務 ID:{task_id}\n你可以繼續聊天 — 完成後結果將顯示於此。"
btw:
usage: "用法:/btw <問題>\n範例:/btw 那個錯誤在哪個檔案?\n\n在不打斷目前工作的情況下,回答關於此對話的快速問題。若要執行獨立的背景任務,請使用 /bg <提示>。"
no_history: "尚無對話 — 請將問題作為一般訊息傳送。"
no_provider: "❌ 無法回答問題:未設定供應商憑證。"
started: "💬 順帶一問:「{preview}」\n正根據此對話的快照回答 — 目前的工作繼續進行。"
answer: "💬 /btw:「{preview}」\n\n{answer}"
failed: "❌ /btw 失敗:「{preview}」\n{error}"
branch:
db_unavailable: "工作階段資料庫無法使用。"
no_conversation: "沒有可分支的對話 — 請先傳送一則訊息。"