Roadmap 0.13, Connect your AI (Track AC)
AC.24 Connect your AI: long requests report progress and can be cancelled
Asked 2026-11-28 (suggestion 2315): one assistant connection for the whole of CadCraft Studio in which every app and add-on describes its own tools, so an assistant finds new functions without anyone changing its set-up. One connection for all apps, live edits with one undo step each, previews and suggestions were already there. Gap: progress and cancel notices from the assistant were ignored; a long request simply ran until it ended or timed out. Built 2026-11-29 in the lab: a tool gets a stop signal and a progress call. A cancel from the assistant releases it at once; a read tool is dropped, an edit, save or export is finished first so it stays one undo step. Through Studio the hub answers the waiting call and tells the app window to stop. Progress is sent by the command-line server (drawing_check rule by rule, illustrate_export view by view). Tests: 33 new. NOT built: progress from an app window to the assistant through Studio, because Studio's local server gives one answer per request and cannot stream; that needs a change in the desktop shell. Few tools report progress yet (two, plus BimCraft's clash and IDS checks, which are ready for it).
Built in source studio-13 2026-12-03 (the Studio half; reaches people with the 0.13 Studio build). Studio's local server can now stream: a tools/call that carries params._meta.progressToken, from a client whose Accept names text/event-stream, is answered as text/event-stream once the app window reports progress (each note flushed as it happens, then the answer); a call that reports nothing before its answer still gets plain JSON, so older clients see no change. While notes come the wait is measured from the last one (120 s of silence, 30 min in all). The chain: the app window's ctx.progress -> host.js sends control.progress to the hub that asked -> the hub's relay passes it to the shell (bridge.js progress -> cc_control_progress) and restarts its own wait -> control.rs rebuilds the note with the request's own token and streams it. The npm bridge (tools/mcp/bridge.mjs, cadcraft-mcp connect) now writes each streamed note to the AI app as it arrives (needs the next @getcadcraft/mcp publish). Cancel is unchanged (notifications/cancelled). Tests: cargo test --lib control:: 7/0 (incl. a real socket: three notes read one by one before the answer; no token or no event-stream Accept = JSON), whole lib 208/0; studio test/progress-relay.mjs 15/0 (real host.js and window channel: notes reach the shell, the hub's wait restarts, a silent call still times out, another window's note is ignored; the bridge passes streamed notes on); desktop-shell bridge.test 153/0; test-hub 174/0; tools/mcp progress-cancel 33/0, hub 25/0, seams 52/0, contract 31/0. host.js synced to seven apps (civilcraft's copy waits for its lanes). Check in Studio: docs/0.13-sessions/studio-check-sheet.md line 3.
Community comments
No comments yet
Add detail as we go: how you would use it, files or steps that show the problem, what other programs do. The team reads every comment.
Sign in or create a free account to add a comment.