fix: add positive idle detection for kiro-cli prompt - #2301
Conversation
refs discussion herdrdev#982
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThis PR adds a new ChangesKiro Prompt Idle Detection
Estimated code review effort: 2 (Simple) | ~10 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Greptile SummaryThe PR adds positive Kiro idle-prompt detection while preserving working and blocked precedence.
Confidence Score: 5/5The PR appears safe to merge with no actionable correctness or security issues identified. The synchronized manifests satisfy the repository’s update contract, and the new tests cover the rule’s idle, working, overlap, stale-scrollback, and blocked-state behavior.
|
| Filename | Overview |
|---|---|
| src/detect/manifests/kiro.toml | Adds a versioned positive idle rule whose priority and localized vetoes preserve blocked and live-working precedence. |
| website/agent-detection/kiro.toml | Keeps the remotely published Kiro manifest byte-aligned with the bundled manifest and its bumped version. |
| src/detect/manifest/tests.rs | Adds focused regression cases covering the new rule and its principal precedence interactions. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
Screen[Kiro terminal screen] --> Blocked{Approval rule matches?}
Blocked -->|Yes| B[Blocked]
Blocked -->|No| Prompt{Prompt anchors in bottom 5 non-empty lines?}
Prompt -->|No| Working{Working marker or spinner matches?}
Prompt -->|Yes| Veto{Working indicator in prompt region?}
Veto -->|No| Idle[Idle]
Veto -->|Yes| Working
Working -->|Yes| W[Working]
Working -->|No| U[Unknown]
Reviews (1): Last reviewed commit: "fix: add positive idle detection for kir..." | Re-trigger Greptile
|
@smileynet could you remove tests? i'm slowly trying to remove integration tests as they do not have meaningful purpose for fast changing patterns |
Summary
notguards prevent false idle when working indicators are in the same screen regionRoot cause
Currently there is no positive confirmation for idle state in the kiro manifest, only a fallback rule that is susceptible to false negatives due to text in scrollback.
Evidence
Captured via
herdr agent read <pane> --source detection --format textagainst kiro-cli 2.13.x on Windows. Verified withherdr agent explain <pane> --json.State transitions confirmed through the local-override hot-reload loop: idle → working → blocked → idle. No false positives from stale scrollback, short terminals, or narrow panes.
Idle:
\\ ext
ask a question or describe a task ↵
/copy to clipboard
\\
Working:
\\ ext
Kiro is working · Type to steer · Ctrl+S to queue
\\
Design
notguards prevent false idle when positive working indicators are in the same region.Validation
cargo test --bin herdr kiro(9 passed)Notes
website/agent-detection/kiro.tomlsynced withsrc/detect/manifests/kiro.tomlin this PR.▸prompt character via regex. This rule matches footer text instead to avoid false positives from▸appearing in output.refs discussion #982