Skip to content

feat: add MiniMax Code TUI and gated ACP Chat binding - #6520

Open
nikhilachale wants to merge 47 commits into
OrchestratorInc:mainfrom
nikhilachale:feat/minimax-tui-harness
Open

nikhilachale wants to merge 47 commits into
OrchestratorInc:mainfrom
nikhilachale:feat/minimax-tui-harness

Conversation

@nikhilachale

@nikhilachale nikhilachale commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator

Code changes: +1753 -24
Tests: +3441 -18
Others: +109 -4

CI recovery for a8a19e569: all 25 GitHub checks pass. The container download failed on a proxy.golang.org HTTP/2 INTERNAL_ERROR before compilation; the container retry passed on the same commit. The unchanged LAN tunnel and composer caret tests also passed on retry: backend gate, renderer smoke. No source or dependency changes were needed for this recovery, and no local checks/tests ran.

Lint follow-up in a8a19e569: the version-mismatch cache regression assertion uses errors.Is, addressing the single errorlint diagnostic from GitHub lint. No dependencies installed or local checks/tests run. All 25 GitHub checks now pass on this head; recovery details are stated above.

Review follow-up in f59496f0f: TUI standing context is emitted only on the first root UserPromptSubmit of each runtime launch. An exclusive launch-local marker prevents repeat injection; failed output releases it for retry, and restore prepares a fresh launch with updated context. Confirmed version mismatches are cached until InvalidateBinaryResolution (harness refresh); probe failures, timeouts, and caller cancellation remain retryable. Added regression cases for these boundaries without running them locally.

Installation deliberately requires the exact source-correlated MiniMax Code 0.6.5, installed manually. AO does not auto-install an unqualified npm-latest release for this adapter. After changing the installed version, refresh the harness to clear the cached resolution result. Shipping Chat registration remains disabled pending the stated qualification gaps.

The two remaining review concerns are fixed and all three already-addressed threads are closed. All 25 GitHub checks passed for the preceding merged head b018cbfbd; that head subsequently reported the test-only lint issue corrected above. No dependencies installed and no local builds, checks, or tests run for this revision, as requested.

Merged main at ff84e3b53 in b018cbfbd, preserving both MiniMax migration 201 and main migration 206 in the migration ledger. GitHub confirms the branch has no merge conflicts. All 25 GitHub checks passed for this merged head; current-revision CI status is stated above. No dependencies installed or local checks/tests run.

Native-restore CI fix in d8d1c1626: a source profile with credentials only in config.yaml can resume after MiniMax creates its own private auth/ state. Missing source auth leaves that private state intact and atomically refreshes configuration. Auth replacement rollback protection remains in place. Updated TUI/Chat and native-created-auth regression cases; no dependencies installed or local checks/tests run. Pre-merge native-protocol CI passes, including interruption/replay, native exact restore, and registered AO daemon qualification against the controlled loopback provider. All 25 checks subsequently passed for merged head b018cbf; current-head CI is green as summarized above.

Chat-context retention follow-up in afa6f17c3: process launches atomically replace one private .ao-chat-context.md file; an empty standing prompt removes it. Legacy per-launch .ao-chat-context-*.md files are cleaned up on subsequent launches without recursing into directories. Updated regression cases cover stable-path repeated launches, refreshed contents, empty prompts, and legacy/unrelated-file handling. No dependencies installed or local checks/tests run.

Launch-retention follow-up in 45a89e48c: successful runtime preparation prunes older launch directories after publishing the current snapshots and hook configuration. Failed publication preserves the previous snapshot; cached callbacks for pruned generations are refused. Cleanup checks AO profile ownership and is confined to the profile through os.Root. Regression cases cover failed/abandoned generations, retained current context, and unaffected native history/neighboring sessions. No dependencies installed or local checks/tests run.

Shutdown-settlement follow-up in 2a25e996b: native fencing requires an accepted local stop or a native cancelled result, including replay. Request-context cancellation alone does not trigger delegation-stop. Shutdown/detach cancels active settlement and suppresses recovery errors and receipt ACKs from the closing attachment. Added regression cases for cancellation classification, closed conversations, and shutdown/detach during settlement. No dependencies installed or local checks/tests run.

Credential refresh preserves private native auth state when source auth is absent while refreshing provider configuration; config-only restores are supported. Auth installation and config-write failures roll back the previous auth state, with recovery backups retained if rollback fails. Added missing-source regression cases for TUI/Chat reuse and config-write rollback cases with/without previous auth. No dependencies installed or local checks/tests run.

Prompt-reporting follow-up in a08646b62: activity callbacks are best effort and do not authorize prompt admission or prove that a runtime generation is current. Removed the callback-status refusal so a missing AO executable, nonzero exit, timeout, or reporting exception cannot block native input. Exact native conversation identity and bounded private-context validation remain enforced. Added regression cases for reporting failures and identity rejection; no dependencies installed or local checks/tests run.

Review fixes in 1e8a81d68: accepts valid dotted AO session IDs in profile validation and hooks; confines styled-only activity reconciliation to MiniMax so Claude/Codex retain older-host support; carries the immutable TUI launch path as a base64url hook-command argument while preserving TMPDIR/TEMP/TMP; and refreshes source credentials/provider configuration on each TUI launch while retaining the AO permission selection and native history. Malformed refresh configuration preserves the previous snapshot; symlink errors identify the resource.

Regression cases were added for those boundaries. No dependencies were installed, and no local builds, checks, or tests were run for this revision, as requested. Earlier qualification evidence below predates these fixes; pre-merge native-protocol verification is linked above; all 25 checks passed for the merged head b018cbf; current-head CI is green as summarized above.

