Kiro icon indicating copy to clipboard operation
Kiro copied to clipboard

Bug: Automatic thread switching loops infinitely when Steering Documents are included (Komon project)

Open kamonabe1927 opened this issue 11 months ago • 1 comments

Before opening, please confirm:

Operating System

macOS Sonoma / MacBook Air (16GB RAM)

Kiro Version

0.7.5

Bug Description

🐞 Bug Description

While working on Komon
(https://github.com/kamonabe/Komon),
Kiro enters an infinite loop of automatic thread switching whenever many Steering Documents are included.

This happens during spec-driven development with 20+ documents loaded (README, rules, templates, future-ideas.md, etc.) and “Including Steering Documents” turned ON.


❌ Actual Behavior

  • When the conversation grows, Kiro detects a context overflow and automatically switches to a new thread
  • The newly created thread starts in a “context full” state immediately
  • Kiro then automatically switches again to yet another thread
  • This repeats indefinitely
  • The conversation becomes impossible to continue
  • With Steering Documents included, Kiro becomes effectively unusable for large projects

This behavior is reproducible consistently in the Komon project.


✅ Expected Behavior

  • When switching threads, the previous context should be properly summarized
  • The new thread should start with sufficient token capacity
  • Steering Documents should not be fully reloaded in a way that instantly consumes context
  • Users should be able to continue long-form spec-driven work across threads
  • Automatic switching should not loop recursively

🔍 Possible Causes (speculation)

  • All Steering Documents may be fully reloaded after each thread switch
  • Conversation summarization might not be reducing token usage
  • Token calculation may be mis-estimated
  • New threads may be initiated in an already-over-capacity state

🔁 Steps to Reproduce

  1. Load all Steering Documents from the Komon repository
    https://github.com/kamonabe/Komon
  2. Enable “Including Steering Documents”
  3. Have a long-form design/specification conversation
  4. Kiro automatically switches threads due to token limits
  5. The new thread immediately overflows
  6. Kiro switches again
  7. An infinite loop occurs

🎯 Impact

High / Critical severity.

  • Makes Komon impossible to develop inside Kiro
  • Affects users who rely heavily on Steering Documents (Kiro’s intended audience)
  • Blocks long-form design, analysis, and specification work entirely

Screenshots, list of loaded documents, or additional logs can be provided if needed.

Steps to Reproduce

🔁 Steps to Reproduce

  1. Clone or open the Komon repository:
    https://github.com/kamonabe/Komon
  2. Load all Steering Documents into Kiro
    (README, rules, templates, future-ideas.md, etc.)
    — more than 20 documents.
  3. Turn ON the option “Including Steering Documents”.
  4. Begin a long-form conversation (design, specification, or workflow discussion).
  5. Continue the conversation until Kiro automatically switches to a new thread due to context limits.
  6. Observe that the new thread immediately shows “context full”, triggering another automatic switch.
  7. The automatic thread switching repeats continuously, creating an effective infinite loop.

Expected Behavior

✅ Expected Behavior

  • When Kiro reaches a context limit and switches to a new thread,
    the previous conversation should be properly summarized so that the new thread starts with available token capacity.

  • The new thread should not begin in an already “context full” state.

  • Steering Documents should not be fully reloaded in a way that instantly consumes the entire token budget.

  • Users should be able to continue long-form spec-driven development even after a thread switch.

  • Automatic thread switching should occur only once (as needed),
    not repeatedly or recursively.

  • The workflow should remain stable and continuous, allowing ongoing discussion of large projects like Komon.

Conversation ID

No response

Additional Context

📝 Additional Context

  • This issue occurs while developing Komon, a project that heavily relies on Kiro’s spec-driven workflow.
    Repository: https://github.com/kamonabe/Komon

  • Komon uses many Steering Documents (20+ files), which is a core use case for Kiro.
    Because of this, stable handling of large conversation contexts is essential.

  • The issue consistently appears regardless of conversation topic, as long as:

    • “Including Steering Documents” is ON
    • Multiple long-form messages are exchanged
    • Thread auto-switching is triggered
  • The looping behavior blocks work entirely, making it impossible to continue specification, design, or rule creation.

  • I can provide screenshots or a full list of Steering Documents upon request.

kamonabe1927 avatar Dec 05 '25 05:12 kamonabe1927

This issue was filed on an early Kiro build (0.x). We've shipped significant improvements across the board since then — current versions are Kiro IDE 1.0.293 and Kiro CLI 2.18.0. Please upgrade to the latest version at https://kiro.dev/ and let us know if you still see this issue by opening a new issue with a fresh Conversation ID and your current version. Closing this as stale.

AnilMaktala avatar Aug 14 '26 16:08 AnilMaktala