🎫 Ticket 210: ACP create mode (mm --acp-create), epic ACP Create
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
68adc9f parent: f39e1bd modified
.tickets/epics.yaml +3 -0 | @@ -77,3 +77,6 @@ epics: | ||
| 77 | 77 | - title: Agent Identity |
| 78 | 78 | state: open |
| 79 | 79 | color: "#006b75" |
| 80 | + - title: ACP Create | |
| 81 | + state: open | |
| 82 | + color: "#5319e7" | |
| @@ -77,3 +77,6 @@ epics: | |||
| 77 | - title: Agent Identity | 77 | - title: Agent Identity |
| 78 | state: open | 78 | state: open |
| 79 | color: "#006b75" | 79 | color: "#006b75" |
| 80 | + - title: ACP Create | ||
| 81 | + state: open | ||
| 82 | + color: "#5319e7" | ||
added
.tickets/issues/0210-acp-create-mode-mm-acp-create-mm-init-from-an-acp.yaml +132 -0 | new file mode 100644 | ||
| @@ -0,0 +1,132 @@ | ||
| 1 | +# Managed by IssueSpec. Hand edits are welcome; keep the schema valid. | |
| 2 | +id: 210 | |
| 3 | +title: "ACP create mode (mm --acp-create): mm init from an ACP client" | |
| 4 | +state: open | |
| 5 | +author: | |
| 6 | + name: k33g | |
| 7 | + email: ph.charriere@gmail.com | |
| 8 | +createdAt: 2026-11-14T05:41:20.000Z | |
| 9 | +updatedAt: 2026-11-14T05:41:20.000Z | |
| 10 | +labels: | |
| 11 | + - enhancement | |
| 12 | + - kind::feature | |
| 13 | +epic: ACP Create | |
| 14 | +body: | | |
| 15 | + A dedicated ACP mode, `mm --acp-create` (also `mm acp-create`, like | |
| 16 | + `mm acp` / `mm init` — ticket 117), that serves the Agent Client Protocol | |
| 17 | + on stdio and lets an ACP client (Zed, JetBrains, Neovim…) do **what | |
| 18 | + `mm init` does**: choose the server, the model, the usage… and write the | |
| 19 | + `agent.yaml` (or the `.mm/` project layout, ticket 205). | |
| 20 | + | |
| 21 | + ## Why | |
| 22 | + | |
| 23 | + Today, to use mm from Zed you must first run `mm init` in a terminal, then | |
| 24 | + point Zed at `mm acp <config>`. With this mode, a single Zed entry | |
| 25 | + (`mm --acp-create`) is enough to create an agent without leaving the editor. | |
| 26 | + | |
| 27 | + ## Constraints | |
| 28 | + | |
| 29 | + - **No configuration, no model needed to start.** Like `mm init`, the mode | |
| 30 | + is answered before the config is loaded and before the engine is | |
| 31 | + initialised (`main.go`, next to `isInit`). The process is a "wizard | |
| 32 | + agent", not an LLM agent: no model is called. | |
| 33 | + - **Reuse `agentinit.Flow`** ([internal/agentinit/flow.go](internal/agentinit/flow.go)): | |
| 34 | + it already separates the wizard state from its display (line mode and | |
| 35 | + window both drive it). The ACP front is a third driver; no logic of | |
| 36 | + `mm init` is duplicated (presets, decide, render, layout checks). | |
| 37 | + - The session `cwd` given by the client at `session/new` is the project | |
| 38 | + dir: the file is written there (`agent.yaml`, or `.mm/agent.yaml` when | |
| 39 | + `project` is yes). | |
| 40 | + | |
| 41 | + ## How the questions are asked (best the client allows) | |
| 42 | + | |
| 43 | + Same strategy as `ask_user` over ACP ([internal/acp/elicit.go](internal/acp/elicit.go), ticket 84): | |
| 44 | + | |
| 45 | + 1. client advertised `elicitation.form` → each step (or the whole | |
| 46 | + pending set) goes as an `elicitation/create` form; | |
| 47 | + 2. otherwise **conversation mode**: the agent posts the step's prompt | |
| 48 | + and options as a message in the chat; the user answers in the prompt | |
| 49 | + box (number or value); choices / yes-no may use | |
| 50 | + `session/request_permission` buttons instead; | |
| 51 | + 3. the steps' `Default` is accepted on an empty answer / `.`. | |
| 52 | + | |
| 53 | + To explore: exposing Choice steps as **session config options** | |
| 54 | + (`session/set_config_option`, dropdowns in Zed) — attractive for | |
| 55 | + provider / model / usage, to be checked against what Zed really shows. | |
| 56 | + | |
| 57 | + ## Commands (`available_commands_update`) | |
| 58 | + | |
| 59 | + - `/preview` — show the agent.yaml that would be written (`Flow.Preview`) | |
| 60 | + - `/back` — go back one step | |
| 61 | + - `/write` — write the file (asks before overwriting, `overwrite` step) | |
| 62 | + - `/restart` — start the flow again | |
| 63 | + | |
| 64 | + ## At the end | |
| 65 | + | |
| 66 | + The file is written, then the agent shows how to use it: the Zed | |
| 67 | + `agent_servers` snippet (`mm acp <path>`), and the `mm acp` command line. | |
| 68 | + Out of scope for this ticket: switching the same process into the normal | |
| 69 | + `mm acp` mode on the new config (hot reload) — a possible follow-up. | |
| 70 | + | |
| 71 | + ## Acceptance criteria | |
| 72 | + | |
| 73 | + - `mm --acp-create` starts with no `agent.yaml` anywhere and answers | |
| 74 | + `initialize` / `session/new`. | |
| 75 | + - From Zed, a full run (provider llamacpp or llmman, model listed from the | |
| 76 | + server, usage, machine…) writes the same file as `mm init` with the same | |
| 77 | + answers (golden test against the line mode). | |
| 78 | + - Works without `elicitation.form` (conversation mode) — Zed today. | |
| 79 | + - Flags given on the command line (`--provider`, `--model`…, same as | |
| 80 | + `mm init -h`) are taken as given and never asked. | |
| 81 | + - Unit tests with a fake ACP client; docs EN+FR (how-to "create an agent | |
| 82 | + from your editor", reference of the mode). | |
| 83 | +tasks: | |
| 84 | + - id: 1 | |
| 85 | + title: Spike — what Zed shows for elicitation, permission dialogs and session config options | |
| 86 | + state: open | |
| 87 | + priority: high | |
| 88 | + author: | |
| 89 | + name: k33g | |
| 90 | + email: ph.charriere@gmail.com | |
| 91 | + createdAt: 2026-11-14T05:41:20.000Z | |
| 92 | + - id: 2 | |
| 93 | + title: Entry point mm --acp-create / mm acp-create, before config load | |
| 94 | + state: open | |
| 95 | + priority: medium | |
| 96 | + author: | |
| 97 | + name: k33g | |
| 98 | + email: ph.charriere@gmail.com | |
| 99 | + createdAt: 2026-11-14T05:41:20.000Z | |
| 100 | + - id: 3 | |
| 101 | + title: ACP front driving agentinit.Flow (conversation mode + elicitation form) | |
| 102 | + state: open | |
| 103 | + priority: medium | |
| 104 | + author: | |
| 105 | + name: k33g | |
| 106 | + email: ph.charriere@gmail.com | |
| 107 | + createdAt: 2026-11-14T05:41:20.000Z | |
| 108 | + - id: 4 | |
| 109 | + title: Slash commands /preview /back /write /restart | |
| 110 | + state: open | |
| 111 | + priority: low | |
| 112 | + author: | |
| 113 | + name: k33g | |
| 114 | + email: ph.charriere@gmail.com | |
| 115 | + createdAt: 2026-11-14T05:41:20.000Z | |
| 116 | + - id: 5 | |
| 117 | + title: Write the file in the session cwd, end message with the Zed snippet | |
| 118 | + state: open | |
| 119 | + priority: medium | |
| 120 | + author: | |
| 121 | + name: k33g | |
| 122 | + email: ph.charriere@gmail.com | |
| 123 | + createdAt: 2026-11-14T05:41:20.000Z | |
| 124 | + - id: 6 | |
| 125 | + title: Tests (fake ACP client, golden vs mm init) and docs EN+FR | |
| 126 | + state: open | |
| 127 | + priority: medium | |
| 128 | + author: | |
| 129 | + name: k33g | |
| 130 | + email: ph.charriere@gmail.com | |
| 131 | + createdAt: 2026-11-14T05:41:20.000Z | |
| 132 | +comments: [] | |
| new file mode 100644 | |||
| @@ -0,0 +1,132 @@ | |||
| 1 | +# Managed by IssueSpec. Hand edits are welcome; keep the schema valid. | ||
| 2 | +id: 210 | ||
| 3 | +title: "ACP create mode (mm --acp-create): mm init from an ACP client" | ||
| 4 | +state: open | ||
| 5 | +author: | ||
| 6 | + name: k33g | ||
| 7 | + email: ph.charriere@gmail.com | ||
| 8 | +createdAt: 2026-11-14T05:41:20.000Z | ||
| 9 | +updatedAt: 2026-11-14T05:41:20.000Z | ||
| 10 | +labels: | ||
| 11 | + - enhancement | ||
| 12 | + - kind::feature | ||
| 13 | +epic: ACP Create | ||
| 14 | +body: | | ||
| 15 | + A dedicated ACP mode, `mm --acp-create` (also `mm acp-create`, like | ||
| 16 | + `mm acp` / `mm init` — ticket 117), that serves the Agent Client Protocol | ||
| 17 | + on stdio and lets an ACP client (Zed, JetBrains, Neovim…) do **what | ||
| 18 | + `mm init` does**: choose the server, the model, the usage… and write the | ||
| 19 | + `agent.yaml` (or the `.mm/` project layout, ticket 205). | ||
| 20 | + | ||
| 21 | + ## Why | ||
| 22 | + | ||
| 23 | + Today, to use mm from Zed you must first run `mm init` in a terminal, then | ||
| 24 | + point Zed at `mm acp <config>`. With this mode, a single Zed entry | ||
| 25 | + (`mm --acp-create`) is enough to create an agent without leaving the editor. | ||
| 26 | + | ||
| 27 | + ## Constraints | ||
| 28 | + | ||
| 29 | + - **No configuration, no model needed to start.** Like `mm init`, the mode | ||
| 30 | + is answered before the config is loaded and before the engine is | ||
| 31 | + initialised (`main.go`, next to `isInit`). The process is a "wizard | ||
| 32 | + agent", not an LLM agent: no model is called. | ||
| 33 | + - **Reuse `agentinit.Flow`** ([internal/agentinit/flow.go](internal/agentinit/flow.go)): | ||
| 34 | + it already separates the wizard state from its display (line mode and | ||
| 35 | + window both drive it). The ACP front is a third driver; no logic of | ||
| 36 | + `mm init` is duplicated (presets, decide, render, layout checks). | ||
| 37 | + - The session `cwd` given by the client at `session/new` is the project | ||
| 38 | + dir: the file is written there (`agent.yaml`, or `.mm/agent.yaml` when | ||
| 39 | + `project` is yes). | ||
| 40 | + | ||
| 41 | + ## How the questions are asked (best the client allows) | ||
| 42 | + | ||
| 43 | + Same strategy as `ask_user` over ACP ([internal/acp/elicit.go](internal/acp/elicit.go), ticket 84): | ||
| 44 | + | ||
| 45 | + 1. client advertised `elicitation.form` → each step (or the whole | ||
| 46 | + pending set) goes as an `elicitation/create` form; | ||
| 47 | + 2. otherwise **conversation mode**: the agent posts the step's prompt | ||
| 48 | + and options as a message in the chat; the user answers in the prompt | ||
| 49 | + box (number or value); choices / yes-no may use | ||
| 50 | + `session/request_permission` buttons instead; | ||
| 51 | + 3. the steps' `Default` is accepted on an empty answer / `.`. | ||
| 52 | + | ||
| 53 | + To explore: exposing Choice steps as **session config options** | ||
| 54 | + (`session/set_config_option`, dropdowns in Zed) — attractive for | ||
| 55 | + provider / model / usage, to be checked against what Zed really shows. | ||
| 56 | + | ||
| 57 | + ## Commands (`available_commands_update`) | ||
| 58 | + | ||
| 59 | + - `/preview` — show the agent.yaml that would be written (`Flow.Preview`) | ||
| 60 | + - `/back` — go back one step | ||
| 61 | + - `/write` — write the file (asks before overwriting, `overwrite` step) | ||
| 62 | + - `/restart` — start the flow again | ||
| 63 | + | ||
| 64 | + ## At the end | ||
| 65 | + | ||
| 66 | + The file is written, then the agent shows how to use it: the Zed | ||
| 67 | + `agent_servers` snippet (`mm acp <path>`), and the `mm acp` command line. | ||
| 68 | + Out of scope for this ticket: switching the same process into the normal | ||
| 69 | + `mm acp` mode on the new config (hot reload) — a possible follow-up. | ||
| 70 | + | ||
| 71 | + ## Acceptance criteria | ||
| 72 | + | ||
| 73 | + - `mm --acp-create` starts with no `agent.yaml` anywhere and answers | ||
| 74 | + `initialize` / `session/new`. | ||
| 75 | + - From Zed, a full run (provider llamacpp or llmman, model listed from the | ||
| 76 | + server, usage, machine…) writes the same file as `mm init` with the same | ||
| 77 | + answers (golden test against the line mode). | ||
| 78 | + - Works without `elicitation.form` (conversation mode) — Zed today. | ||
| 79 | + - Flags given on the command line (`--provider`, `--model`…, same as | ||
| 80 | + `mm init -h`) are taken as given and never asked. | ||
| 81 | + - Unit tests with a fake ACP client; docs EN+FR (how-to "create an agent | ||
| 82 | + from your editor", reference of the mode). | ||
| 83 | +tasks: | ||
| 84 | + - id: 1 | ||
| 85 | + title: Spike — what Zed shows for elicitation, permission dialogs and session config options | ||
| 86 | + state: open | ||
| 87 | + priority: high | ||
| 88 | + author: | ||
| 89 | + name: k33g | ||
| 90 | + email: ph.charriere@gmail.com | ||
| 91 | + createdAt: 2026-11-14T05:41:20.000Z | ||
| 92 | + - id: 2 | ||
| 93 | + title: Entry point mm --acp-create / mm acp-create, before config load | ||
| 94 | + state: open | ||
| 95 | + priority: medium | ||
| 96 | + author: | ||
| 97 | + name: k33g | ||
| 98 | + email: ph.charriere@gmail.com | ||
| 99 | + createdAt: 2026-11-14T05:41:20.000Z | ||
| 100 | + - id: 3 | ||
| 101 | + title: ACP front driving agentinit.Flow (conversation mode + elicitation form) | ||
| 102 | + state: open | ||
| 103 | + priority: medium | ||
| 104 | + author: | ||
| 105 | + name: k33g | ||
| 106 | + email: ph.charriere@gmail.com | ||
| 107 | + createdAt: 2026-11-14T05:41:20.000Z | ||
| 108 | + - id: 4 | ||
| 109 | + title: Slash commands /preview /back /write /restart | ||
| 110 | + state: open | ||
| 111 | + priority: low | ||
| 112 | + author: | ||
| 113 | + name: k33g | ||
| 114 | + email: ph.charriere@gmail.com | ||
| 115 | + createdAt: 2026-11-14T05:41:20.000Z | ||
| 116 | + - id: 5 | ||
| 117 | + title: Write the file in the session cwd, end message with the Zed snippet | ||
| 118 | + state: open | ||
| 119 | + priority: medium | ||
| 120 | + author: | ||
| 121 | + name: k33g | ||
| 122 | + email: ph.charriere@gmail.com | ||
| 123 | + createdAt: 2026-11-14T05:41:20.000Z | ||
| 124 | + - id: 6 | ||
| 125 | + title: Tests (fake ACP client, golden vs mm init) and docs EN+FR | ||
| 126 | + state: open | ||
| 127 | + priority: medium | ||
| 128 | + author: | ||
| 129 | + name: k33g | ||
| 130 | + email: ph.charriere@gmail.com | ||
| 131 | + createdAt: 2026-11-14T05:41:20.000Z | ||
| 132 | +comments: [] | ||