Adds MiniMax Code TUI workers and a first-party ACP Chat candidate using shared AO Chat, private profiles, native permissions and live model variants. Stop now awaits the native delegation-stop receipt before committing interruption or announcing Ready; failed settlement preserves the durable receipt for recovery. Cancelled-result replay settles outside the transport reader with duplicate suppression and a bounded context. Reviewers and TUI↔Chat handoff remain unsupported.

Prior-head native and registered AO/API qualification passes against the official MiniMax Code 0.6.5 CLI and a controlled loopback model endpoint: streaming, approve/reject, executing-tool cancellation, immediate continuation, daemon replacement, archive and exact restore with refreshed private context. Real account authorization and actual AO UI screenshots remain NOT_RUN. Shipping Chat registration remains disabled. Full Go/Frontend CI status is recorded in the qualification comment; no local test/provider/UI execution ran.

TUI standing context uses supported UserPromptSubmit additionalContext from bounded immutable 0600 snapshots on the first root prompt of each runtime launch; later prompts do not repeat it. Restore creates a fresh launch and refreshes this context. Native identity, rules and permissions stay native-owned. Legacy identity-append histories are unchanged and refused for restore; authenticated wire-role proof and actual AO proof for the changed TUI hook route remain pending.

Removed 41 evidence/duplicate-doc files (10,930 added text lines and 8 images). Historical originals and failure scope remain accessible through verified immutable links. New runtime evidence belongs in PR comments/attachments, not source files.

@github-actions

Copy link
Copy Markdown
Contributor

🏆 Review leaderboard

Oct 3–10, 2026 · UTC

Rank Reviewer PRs reviewed Review rounds PR comments
🥇 @illegalcall @illegalcall 28 47 11
🥈 @ronishrohan @ronishrohan 20 23 17
🥉 @Vaibhaav-Tiwari @Vaibhaav-Tiwari 15 19 11
4 @Prasad-D-Ware @Prasad-D-Ware 10 27 1
5 @nikhilachale @nikhilachale 9 22 3
6 @axisrow @axisrow 8 10 44
7 @mohakchakraborty2004 @mohakchakraborty2004 7 7 1
8 @Rishet11 @Rishet11 6 15 2
9 @Pritom14 @Pritom14 5 5 3
10 @codebanditssss @codebanditssss 4 4 2

Ranked by distinct external PRs reviewed, then review rounds, then PR comments. Self-activity and bot activity are excluded.

Show 6 more reviewers
Rank Reviewer PRs reviewed Review rounds PR comments
11 @Annieeeee11 @Annieeeee11 3 6 1
12 @harshitsinghbhandari @harshitsinghbhandari 2 4 0
13 @neversettle17-101 @neversettle17-101 2 3 0
14 @whoisasx @whoisasx 2 2 0
15 @AgentWrapper @AgentWrapper 1 3 0
16 @ApexYash11 @ApexYash11 1 2 0

@nikhilachale

nikhilachale commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator Author

Preserved AO failure evidence, attached at 621053876ff01230dd5287da299df38a73fca62b.

AO attempt 001 visibly refused the initial turn because the original hook resolved the wrong profile from MiniMax's plugin cache. Capture record · provenance.

AO 001: retained native hook refusal

AO attempt 002 shows the successful initial proof and second edit, then a retained cancellation draft after exact restore. Its frozen result remains cancellation FAIL (45 seconds) and empty-input readiness BLOCKED. Gate summary and capture record · provenance.

AO 002: retained draft after restore

Current head includes the reviewed composer detection fix; focused tests, pinned lint, and captured-output checks passed. A separately timestamped one-Ctrl+C control confirmed audit draft clearing on the same native session. Fresh complete lifecycle validation is pending. AO auth remains configured/unverified, with the strict authentication gate BLOCKED.

@nikhilachale

nikhilachale commented Oct 10, 2026 •

Copy link
Copy Markdown
Collaborator Author

Final live audit evidence at functional source 17a1467a404234f34d8bc8824d293993e1703564; documentation/assets head e83c478c962d3a0b43e617061e3232af078e668d. AO binary SHA-256 4b47bd780af069862dffd9ace01bb768fca6e5ae9959956da15fe7e75faabf7e; runner SHA-256 8887aa2e7101b9e6d3950bfca08ffddf2e1e6c1c3f1d030c8dec2676443aecea.

AO004: 28 PASS, 1 authentication BLOCKED, no FAIL/NOT_RUN; strict overall BLOCKED, diagnostic-only. mcode 0.6.5 / Z.ai / glm-5.3-flash. AO session audit-minimax-code-acbea22e-1, native-ID SHA-256 fd7a69d95770906f65b69ddf93dcc012a3457326327446cb044a2cb5706525a4. Frozen gates.

All functional gates passed: initial/second mutation, hidden/project instructions, activity, native identity, observed active-turn cancellation, guarded one-Ctrl+C draft cleanup with exact recovery-file presence/removal, confirmed termination, same-ID/workspace restore, initialized empty composer, continuation/history/file preservation, fresh restore-only instructions and model agreement. Provider success does not verify the auth probe. Cancellation is not proof that an already-running subprocess was reaped.

Actual retained restored session captured in AO Electron on this VPS at 2026-10-10T14:53:58.011881Z using scrot on owned Xvfb; UI source matches functional source. PNG SHA-256 30419d725e8f6ed3d39547e4d28041d8f9befbfedd2d2afa7e1f67747ef14da0. Visually inspected: selected AO session, native post-restore mutation, empty composer and model; no credentials/raw native ID visible. The transcript shows a queued wait completing after restore. No native input/new provider turn was sent for capture. Provenance.

AO004 restored continuation inside real AO Electron

