Repository navigation
v0.3.18 — cockpit, native file sending, honest resumption
OpenCode QQ Bot v0.3.18
Two weeks of hardening since v0.3.17 — driven by production incidents, owner reviews, and a public design discussion with the Open Agent API author.
Highlights
qq_send_file — AI sends files natively
The AI sends local files/images to QQ through a first-class tool with a JSON-Schema contract. Failures return precise structured errors (allowlist roots listed so the model can self-correct); identical files auto-dedupe. The old QQ_SEND_FILE: text marker survives as a fallback. Root cause it fixes: the marker syntax was never injected into prompts, so models guessed — and needed several attempts.
System-level channel instructions
QQ rendering/format rules now arrive as session instructions (<context key="qq">) instead of being appended to prompt text. Desktop session history stays clean; the rule follows the session, keyed by channel.
Status cockpit
/status is now the single dashboard — server/session/model/agent/observation/mirror/queue/logs. /status watch on|off and /status mirror on|off are the only switches; standalone /watch /mirror retired.
Honest dead-turn resumption
A dead background turn is judged by three signals (last-activity threshold + running-tool grace window + turn-unterminated), aborted with the outcome recorded (rationale/action/consequence), and resumed with a targeted dedupe hint naming the in-flight tool. When the abort is unconfirmed, the model must verify processes and side effects before redoing any write. Shaped by Discussion #3 with jiangxingfan1-coder.
Busy-time steer by default
Messages arriving mid-turn merge into the running turn (official steer semantics). /queue <text> enqueues explicitly; QQ_BUSY_DEFAULT=queue restores classic FIFO.
Engineering
69 test suites on a parallel runner (was serial); state-store hardening (test guard, ghost-mapping eviction, load validation); deploy/ retired; design-doc reconciliation batch; macOS/Linux desktop automation playbooks (desk-research level).
Upgrade
opencode plugin add @linjz/opencode-qqbot@latest # plugin flavor
openqq restart # activate (idle, batched)Known P3 (cosmetic, registered): permission-card save line truncates to 121 visible chars vs the ≤120 criterion — rationale and both fix paths documented in-code at formatPermissionPrompt.