MoonshotAI / MoonshotAI/kimi-code
Feature: batch/merge queued messages into single API request (like Claude Code)
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 7.5k
- Forks
- 1.2k
- Avg merge
- 11h 53m
- Merged PRs (30d)
- 350
Description
Problem
When using Kimi Code TUI with a slow or thinking-intensive model, users often queue multiple messages while the agent is processing. Currently, each queued message is sent as a separate API request once the current turn completes.
This differs from Claude Code behavior, where queued messages are merged into a single request when the agent becomes available. The current behavior causes:
- Loss of conversational context between queued messages
- Multiple API round-trips instead of one
- Fragmented reasoning when user intended to provide multi-part input
Current Behavior
- User sends message A (agent starts processing)
- User queues messages B, C, D while agent is busy
- Agent finishes A → sends B as separate request → finishes B → sends C as separate request → etc.
Expected Behavior (Claude Code style)
- User sends message A (agent starts processing)
- User queues messages B, C, D while agent is busy
- Agent finishes A → merges B+C+D into single request → processes combined input
Use Case
This is especially important for:
- Complex multi-step instructions that user types incrementally
- Corrections/additions to previous queued message
- Users on high-latency connections who want to minimize round-trips
Proposed Solution
Add a config option (e.g., in or ) that:
- Accumulates all pending queued messages when current turn completes
- Concatenates them with appropriate separators (e.g., double newline)
- Sends as single user message to the API
Alternative: make this the default behavior with opt-out, since it matches Claude Code UX that many users expect.
Environment
- Kimi Code version: 0.31.1
- Platform: macOS (but affects all)
- Provider: any (tested with OpenCode proxy → Kimi K3)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no files, tests, or entry points. Start by locating the TUI's queued-message handling and the configuration path for request behavior. Done means pending messages are combined into one API request after the current turn, with the chosen default or opt-out behavior covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- api, cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100