Files
Caspian 東澔 21e7800c24 Remove Smart Triage (ai-tasks) and the MiMo Code / Xiaomi MiMo providers (#879)
* Remove Smart Triage (ai-tasks) and the MiMo Code / Xiaomi MiMo providers

Take two features offline:

- Smart Triage (ai-tasks): remove the triage subsystem end to end — the
  Settings panel, the sidebar "Proposed tasks" group, the local-LLM
  scheduler/fetcher + sidecar agent, IPC commands, UiMutationEvents, i18n,
  and the triage-owned tables (triage_candidate, triage_fetch_cursor). The
  on-device local model (title generation), Slack inbox/Contexts, the
  companion, and the opencode/kimi providers are untouched. The
  kind / ai_priming_consumed / triage_source_* / is_ai_priming columns are
  retained inert to avoid row-index and schema-snapshot churn.

- Providers: remove the MiMo Code agent CLI backend (sidecar
  opencode-protocol/mimo, vendoring, Rust provider family, model catalog,
  provider capabilities, IPC, login, and the @mimo-ai/cli dependency) and
  the standalone Xiaomi MiMo Claude model provider. opencode's Xiaomi
  token-plan entries and the shared xiaomi icon are kept.

* test: drop stale spawn_lark_cli_auth_terminal from companion allowlist

Smart Triage removal deleted the Lark CLI auth terminal command and its
frontend invoke. The companion dispatch coverage test's BROWSER_UNSUPPORTED
allowlist still listed it, tripping the stale-entry guard on both Rust Test
and Windows Rust Test. Remove the dead entry.

* Archive never-started AI-triage workspaces on upgrade

Smart Triage removal left the workspaces.kind='ai_triage' rows in place
but dropped the dedicated 'Proposed tasks' sidebar group, so leftover
auto-generated proposals would resurface as ordinary workspaces.

Add a one-time, idempotent startup reconcile that archives the triage
workspaces the user never started — priming still unconsumed AND no real
(non-priming) message — mirroring the old triage reaper's touched-guard.
Goes through the full reversible archive path (worktree torn down, branch
removed, chat history preserved in the archive list). Workspaces the user
actually opened and messaged are left as normal workspaces.

Runs inline after the existing orphan reconcilers in setup; a no-op for
users who never used triage.

* test(codex): poll for turn/start in steer-gate setup to fix CI flake

driveToSendMessage waited a fixed two setTimeout(0) ticks before resolving
turn/start, but sendMessage awaits ensureContext first — on slow CI runners
the RPC wasn't pending yet, so resolveNext returned false. Poll the pending
queue instead.

---------

Co-authored-by: Nathan L <liangeqiang@gmail.com>
2026-06-23 17:32:13 +08:00
..
2026-06-08 18:41:50 +08:00