AO003 remains cancellation FAIL, cleanup BLOCKED without input, kill/restore NOT_RUN. Native Stopped/draft was visible but raw Ring.Tail omitted the unterminated footer; AO remained active. Final correction uses existing rendered-surface capability with current tail-fenced cues and no stale fallback. Captured 14:33:22.726970Z, functional/UI source a15b135cd4dcb7b227a0b95a93ee4162541b3e0d, binary 7a20be24b279cd8b09d4f55432aa98d21a31fa66fd81a6291cf8148dde52d2bc. PNG SHA-256 da6db062f62e80493b6199328f3e115410bb97a5175e18915c32567022bbcff3. Full provenance. AO001/002 earlier failures remain in their published comment.

AO003 retained cancellation failure inside real AO Electron

Both revision-pinned PNG URLs returned HTTP 200 and matched local SHA-256. Exact stored provider-key scan: 46 intended files, zero matches; git diff --check passed. Owned AO004 session termination confirmed through API, then exact verified daemon/Electron stopped. Original audit report was not overwritten. Sources, profiles, reports and captures retained.

Final validation: exact evidence head e83c478c962d3a0b43e617061e3232af078e668d has 23/23 GitHub checks PASS, as did functional head17a1467. Backend/race/API/sqlc/lint · frontend/renderer · native OS/container. Full local pinned golangci-lint2.13.2 completed exit0 with 0 issues.

The single final local timeout 1800 go test -race -count=1 -timeout=20m ./... attempt is INCOMPLETE with observed failures, bounded at30minutes after service/usage. Captured179 package passes, five failed packages, zero DATA RACE warnings. Failures: fake lifecycle missing events.log; opencodev2 malformed-version fixture affected by installed OpenCode1; ACP large-history replay peer disconnected; service/agent private-file unsafe-mode rejection; chat50ms render deadline took3.082s. These are observed, not proven baseline failures. Remaining packages were not reached locally in this attempt. The original launcher returned143 while timeout/go survived and were monitored alone to the bound; no complete suite exit code is claimed. No unrelated fixes or whole-suite retry. Local frontend tsc exit134 was not rerun; its CI gap is closed at the exact head. All OS-specific results above are CI results, not local Linux passes.

@i-trytoohard i-trytoohard added this to the Agents & orchestration milestone Oct 10, 2026
@i-trytoohard i-trytoohard added comp/daemon Go daemon, process lifecycle, and backend control plane. enhancement New feature or request labels Oct 10, 2026

@nikhilachale nikhilachale left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Read-only review of head e83c478. Changes are warranted for the three P2 findings below; I do not recommend approval at this head. I traced the adapter through session launch/restore, hook projection, lifecycle precedence, terminal observation, model/install metadata, generated API declarations, and SQLite migration/reconciliation, and compared native contracts with the pinned MiniMax v0.6.5 source (309e28554ec091bb17b6c4f67111c8c01d688b94). No migration-number collision was found against current main fbce287. No local tests, builds, linters, or validation suites were run, as requested. This is a COMMENT review because the authenticated GitHub identity is the PR author, which cannot submit a formal request-changes/approval review on its own PR.

Comment thread backend/internal/adapters/agent/minimaxcode/minimaxcode.go
Comment thread backend/internal/adapters/agent/minimaxcode/history.go Outdated
Comment thread backend/internal/adapters/agent/minimaxcode/assets/hook.cjs Outdated
Comment thread backend/internal/adapters/agent/minimaxcode/profile.go
Comment thread backend/internal/adapters/agent/minimaxcode/activity.go Outdated
Comment thread backend/internal/skillassets/using-ao/commands/spawn.md Outdated
@nikhilachale

Copy link
Copy Markdown
Collaborator Author

Harness-specific reports, JSON receipts, screenshots and provenance now live on this integration PR branch, rather than the skill PR #6509.

Evidence index with embedded screenshots and JSON links.

Historical successes, failures and scope limitations remain as recorded. Moving these files does not rerun native/AO testing or upgrade any verdict.

This is evidence relocation only. Existing tested source/native hashes and failures are preserved; the documentation commit is not a fresh runtime pass. Applicable checks run in PR CI.

Recorded harness evidence — see scope above

Preserve harness-owned evidence and merge current canonical API, storage, and native Chat updates. Runtime proof remains qualified by its original source.
@nikhilachale

Copy link
Copy Markdown
Collaborator Author

Canonical main conflicts reconciled at a4aba52d9527, preserving previous source/evidence ancestry and every existing harness report/screenshot byte. Reconciliation receipt.

Validation is PR CI only; current-head checks are pending until GitHub reports them. This merge does not constitute a new native/AO run or promote historical fresh/restore/provider-role proof. Harness evidence stays on this integration PR; PR6509 remains reusable guidance and linked summaries.

Build the real daemon in PR CI for isolated VPS runtime verification without local validation suites or dependency installations. Record source revision, Go build info, and executable hash.
@nikhilachale

Copy link
Copy Markdown
Collaborator Author

Canonical main conflicts reconciled at 00df8abd4aeb, preserving previous source/evidence ancestry and every existing harness report/screenshot byte. Reconciliation receipt.

Validation is PR CI only; current-head checks are pending until GitHub reports them. This merge does not constitute a new native/AO run or promote historical fresh/restore/provider-role proof. Harness evidence stays on this integration PR; PR6509 remains reusable guidance and linked summaries.

@nikhilachale

nikhilachale commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator Author

Historical pre-fix qualification. The cancellation and replay fixes, current PASS receipts and remaining UI/auth scope are in the updated qualification report. Original failures below are retained with their original source scope.

MiniMax Chat qualification — cleanup head b75f8dc0dd4e9de6d7d30998d950910737baef9a

Runtime evidence below was captured at f631d336e117bed7dbb30f615099c21d39a26b44. The cleanup head removes 41 evidence/duplicate-doc files and adds two explanatory Go comment lines only; it changes no runtime behavior. New-head CI results are separate from those historical receipts.

