{"id":42286752,"url":"https://github.com/hmbown/deepseek-tui","last_synced_at":"2026-05-14T02:02:35.459Z","repository":{"id":333698083,"uuid":"1137711311","full_name":"Hmbown/DeepSeek-TUI","owner":"Hmbown","description":"Coding agent for DeepSeek models that runs in your terminal","archived":false,"fork":false,"pushed_at":"2026-04-23T03:37:09.000Z","size":852184,"stargazers_count":27,"open_issues_count":11,"forks_count":4,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-23T05:28:10.688Z","etag":null,"topics":["cli","deepseek","llm","rust","terminal","tui"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Hmbown.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-01-19T18:21:01.000Z","updated_at":"2026-04-23T03:37:12.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/Hmbown/DeepSeek-TUI","commit_stats":null,"previous_names":["hmbown/deepseek-tui"],"tags_count":69,"template":false,"template_full_name":null,"purl":"pkg:github/Hmbown/DeepSeek-TUI","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hmbown%2FDeepSeek-TUI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hmbown%2FDeepSeek-TUI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hmbown%2FDeepSeek-TUI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hmbown%2FDeepSeek-TUI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Hmbown","download_url":"https://codeload.github.com/Hmbown/DeepSeek-TUI/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Hmbown%2FDeepSeek-TUI/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32265977,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-25T09:15:33.318Z","status":"ssl_error","status_checked_at":"2026-04-25T09:15:31.997Z","response_time":59,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","deepseek","llm","rust","terminal","tui"],"created_at":"2026-01-27T09:18:15.148Z","updated_at":"2026-05-14T02:02:35.453Z","avatar_url":"https://github.com/Hmbown.png","language":"Rust","funding_links":["https://www.buymeacoffee.com/hmbown"],"categories":[],"sub_categories":[],"readme":"# DeepSeek TUI\n\n\u003e Terminal coding agent for DeepSeek V4. It runs from the `deepseek` command, streams reasoning blocks, edits local workspaces with approval gates, and includes an auto mode that chooses both model and thinking level per turn.\n\n[简体中文 README](README.zh-CN.md)\n[日本語 README](README.ja-JP.md)\n\n## Install\n\n`deepseek` is distributed as Rust binaries: the dispatcher command\n(`deepseek`) and the companion TUI runtime (`deepseek-tui`). Pick whichever\ninstall path you already use; they all put the same commands on your `PATH`.\nThe npm package is an installer/wrapper for the release binaries, not the\nagent runtime itself.\n\n```bash\n# 1. npm — easiest if you already use Node. The package downloads the\n#    matching prebuilt Rust binaries from GitHub Releases.\nnpm install -g deepseek-tui\n\n# 2. Cargo — no Node needed.\ncargo install deepseek-tui-cli --locked   # `deepseek` (entry point)\ncargo install deepseek-tui     --locked   # `deepseek-tui` (TUI binary)\n\n# 3. Homebrew — macOS package manager.\nbrew tap Hmbown/deepseek-tui\nbrew install deepseek-tui\n\n# 4. Direct download — no package manager or toolchain.\n#    https://github.com/Hmbown/DeepSeek-TUI/releases\n#    Prebuilt for Linux x64/ARM64, macOS x64/ARM64, Windows x64.\n\n# 5. Docker — prebuilt release image.\ndocker run --rm -it \\\n  -e DEEPSEEK_API_KEY \\\n  -v \"$PWD:/workspace\" \\\n  ghcr.io/hmbown/deepseek-tui:latest\n```\n\n\u003e In mainland China, speed up the npm path with\n\u003e `--registry=https://registry.npmmirror.com`, or use the\n\u003e [Cargo mirror](#china--mirror-friendly-installation) below.\n\n[![CI](https://github.com/Hmbown/DeepSeek-TUI/actions/workflows/ci.yml/badge.svg)](https://github.com/Hmbown/DeepSeek-TUI/actions/workflows/ci.yml)\n[![npm](https://img.shields.io/npm/v/deepseek-tui)](https://www.npmjs.com/package/deepseek-tui)\n[![crates.io](https://img.shields.io/crates/v/deepseek-tui-cli?label=crates.io)](https://crates.io/crates/deepseek-tui-cli)\n[DeepWiki project index](https://deepwiki.com/Hmbown/DeepSeek-TUI)\n\n![DeepSeek TUI screenshot](assets/screenshot.png)\n\n---\n\n## What Is It?\n\nDeepSeek TUI is a coding agent that runs in your terminal. It can read and edit files, run shell commands, search the web, manage git, and coordinate sub-agents from a keyboard-driven TUI.\n\nIt is built around DeepSeek V4 (`deepseek-v4-pro` / `deepseek-v4-flash`), including 1M-token context windows, streaming reasoning blocks, and prefix-cache-aware cost reporting.\n\n### Key Features\n\n- **Auto mode** — `--model auto` / `/model auto` chooses both the model and thinking level for each turn\n- **Thinking-mode streaming** — see DeepSeek reasoning blocks as the model works\n- **Full tool suite** — file ops, shell execution, git, web search/browse, apply-patch, sub-agents, MCP servers\n- **1M-token context** — context tracking, manual or configured compaction, and prefix-cache telemetry\n- **Prefix-cache stability tracking** — a footer chip surfaces how stable the cached prefix has been across recent turns so cost-busting edits are visible before they land\n- **Three modes** — Plan (read-only explore), Agent (interactive with approval), YOLO (auto-approved)\n- **Reasoning-effort tiers** — cycle through `off → high → max` with `Shift + Tab`\n- **Session save/resume** — checkpoint and resume long-running sessions\n- **Workspace rollback** — side-git pre/post-turn snapshots with `/restore` and `revert_turn`, without touching your repo's `.git`\n- **OS-level sandbox** — Seatbelt on macOS, Landlock on Linux, Job Objects on Windows; shell commands run with workspace-scoped filesystem access only\n- **Durable task queue** — background tasks can survive restarts\n- **HTTP/SSE runtime API** — `deepseek serve --http` for headless agent workflows\n- **MCP protocol** — connect to Model Context Protocol servers for extended tooling; please see [docs/MCP.md](docs/MCP.md)\n- **Native RLM** (`rlm_open`/`rlm_eval`) — persistent REPL sessions for batched analysis; run cheap `deepseek-v4-flash` children with bounded helpers like `peek`, `search`, `chunk`, and `sub_query_batch`\n- **LSP diagnostics** — inline error/warning surfacing after every edit via rust-analyzer, pyright, typescript-language-server, gopls, clangd\n- **User memory** — optional persistent note file injected into the system prompt for cross-session preferences\n- **Localized UI** — `en`, `ja`, `zh-Hans`, `pt-BR` with auto-detection\n- **Live cost tracking** — per-turn and session-level token usage and cost estimates; cache hit/miss breakdown; CNY display when the session locale is `zh-Hans`\n- **Skills system** — composable, installable instruction packs from GitHub; ships with a bundled starter set (`skill-creator`, `mcp-builder`, `plugin-creator`, `v4-best-practices`, `documents`, `presentations`, `spreadsheets`, `pdf`, `feishu`, `skill-installer`, `delegate`) so `/skills` is useful from first launch\n- **Terminal-native notifications** — OSC 9 (iTerm2/WezTerm/Ghostty), OSC 99 (Kitty), OSC 777 (Ghostty), plus desktop notification fallback\n- **Built-in theme picker** — Catppuccin, Tokyo Night, Dracula, Gruvbox alongside the original light/dark palettes; switch live with `/theme`\n\n---\n\n## How It's Wired\n\n`deepseek` (dispatcher CLI) → `deepseek-tui` (companion binary) → ratatui interface ↔ async engine ↔ OpenAI-compatible streaming client. Tool calls route through a typed registry (shell, file ops, git, web, sub-agents, MCP, RLM) and results stream back into the transcript. The engine manages session state, turn tracking, the durable task queue, and an LSP subsystem that feeds post-edit diagnostics into the model's context before the next reasoning step.\n\nSee [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) for the full walkthrough.\n\n### Sub-agents: Concurrent Background Execution\n\nDeepSeek TUI can dispatch multiple sub-agents that run in parallel — like a concurrent task queue:\n\n- **Non-blocking launch.** `agent_open` returns immediately. The child gets its own fresh context and tool registry and runs independently. The parent keeps working.\n- **Background execution.** Sub-agents execute concurrently (default cap: 10, configurable to 20). The engine manages the pool — no polling loop needed.\n- **Completion notification.** When a sub-agent finishes, the runtime delivers a structured `\u003cdeepseek:subagent.done\u003e` event with a summary, evidence list, and execution metrics. The parent model reads the `summary` field and integrates findings.\n- **Bounded result retrieval.** Large transcripts are parked behind `var_handle` references. The model calls `handle_read` for slices, ranges, or JSONPath projections — keeping the parent context lean.\n\nSee [docs/SUBAGENTS.md](docs/SUBAGENTS.md) for the full sub-agent reference.\n\n---\n\n## Quickstart\n\n```bash\nnpm install -g deepseek-tui\ndeepseek --version\ndeepseek --model auto\n```\n\nPrebuilt binaries are published for **Linux x64**, **Linux ARM64** (v0.8.8+), **macOS x64**, **macOS ARM64**, and **Windows x64**. For other targets (musl, riscv64, FreeBSD, etc.), see [Install from source](#install-from-source) or [docs/INSTALL.md](docs/INSTALL.md).\n\nOn first launch you'll be prompted for your [DeepSeek API key](https://platform.deepseek.com/api_keys). The key is saved to `~/.deepseek/config.toml` so it works from any directory without OS credential prompts.\n\nYou can also set it ahead of time:\n\n```bash\ndeepseek auth set --provider deepseek   # saves to ~/.deepseek/config.toml\ndeepseek auth status                    # shows the active credential source\n\nexport DEEPSEEK_API_KEY=\"YOUR_KEY\"      # env var alternative; use ~/.zshenv for non-interactive shells\ndeepseek\n\ndeepseek doctor                         # verify setup\n```\n\nIf `deepseek doctor` says the rejected key came from `DEEPSEEK_API_KEY`, remove\nthe stale export from your shell startup file, open a fresh shell, or run\n`deepseek auth set --provider deepseek`. Use `deepseek auth status` to see the\nconfig, keyring, and env-var source state without printing the key. Saved config\nkeys take precedence over the keyring and environment and are easier to rotate.\n\n\u003e To rotate or remove a saved key: `deepseek auth clear --provider deepseek`.\n\n### Auto Mode\n\nUse `deepseek --model auto` or `/model auto` when you want DeepSeek TUI to decide how much model and reasoning power a turn needs.\n\nAuto mode controls two settings together:\n\n- Model: `deepseek-v4-flash` or `deepseek-v4-pro`\n- Thinking: `off`, `high`, or `max`\n\nBefore the real turn is sent, the app makes a small `deepseek-v4-flash` routing call with thinking off. That router looks at the latest request and recent context, then selects a concrete model and thinking level for the real request. Short/simple turns can stay on Flash with thinking off; coding, debugging, release work, architecture, security review, or ambiguous multi-step tasks can move up to Pro and/or higher thinking.\n\n`auto` is local to DeepSeek TUI. The upstream API never receives `model: \"auto\"`; it receives the concrete model and thinking setting chosen for that turn. The TUI shows the selected route, and cost tracking is charged against the model that actually ran. If the router call fails or returns an invalid answer, the app falls back to a local heuristic. Sub-agents inherit auto mode unless you assign them an explicit model.\n\nUse a fixed model or fixed thinking level when you want repeatable benchmarking, a strict cost ceiling, or a specific provider/model mapping.\n\n### Linux ARM64 (Raspberry Pi, Asahi, Graviton, HarmonyOS PC)\n\n`npm i -g deepseek-tui` works on glibc-based ARM64 Linux from v0.8.8 onward. You can also download prebuilt binaries from the [Releases page](https://github.com/Hmbown/DeepSeek-TUI/releases) and place them side by side on your `PATH`.\n\n### China / Mirror-friendly Installation\n\nIf GitHub or npm downloads are slow from mainland China, use a Cargo registry mirror:\n\n```toml\n# ~/.cargo/config.toml\n[source.crates-io]\nreplace-with = \"tuna\"\n\n[source.tuna]\nregistry = \"sparse+https://mirrors.tuna.tsinghua.edu.cn/crates.io-index/\"\n```\n\nThen install both binaries (the dispatcher delegates to the TUI at runtime):\n\n```bash\ncargo install deepseek-tui-cli --locked   # provides `deepseek`\ncargo install deepseek-tui     --locked   # provides `deepseek-tui`\ndeepseek --version\n```\n\nPrebuilt binaries can also be downloaded from [GitHub Releases](https://github.com/Hmbown/DeepSeek-TUI/releases). Use `DEEPSEEK_TUI_RELEASE_BASE_URL` for mirrored release assets.\n\n### Windows (Scoop)\n\n[Scoop](https://scoop.sh) is a Windows package manager. DeepSeek TUI is listed\nin Scoop's main bucket, but that manifest updates independently and can lag the\nGitHub/npm/Cargo release. Run `scoop update` first, then verify the installed\nversion with `deepseek --version`:\n\n```bash\nscoop update\nscoop install deepseek-tui\ndeepseek --version\n```\n\nUse npm or direct GitHub release downloads when you need the newest release\nbefore Scoop's manifest catches up.\n\n\n\u003cdetails id=\"install-from-source\"\u003e\n\u003csummary\u003eInstall from source\u003c/summary\u003e\n\nWorks on any Tier-1 Rust target — including musl, riscv64, FreeBSD, and older ARM64 distros.\n\n```bash\n# Linux build deps (Debian/Ubuntu/RHEL):\n#   sudo apt-get install -y build-essential pkg-config libdbus-1-dev\n#   sudo dnf install -y gcc make pkgconf-pkg-config dbus-devel\n\ngit clone https://github.com/Hmbown/DeepSeek-TUI.git\ncd DeepSeek-TUI\n\ncargo install --path crates/cli --locked   # requires Rust 1.88+; provides `deepseek`\ncargo install --path crates/tui --locked   # provides `deepseek-tui`\n```\n\nBoth binaries are required. Cross-compilation and platform-specific notes: [docs/INSTALL.md](docs/INSTALL.md).\n\n\u003c/details\u003e\n\n### Other API Providers\n\n```bash\n# NVIDIA NIM\ndeepseek auth set --provider nvidia-nim --api-key \"YOUR_NVIDIA_API_KEY\"\ndeepseek --provider nvidia-nim\n\n# Fireworks\ndeepseek auth set --provider fireworks --api-key \"YOUR_FIREWORKS_API_KEY\"\ndeepseek --provider fireworks --model deepseek-v4-pro\n\n# Generic OpenAI-compatible endpoint\ndeepseek auth set --provider openai --api-key \"YOUR_OPENAI_COMPATIBLE_API_KEY\"\nOPENAI_BASE_URL=\"https://openai-compatible.example/v4\" deepseek --provider openai --model glm-5\n\n# Self-hosted SGLang\nSGLANG_BASE_URL=\"http://localhost:30000/v1\" deepseek --provider sglang --model deepseek-v4-flash\n\n# Self-hosted vLLM\nVLLM_BASE_URL=\"http://localhost:8000/v1\" deepseek --provider vllm --model deepseek-v4-flash\n\n# Self-hosted Ollama\nollama pull deepseek-coder:1.3b\ndeepseek --provider ollama --model deepseek-coder:1.3b\n```\n\n---\n\n## What's New In v0.8.35\n\nA post-release cleanup branch for the `v0.8.34` line. It keeps the\nmodel-facing surface stable while trimming first-turn context, clarifying\ncontext-pressure behavior, and reducing sidebar noise during long runs.\n[Full changelog](CHANGELOG.md).\n\n- **First-turn context is leaner.** Hidden tool/cache state is excluded\n  from the generated project pack, and `/context` now names prompt layers\n  instead of showing one opaque blob.\n- **Prompt rules are de-conflicted.** Useful `deepseek` diagnostics are\n  allowed, simple one-step work no longer forces checklist ceremony, and\n  sustained sessions consistently suggest `/compact` around 60%.\n- **Automatic compaction stays conservative.** The 80% threshold remains\n  an opt-in hard guardrail so DeepSeek V4 prefix-cache behavior is not\n  disturbed by default.\n- **The Tasks sidebar settles down.** Completed live-tool rows expire\n  after a short linger, and very old running shell rows collapse instead\n  of filling the right rail.\n- **`auto_compact` help is honest.** Settings now report the real default:\n  off.\n\n---\n\n## Usage\n\n```bash\ndeepseek                                         # interactive TUI\ndeepseek \"explain this function\"                 # one-shot prompt\ndeepseek exec --auto --output-format stream-json \"fix this bug\"  # NDJSON backend stream\ndeepseek exec --resume \u003cSESSION_ID\u003e \"follow up\"  # continue a non-interactive session\ndeepseek --model deepseek-v4-flash \"summarize\"   # model override\ndeepseek --model auto \"fix this bug\"             # auto-select model + thinking\ndeepseek --yolo                                  # auto-approve tools\ndeepseek auth set --provider deepseek            # save API key\ndeepseek doctor                                  # check setup \u0026 connectivity\ndeepseek doctor --json                           # machine-readable diagnostics\ndeepseek setup --status                          # read-only setup status\ndeepseek setup --tools --plugins                 # scaffold tool/plugin dirs\ndeepseek models                                  # list live API models\ndeepseek sessions                                # list saved sessions\ndeepseek resume --last                           # resume the most recent session in this workspace\ndeepseek resume \u003cSESSION_ID\u003e                     # resume a specific session by UUID\ndeepseek fork \u003cSESSION_ID\u003e                       # fork a session at a chosen turn\ndeepseek serve --http                            # HTTP/SSE API server\ndeepseek serve --acp                             # ACP stdio adapter for Zed/custom agents\ndeepseek run pr \u003cN\u003e                              # fetch PR and pre-seed review prompt\ndeepseek mcp list                                # list configured MCP servers\ndeepseek mcp validate                            # validate MCP config/connectivity\ndeepseek mcp-server                              # run dispatcher MCP stdio server\ndeepseek update                                  # check for and apply binary updates\n```\n\nDocker images are published to GHCR for release builds:\n\n```bash\ndocker volume create deepseek-tui-home\n\ndocker run --rm -it \\\n  -e DEEPSEEK_API_KEY=\"$DEEPSEEK_API_KEY\" \\\n  -v deepseek-tui-home:/home/deepseek/.deepseek \\\n  ghcr.io/hmbown/deepseek-tui:latest\n```\n\n### Zed / ACP\n\nDeepSeek can run as a custom Agent Client Protocol server for editors that\nspawn local ACP agents over stdio. In Zed, add a custom agent server:\n\n```json\n{\n  \"agent_servers\": {\n    \"DeepSeek\": {\n      \"type\": \"custom\",\n      \"command\": \"deepseek\",\n      \"args\": [\"serve\", \"--acp\"],\n      \"env\": {}\n    }\n  }\n}\n```\n\nThe first ACP slice supports new sessions and prompt responses through your\nexisting DeepSeek config/API key. Tool-backed editing and checkpoint replay are\nnot exposed through ACP yet.\n\nCommunity-maintained adapter: [acp-deepseek-adapter](https://github.com/rockeverm3m/acp-deepseek-adapter)\nbridges `deepseek exec --auto` to `cc-connect` for users who need tool-backed\nACP workflows outside the built-in Zed slice.\n\n### Keyboard Shortcuts\n\n| Key | Action |\n|---|---|\n| `Tab` | Complete `/` or `@` entries; while running, queue draft as follow-up; otherwise cycle mode |\n| `Shift+Tab` | Cycle reasoning-effort: off → high → max |\n| `F1` | Searchable help overlay |\n| `Esc` | Back / dismiss |\n| `Ctrl+K` | Command palette |\n| `Ctrl+R` | Resume an earlier session |\n| `Alt+R` | Search prompt history and recover cleared drafts |\n| `Ctrl+S` | Stash current draft (`/stash list`, `/stash pop` to recover) |\n| `@path` | Attach file/directory context in composer |\n| `↑` (at composer start) | Select attachment row for removal |\n\nFull shortcut catalog: [docs/KEYBINDINGS.md](docs/KEYBINDINGS.md).\n\n---\n\n## Modes\n\n| Mode | Behavior |\n| --- | --- |\n| **Plan** 🔍 | Read-only investigation — model explores and proposes a plan before making changes; multi-step investigations use `checklist_write` |\n| **Agent** 🤖 | Default interactive mode — multi-step tool use with approval gates; substantial work is tracked with `checklist_write` |\n| **YOLO** ⚡ | Auto-approve all tools in a trusted workspace; multi-step work still keeps a visible checklist |\n\n---\n\n## Configuration\n\nUser config: `~/.deepseek/config.toml`. Project overlay: `\u003cworkspace\u003e/.deepseek/config.toml` (denied: `api_key`, `base_url`, `provider`, `mcp_config_path`). [config.example.toml](config.example.toml) has every option.\n\nKey environment variables:\n\n| Variable | Purpose |\n|---|---|\n| `DEEPSEEK_API_KEY` | API key |\n| `DEEPSEEK_BASE_URL` | API base URL |\n| `DEEPSEEK_HTTP_HEADERS` | Optional custom model request headers, e.g. `X-Model-Provider-Id=your-model-provider` |\n| `DEEPSEEK_MODEL` | Default model |\n| `DEEPSEEK_STREAM_IDLE_TIMEOUT_SECS` | Stream idle timeout in seconds, default `300`, clamped to `1..=3600` |\n| `DEEPSEEK_PROVIDER` | `deepseek` (default), `nvidia-nim`, `openai`, `openrouter`, `novita`, `fireworks`, `sglang`, `vllm`, `ollama` |\n| `DEEPSEEK_PROFILE` | Config profile name |\n| `DEEPSEEK_MEMORY` | Set to `on` to enable user memory |\n| `DEEPSEEK_ALLOW_INSECURE_HTTP=1` | Allow non-local `http://` API base URLs on trusted networks |\n| `NVIDIA_API_KEY` / `OPENAI_API_KEY` / `OPENROUTER_API_KEY` / `NOVITA_API_KEY` / `FIREWORKS_API_KEY` / `SGLANG_API_KEY` / `VLLM_API_KEY` / `OLLAMA_API_KEY` | Provider auth |\n| `OPENAI_BASE_URL` / `OPENAI_MODEL` | Generic OpenAI-compatible endpoint and model ID |\n| `SGLANG_BASE_URL` | Self-hosted SGLang endpoint |\n| `VLLM_BASE_URL` | Self-hosted vLLM endpoint |\n| `OLLAMA_BASE_URL` | Self-hosted Ollama endpoint |\n| `OLLAMA_MODEL` | Self-hosted Ollama model tag |\n| `NO_ANIMATIONS=1` | Force accessibility mode at startup |\n| `SSL_CERT_FILE` | Custom CA bundle for corporate proxies |\n\nSet `locale` in `settings.toml`, use `/config locale zh-Hans`, or rely on `LC_ALL`/`LANG` to choose UI chrome and the fallback language sent to V4 models. The latest user message still wins for natural-language reasoning and replies, so Chinese user turns stay Chinese even on an English system locale. See [docs/CONFIGURATION.md](docs/CONFIGURATION.md) and [docs/MCP.md](docs/MCP.md).\n\n---\n\n## Models \u0026 Pricing\n\n| Model | Context | Input (cache hit) | Input (cache miss) | Output |\n|---|---|---|---|---|\n| `deepseek-v4-pro` | 1M | $0.003625 / 1M* | $0.435 / 1M* | $0.87 / 1M* |\n| `deepseek-v4-flash` | 1M | $0.0028 / 1M | $0.14 / 1M | $0.28 / 1M |\n\nDeepSeek Platform defaults to `https://api.deepseek.com/beta` in v0.8.16 so beta-gated API features can be tested without extra setup. Set `base_url = \"https://api.deepseek.com\"` to opt out.\n\nLegacy aliases `deepseek-chat` / `deepseek-reasoner` map to `deepseek-v4-flash` and retire after July 24, 2026. NVIDIA NIM variants use your NVIDIA account terms.\n\n*DeepSeek Pro rates currently reflect a limited-time 75% discount, which remains valid until 15:59 UTC on 31 May 2026. After that time, the TUI cost estimator will revert to the base Pro rates.*\n\n\u003e [!Note]\n\u003e For the latest DeepSeek-V4-Pro pricing, including the current 75% discount valid until 15:59 UTC on 31 May 2026, please consult the official [DeepSeek pricing page](https://api-docs.deepseek.com/zh-cn/quick_start/pricing). All rates listed in the README correspond to the officially published values.\n\n---\n\n## Publishing Your Own Skill\n\nDeepSeek TUI discovers skills from workspace directories (`.agents/skills` → `skills` → `.opencode/skills` → `.claude/skills` → `.cursor/skills`) and global directories (`~/.agents/skills` → `~/.claude/skills` → `~/.deepseek/skills`). Each skill is a directory with a `SKILL.md` file:\n\n```text\n~/.agents/skills/my-skill/\n└── SKILL.md\n```\n\nFrontmatter required:\n\n```markdown\n---\nname: my-skill\ndescription: Use this when DeepSeek should follow my custom workflow.\n---\n\n# My Skill\nInstructions for the agent go here.\n```\n\nCommands: `/skills` (list), `/skill \u003cname\u003e` (activate), `/skill new` (scaffold), `/skill install github:\u003cowner\u003e/\u003crepo\u003e` (community), `/skill update` / `uninstall` / `trust`. Community installs from GitHub require no backend service. Installed skills appear in the model-visible session context; the agent can auto-select relevant skills via the `load_skill` tool when your task matches their descriptions.\n\nFirst launch also installs bundled system skills for common workflows:\n`skill-creator`, `delegate`, `v4-best-practices`, `plugin-creator`,\n`skill-installer`, `mcp-builder`, `documents`, `presentations`,\n`spreadsheets`, `pdf`, and `feishu`. These live under\n`~/.deepseek/skills` and are versioned so new bundles are added on upgrade\nwithout recreating skills the user deliberately deleted.\n\n---\n\n## Documentation\n\n| Doc | Topic |\n|---|---|\n| [ARCHITECTURE.md](docs/ARCHITECTURE.md) | Codebase internals |\n| [CONFIGURATION.md](docs/CONFIGURATION.md) | Full config reference |\n| [MODES.md](docs/MODES.md) | Plan / Agent / YOLO modes |\n| [MCP.md](docs/MCP.md) | Model Context Protocol integration |\n| [RUNTIME_API.md](docs/RUNTIME_API.md) | HTTP/SSE API server |\n| [INSTALL.md](docs/INSTALL.md) | Platform-specific install guide |\n| [MEMORY.md](docs/MEMORY.md) | User memory feature guide |\n| [SUBAGENTS.md](docs/SUBAGENTS.md) | Sub-agent role taxonomy and lifecycle |\n| [KEYBINDINGS.md](docs/KEYBINDINGS.md) | Full shortcut catalog |\n| [RELEASE_RUNBOOK.md](docs/RELEASE_RUNBOOK.md) | Release process |\n| [LOCALIZATION.md](docs/LOCALIZATION.md) | UI locale matrix \u0026 switching |\n| [OPERATIONS_RUNBOOK.md](docs/OPERATIONS_RUNBOOK.md) | Ops \u0026 recovery |\n\nFull Changelog: [CHANGELOG.md](CHANGELOG.md).\n\n---\n\n## Thanks\n\n- **[DeepSeek](https://github.com/deepseek-ai)** — thank you for the models and support that power every turn. 感谢 DeepSeek 提供模型与支持，让每一次交互成为可能。\n- **[DataWhale](https://github.com/datawhalechina)** 🐋 — thank you for your support and for welcoming us into the Whale Brother family. 感谢 DataWhale 的支持，并欢迎我们加入“鲸兄弟”大家庭。\n- **[OpenWarp](https://github.com/zerx-lab/warp)** — thank you for prioritizing DeepSeek TUI support and for collaborating on a better terminal-agent experience.\n- **[Open Design](https://github.com/nexu-io/open-design)** — thank you for support and collaboration around design-forward agent workflows.\n\nThis project ships with help from a growing community of contributors:\n\n- **[merchloubna70-dot](https://github.com/merchloubna70-dot)** — 28 PRs spanning features, fixes, and VS Code extension scaffolding (#645–#681)\n- **[WyxBUPT-22](https://github.com/WyxBUPT-22)** — Markdown rendering for tables, bold/italic, and horizontal rules (#579)\n- **[loongmiaow-pixel](https://github.com/loongmiaow-pixel)** — Windows + China install documentation (#578)\n- **[20bytes](https://github.com/20bytes)** — User memory docs and help polish (#569)\n- **[staryxchen](https://github.com/staryxchen)** — glibc compatibility preflight (#556)\n- **[Vishnu1837](https://github.com/Vishnu1837)** — glibc compatibility improvements (#565)\n- **[shentoumengxin](https://github.com/shentoumengxin)** — Shell `cwd` boundary validation (#524)\n- **[toi500](https://github.com/toi500)** — Windows paste fix report\n- **[xsstomy](https://github.com/xsstomy)** — Terminal startup repaint report\n- **[melody0709](https://github.com/melody0709)** — Slash-prefix Enter activation report\n- **[lloydzhou](https://github.com/lloydzhou)** and **[jeoor](https://github.com/jeoor)** — Compaction cost reports; lloydzhou also contributed deterministic environment context (#813, #922) and KV prefix-cache stabilisation (#1080)\n- **[Agent-Skill-007](https://github.com/Agent-Skill-007)** — README clarity pass (#685)\n- **[woyxiang](https://github.com/woyxiang)** — Windows install documentation (#696)\n- **[wangfeng](mailto:wangfengcsu@qq.com)** — Pricing/discount info update (#692)\n- **[zichen0116](https://github.com/zichen0116)** — CODE_OF_CONDUCT.md (#686)\n- **[dfwqdyl-ui](https://github.com/dfwqdyl-ui)** — model ID case-sensitivity compatibility report (#729)\n- **[Oliver-ZPLiu](https://github.com/Oliver-ZPLiu)** — stale `working...` state bug report and Windows clipboard fallback (#738, #850)\n- **[reidliu41](https://github.com/reidliu41)** — resume hint, workspace trust persistence, Ollama provider support, and thinking-block stream finalization (#863, #870, #921, #1078)\n- **[xieshutao](https://github.com/xieshutao)** — plain Markdown skill fallback (#869)\n- **[GK012](https://github.com/GK012)** — npm wrapper `--version` fallback (#885)\n- **[y0sif](https://github.com/y0sif)** — parent turn-loop wakeup after direct child sub-agent completion (#901)\n- **[mac119](https://github.com/mac119)** and **[leo119](https://github.com/leo119)** — `deepseek update` command documentation (#838, #917)\n- **[dumbjack](https://github.com/dumbjack)** / **浩淼的mac** — command-safety null-byte hardening (#706, #918)\n- **macworkers** — fork confirmation with the new session id (#600, #919)\n- **zero** and **[zerx-lab](https://github.com/zerx-lab)** — notification condition config and richer OSC 9 notification body (#820, #920)\n- **[chnjames](https://github.com/chnjames)** — cached @mention completions, config recovery polish, and Windows UTF-8 shell output (#849, #927, #982, #1018)\n- **[angziii](https://github.com/angziii)** — config safety, async cleanup, Docker hardening, and command-safety fixes (#822, #824, #827, #831, #833, #835, #837)\n- **[elowen53](https://github.com/elowen53)** — UTF-8 decoding and deterministic test coverage (#825, #840)\n- **[wdw8276](https://github.com/wdw8276)** — `/rename` command for custom session titles (#836)\n- **[banqii](https://github.com/banqii)** — `.cursor/skills` discovery path support (#817)\n- **[junskyeed](https://github.com/junskyeed)** — dynamic `max_tokens` calculation for API requests (#826)\n- **Hafeez Pizofreude** — SSRF protection in `fetch_url` and Star History chart\n- **Unic (YuniqueUnic)** — Schema-driven config UI (TUI + web)\n- **Jason** — SSRF security hardening\n- **[axobase001](https://github.com/axobase001)** — snapshot orphan cleanup, npm install guards, session telemetry fixes, model-scope cache clear, symlinked skill support, and npm mirror-escape-hatch guidance (#975, #1032, #1047, #1049, #1052, #1019, #1051, #1056)\n- **[MengZ-super](https://github.com/MengZ-super)** — `/theme` command foundation and SSE gzip/brotli decompression (#1057, #1061)\n- **[DI-HUO-MING-YI](https://github.com/DI-HUO-MING-YI)** — Plan-mode read-only sandbox safety fix (#1077)\n- **[bevis-wong](https://github.com/bevis-wong)** — precise paste-Enter auto-submit reproducer (#1073)\n- **[Duducoco](https://github.com/Duducoco)** and **[AlphaGogoo](https://github.com/AlphaGogoo)** — skills slash-menu and `/skills` coverage fix (#1068, #1083)\n- **[ArronAI007](https://github.com/ArronAI007)** — window-resize artifact fix for macOS Terminal.app and ConHost (#993)\n- **[THINKER-ONLY](https://github.com/THINKER-ONLY)** — OpenRouter and custom-endpoint model-ID preservation (#1066)\n- **[Jefsky](https://github.com/Jefsky)** — DeepSeek endpoint correction report (#1079, #1084)\n- **[wlon](https://github.com/wlon)** — NVIDIA NIM provider API-key preference diagnosis (#1081)\n- **[Horace Liu](https://github.com/liuhq)** — Nix package support and install documentation (#1173)\n\n---\n\n## Contributing\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md). Pull requests welcome — check the [open issues](https://github.com/Hmbown/DeepSeek-TUI/issues) for good first contributions.\n\nSupport: [Buy me a coffee](https://www.buymeacoffee.com/hmbown).\n\n\u003e [!Note]\n\u003e *Not affiliated with DeepSeek Inc.*\n\n## License\n\n[MIT](LICENSE)\n\n## Star History\n\n[![Star History Chart](https://api.star-history.com/chart?repos=Hmbown/DeepSeek-TUI\u0026type=date\u0026legend=top-left)](https://www.star-history.com/?repos=Hmbown%2FDeepSeek-TUI\u0026type=date\u0026logscale=\u0026legend=top-left)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhmbown%2Fdeepseek-tui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhmbown%2Fdeepseek-tui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhmbown%2Fdeepseek-tui/lists"}