Repository navigation
feat: inspect and launch suggested tasks in Companion chat - #2377
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: passed. What this changesAdds native cards for inspecting, copying, dismissing and explicitly launching Gateway-suggested tasks while retaining the current conversation and draft. Example: A suggestion appears while the composer contains “Retain this exact combined Gateway unsent draft.”
Review scores
ProductKind: Feature · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep this maintainer-authored PR open: native task handling is absent from main, and the reviewed change has no identified blocking defect. Reviewed head: Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe authenticated Gateway client supplies proposals and acceptance replies to a transient chat coordinator; native controls display them and send explicit actions back through that client. flowchart LR
A[Gateway task registry] --> B[Authenticated Gateway client]
B --> C[Task suggestion coordinator]
C --> D[Native task card]
D --> E[Explicit accept or dismiss]
E --> B
B --> F[Sessions refresh]
C --> G[Transient receipt custody]
Technical reviewBest possible solution: Retain the capability-gated native consumer using the existing Gateway task owner, explicit acceptance and transient receipt custody. Do we have a high-confidence way to reproduce the issue? This is a feature addition: source inspection confirms that current main lacks native task cards, while supplied runtime evidence exercises the added consumer. Is this the best way to solve the issue? The implementation keeps proposals and launch effects Gateway-owned, preserves the existing composer owners and honestly separates native consumption from the unmerged upstream generation change. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 29f0553fbed0. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall readiness starts with the lower of the proof and patch scores. It is capped at 3/6 if the fix is partial, the change offers little benefit, a product decision is still open, or the PR reverses an earlier decision without saying why. ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (1 earlier review cycle)
Reviewed November 30, 2026, 6:41 PM ET / 23:41 UTC (Revision 2). |
Current native task-card proofTested/reviewed Windows tree: Generated instructions and retained draftAfter native dismissalCompact primary-action focusVerified-identity recovery stateDismissal failure feedbackInvalid repository correctionNo administrator launch authorityThe current native matrix executed 42 cases, all passed, zero failed/skipped. Independent Gateway history verifies that the draft was not sent. Start was checked as enabled in the combined case but not invoked; real worktree/cloud execution, screen-reader/Tab traversal and full task-card Axe remain unverified. |
Redesign the native suggested-task card to mirror the web Control UI: floating right-aligned card with uppercase context eyebrow, icon copy, stack navigation and dismiss actions, title and bounded summary, instructions disclosure with path and prompt blocks, and an accent split Start button whose menu offers worktree, this session and cloud. Keep task safety semantics unchanged: admin and scope gating, frozen retry identity, custody, relative-path rejection and draft retention. Add read-only presentation and snapshot revisions so unsent card input never survives an operator change, plus short-pane, welcome-layout and focus handoff handling with native UI coverage.
Integrate current main (0347d12) into the suggested-task card redesign. Resolve GatewayScenario so main's theme fixtures and the opt-in task, chat and question fixtures coexist with separate scopes and routing. Adapt the task card surfaces to main's live Gateway theme contracts: themed corner radii, code font roles and palette-projected task brushes, with High Contrast and Windows default restore unchanged. Task protocol, custody, retry identity and launch semantics are unchanged.
Integrate current main (3670fcd) into the suggested-task card branch, resolving ConnectEnvelopeBuilder and FixtureGatewayServer additively without changing task capability negotiation. Address ClawSweeper review: remove ProducerAcceptanceModesAreSupported and the two new-session-label contract cases after mutation proof that the surviving transport and production-root launch tests catch the same regressions. Extend the compiled-Gateway proof to actually accept local and worktree suggestions, asserting acknowledgement, authoritative new session, retained conversation and exact draft, and no replay. Write acceptance receipts only after the full test and cleanup succeed and preserve primary failures when cleanup also fails.
|
Addressed the ClawSweeper review (it reviewed
|
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Resolve append-only Resources.resw conflicts in en-us, fr-fr, nl-nl, pt-br, zh-cn and zh-tw by keeping both the suggested-task keys and main's activity/run-phrase keys. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Pick up openclaw#2424, which points the chat-tail-reflow-budget ledger row at its renamed guard test. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Resolve openclaw#2377 (suggested tasks) overlaps: keep both the Ask OpenClaw helper welcome guard and the task-suggestion composer wiring in OpenClawReactorChatRoot, both fixture scenario parameters in GatewayScenario, and both string sets in every Resources.resw locale. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>







What Problem This Solves
Companion users currently leave native chat to inspect or act on Gateway-suggested follow-up work. They need a native way to read, copy, dismiss or explicitly launch a proposal without losing the conversation they are writing in.
User Impact
User impact: act on supported Gateway task proposals directly above the native composer while keeping the selected conversation and exact unsent draft. Starts are explicit and scope/capability-gated; uncertain starts do not silently replay. Older Gateways remain compatible, and native-origin automatic suggestion generation still depends on the Gateway version/policy. Any profile-identity invalidation deliberately discards unsent task-card input (including same-operator name/avatar edits), not the main composer draft.
Why This Change Was Made
The card uses the existing authenticated Gateway client, bounded transient chat coordinator/custody and Windows-owned controls. It adds no competing task store or chat-send fallback. This follow-up resolves current-main integration, removes redundant tests only after mutation verification, and strengthens the real launch/visual evidence.
Evidence
Current-code native controls and actual Companion executable frames are collected below. Real compiled-Gateway local/worktree launches retain the exact draft; the signed installer upgrade remains visibly blocked.
Validation
Tested uncommitted staged tree
ab7842df9a2ba24974c387def98694b857b906a6, based on HEAD9eff64bdc39893c9aae7aae80bf129c59bc6a1aeand MERGE_HEAD3670fcd6cd8849befd86f252b2c64a0f285c21ba. The parent will bind the final commit to this tree before publishing. These are local/Crabbox executions, not a claim that hosted PR CI ran. Only the combined native test source changed in this review round. The complete 102-case matrix and canonical ARM64 full build/Shared/Tray below belong to the previously reviewed product-identical tree; they are retained as prior evidence, not relabeled executions of the new tree. The three compiled-Gateway cases are rerun from this exact staged tree.Every build/test child removed inherited live Gateway/profile selectors and selected task-owned roots; approval-path isolation, exclusive desktop admission and owned foreground/focus remained required. Native input ran on ARM64 console session 1, not SSH session 0. Only owned tasks/processes were cleaned up. Original setup/capture failures and the unchanged upload-retention suite failure are retained separately; the owner-batch pass does not replace the separately reported final full-suite pass. No unrelated retention source/test or sandbox/ACL policy was changed.
Exact canonical commands:
Selected UI invocations, serialized through the admitted task-owned native runner. The matching initial ARM64 UI build used the repository's full project-reference route. The final harness-only rebuild below used already-built, hash-verified product/dependency outputs (omit BuildProjectReferences=false for a fresh checkout):
The preceding reviewed tree has a passed canonical full build, Shared (6,214 passed / 29 ordinary skips) and Tray (7,121 passed) closeout. Per the requested proportional gate those containing suites were not rerun for this test-only diagnostic change; the local Tray UITests rebuild and three compiled-Gateway cases are fresh current-tree executions. Previous failures remain private historical evidence; no unrelated source or port policy changed.
Review follow-up verification
acceptanceSends:1). Undeclared duplicate upload digests are now rejected.Real behavior proof
Actual acceptance, not only inspection/dismissal: the native local and worktree actions each sent one real
taskSuggestions.acceptto the compiled Gateway, received an acknowledgment, published a different new session and reached terminal synthetic-model output. Both retained the original selected conversation, exact unsent draft and native editor; a stale callback sent no second accept. A separate read-only Git registry check found two registered worktrees, both existing inside the task root. The model endpoint/repository are synthetic; the Gateway registry/session/acceptance paths are real.The Starting frame uses a disclosed response-delivery barrier: the real Gateway acceptance reply has arrived, and only its delivery to the consumer is held while native Starting paints. This is not a fabricated acknowledgment or representative latency measurement. The menu is captured from its owned popup HWND, not assumed present in the owner PrintWindow image.
The local Started frame visibly shows its receipt. In the selected worktree post-terminal frame the card has already retired on authoritative refresh; acceptance and the new session are verified by its trace/receipt, while the exact original draft remains visible.
The upload manifest also includes current single/multiple stack, literal instructions, repository/failure, identity notice, late welcome and 480x360 real-root comparisons, both Companion Light/Dark frames and both accepted-launch sequences. Historical/current comparisons are labeled and scaled only (the early prototype is not a released-before build); all selected frames contain synthetic content and are cropped to owned windows. The actual Companion executable frames are distinguished from mounted-root/native harness frames. The parent must replace and verify every image URL placeholder before posting. Local files are not public evidence links.
Allowlisted excerpts of the actual local task RPC request/response (T1/S2 are per-run pseudonyms; auth, device identifiers, private paths, hostnames and raw session keys were never persisted in this trace):
[ { "direction": "request", "sequence": 3, "method": "taskSuggestions.accept", "mode": "local", "task": "T1" }, { "direction": "response", "sequence": 3, "method": "taskSuggestions.accept", "ok": true, "pendingCount": null, "task": "T1", "session": "S2" } ]The accompanying list trace observed a pending task before acceptance and no pending task afterward. Both local/worktree trace files record
acceptanceSends:1; their hashes and screenshot hashes are in the local proof manifest. Consumer source, loaded product/test/Microsoft-Reactor binary identity and relevant compiled-producer source/entry/build metadata are retained. The producer's build-info commit is null, so a complete upstream commit/dependency-tree or official-release identity is not claimed.Required proof pools
windows-11-arm64: native ARM64 build/runtime path; focused current-code results above, not a blanket pool-complete claim.windows-winui-interactive: current native task controls and actual Companion process; focused visible/keyboard/ownership proof above, not full accessibility coverage.windows-clean-installer-upgrade: requested latest-stable settings-preserving upgrade. Blocked pending an authorized disposable install lane and exact signed candidate artifact.Not verified / blocked
ClawSweeper response