Chat is implemented as a gated candidate, not enabled in the shipping registry. PR remains draft. The current pinned MiniMax Code 0.6.5 has a reproducible cancellation/readiness failure. The existing shared AO Chat renderer is reused; no provider-specific React screen or renderer-side ACP client was added.

Source scope: base 933fa5bb1e347c12cd9ee66080a935f9ff97deec; official @minimax-ai/code@0.6.5, Node24/Linux, Python3. The actual released CLI, ACP transport and AO detached host ran against an isolated credential-free loopback Anthropic endpoint. Only the model endpoint is scripted. These results establish native protocol/tool/history behavior and instruction delivery, not real account authorization, model reasoning or actual AO UI coverage. No local build, tests, formatter, native/provider or UI runs were executed.

Native evidence at the pre-cleanup runtime revision

Native run at f631d336e1 · original log/format artifact (14-day retention; essential receipts retained below).

Step Result Functional proof
Official CLI and ACP identity PASS Official0.6.5 install, binary/version and minimax-code ACPv1 handshake; exact native mvs_ identity.
Configured model and native permissions PASS Catalog model resolves to its advertised native variant; native permissionMode reads back default. Explicit native whole-Bash Ask policy is preserved in the private profile.
Stream and initial private context PASS Multiple partial chunks before completion; the actual model request contains fresh private context.
Approve PASS Offered allow-once decision; protected file absent before approval and written afterward.
Reject PASS A separate offered reject-once decision; rejected protected file remains absent.
Stop executing tool PASS Actual tool PID plus Linux kernel-start witness observed running, then exact process stopped within5s and turn settled interrupted.
No delayed side effect PASS Provider stays alive until a13s deferred check, beyond the tool's12s delayed-write deadline; late artifact absent even when continuation fails.
Immediate continuation after Stop FAIL Native rejects the new prompt with -32603 active-turn error below. No full interrupt/continuation PASS.
Replacement-process exact restore PASS Independent control hibernates/replaces provider, loads the same native ID/workspace and retains ordered, repeatable history without duplicate event identities.
Fresh private context after load PASS, delivery scope Marker introduced after hibernate appears in the actual post-load model request alongside prior history; private context absent from native user/assistant transcript. Independent real-model consumption NOT_RUN.
Missing history and wrong workspace PASS Typed restore refusal; missing-ID control explicitly requests FreshIfMissing=true, which the binding refuses to turn into a fresh conversation.
Registered AO daemon/API journey BLOCKED / NOT_RUN CI candidate registry overlay and real-daemon test exist, but dependent execution correctly skips after the required native gate fails.

Essential f631d33 log receipts:

PASS native streaming and initial private context delivery
PASS native ao-approve decision and protected side-effect boundary
PASS native ao-reject decision and protected side-effect boundary
PASS exact active-tool process cancellation and interrupted settlement
FAIL immediate continuation: ACP session/prompt code=-32603
Internal error: MiniMax Code Runtime failed: Session already has an active Turn. Use queue send to deliver the message after it.
PASS no delayed side effect after native cancellation
FAIL TestNativeMiniMaxACPConformance (18.67s)
PASS replacement-process exact native load and stable ordered history replay
PASS fresh private context delivered after exact native load
PASS native missing-ID and mismatched-workspace restore refusal
PASS TestNativeMiniMaxACPExactRestoreConformance
Overall native qualification: FAIL (31.502s)

The native cancelled result can arrive before its underlying active-turn lease releases. Pinned ACP completion/cancel handlers, native lock rejection and controller release explain the observed ordering. No authoritative root-idle fence was found in the advertised ACP methods. A text-matched retry would require discarding an uncommitted host failure receipt and create a crash-recovery ambiguity; no sleep, silent requeue or broad retry machinery was added. A corrected native contract/version must be independently qualified before enabling Chat. Newer published versions were not executed or declared compatible.

Reproduce on an authorized Linux host with official0.6.5, Node24 and Python3 installed, from backend/:

AO_NATIVE_MINIMAX_ACP=1 go test -race -count=1 -v -timeout=8m \
  ./internal/adapters/chatdriver/minimaxacp \
  -run '^TestNativeMiniMaxACP(Conformance|ExactRestoreConformance)$'

Required AO screenshots and live journeys

No current-head AO UI screenshots were captured. Local app/provider execution is excluded by the user's execution-host constraint; remote CI did not launch an actual AO UI. Chat admission remains blocked by the native failure. Earlier TUI images are not relabeled as current Chat proof.

AO user step Status Screenshot / missing proof
Agent Harness discovery NOT_RUN Actual current-head page capture unavailable.
Download/install from Agent Harness NOT_RUN Native CI installation is separate from this AO button journey.
Login / Connected / configuration NOT_RUN No actual UI or authenticated provider authorization.
Agent Harness model list NOT_RUN Native model selection does not qualify this UI surface.
Model on/off persistence and provider controls NOT_RUN No actual UI control/routing journey.
New Task agent, Chat choice and models BLOCKED Candidate intentionally unregistered; no screenshot.
Task running and follow-up in shared Chat BLOCKED Registered AO/UI journey not executed; no screenshot.
Shared Chat approve/reject/Stop BLOCKED Standalone native receipts above are separate; no UI screenshot.
AO Kill → Archived BLOCKED Native hibernate is not AO archive/board proof.
AO Restore → Kanban card BLOCKED Native exact-load proof is separate from AO restore/board capture.
UI reconnect and daemon recovery BLOCKED Real-daemon test exists but has not run past the native gate; no UI proof.
Reviewer and TUI↔Chat handoff Outside this Chat change No claim of added support.

Preserved earlier attempts

