Repository navigation
Description
Description
Support running kiro-cli acp on the v3 engine (kiro-cli 3.x), including Kiro's own workflow feature (run_workflow), in openab. Today a bot can only use v2 args (acp --agent <name> --trust-all-tools). On kiro-cli 3.3.0, acp --agent-engine=v3 rejects --agent and --trust-all-tools, so a bot cannot move to v3 by editing args alone.
Findings below come from a throwaway probe (kiro-cli 3.3.0, nightly-kiro image, a client driven like openab's connection.rs, no live bot touched). Code references are to openab at 4fea4249.
What v3 does differently
- Agents are selected as modes.
session/newlists them inmodes.availableModes, and a session always starts asvibe(default, full tools). The selector issession/set_mode, orsession/set_config_optionwithconfigId: "mode"; both work when the agent exists. - v3 does not read v2 JSON agents (
~/.kiro/agents/<name>.json) and does not auto-upgrade them. Only~/.kiro/agents/<name>.md(frontmatter:name,description,tools,includeMcpJson) is loaded. Thetoolsallowlist is honoured. chat.defaultAgentis v2-only.--agent,--model,--trust-all-toolsare v2-only flags.- An unknown mode id returns success from both
set_modeandset_config_option, and the session staysvibewith the default toolset. openab treats a non-error response as success (pool.rs:633,connection.rs:632), so a missing agent is silent and the bot runs with full tools. includeMcpJson: falsedoes not stop user MCP servers from starting atsession/new.- Workflow tools are off by default (
session/newresult_meta.workflowsEnabled=false). They turn on only when the client sends_meta.kiro.settings.workflows.enabled=truein thesession/newparams. Thechat.enableWorkflowssetting, the same key ininitializecapabilities, and env vars have no effect. - One engine process serves all sessions of one
kiro-cliprocess: idle about 340-370 MB, peak about 510 MB with four sessions and an active workflow.
Workflow behaviour over ACP (kiro-cli 3.3.0)
session/promptreturnsend_turnbefore the workflow finishes (3.4 s versus 8.4 s in a trivial run; about 100 s later in a two-step run). The final answer arrives afterwards assession/updateagent_message_chunkframes with no request id.- Step sessions emit their own
session/updateframes with the step'ssessionId. - Every step session sends its own
session/request_permission(2-3 per shell command). An answer to one step does not carry over. If the client never answers, the run staysrunningwith no timeout. - Step agents can be
wf-*,semantic_reviewer, or.mdcustom agents. Custom agentresourcesare not loaded in steps.
Proposed openab changes
session/newaccepts a configurable_meta(at leastkiro.settings.workflows.enabled), so a workflow-enabled session can be requested.- Verify agent selection. After
set_config_option, compare the returnedcurrentValuewith the requested value. If they differ, fail the session instead of continuing asvibe. Applies to every[pool] default_config_optionsentry. - Filter notifications by
params.sessionId.classify_notification(protocol.rs) readsparams.updateonly, so step-session chunks would be appended to the parent's reply. - Keep reading after the prompt response, for the late workflow summary, and route it to the right thread. Frames after the response today go only to the current subscriber, so they are dropped or leak into the next prompt.
Also needed outside openab core: a v3 variant of any launcher that writes ~/.kiro/agents/<name>.md instead of the JSON agent and that does not require --agent in args. Pool sizing must account for about 0.5 GB per kiro-cli process.
Suggested config for a v3 bot (needs changes 1-4 first, plus an <agent>.md file and an empty ~/.kiro/settings/mcp.json):
[agent]
args = ["acp", "--agent-engine=v3"]
[pool]
default_config_options = { mode = "openab-bot" }Use Case
- Moving bots to the v3 engine, which is the default for newer kiro-cli, without silently dropping the agent's tool restrictions.
- Letting a bot run fixed, reviewed Kiro workflows (for example a planner, coder and reviewer sequence) from a chat thread.
Security notes for workflows: relayed chat text reaches steps as user text (kirodotdev/Kiro#12346, #12325), and steps run shell commands that openab auto-approves. Only fixed, reviewed workflow files should be allowed.
Related upstream issues in kirodotdev/Kiro: #11857 (workflow result queued behind a busy turn is lost), #11863 (answers to a paused step), #12273 (custom agent resources not loaded in steps), #11715 (custom agents must be registered), #11281 (non-interactive v3 sends no _meta.kiro capabilities), #12278 (v3 engine exits when stdin is idle 15 s), #11876 (enabling workflows drops built-in agents from the list).
Activity
fix(session): bound the workflow tail, keep strict mode honest, move …
fix(session): bound the workflow tail, keep strict mode honest, move …
fix(session): keep the late workflow relay open after a quiet gap
fix(session): bound the workflow relay queue and keep the tail draining
fix(session): cap one late-output flush at 16 platform messages
chore(docker): bump Devin CLI pin to 3000.14.30821 (#1610)
feat(session): support kiro-cli v3 engine and Kiro workflows over ACP
fix(session): bound the workflow tail, keep strict mode honest, move …
fix(session): keep the late workflow relay open after a quiet gap
fix(session): bound the workflow relay queue and keep the tail draining
fix(session): cap one late-output flush at 16 platform messages
chore(docker): bump Devin CLI pin to 3000.14.30821 (openabdev#1610)
feat(session): support kiro-cli v3 engine and Kiro workflows over ACP (…
chaodu-agent commentedon Nov 24, 2026
Closing as completed by #1609 (merged in 406fada), which implements all four proposed openab changes as opt-in settings:
[agent] session_new_metais sent as_metainsession/new, so a workflow-enabled session can be requested.[pool] strict_default_config_optionscompares the returnedcurrentValuewith the requested value and fails session creation on a mismatch.session/updateframes are filtered byparams.sessionId; permission requests from step sessions are still answered.session/promptresponse is relayed to the thread by a bounded tail task.Setup is documented in
docs/kiro-v3.md.Remaining items:
session/loadresume and a v3 agent launcher outside openab core are tracked in #1619; an end-to-end check against kiro-cli 3.x is tracked in #1620.