Repository navigation
Conversation
…or not The engine's own dialog, widened inside doperpowers from $.ui.ask's one question to the full set; blocking returns the engine's text, async returns at once and delivers the answer beside the next tool result or as a new prompt; the built-in withdrawn; <need-input> retired. Engine facts probed on 2.1.296. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…acts from the bundle; Esc ends a blocking turn, Chat about this is delivered Co-Authored-By: Claude Opus 5.5 <[email protected]>
… queue, origin-bound claims and delivery, stops not undone, accepted-only resume, fixed-payload parity, eval fixtures Co-Authored-By: Claude Opus 5.5 <[email protected]>
…rt the selections, preview and note Co-Authored-By: Claude Opus 5.5 <[email protected]>
…al, reserved delivery with put-back, token-correlated claims Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ld-answer test moves to M2
…ted-image store, async path lines
…e built-in (M1) The tool takes the built-in's input plus async, opens Claude Code's own dialog through $.ui.ask widened to the whole question set by a token claim on this plugin's origin, and returns the engine's result text byte for byte; pasted pictures come back as image blocks from the session's pasted-image store. The built-in is withdrawn behind tool search from the start of an interactive session and refused when called. Validation reproduces the built-in's error text. A declined ask latches the turn: later model calls are refused and the next model request is aborted unsent (turn.step + $.turn.abort, chosen over PostToolBatch preventContinuation, which draws a stop line). Subagents are refused and the agent definitions withhold the tool.
…bort runs Stop hooks
…s them; catch policies on the gating hooks The pasted-image store keeps a paste the dialog's Delete removed, so the engine's '(Image attached)' marks decide: when the marked answers account for every new file, all were kept and go as image blocks; otherwise none goes (debug line). 'Chat about this' keeps its text refusal and appends one [Image: source: <realpath>] line per kept picture. The four gating hooks ask.tsx adds get a .catch: the withdrawal fails closed for the model, the tool's own failure is a refusal naming it, re-entry passes on.
…s [Image source:] form
…age source: <path>], from one exported helper
… resume (M2) An async ask returns at once and stands open in its transcript row and above the prompt behind [ answer ]; a press raises the engine dialog from the ui.press dispatch. Esc leaves it open; an answer or "Chat about this" is delivered: submitted at once while idle, else held for the next model-made main-loop result (never a plugin's call, a deny, or a call the human's interrupt cut), the turn's answered end, or the human's next prompt as context. Failed submissions put their answers back in front. Every ask's row draws as the built-in's (the engine's own row is out of reach: probed). A resumed session rebuilds accepted asks from the rows the model read.
…gin's framed rows; a cut search rebuilds nothing The prompt.submit route puts its reserved answers back when the pass beneath rejects, before the fail-open policy lets the prompt through. Resume counts a user row as a delivery only when it carries the engine's plugin framing, so a human quoting a delivery head does not close an ask. The large-transcript search narrows to the stored forms resume reads (no prompt-snapshot rows), tells no match (exit 1) from failure, and rebuilds nothing, with a debug line, when its output was cut at 4 MiB. $.fs.read takes no offset/limit, so the search stays.
…ontext Both delivery routes append to a context list that may already hold another hook's entries, so a stored attachment can carry the delivery head in a later entry; the search matched only a head opening the list, and such an ask was rebuilt open. A later entry is now matched too (`","<head>`). A shell check runs the real grep with the mod's own arguments (searchArgs) over a fixture transcript and compares its rebuild with the full read's; the mods runner runs it after the mods' tests, which cannot reach a process.
…uestion with async; the mark reads as a message The style's need-input paragraph becomes one on AskUserQuestion and its async flag (maws-to-human-contract 3). The view and the streaming hook read <need-input> as an alias of <message>, its <choice> lines as text; the choice grammar, question buttons, answer prompt form and the prompt.submit hook that settled questions are gone.
…sage; a question the turn ends on is blocking (eval round 2)
… the repo map and hooks.json; 7.148.0
…bout this" reads a whole answer for its image mark Resume rebuilt asks from every row of the transcript, so after a rewind the abandoned branch's accepted asks came back open and its deliveries closed asks still open on the resumed branch. It now reads only the conversation the engine resumes: back from the leaf (the last row written, or the leaf a rewind's explicit last-prompt record names, none when it went back past the first prompt), parent by parent, across a compaction by the boundary's logicalParentUuid. A search of a transcript over 4 MiB has no ancestry and keeps every line found; that and a rewind inside a running session (no event a hook sees) are recorded as known limits. The "Chat about this" refusal lists each answer as the human typed it, newlines included; the parser took only the first line, so a multiline answer lost its (Image attached) mark and the kept picture was dropped. It now reads the whole answer, up to the question's notes, the next question, or the end.
…ound one is rebuilt as the engine restores it 0fac448 walked the parentUuid chain on every resume, but one model response is a row per block and each tool result is parented to its own call's row, so an async ask's acceptance beside a later call in the same response fell off the chain and the ask was not rebuilt: a regression in a normal session. Without a rewind record the whole file is the conversation again, as before. With one, the chain is rebuilt as the engine's i1r restores it: each response on the chain brings its rows (same message.id), the results of its calls (by parent, sourceToolAssistantUUID, or call id), and the runs of side rows under them that neither fork nor rejoin the chain (Vae), so a context attachment carrying a delivery on such a result comes with it.
9 of 12 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This replaces the built-in AskUserQuestion with
mcp__doperpowers__AskUserQuestion. It takes the built-in's input plusasync, and it is asked through Claude Code's own dialog.asyncfalse, the default): the engine's dialog opens at once and the call returns the built-in's own result text. The recorded result is byte-identical to the built-in's.async: true): the call returns at once. The questions wait in the human's view, in the call's row and in a band above the prompt, each behind an[ answer ]button. When the human submits, the answer reaches the model one of three ways:<need-input>mark is retired; an old one now reads as a<message>.Spec:
docs/doperpowers/specs/2026-10-13-ask-async-design.md. Execution report:docs/doperpowers/specs/2026-10-13-ask-async-report.md. Version 7.148.0.Validation Evidence
tests/mods/run-mods-tests.sh167 pass/0 fail, thenask search: all checks passedtests/claude-code/test-to-human-stream-hook.shto-human-stream hook: all checks passednpx -p typescript@5 tsc -p hooks/mods/tsconfig.jsonclaude plugin validate .claude-plugin/plugin.json✔ Validation passed with warnings. The warnings are main's baseline, compared in a detached worktree of main. The gating-hook notes drop from 9 to 8.--debug-filehooks module doperpowers@inline loaded (worker, environment 1, tier user), with no refusal and noHooksErrortool_resultin the two transcriptsIDENTICAL: `"The user answered: "Which backend?"="SQLite" selected preview:\n+--------+\nhook_additional_contextattachment withhookName: tool.call; idle:The doperpowers plugin sent a message:\nThe human responded to your async AskUserQuestion (call toolu_…); after an interrupt: no new turn starts, and the next prompt carries it (hookName: prompt.submit)[ answer ]; each(call <id>)appears ×1 in theattachmentrows<tool_use_error>Withdrawn in this session: ask through mcp__doperpowers__AskUserQuestion, which takes this tool's input plus async.</tool_use_error>; subagent:AskUserQuestion is for the main conversation: report what you need to the agent that dispatched you./exit, thenclaude --resume[ answer ]with1 open questionabove the prompt; the answered ask draws its answers; the call refused by validation is not an ask<need-input>retired (acceptance 8)output-styles/to-human.md; an old mark draws as a message, with<choice>as text and no buttonsNot run: the human declined the question asked in this turn., nox.txtis written, and no assistant row follows; after "Chat about this", the turn goes on (echo after-ask→after-ask)[text, image/png block]and the model describes the image; async: the delivery ends[Image source: /private/tmp/claude-501/…/images/1.png]and the model Reads itEval (acceptance 11; behavior change).
claude-opus-5-5with the to-human style, 3 runs per cell, interactive sessions in tmux, scored from the transcripts:<need-input>mark; 2/3 no question (the model referred to a question it never wrote)todo.pywritten in the same turnThe first style round missed the bar twice: one run asked async and then waited, and another recommended an answer instead of asking. The second round revised only the style paragraph and restored the old style's guard sentence. The table shows round 2.
Reviews. Each milestone got a task review (sol/xhigh), and each review's findings were fixed and re-reviewed. The whole-branch review at the high rung (
doperpowers:reviewer-high) found two issues, then a regression in the first fix; all are fixed, and the final verdict iscorrect.Unresolved Review Findings
hooks/mods/ask.tsxis about 1,250 lines. Its pure helpers (validation, row and delivery text, transcript rebuild) could move to a sibling.tsthatask.tsxre-exports. Left as is because the spec's Interfaces section places these exports inask.tsx, and the file has one responsibility. (M2 task review, Minor.)The resume search for transcripts over 4 MiB (
ask.tsx,searchArgs) has three gaps:It was left because the case is rare, the limits are documented in
hooks/mods/README.md, and streaming through$.process.spawnwould be the next step. (M2 task review and branch review, Minor.)The eval scorer does not enforce S1's same-turn requirement (
.doperpowers/sde/…/m3-eval/bin/score.py, a gitignored eval artifact). The recorded S1 runs were each checked by hand to finish in one turn. (M3 task review, Minor.)A pasted picture the human removed can still be sent if their own answer ends with the literal text
(Image attached). No hook-reachable signal names which attachments the human kept, so the mod counts the engine's marks. Recorded as a known limit in the README; the design session accepted it. (M1 task review.)Residue
~/.claude/agents/astra.mdandsol-xhigh.mdwithhold the compact tools but notmcp__doperpowers__AskUserQuestion. The hook still refuses a subagent's call; only the schema rides in their context. This is user config, and the design session updates it after merge.MAWS_NATIVE_TO_HUMAN, MAWS draws the report itself. The engine writes a plugin tool'stool_userow to the transcript only after the call resolves, so a transcript watcher cannot see an open blocking ask of this tool.docs/doperpowers/specs/2026-10-13-smns-project-log-design.mdstill sources itsneed-inputevent from the retired mark. Its source is now an async ask:textis the questions,choicesthe option labels,srcthe call. That spec's owner takes this.