First checkpoint retains the initial workflow/model failures. Later attempts remain separate:

  • 8f21224812cbc4d898cdafc0ef1b4861a4985c47: request-correlation failure. Native enriched the user text; the fixture looked up a plain prompt key. This did not prove missing instructions. Corrected with standalone-label correlation and regressions.
  • 1698e7a7bd68b94d772910e81eb207e25e8d6a45 and 7026395ddb76273d403dcd36645eda646c59d4db: first incomplete diagnostic, explicit failure receipt: previous ACP prompt is active or not acknowledged was AO host admission, not MiniMax. Standalone consumer now ACKs the exact terminal receipt and waits for ready, matching the daemon controller. Bash timeout units were also corrected to native seconds; that change alone was not established as the cause.
  • 0dc81f0a83a47ba6820b0ff8485f5a2e6559810e: no pending native approval; native allowed the safe operation. Investigation found missing global permission.json copying. The binding now preserves native policy; fixture uses a documented explicit Ask rule.
  • ed7d93a075c20a403bf555f99d3987bd60c3a777: genuine immediate-continuation failure, with approval/rejection now passing.
  • ca6acbd03f7ff448f5a603fbcd7593b024a745b0: independent restore proof and retained cancellation failure. The pre-cleanup runtime revision repeats these outcomes.

New runtime evidence remains in PR comments/CI attachments and owned temporary paths, not committed audit reports, logs, JSON receipts or screenshots. Source contract docs and reusable synthetic tests remain normal source. Legacy TUI evidence and duplicate contract docs were removed from the current diff after all 41 immutable source destinations were verified against the original bytes/hashes. Historical migration index preserves their original failure labels and limited scope. Cleanup targets only owned test sessions/profiles; this does not qualify the separate real AO cleanup/UI journey.

Completed pre-cleanup CI receipt

All workflows below completed on f631d336e117bed7dbb30f615099c21d39a26b44; no earlier green run is substituted.

Workflow Result
Go: complete backend/cloud/race suites, lint, API/SQL drift and Windows checks SUCCESS
Frontend: full tests/typechecks, renderer smoke and native helper SUCCESS
CLI E2E SUCCESS
gitleaks SUCCESS
Harness release feeds SUCCESS
Required MiniMax ACP conformance FAIL: immediate continuation after cancellation; independent exact restore PASS. Dependent registered API qualification SKIPPED.

The source worktree is clean and the PR remains draft. No local execution or complete integration/production-readiness PASS is claimed. Native failure, registered AO/API, real authorization and actual UI/screenshot gaps remain explicit above.

Cleanup-head CI

Head b75f8dc0dd4e9de6d7d30998d950910737baef9a. Static git diff --check passed. No local suites or provider/UI execution ran. Remote workflows are recorded below at publication; pending runs are not marked passed.

Workflow Status Result
Frontend in_progress PENDING
Harness release feeds completed success
gitleaks completed success
MiniMax ACP conformance completed failure
Go in_progress PENDING
CLI E2E completed success

The cleanup-head native log repeats the original blocker after successful stream/context, approve/reject and exact tool cancellation: immediate continuation at native_test.go:163 fails with ACP -32603, Session already has an active Turn. The 13s delayed-side-effect check still passes. Independent TestNativeMiniMaxACPExactRestoreConformance passes (11.10s); overall native suite fails (29.554s). Registered API execution remains skipped; no UI screenshots or real-provider authorization are claimed.

@nikhilachale nikhilachale changed the title feat: add MiniMax Code TUI harness feat: add MiniMax Code TUI and gated ACP Chat binding Oct 17, 2026
@nikhilachale

nikhilachale commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator Author

Historical evidence relocation before PR cleanup

This cleanup removes 41 PR-added files / 10,930 added text lines, including 8 historical PNGs, from the current diff:39 audit/evidence/index files and2 duplicate research/integration documents. Runtime behavior and tests are retained. The native0.6.5 cancellation/readiness blocker remains; Chat is still unregistered and the PR stays draft.

The originals were already published in commit f631d336e117bed7dbb30f615099c21d39a26b44. That commit remains in normal branch history; no history rewrite is used. Every path and original Git blob was verified against GitHub's published tree, and byte counts/SHA-256 hashes are retained below. An independently verified archive also exists outside the checkout. These are existing historical records and images, not new runtime proof or current-head AO screenshots. Original failure labels, capture provenance and standalone-versus-AO scope remain in the linked companion files. Relocation does not upgrade any result.

Current Chat qualification, original failures and UI gaps remains the runtime report. New evidence continues to belong in PR comments/attachments.

