Skip to content

Simplify UI and improve footer display (v0.3.14)#2

Merged
Hmbown merged 3 commits into
mainfrom
claude/polish-ui-docs-3wOKS
Feb 5, 2026
Merged

Simplify UI and improve footer display (v0.3.14)#2
Hmbown merged 3 commits into
mainfrom
claude/polish-ui-docs-3wOKS

Conversation

@Hmbown
Copy link
Copy Markdown
Owner

@Hmbown Hmbown commented Feb 5, 2026

Summary

This release streamlines the TUI interface and improves information density in the footer:

  • Version bump: 0.3.13 → 0.3.14
  • README overhaul: Restructured for clarity with condensed feature list, simplified getting started, and better organized documentation links
  • Footer redesign: Replaced time/mode/agent info with session ID, token count, and help hint for better context awareness
  • Color improvements: Changed STATUS_SUCCESS to green and STATUS_WARNING to amber for better visual distinction
  • Welcome banner: Simplified to focus on tips and mode info, removed session ID display
  • Code cleanup: Removed unused imports (chrono::Local, uuid::Uuid, Color, Modifier) and simplified mode cycling comment

The changes maintain all functionality while improving UX clarity and reducing visual clutter.

Testing

  • cargo test --all-features
  • cargo fmt --all -- --check
  • cargo clippy --all-targets --all-features

Checklist

  • Updated docs (README.md restructured)
  • Verified TUI behavior (footer, welcome banner, colors)
  • Removed dead code and unused imports

https://claude.ai/code/session_011XiGZRhainhyvZ8BKKrfzj

