feat: add AskUserQuestion runtime and TUI - #908
Merged
Conversation
This was referenced Jul 13, 2026
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.
Summary
Why
Refs #825. Agents need a bounded way to ask the user for missing decisions and then continue the same turn. This extends the existing permission/runtime/TUI seams while keeping their separate policy and lifecycle responsibilities.
Scope
Desktop registration and UI remain PR3. This PR deliberately excludes
maka run, headless/Harbor, Pi transport, child agents, and the other out-of-scope items recorded in #825.Verification
npm --workspace @maka/core test— 873 passed, 0 failed.npm --workspace @maka/runtime test— 1,470 passed, 0 failed, 7 skipped.npm --workspace maka-agent test— 317 passed, 0 failed.npm run typecheck— all workspaces passed.git diff --check origin/main...HEAD— passed.pi-tuiFakeTerminal: bottom-overlay rendering and placement, FIFO sequencing, keyboard selection, Other editing/submission, Esc unanswered, Stop, abort, and late responses. A static screenshot is not useful evidence for this stateful terminal interaction.Impact
The root interactive TUI gains AskUserQuestion. Existing permission behavior remains unchanged, including its 300-second timeout; user questions have no fixed timeout and remain interruptible by Stop/abort/teardown. No migration or release-note action is required.
Reviewer notes
The response command is intentionally ephemeral. Only the resulting JSON tool result is durable. Reviewer completed two full-diff passes, including after rebasing onto current
main, with no P0–P3 findings and a Go conclusion.Ready for review
Verificationexplains why it is not applicable