Original file (immutable historical link) Bytes SHA-256
docs/harnesses/minimax-code-chat.md 8864 8b5320012d1f6f0936ede311bc6f8f087f7c1d2621f3dbd813dbd2872c980e78
docs/research/assets/minimax-code-prompt-audit-20261012/README.md 3334 476d914ce7ab35b9cb1800382eed158238b10ed3498154973ed57e567d7a8cae
docs/research/assets/minimax-code-prompt-audit-20261012/acp-ci-budget-reconciliation.json 1009 74bc52da40543c3aee511297a313cfd6fe09586a8e1134fea521083090579737
docs/research/assets/minimax-code-prompt-audit-20261012/asset-manifest.json 4301 b730400af5563684bda491b1639ae9e8521021ac21af93b69be33fec66f53e46
docs/research/assets/minimax-code-prompt-audit-20261012/main-reconciliation-002.json 776 fb1b28254545035488d5198b16929d068a4b9cdd3d01eddefcfcc6a79f077058
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-artifact.json 5560 505744d9772f41a1baa7b847a3c36ede0f2f34fa740da77dc8501a1924368b42
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-baseline-cleanup.json 912 d6a5b2dcaaa8ac4943a764ba050a7a0cbbcd37b327497dce56c5e90755099e21
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-control-001/receipt.json 1444 e4bf1a58abf17518139770db17ffd6147aeb2bcfe3456e4a81c2f7689736c718
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/cli-input-current-token-assessment.json 472 8fe858b484d3bf6b48b6c7c5d47d0cd506b259aac5a9362affe4729143f7b2b1
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/corrected-native-reap-assessment.json 877 99a705ca13169ad22e74ff064f0d62a15eafbe5be0aaf8b1f2d2af524ba737d5
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/executing-cancel.json 16744 ab188efcba048f9e4bda8e77bbd7a42f72e00c50c37fae3f4b9d3a4e302df0e4
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/executing-kill.json 115 f69b61333cd0e8c29371eafd7f03d808556ba955d27d59cacce74bbb80d3d95a
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/first-restore-assessment.json 298 69d0066e94f69291f4d22dc3e3a280216cad6682b08efb4aabfc3fa30e11713e
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/first-restore-unqualified-process-reap.json 2304 006c0941fb68b2f5ba62eb1fab0b267a618281bee1da74f6d91e8a5e9ebbc6cf
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/fresh-stock-private-project-user.png 118622 26592688d8769b6d59812e971392fac13583be0c50aaadfdb74e67031c272435
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/receipt.json 3318 2baf63cd1f5a51ca90a832926031d7838d8e14b37d3ff5c6d44a0b78e1d49f4a
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/restore-same-private-target-failure.json 315 eb4a8bb5019136bdcb39d5798e7fc5c48a1d843b418ff23232bdcbc2277c9fa0
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/restored-distinct-target-empty-composer.png 66330 3cbee3940a1485b6c95dabcba7ad20bd4b05c2c0ab3dee4d06a0d793bc7e6e65
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/restored-distinct-target-ready.png 107714 15eb34a5a267b622c4d3071f412e4e36278ee775f401a274aaf49c429b84514b
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/restored-stock-empty-composer.png 108141 c4b70b20b9153d24a06fcdf6c6393520247025bc87ba4b917cdba4fd28440a5e
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/retained-draft-capture-unavailable.json 251 c331a997dca0e4b87449437ed089a6c3dd397279e62b975949c3e9f5d783f966
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-focused-001/serving-fresh.json 1205 27841874143197a983428c2ea75c5f775f1a845958dbd7cd495af3102db013ab
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-native-provenance.json 222721 2c470ff3b55b8f879e2377c1f330e49fc554b7ab62559188c1ccf91ce45e33bd
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-official-distribution-probe.json 1725 0977c4bb85753bf6512acc0cef9e17c3a94e81c4a0199611e7e566471f5febf0
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-official-install.json 229821 7e2a3777469a8fee25b8f31f670bfc0953e0ebf1961c0ba892964cf525b31705
docs/research/assets/minimax-code-prompt-audit-20261012/minimax-stock-provider-config.json 561 cd9d518e9f704c326a04b3d02ecd96208ca1d685a4c774875c4e2c574ea81bd3
docs/research/assets/minimax-code-prompt-audit-20261012/reconciliation.json 882 1c829d9121e68634adedddf9b0b3cc00a7cb990030bcfa97cc6d5b65a1ccedb7
docs/research/assets/minimax/minimax-ao-001-retained-failure.md 2226 94e55773aeea57c807d63265cfe77acf6d5e134896b9117f577d46fa4ce8c5b3
docs/research/assets/minimax/minimax-ao-001-retained-failure.png 106995 e9f6efdf08876e4ebe2e938c6d405ab65e90785bd46665fc0ec1ca166fbdfd24
docs/research/assets/minimax/minimax-ao-001-retained-failure.provenance.json 1390 f65952eb733413e697842214e96976a20ae2ec66cf4a774f24a82b48d6d74c3c
docs/research/assets/minimax/minimax-ao-002-retained-draft.md 3080 71218ec94b3fba058de0c71fd09d8b97e3a93454d075cbfce567333a07791b52
docs/research/assets/minimax/minimax-ao-002-retained-draft.png 125651 e0a690e4c7a274b301f58aebf9965ac923a5e011ba64ff70fc86adaac885991b
docs/research/assets/minimax/minimax-ao-002-retained-draft.provenance.json 1533 4d2aa9d7092242790133eb764e63315beedb73b9fb43eaf6d9483a3f246ac03d
docs/research/assets/minimax/minimax-ao-003-cancellation-failure-dark.md 666 0af94cb07a7b749c0431b868fe6ab475a5e98d8659e23f284c0335ff9cce54ac
docs/research/assets/minimax/minimax-ao-003-cancellation-failure-dark.png 110355 da6db062f62e80493b6199328f3e115410bb97a5175e18915c32567022bbcff3
docs/research/assets/minimax/minimax-ao-003-cancellation-failure-dark.provenance.json 2179 5037a15c1340c6f5995ea1a279cdd7594f75b83f002c9adbd878887776f566fb
docs/research/assets/minimax/minimax-ao-004-gates.json 4759 7292f3dd36b4393c915eef94e82774476335fcef88c9890760d51b9fccbdeba8
docs/research/assets/minimax/minimax-ao-004-restored-success-dark.png 113940 30419d725e8f6ed3d39547e4d28041d8f9befbfedd2d2afa7e1f67747ef14da0
docs/research/assets/minimax/minimax-ao-004-restored-success-dark.provenance.json 1664 2d7f40b4440ff959c69fce756982b2033cae3f27e985b1d71ba96b5f45c90184
docs/research/minimax-code-evidence-index-2026-10-12.md 2276 cb2f72b8869b4df9b257679abef91a056aac9740a65b910a8e0fd84c20a05538
docs/research/minimax-code-tui.md 12147 f75dc6b1107340bf88d8f38bbbc76f3514ffea988e5a72b0f9edcf036cca3992

Historical images already published in that commit are embedded below. These retain their original scope and are not claimed as current Chat/UI verification. Read the companion receipt/provenance files above for each original capture.

