Skip to content

release/v5.6.2#66

Merged
code-crusher merged 1 commit intomainfrom
release/v5.6.2
Mar 9, 2026
Merged

release/v5.6.2#66
code-crusher merged 1 commit intomainfrom
release/v5.6.2

Conversation

@code-crusher
Copy link
Member

@matter-ai-bot
Copy link
Contributor

matter-ai-bot bot commented Mar 9, 2026

Summary By MatterAI MatterAI logo

🔄 What Changed

Introduced reasoning duration tracking for AI tasks, updated chat UI components (KiloTaskHeader, BottomControls), and implemented auto-collapsing logic for reasoning blocks to improve the user experience during streaming.

🔍 Impact of the Change

Enhances user observability of AI "thought" time and improves the chat interface's layout stability and configuration accessibility. The version has been bumped to 5.6.2.

📁 Total Files Changed

Click to Expand
File ChangeLog
Schema Update packages/types/src/kilocode/kilocode.ts Added reasoningDuration to the Zod metadata schema.
Duration Logic src/core/task/Task.ts Calculates and persists reasoning time in message metadata upon completion.
Version Bump src/package.json Incremented extension version to 5.6.2.
UI Refactor webview-ui/src/components/chat/ChatView.tsx Integrated KiloTaskHeader, BottomControls, and optimized Virtuoso scrolling.
Timer Logic webview-ui/src/components/chat/ReasoningBlock.tsx Added auto-expand/collapse and duration display logic using metadata.

🧪 Test Added/Recommended

Recommended

  • Unit test for reasoningDuration calculation in Task.ts to handle clock skew.
  • Integration test for ReasoningBlock timer cleanup to prevent memory leaks.
  • Snapshot tests for KiloTaskHeader with various metric values.

🔒 Security Vulnerabilities

N/A

Implementation

The PR introduces reasoningDuration to the kiloCodeMetaDataSchema using Zod. In Task.ts, the duration is calculated as the delta between Date.now() and the message timestamp when a reasoning block finishes. The ReasoningBlock component was updated with a useEffect hook to handle auto-expansion during streaming and a delayed collapse (2s) via setTimeout upon completion. ChatView.tsx was refactored to use KiloTaskHeader and improved Virtuoso scrolling parameters to reduce "gray screen" issues.

Screenshots

before after
N/A N/A

How to Test

  1. Start a task that requires reasoning (e.g., complex coding).
  2. Observe the reasoning block expanding during streaming.
  3. Verify the timer stops and the block collapses after 2 seconds once finished.
  4. Check the task header for updated token and cost metrics.

Get in Touch

N/A

Total Score: 4

@matter-ai-bot
Copy link
Contributor

matter-ai-bot bot commented Mar 9, 2026

✅ Reviewed the changes: The changes look solid. The reasoning duration tracking and UI improvements are implemented correctly with proper state management and cleanup.

@code-crusher code-crusher merged commit dc4857a into main Mar 9, 2026
5 of 13 checks passed
@code-crusher code-crusher deleted the release/v5.6.2 branch March 9, 2026 19:08
@code-crusher code-crusher mentioned this pull request Mar 20, 2026
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.

1 participant