- Fix welcome banner generating a fake session ID (random UUID that
  didn't match the actual session); now shows tips and omits the
  misleading session line
- Fix footer redundancy: mode and model were shown in both the header
  and footer; footer now shows session ID, token count, and help hint
- Fix STATUS_SUCCESS and STATUS_WARNING being the same color
  (both DEEPSEEK_SKY), making success/warning states indistinguishable;
  success is now green, warning is amber
- Remove unprofessional thinking tagline ("You're absolutely right!
  ... maybe."); replaced with professional labels
- Fix README mode cycle documentation (said Normal->Plan->Agent->YOLO
  but code actually cycles Plan->Agent->YOLO->Plan)
- Fix README tool miscategorization: web.run, web_search,
  request_user_input, and multi_tool_use.parallel were listed under
  "File Operations" instead of their own categories
- Rewrite README with numbered getting-started steps, keyboard
  shortcuts table, cleaner tool categories, environment variable table,
  and compact troubleshooting table
- Remove unused imports (chrono::Local, uuid::Uuid, Color, Modifier)
  and dead code (mode_color, mode_badge_style)

https://claude.ai/code/session_011XiGZRhainhyvZ8BKKrfzj
Copilot AI review requested due to automatic review settings February 5, 2026 19:24
@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello @Hmbown, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request focuses on enhancing the user experience of the DeepSeek TUI by simplifying its interface and improving information density. The changes streamline the welcome banner and footer display, making key information more accessible and reducing visual clutter. Additionally, the README has been significantly updated for better clarity and ease of use, and minor code cleanups were performed to improve maintainability.

Highlights

  • UI Simplification: The TUI interface has been streamlined, including a redesigned footer that now displays session ID, token count, and a help hint, replacing previous time, mode, and agent information. The welcome banner is also simplified to focus on tips and mode information.
  • Visual Enhancements: Status colors have been improved for better visual distinction, with STATUS_SUCCESS now appearing green and STATUS_WARNING as amber.
  • Documentation Overhaul: The README.md has undergone a significant restructuring to enhance clarity, condense feature lists, simplify getting started instructions, and better organize documentation links.
  • Code Cleanup: Unused imports (chrono::Local, uuid::Uuid, Color, Modifier) have been removed, and minor code comments, such as the mode cycling description, have been simplified.
  • Version Update: The project version has been bumped from 0.3.13 to 0.3.14.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • Cargo.lock
    • Updated the project version from 0.3.13 to 0.3.14.
  • README.md
    • Restructured the entire document for improved readability and conciseness.
    • Condensed the feature list and simplified the 'Getting Started' section.
    • Reorganized documentation links, configuration details, and troubleshooting into tables.
    • Updated examples and removed redundant sections.
    • Changed the main title from 'DeepSeek CLI 🤖' to 'DeepSeek CLI'.
    • Updated the project description to 'This is an unofficial, community-driven project.'
  • src/palette.rs
    • Changed STATUS_SUCCESS color to Color::Rgb(80, 200, 120) (Green).
    • Changed STATUS_WARNING color to Color::Rgb(255, 170, 60) (Amber).
  • src/tui/app.rs
    • Modified the format_welcome_banner to be more concise, removing session ID and adding general tips.
    • Removed the uuid::Uuid import as session ID is no longer displayed in the banner.
    • Simplified the comment for mode cycling from 'Plan → Agent → YOLO → Plan' to 'Plan -> Agent -> YOLO -> Plan'.
  • src/tui/ui.rs
    • Removed unused imports: chrono::Local, Color, Modifier.
    • Redesigned the TUI footer to display session ID (truncated), conversation token count, and a 'F1 help' hint, replacing time, mode, and agent info.
    • Removed helper functions mode_color and mode_badge_style which were related to the old footer display.
    • Simplified the list of taglines for the deepseek_thinking_label.
Activity
  • No human activity has been recorded for this pull request since its creation.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@Hmbown
Copy link
Copy Markdown
Owner Author

Hmbown commented Feb 5, 2026

@claude
Screenshot 2026-02-05 at 13 26 07
please fix the failing checks

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces several valuable UI/UX improvements and code simplifications. The redesigned footer provides more relevant information like session ID and token count, which is a great enhancement. The welcome banner is now more concise, and the color changes for status messages improve visual clarity. The extensive overhaul of the README.md makes it much more organized and easier for new users to follow. I've made one suggestion to restore the shell completion examples for bash and fish in the README to maintain completeness. Overall, this is a solid update that refines the user experience.

Comment thread README.md
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR simplifies the TUI interface and improves the footer display by showing more relevant context information.

Changes:

  • Version bumped from 0.3.13 to 0.3.14
  • Footer redesigned to show session ID, token count, and help hint instead of time/mode/agent info
  • Status colors updated: STATUS_SUCCESS changed to green and STATUS_WARNING to amber for better visual distinction
  • Welcome banner simplified to remove temporary session ID display
  • Removed unused imports and functions (chrono::Local, uuid::Uuid, mode badge styling)
  • README restructured for better clarity and organization

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
Cargo.lock Version bump to 0.3.14
src/palette.rs Updated STATUS_SUCCESS to green and STATUS_WARNING to amber for better semantic meaning
src/tui/app.rs Simplified welcome banner by removing unused session ID parameter and removing uuid import
src/tui/ui.rs Footer redesign showing session ID, token count, and help hint; removed unused imports and helper functions; simplified thinking taglines
README.md Comprehensive restructuring for improved clarity and readability

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/tui/app.rs Outdated
Hmbown and others added 2 commits February 5, 2026 13:28
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@Hmbown Hmbown merged commit 2701a73 into main Feb 5, 2026
1 check passed
@Hmbown Hmbown deleted the claude/polish-ui-docs-3wOKS branch February 5, 2026 19:29
Hmbown added a commit that referenced this pull request Feb 19, 2026
* Polish UI, fix bugs, and rewrite README for clarity

- Fix welcome banner generating a fake session ID (random UUID that
  didn't match the actual session); now shows tips and omits the
  misleading session line
- Fix footer redundancy: mode and model were shown in both the header
  and footer; footer now shows session ID, token count, and help hint
- Fix STATUS_SUCCESS and STATUS_WARNING being the same color
  (both DEEPSEEK_SKY), making success/warning states indistinguishable;
  success is now green, warning is amber
- Remove unprofessional thinking tagline ("You're absolutely right!
  ... maybe."); replaced with professional labels
- Fix README mode cycle documentation (said Normal->Plan->Agent->YOLO
  but code actually cycles Plan->Agent->YOLO->Plan)
- Fix README tool miscategorization: web.run, web_search,
  request_user_input, and multi_tool_use.parallel were listed under
  "File Operations" instead of their own categories
- Rewrite README with numbered getting-started steps, keyboard
  shortcuts table, cleaner tool categories, environment variable table,
  and compact troubleshooting table
- Remove unused imports (chrono::Local, uuid::Uuid, Color, Modifier)
  and dead code (mode_color, mode_badge_style)

https://claude.ai/code/session_011XiGZRhainhyvZ8BKKrfzj

* Update src/tui/app.rs
* Update README.md
Hmbown added a commit that referenced this pull request Apr 28, 2026
Sub-area #2 of the v0.6.6 UI redesign (issue #121).

Reasoning is the only deliberately-warm element in the redesigned
transcript. The treatment makes that visible:

- Header opener becomes `…` (slow exhale) instead of the spinner glyph
- Body left rail switches from solid `▏` to dashed `╎` so it visibly
  differs from message body and tool output rails
- Body text carries an italic modifier
- Body lines tint with `palette::reasoning_surface_tint(depth)` — 12%
  blend of SURFACE_REASONING (#362C1A) over DEEPSEEK_INK. ANSI-16
  terminals get no bg (the named-color mapping would distort the warm)
- A trailing `▎` cursor in ACCENT_REASONING_LIVE follows the most recent
  body line during streaming, suppressed under low_motion

Wires up palette helpers from the prior commit: `ColorDepth::detect`,
`reasoning_surface_tint`, `blend`. SURFACE_REASONING is no longer
dead-coded. The unused `thinking_symbol` helper is removed since the new
header doesn't spin.

Tests: dashed rail and italic body land on every body line; streaming
cursor appears only when motion is allowed; collapsed-summary affordance
keeps working.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
MMMarcinho pushed a commit to MMMarcinho/DeepSeek-TUI that referenced this pull request May 6, 2026
Sub-area Hmbown#2 of the v0.6.6 UI redesign (issue Hmbown#121).

Reasoning is the only deliberately-warm element in the redesigned
transcript. The treatment makes that visible:

- Header opener becomes `…` (slow exhale) instead of the spinner glyph
- Body left rail switches from solid `▏` to dashed `╎` so it visibly
  differs from message body and tool output rails
- Body text carries an italic modifier
- Body lines tint with `palette::reasoning_surface_tint(depth)` — 12%
  blend of SURFACE_REASONING (#362C1A) over DEEPSEEK_INK. ANSI-16
  terminals get no bg (the named-color mapping would distort the warm)
- A trailing `▎` cursor in ACCENT_REASONING_LIVE follows the most recent
  body line during streaming, suppressed under low_motion

Wires up palette helpers from the prior commit: `ColorDepth::detect`,
`reasoning_surface_tint`, `blend`. SURFACE_REASONING is no longer
dead-coded. The unused `thinking_symbol` helper is removed since the new
header doesn't spin.

Tests: dashed rail and italic body land on every body line; streaming
cursor appears only when motion is allowed; collapsed-summary affordance
keeps working.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
YaYII added a commit to YaYII/DeepSeek-TUI that referenced this pull request May 9, 2026
🔴 Fix Hmbown#1 (Embedder blocks async runtime):
- Pre-warm embedder in init_vector_db() via warmup_embedder()
- Model downloaded during startup, not first retrieval
- Eliminates 5-10s UI freeze on first embed call

🔴 Fix Hmbown#2 (Compaction summary pollution):
- store_compaction_summary_to_vector_db() now extracts only
  the summary section from the SystemPrompt, stripping
  boilerplate headers and workflow context
- Uses regex extraction between ## Summary and ## Workflow markers

🔴 Fix Hmbown#3 (No vector index → full table scan):
- New ensure_vector_index() in LanceDbBackend
- Checks list_indices() for existing IVF-PQ index on embedding column
- Creates missing index via table.create_index(["embedding"], Index::Auto)
- Called from ensure_tables() for all three tables

🔴 Fix Hmbown#4 (Compaction threshold regression for non-vector users):
- Added MINIMUM_AUTO_COMPACTION_TOKENS_WITHOUT_VECTOR = 500K
- should_compact() now accepts vector_db_enabled: bool
- Non-vector users keep 500K floor; vector users use 50K floor
- auto_floor_tokens=0 (explicit disable by tests) bypasses both floors
- token_threshold default restored to 800K (fallback only;
  real values come from compaction_threshold_for_model_and_effort)

🟡 Fix Hmbown#7 (No score threshold → noise injection):
- search_memories() and search_summaries() now filter
  results where score < 0.4 before returning
- Prevents low-quality retrieval from polluting system prompt

Tests: 62/62 compaction ✓, 17/17 vector_db ✓
YaYII added a commit to YaYII/DeepSeek-TUI that referenced this pull request May 9, 2026
🔴 Hmbown#1 Embedder blocks async runtime:
  - Pre-warm embedder in init_vector_db() via warmup_embedder()
  - Model downloaded at startup, eliminating 5-10s UI freeze

🔴 Hmbown#2 Compaction summary boilerplate pollution:
  - store_compaction_summary_to_vector_db() now extracts only
    the actual summary section using regex, stripping headers
    and workflow context from embeddings

🔴 Hmbown#3 No vector index → full table scan:
  - New ensure_vector_index() checks list_indices() for IVF-PQ
  - Creates missing index via create_index(["embedding"], Auto)
  - Called from ensure_tables() for all 3 tables

🔴 Hmbown#4 Compaction threshold regression:
  - Added MINIMUM_AUTO_COMPACTION_TOKENS_WITHOUT_VECTOR = 500K
  - should_compact() accepts vector_db_enabled: bool
  - Non-vector users keep 500K floor; vector users get 50K
  - auto_floor_tokens=0 bypasses both (test compatibility)
  - token_threshold default restored to 800K

🟡 Hmbown#7 Score threshold filtering added:
  - search_memories() and search_summaries() filter score < 0.4

Tests: 62/62 compaction ✓, 17/17 vector_db ✓, 99/100 engine ✓
@Hmbown Hmbown mentioned this pull request May 10, 2026
8 tasks
Hmbown added a commit that referenced this pull request May 11, 2026
…t drift (#1118 follow-up #2)

The opening preamble from commit `47f6d69e5` works for the first
few turns, but as English context accumulates in the session (code
read into the transcript, error logs, file listings, search
results, project context), the transformer's recency bias pulls
`reasoning_content` back toward English even when the user keeps
writing in their own language. The empirical fingerprint is "model
thinks in Chinese for the first 3-4 turns, then quietly switches
to English thinking around turn 5 as more code lands in context."

Community feedback (WeChat thread on #1118@mumu describes an
XML-tagged "bilingual bookend" pattern they used in another
project, and @益达 confirms the translation-accuracy problem with
fully-translated prompts) pointed at the bookend pattern: keep the
rule-heavy middle of the prompt in English (single source of
truth, model is natively multilingual), but reinforce the locale
directive at BOTH ends in native script. The opening anchors
behavior at session start; the closer sits at the maximum-
recency position right before the user's next message and
re-asserts the rule each turn.

`locale_reinforcement_closer()` returns Some for `zh-Hans` /
`zh-CN` / `zh`, `ja` / `ja-JP`, `pt-BR` / `pt`. English (and
unmatched locales) return None — system prompt stays
byte-identical to the previous behavior for English users.

The closer is appended after the previous-session handoff block
(the existing "last block" position), so it's the very last
content before the user's first message. Any future block that
needs to sit closer to the user should be added BEFORE the
closer with an updated test invariant.

Three new tests pin the contract:

* `locale_reinforcement_closer_returns_native_script_for_supported_locales`
  — each supported locale's closer is in its native script and
  explicitly mentions `reasoning_content` (the V4 knob).
* `system_prompt_bookends_zh_hans_with_preamble_and_closer` —
  the full zh-Hans system prompt contains both `## 语言要求`
  (preamble) and `## 语言再次提醒` (closer), in that order, and
  no other top-level `##` section follows the closer.
* `system_prompt_skips_locale_preamble_for_english` (extended)
  — English locale gets neither the preamble nor any of the
  three locale closers.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Hmbown pushed a commit that referenced this pull request May 15, 2026
)

When an OpenAI-compatible backend (vLLM, Ollama, LM Studio, Together AI,
self-hosted vLLM/SGLang, etc.) streams an assistant message containing
multiple tool_calls in a single round, only the **last** tool's
`Event::ToolCallStarted` was firing. The preceding N-1 tool calls
executed and produced tool_result events, but never announced their
start to consumers (TUI / runtime API / embedder bridges), leaving them
with N orphan tool_result blocks and no matching tool_use blocks in the
assistant history.

## Reproduction

```text
backend dispatches:   7 × write_file + 1 × exec_shell
log shows:            7 × ApprovalRequired events ✓
listeners receive:    1 × chat:tool_start, 7 × chat:tool_end
session history:      1 tool_use + 7 tool_result (6 orphans)
```

Tested against vLLM 0.7 + Qwen3.6-35B-A3B with a "scaffold 7-file Tauri
template" prompt. Any model+backend combo that emits batch tool_calls
trips this — typical when a single LLM round asks for multiple parallel
file writes or edits.

## Root cause

`run_turn` tracked the currently-streaming tool block with a single
`current_tool_index: Option<usize>`. The Anthropic-style adapter
(non-streaming response → events at `chat.rs::L1807`) emits
Start/Stop pairs in lockstep so the slot never overlaps. But the
OpenAI streaming parser (`chat.rs::L1954-2064`) emits every
`ContentBlockStart::ToolUse` as soon as a tool_call delta lands, then
batches every `ContentBlockStop` at `finish_reason`:

```text
Start { index: 0 }       // tool #1
Delta { index: 0, .. }
Start { index: 1 }       // tool #2 — overwrites current_tool_index
Delta { index: 1, .. }
…
Start { index: 6 }       // current_tool_index = Some(6)
Delta { index: 6, .. }
Stop  { index: 0 }       // take() returns Some(6)  ← wrong tool!
Stop  { index: 1 }       // take() returns None
Stop  { index: 2 }       // take() returns None
…
```

The first `Stop` consumes the last index and emits `ToolCallStarted`
for the wrong `tool_uses` entry; every subsequent `Stop` finds the
slot already `None` and skips the entire `if let Some(index) = …`
branch, dropping the announcement.

## Fix

Replace the single slot with `HashMap<u32 block_index, usize
tool_uses_idx>`:

- `ContentBlockStart::ToolUse` and `::ServerToolUse` insert the
  `(event.index → tool_uses.len())` mapping.
- `InputJsonDelta` looks up by the `ContentBlockDelta` outer index.
- `ContentBlockStop` removes by the stop's index, so each Stop routes
  to its own `tool_uses` entry regardless of arrival order.

Routing no longer depends on `current_block_kind` (which has the same
single-slot overwrite problem); `current_tool_indices.remove(&index)`
returning `Some(_)` already proves the Stop belongs to a tool block.

## Tests

Added `batch_tool_calls_preserve_all_tool_use_indices` in
`core/engine/turn_loop.rs::tests` — feeds 7 Starts and 7 Stops through
the same `HashMap` API used by `run_turn`, asserts every index round-trips.

Manual end-to-end verification: vLLM + Qwen3.6-35B + 7-file Tauri
template prompt → frontend `messages` history now contains all 7
`write_file` tool_use blocks paired with their tool_result blocks.

Co-authored-by: hexin <he.xin@h3c.com>
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.

3 participants