Historical capture: fresh-stock-private-project-user.png

Historical capture; original scope/provenance in the index: fresh-stock-private-project-user.png

Historical capture: restored-distinct-target-empty-composer.png

Historical capture; original scope/provenance in the index: restored-distinct-target-empty-composer.png

Historical capture: restored-distinct-target-ready.png

Historical capture; original scope/provenance in the index: restored-distinct-target-ready.png

Historical capture: restored-stock-empty-composer.png

Historical capture; original scope/provenance in the index: restored-stock-empty-composer.png

Historical capture: minimax-ao-001-retained-failure.png

Historical capture; original scope/provenance in the index: minimax-ao-001-retained-failure.png

Historical capture: minimax-ao-002-retained-draft.png

Historical capture; original scope/provenance in the index: minimax-ao-002-retained-draft.png

Historical capture: minimax-ao-003-cancellation-failure-dark.png

Historical capture; original scope/provenance in the index: minimax-ao-003-cancellation-failure-dark.png

Historical capture: minimax-ao-004-restored-success-dark.png

Historical capture; original scope/provenance in the index: minimax-ao-004-restored-success-dark.png

Cleanup applied

Commit b75f8dc0dd removes all 41 indexed files from the current PR diff. Before removal, all 41 immutable GitHub destinations were fetched and verified byte-for-byte with SHA256; all 8 images had valid PNG signatures. Originals remain in normal Git history; no history was rewritten. Final PR diff: 51 files, +4,030 −33, zero binary assets. Cleanup changes no runtime behavior. Historical failures and screenshot limitations above remain unchanged.

@nikhilachale
nikhilachale marked this pull request as ready for review October 17, 2026 06:51
@nikhilachale

nikhilachale commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator Author

MiniMax cancellation fixed — current head ef3e216f0e48d078e2514ee7e44ea3d19c79e194

Current-head MiniMax native + registered AO/API workflow: SUCCESS. Official @minimax-ai/code@0.6.5, Linux/Node24/Python3; no patched CLI or replacement ACP executable. The native CLI, ACP transport, AO daemon, API, SQLite, worktrees and tools are real. Only the explicitly configured credential-free loopback model endpoint is scripted. This proves protocol/tool/history/context delivery, not real account authorization, real-model reasoning or actual AO UI screenshots.

Fix: e6d5bb3601. MiniMax's cancelled prompt can arrive before the runtime releases its root turn. AO now awaits supported mcode/session/delegation/stop and validates schema v1, the exact root, confirmed root stop, and empty active/failed delegate lists before terminal commit/Ready. Native extension, stop receipt and abort release boundary establish that this is a native settlement receipt. The earlier claim that no usable native boundary existed was incomplete and is corrected here.

No prompt retry, fixed readiness sleep, native patch or version substitution was added. On timeout, transport failure, malformed/wrong-session receipt or outstanding work, AO retains the active turn and uncommitted host receipt, reports recovery-inconclusive/Stopped, and rejects another prompt. A replacement daemon replays the receipt and verifies settlement again. Regression cases cover admission ordering and incomplete/failed receipts.

The independent review also found a cancelled-result replay deadlock in the first fix: terminal replay was handled on the sole transport reader, so awaiting a stop RPC there blocked its own response. The final code atomically claims the replayed receipt and settles on one worker outside the reader; duplicate replay cannot start another settlement, and active-turn admission remains fenced. Native item settlement follows successful quiescence. Replay carries context.WithoutCancel(ctx) with a separate 10s native hook deadline.

The new real net.Pipe regression first failed before the fix: TestPersistentACPInterruptedReplayCanReadSettlementResponse, timed out waiting for event (2s). The same regression now passes with -race, proving receipt RPC response consumption, duplicate replay suppression, interrupted completion, Ready and exact terminal ACK. Independent static review found no remaining actionable issues after the final context change.

Current-head functional receipts

Step Result Proof
Persistent cancelled-result replay and admission PASS, race-enabled transport regression Replayed terminal, stop RPC/reply, duplicate suppression and exact ACK without blocking the reader.
Official native stream and private context PASS Actual model request carries initial context; multiple chunks before completion.
Native approve/reject PASS Offered decisions; protected side effect only after approval, absent after rejection.
Executing native tool Stop PASS Exact PID/kernel-start witness stops; native turn settles interrupted.
Immediate next message PASS Same-session follow-up completes after verified native release.
Delayed cancellation effect PASS Late artifact absent beyond the tool deadline.
Independent exact native restore PASS Same native ID/workspace, stable history, fresh post-load private context; missing/wrong-workspace refusal.
Registered settings and explicit Chat spawn PASS, CI-only registry overlay Actual AO settings/API, isolated worktree, native owner and initial context.
Idempotent API send and streamed projection PASS One durable turn, one native dispatch, one worktree mutation.
API approve/reject PASS Native offered decisions and protected side-effect boundary.
API Stop and immediate continuation PASS Exact executing native tool stops; same-session continuation succeeds.
Actual daemon replacement PASS Surviving exact detached host adopted; no duplicate dispatch or timeline loss.
AO Kill/archive → exact Restore PASS, API scope Confirmed native teardown and terminated record; exact identity/workspace/conversation restored.
Fresh context after AO restore PASS, delivery scope Token introduced only after confirmed Kill appears in actual post-restore model request; prior history and worktree edit retained.
Final isolation PASS No late cancellation artifact; project source checkout unchanged.
Actual Agent Harness/New Task/Chat/board UI, install/login, model toggles NOT_RUN CI did not launch AO UI; no screenshots or real provider authorization. Historical images are not relabeled.
Reviewer and TUI↔Chat handoff Outside scope No new support claimed.
PASS TestNativeMiniMaxACPConformance (18.61s)
PASS TestNativeMiniMaxACPExactRestoreConformance (12.39s)
Native suite: PASS (31.988s)
PASS TestNativeMiniMaxRegisteredChatAPI (50.96s)
API suite: PASS (50.961s)
CI formatting diagnostic: empty patch

