Skip to content

feat(kiro): keep idle Kiro panes sendable with synthetic titles - #29009

Open
LDH1103 wants to merge 3 commits into
stablyai:mainfrom
LDH1103:feat/kiro-idle-synthetic-title
Open

LDH1103 wants to merge 3 commits into
stablyai:mainfrom
LDH1103:feat/kiro-idle-synthetic-title

Conversation

@LDH1103

@LDH1103 LDH1103 commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

"Send notes to" lists an idle agent pane only while its hook status is fresh (30 minutes) or while a live terminal title proves the agent is still there. Kiro never sets a terminal title during a turn, so after 30 idle minutes a Kiro pane drops out as "Agent status is stale". Now that Kiro reports hook status (#26695), Orca writes Kiro's titles itself, the same way it already does for ZCode.

What Changed

Before: a Kiro pane idle for more than 30 minutes is disabled in "Send notes to" with "Agent status is stale". @ryoupr reproduced this with real Kiro panes in #24937 (screenshot).

After: Kiro's hook events drive Kiro, Kiro ready and Kiro - action required titles, and the title classifiers read them as Kiro. A stale but live Kiro pane is promoted back to sendable through the same live-title path Codex already uses.

Mechanism:

  • synthetic-agent-title.ts: Kiro joins SYNTHETIC_AGENT_TITLE_AGENTS with a profile that synthesizes every state, like ZCode.
  • agent-name-token-match.ts: kiro joins AGENT_NAMES, so the title classifiers token-match it.
  • agent-title-identity.ts, terminal-title-agent-type.ts, title-derived-pane-agent-identity.ts: map the Kiro label to kiro, the same three places Jcode was added.
  • getTuiAgentRestSignal('kiro') now derives to synthetic-title.

Why

#24178 tried the synthetic-title route on 2026-09-30 and was closed for three reasons. Here is where each one stands now:

  1. No producer. feat(kiro): report Kiro agent status and list Kiro sessions in history #26695 gave Kiro managed hooks (agentSpawn, userPromptSubmit, preToolUse, postToolUse, stop), and main-window-agent-status.ts drives synthetic titles from hook events. agentSpawn maps to done, so a default-engine pane gets Kiro ready at launch.
  2. Settle lane. The rest signal becomes synthetic-title, which closes the quiet-foreground lane. tui-idle-evidence.test.ts (rest signal agrees with the lanes that can settle a wait) requires this once an agent has a synthetic title, so I did not carve out an exception. The cost for panes with no hooks is listed under known limits.
  3. False positives. Matching uses the existing token guard, so kiro-cli, .kiro, orca-kiro-hooks and paths don't match. A title that is exactly kiro does, which is the same exposure devin, zcode and jcode already have.

Kiro's titles, measured on Windows ConPTY:

Capture OSC titles
kiro-cli 2.27.1, V3 (--tui --v3), committed as kiro-2-27-1-v3-turn.txt Only before the first paint (executable path, kiro, Windows PowerShell). None from working to idle.
kiro-cli 2.31.1, V2 (chat --tui, Orca's default launch) Same: only before the first paint, none through the turn. Not committed, because the capture shows local paths and session ids.

#24177 reports the same for 2.23.0 on Linux.

Linked Issue

Fixes #42058

Refs #24177. This is the synthetic-title fix proposed there, now that #26695 provides the producer.

Visual Proof

N/A for the after state. This changes which panes "Send notes to" can select, and it is pinned by a unit test with the exact stale-row shape from the screenshot above. I did not check it in a running build: this machine can't build Orca's native modules (no VC++ toolset).

Testing

Automated (Windows 11):

  • New notes-send-agent-targets.test.ts case: a stale Kiro hook row, a Kiro ready pane title and a live PTY make the pane eligible. It fails with only the synthetic-title commit, because Kiro ready resolved to no agent, and passes with the identity change.
  • synthetic-agent-title.test.ts: Kiro titles for every hook state.
  • kiro-title-transcript.test.ts: the 2.27.1 V3 transcript sets OSC titles only before its first paint.
  • tui-agent-rest-signal.test.ts and tui-idle-evidence.test.ts: Kiro's rest signal and the lane-consistency check.
  • Title, rest-signal, tui-idle, terminal-wait, notes-target and pane-evidence suites: 77 files, 1,328 passed, 3 skipped.
  • run-typecheck-projects-in-parallel exit 0. oxlint and oxfmt --check pass on the changed files.
  • Broader Kiro-related run: 5 failures, all identical on main on this machine. They are Windows path and temp-dir permission failures in session-scanner.test.ts and ai-vault-search.test.ts, and the missing Rust toolchain in windows-hook-payload-delivery.test.ts.

Not tested: a running app, macOS, Linux and SSH.

  • I manually tested these changes locally
  • Automated tests added/updated, or explained why not below

AI Disclosure

Implemented with Claude Opus 5.5 (Anthropic) through Claude Code at my direction. The kiro-cli title behavior above was measured on real installs, not taken from docs.

Review

  • Cross-platform: shared and renderer logic only, with no platform branches. Titles come from hook events, so they follow wherever Kiro's hooks run.
  • Default engine: agentSpawn gives a Kiro ready title at launch, so tui-idle waits settle on the synthetic-title lane instead of a quiet foreground.
  • Security: no new inputs. The titles are fixed strings.

Known limits:

  • A Kiro pane with no hooks no longer settles a tui-idle wait on a quiet foreground. That covers V3 on main today, V3 before its first prompt even with feat(kiro): report V3 engine (--v3) status through a global standalone hooks file #24937 (V3 fires nothing until then), and agent configs the installer refuses.
  • A V3 pane gets titles only after its first prompt, so it still isn't listed in "Send notes to" until then.
  • A title that is exactly kiro, such as a shell in a folder named kiro, reads as Kiro.

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

Follow-up to @ryoupr's macOS testing on #24937. This PR is based on main and works with #26695's default-engine hooks on its own. With #24937, V3 panes get the same titles.

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

Kiro sets OSC titles only before its first paint (its executable path, a static 'kiro', then 'Windows PowerShell' under ConPTY) and none through a turn, so once a Kiro hook row ages past the 30-minute freshness window nothing on the terminal says an agent is still there: the pane drops out of 'Send notes to' as 'Agent status is stale'. Kiro now joins the hook-driven synthetic title agents, writing 'Kiro', 'Kiro ready' and 'Kiro - action required' for every state, as ZCode does.

The captured Kiro 2.27.1 V3 transcript pins the missing title.
The synthetic 'Kiro ready' title alone did not bring an idle Kiro pane back into 'Send notes to'. The title classifiers only know the agents in AGENT_NAMES, so 'Kiro ready' resolved to no agent and the stale hook row stayed disabled as 'Agent status is stale'. Kiro now joins AGENT_NAMES and the title label maps, the same way Jcode did, and a notes-target test pins the stale-pane promotion reproduced in stablyai#24937.
@coderabbitai

coderabbitai Bot commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Kiro is added to agent-title matching, title identity mapping, and synthetic working, permission, and idle titles. A Windows Kiro CLI V3 terminal transcript and capture metadata are added. A test checks transcript marker order and OSC-title presence before and after first paint.

Merge Risk: Minimal · up to caafd

This change keeps idle Kiro panes selectable by recognizing synthetic Kiro titles. No concrete merge-blocking risk was found.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the feature area (Kiro) and the main change (keeping idle Kiro panes sendable through synthetic titles). The changeset adds Kiro synthetic titles, title classifier identity mapping, an…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Description check Passed The description follows the repository template and covers the requested sections, including changes, rationale, linked issues, visual proof, testing, known risks, AI disclosure, review, and checklist…
Full details: Title check

Explanation

The title names the feature area (Kiro) and the main change (keeping idle Kiro panes sendable through synthetic titles). The changeset adds Kiro synthetic titles, title classifier identity mapping, and a rest signal change, which the title describes. It uses the conventional commit prefix and stays under one line.

Full details: Description check

Explanation

The description follows the repository template and covers the requested sections, including changes, rationale, linked issues, visual proof, testing, known risks, AI disclosure, review, and checklist. The Risk section does not state an explicit level or provide back-out guidance. The unchecked CI checkbox is allowed by the template. These gaps are non-critical.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 10a79070-479e-4d00-9884-9ca4b67d8503
Commits

Reviewing files that changed from the base of the PR and between 0b196e3 and caafde5.

Files selected for processing: 7

  • src/main/runtime/kiro-title-transcript.test.ts
  • src/renderer/src/components/sidebar/workspace-card/activity/title-derived-pane-agent-identity.test.ts
  • src/renderer/src/components/sidebar/workspace-card/activity/title-derived-pane-agent-identity.ts
  • src/shared/agent-status/title/agent-name-token-match.ts
  • src/shared/agent-status/title/agent-title-identity.ts
  • src/shared/agent-status/title/synthetic-agent-title.ts
  • src/shared/agent-status/title/terminal-title-agent-type.ts

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

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

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Idle Kiro panes become unselectable in "Send notes to" after 30 minutes

1 participant