Skip to content

Track requester-controlled task input waits - #212

Merged
hsliuustc0106 merged 1 commit into
mainfrom
feat/task-input-waits
Oct 17, 2026
Merged

hsliuustc0106 merged 1 commit into
mainfrom
feat/task-input-waits

Conversation

@hsliuustc0106

Copy link
Copy Markdown
Contributor

Fixes #207. Refs #198 and #55.

Add requester-only task-wait-input / task-answer-input bookkeeping: a working task records one bounded selected question with a host-generated ID; only an answer to the current question can restore working status. Persist the latest question/answer snapshot and actor trail without copying chat history or prompting an agent.

Keep approval and input waits independent. Explicitly task-tagged sends held during an input wait retain every approval ID, including across restart. The Bot owner decides approvals; the task requester answers the question. Neither action substitutes for the other. Restrict task-start to claimed work so it cannot bypass a blocked input/approval state. Rejection, cancellation and Bot deletion preserve terminal outcomes.

Seven channel regressions cover identity, invalid/stale input, restart, concurrent questions/answers, multiple holds and distinct requester/Bot-owner authority. Two new real-DSH mock-smoke steps verify that recording and answering input make zero model calls. Update docs, changelog and generated patches. Independent of #201/#203.

Verification at 7ab9c0dd690604ebe46742423eba1ffb0bb00663:

  • TZ=UTC DSH_HARNESS=/workspace/FlyBot/core/dev/harness npm run verify: pass, 1,029 tests, 0 failed/skipped.
  • Pack, strict plugin API typecheck (TypeScript 5.9.3), actionlint 1.7.7, changelog and source whitespace checks: pass. Generated patch context whitespace is excluded from the latter; ds-bot-patches.mjs check verifies byte-exact reconstruction.
  • Before implementation the input-wait tests failed on missing endpoints. Additional bypass tests failed while task-start still allowed blocked work, then passed after the guard.
  • Mock smoke: all 42 steps pass with DSH tag dsh-v0.2.0-rc.2 (639ed015397290b3745d163aafe02ffee4aa3f84). Both new task-input steps report zero model calls. Both bench processes stopped.
  • Not run: Desktop, real models or live OpenCode/Bot Social integration. External review remains with the maintainer; no independent agreement is claimed.

No automatic clarification delivery, adapter credential, remote execution authority or team-mode gate is added.

Author-run smoke evidence and reproduction

From core/ with a built checkout of the pinned DSH tag:

DSH_HARNESS=/workspace/FlyBot-dsh-smoke CONTEXT_WINDOW=100000 CHECK_RATIO=0.45 dev/bench.sh task-input 3396 8996 reset
node dev/smoke.mjs task-input 3396
dev/bench.sh task-input 3396 8996 stop
ok   bootstrap: Chief waits for a model (3.0 s, 0 model calls)
ok   user picks a model; Chief greets and asks in its reply (3.6 s, 1 model calls)
ok   Chief creates Writer, who replies (7.0 s, 8 model calls)
ok   a Bot is not offered dsh's blocking question tool (5.3 s, 2 model calls)
ok   user creates Coder, who keeps the default model (3.3 s, 1 model calls)
ok   Chief creates a group (5.7 s, 3 model calls)
ok   user talks in the group (3.3 s, 1 model calls)
ok   admin calls everyone (4.5 s, 3 model calls)
ok   Chief posts to the group (5.8 s, 5 model calls)
ok   Chief sets the group notice (5.7 s, 3 model calls)
ok   Chief reads the group (5.7 s, 3 model calls)
ok   Writer writes long reply 1 (5.3 s, 2 model calls)
ok   Writer writes long reply 2 (5.3 s, 2 model calls)
ok   Writer writes long reply 3 (5.3 s, 4 model calls)
ok   Writer searches its own chat across parts (5.7 s, 3 model calls)
ok   earlier part pages load (2.9 s, 0 model calls)
ok   Writer keeps working 1 (5.3 s, 2 model calls)
ok   Writer keeps working 2 (5.3 s, 4 model calls)
ok   Writer keeps working 3 (5.3 s, 2 model calls)
ok   Writer condensed in place, not switched (2.9 s, 0 model calls)
ok   Writer finds a condensed message (5.7 s, 3 model calls)
ok   Writer wraps up 1 (5.3 s, 4 model calls)
ok   Writer wraps up 2 (5.3 s, 2 model calls)
ok   Writer wraps up 3 (5.3 s, 4 model calls)
ok   Writer wraps up 4 (5.3 s, 2 model calls)
ok   exchange log between Chief and Writer (2.8 s, 0 model calls)
ok   update Writer (2.8 s, 0 model calls)
ok   Coder works in a folder of its own (2.9 s, 0 model calls)
ok   Coder answers from its folder (5.3 s, 2 model calls)
ok   Coder goes back to the team workspace (2.9 s, 0 model calls)
ok   pin Coder (2.9 s, 0 model calls)
ok   make Coder a Main Bot and back (2.9 s, 0 model calls)
ok   duplicate Coder (3.3 s, 1 model calls)
ok   set prefs (2.9 s, 0 model calls)
ok   delete the group (2.9 s, 0 model calls)
ok   delete the copy (2.9 s, 0 model calls)
ok   Chief sees its attached MCP and skill (5.4 s, 2 model calls)
ok   Chief first group turn sees its attached MCP and skill (3.7 s, 1 model calls)
ok   Coder does not inherit Chief capabilities (5.3 s, 2 model calls)
ok   detached capabilities disappear from Chief (5.3 s, 2 model calls)
ok   task records an input wait without a model call (2.9 s, 0 model calls)
ok   matching task input resumes bookkeeping without a model call (2.9 s, 0 model calls)

smoke: all 42 steps passed

Fixes #207. Refs #198 and #55. Bind answers to the current question and requester, preserve independent approval holds, and refuse task-start as a blocked-state bypass. Task state changes do not prompt or execute an agent.
@hsliuustc0106
hsliuustc0106 added this pull request to the merge queue Oct 17, 2026
Merged via the queue into main with commit 175328d Oct 17, 2026
6 checks passed
@hsliuustc0106
hsliuustc0106 deleted the feat/task-input-waits branch October 17, 2026 16:46
@hsliuustc0106 hsliuustc0106 added the status:done Scoped task completed and merged; does not imply parent acceptance is complete label Oct 17, 2026 — with ChatGPT Codex Connector
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status:done Scoped task completed and merged; does not imply parent acceptance is complete

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Track requester-controlled task clarification waits

1 participant