Shipping Chat registration remains disabled; candidate registration above is a CI-only source overlay, not a shipped feature flag. PR stays draft pending full integration/UI qualification. This green check does not fill the missing UI/auth rows.

Preserved failure progression

  • Original pre-fix report, failing b75 native run: immediate continuation rejected with -32603, active turn still held.
  • e6d5bb3601 run: native cancellation/continuation and exact restore PASS; newly reached API initial-context assertion FAIL. The fixture stored only the last label-matched request, allowing tool-free title/suggestion calls to overwrite the worker receipt. Current fixture separates worker receipts using the advertised Bash catalog; regression retains the private-context assertion. Initial formatting failures were corrected using CI-produced formatting deltas.
  • adde537b95 run: initial API private context PASS; idempotency assertion FAIL because it incorrectly expected duplicate responses to repeat a turn ID. Existing AO API deliberately returns duplicate: true and an empty turn ID. Current test honors that contract and still verifies one original durable turn and one native dispatch.
  • a1066df789 replay regression: expected RED before replay fix, timeout waiting for terminal event. Fixed in 3886f0c39c by moving settlement off the reader with an atomic single-worker claim.
  • 3886f0c39c run: replay/native/API PASS; full Go lint reported error wrapping in the regression and G118 for background context on the replay goroutine. Both corrected explicitly in the final head; no lint suppression.
  • Current ef3e216f0e48d078e2514ee7e44ea3d19c79e194: replay and both complete native/API qualification suites PASS as linked above; final-head lint also PASS.

Remaining CI and evidence ownership

Current-head Go and Frontend full workflows are still running at publication. Native/replay/API, lint, API/SQL drift, CLI native/container checks, release feeds and gitleaks have passed. Pending full suites are not called passed. Independent static review is complete with no remaining actionable findings.

No local build/tests/formatters/native/provider/UI execution ran. Only static local reads/edits/diff checks were used; all execution receipts above are from GitHub CI. Evidence stays in PR comments/CI attachments and temporary paths outside the checkout. Historical evidence migration remains unchanged in scope.

@Prasad-D-Ware Prasad-D-Ware left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review of the MiniMax Code TUI/Chat integration at 1e8a81d. I've left five inline comments; I traced each one in the code but didn't run anything. The most important is the UserPromptSubmit generation check in hook.cjs: as written it can't detect a stale runtime. The credential-refresh comment can delete a working auth/ snapshot. The other three are a misleading recovery error on shutdown and two places where files pile up under ~/.ao.

Comment thread backend/internal/adapters/agent/minimaxcode/assets/hook.cjs
Comment thread backend/internal/adapters/agent/minimaxcode/profile.go Outdated
Comment thread backend/internal/adapters/chatdriver/acp/conversation.go
Comment thread backend/internal/adapters/agent/minimaxcode/profile.go
Comment thread backend/internal/adapters/chatdriver/minimaxacp/driver.go Outdated

@Prasad-D-Ware Prasad-D-Ware left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-reviewed the changes since my last review (1e8a81d → d8d1c16). All five comments are addressed, and I have no new blocking findings.

  • hook.cjs: the exit-status guard is removed, and ao hooks now runs as best-effort reporting. A process from an earlier generation is now stopped by the pruned routing.json (its hook fails closed) instead of by a check that never fired.
  • refreshProfileCredentials: a missing source auth/ keeps the private auth, a non-directory source is rejected, and a failed config write or a cancel after install rolls auth back. If the rollback itself fails, the backup is kept.
  • conversation.go: the fence now runs only for an accepted local stop or a native cancelled result. The closed/detaching check and the stored settlement cancel are guarded by the same lock as closeProvider, so shutdown can't slip through and wait out the 10s timeout. The new tests cover shutdown, persistent detach and a context-cancelled request.
  • Launch pruning: this runs only after the new generation is fully written. It checks the ownership marker, works inside an os.OpenRoot root, and skips names that aren't launch IDs.
  • Chat context file: there's now one stable .ao-chat-context.md, replaced atomically, and per-launch copies left by earlier builds are swept.

Non-blocking note: because the private auth/ is now kept whenever the source has none, a user who logs out by deleting ~/.minimax/auth will still have the old credentials used by existing AO sessions. That seems to be an intended trade-off for config-only providers (d8d1c16). It may be worth a line in the docs or in AuthStatus.

CI: all 25 checks pass on d8d1c16.

@Prasad-D-Ware

Copy link
Copy Markdown
Member

Thanks for the merge with main. I re-checked b018cbfbd: the conflict in the migration list is resolved correctly (0201 and 0206 are both kept). 0201 only widens the sessions.harness CHECK, so it's safe to run after 0206, and CI is green.

Before we approve, could you answer the two open review threads? Neither has a reply or a code change yet:

  1. Prompt-size injection (hook.cjs): up to 512 KB of standing.txt is added as additionalContext on every admitted UserPromptSubmit, including ao send deliveries. Does MiniMax save that context in messages.jsonl? If it does, history grows by the full standing prompt each turn. Could it be injected once per launch, or only on the first prompt after a restore?
  2. 0.6.5 version pin (minimaxcode.go): please confirm that requiring exactly 0.6.5 is an intended product decision. Also, a version mismatch isn't cached, so every ResolveBinary call (from AuthStatus, the model catalog, agent ls --refresh) runs mcode --version again with a 10s timeout. Can the mismatch result be cached until InvalidateBinaryResolution?

A fix, or an explanation of why either one should stay as it is, works for us. Once both are answered we'll do a final pass.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/daemon Go daemon, process lifecycle, and backend control plane. enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants