MoonshotAI / MoonshotAI/kimi-code

TUI renders assistant text with dropped characters (spaces/letters) while wire.jsonl stores it correctly

Open
#1,980 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
7.5k
Forks
1.2k
Avg merge
11h 53m
Merged PRs (30d)
350

Description

Summary

Assistant messages are occasionally rendered with dropped characters (missing spaces and letters, e.g. merged words) in the interactive TUI, while the same message is stored correctly in the session wire log. The corruption appears only in the display path, not in the generated text.

Evidence

From the session wire log (~/.kimi-code/sessions/<session>/agents/main/wire.jsonl):

  1. Stored assistant message (correct):

    ...Якщо хочеш прибрати його заради чистоти — скажи...

  2. What was actually rendered on screen (as later quoted back by the user):

    ...Якщо хочеш прибрати йогоради чистоти...

The pattern repeats across the session: dropped spaces and single characters at varying positions ("merged words"). I verified multiple occurrences: in every case the stored wire text is correct and only the rendered output is corrupted. (I can provide the exact wire.jsonl line numbers/excerpts privately if needed.)

Environment

  • Kimi Code CLI: 0.20.1
  • OS: Linux (kernel 7.0.0-28-generic, Ubuntu 24.04 base)
  • VS Codium, version: 1.126.04524
    Date: 2026-06-23T01:46:13Z
    Electron: 42.2.0
    ElectronBuildId: undefined
    Chromium: 148.0.7778.97
    Node.js: 24.15.0
    V8: 14.8.178.14-electron.0
  • Kimi Code Extension v. 0.6.3 (problem exists after updating to this version)
  • Locale: uk_UA.UTF-8

Expected vs actual

  • Expected: rendered text matches the generated/stored text exactly.
  • Actual: occasional missing spaces/letters in the rendered stream. A redraw (scroll/resize) sometimes shows the text correctly.

Suspected cause

Possibly a display-width miscalculation during streaming/redraw. Affected sessions contain lots of non-ASCII content: Cyrillic text, emoji, and box-drawing characters (, , ). Losing glyphs/spaces at width boundaries would match the observed pattern.

Steps to reproduce

  1. Run a session in a uk_UA.UTF-8 locale terminal.
  2. Have the assistant produce long Ukrainian-language messages that include emoji and box-drawing characters.
  3. Observe occasional merged words (missing spaces) in the rendered output; compare against the stored message in wire.jsonl.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the rendering issue in a uk_UA.UTF-8 terminal using long Ukrainian text with emoji and box-drawing characters, then compare the TUI output with the corresponding message in ~/.kimi-code/sessions//agents/main/wire.jsonl. Trace the display and redraw path to identify where characters are dropped; done means rendered assistant text matches the stored text, including during streaming and after redraw.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.