nanocoder

Nano-Collective活跃维护

终端里的开源编码智能体,支持自带模型(Ollama、OpenAI、OpenRouter 等),代码留在本地,由社区维护而非公司运营。

An open coding agent for your terminal, built by a community collective rather than a company. Bring your own model, keep your code on your machine, and owe nothing to anyone.

v1.32.0发布于 2026-11-04 12:43 UTC2,559star +6 / 7 天396fork同步于 2026-11-10 11:43 UTC

怎么上手

由 README 提炼,执行前请确认
npm install -g @nanocollective/nanocoder
nanocoder
硬件要求按 README 说明

README 未说明显存或 GPU 型号要求;本地模型通过 Ollama 运行,硬件门槛取决于所选模型

下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

终端里的开源编码智能体,自带模型、代码留在本机,不绑定任何厂商

终端里的开源编码智能体,支持自带模型(Ollama、OpenAI、OpenRouter 等),代码留在本地,由社区维护而非公司运营。

核心能力

  • 支持 Ollama 本地模型和任意 OpenAI 兼容 API
  • 提供 normal、auto-accept、yolo、plan、architect 五种开发模式
  • 用 nanocoder review 审查分支或 PR 的缺陷与安全问题
  • 用 nanocoder worktree 在隔离 worktree 中打开 PR 会话
  • 全屏与内联两种渲染模式,内联保留终端原生回滚

容易踩的坑

本地模型需先自行安装并运行 Ollama;nanocoder review 仅支持 diff 且必须交互式 TTY,不能管道重定向或存文件;nanocoder worktree 需要 Git、已认证的 gh CLI 和交互式终端

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v1.32.0
  1. v1.32.0nanocoder v1.32.0最新正式版2026-11-04 · 2026-11-04 12:43 UTC

    What's Changed

    • Nanocoder's ACP agent now honours the mcpServers an editor sends on session/new, session/load and session/resume. Stdio and HTTP servers are connected for that session only, so their tools exist in that session (and in subagents it starts) and in no other, and your own MCP configuration is never read or changed. Loading or resuming a session replaces its previous servers, and closing it, or deleting it, disconnects them. A server that fails to connect, or uses SSE, is logged and skipped and the request still succeeds. initialize now reports mcpCapabilities (http). A tool whose name an existing tool already has is skipped, and these tools follow the usual approval rules. Sessions with no servers behave as before.
    • ACP extension requests now use the _ prefix ACP reserves for custom methods: _nanocoder/renameSession, _nanocoder/timeline/list, _nanocoder/timeline/revert and _nanocoder/retryTurn. The bare names still work as deprecated aliases and log a one-time notice, and will be removed in a later release. initialize now lists the exact method and notification names under agentCapabilities._meta.nanocoder, so a client can detect support instead of guessing from the version. A custom request the agent doesn't recognise now fails with the standard "Method not found" (-32601) instead of a plain error. The VS Code extension uses the advertised names and falls back to the bare ones for an older agent.
    • ACP sessions now keep their own provider and model. Changing them with session/set_config_option affects only that session (a running turn finishes on the model it started with), its subagents use the model it is on, the config options returned for a session are its own, and saved sessions record their own provider and model. session/resume and session/load restore the saved provider and model when they are still available, and otherwise stay on the default and report the saved choice in _meta["nanocoder/modelFallback"]. The agent advertises agentCapabilities._meta.nanocoder.perSessionModel.
    • ACP clients can now exempt a session from retention with the new _nanocoder/pinSession extension method (sessionId, pinned). Neither retentionDays nor maxSessions deletes a pinned session, and pinned sessions do not count toward maxSessions; session/delete still removes them. session/list entries report the mark as _meta["nanocoder/pinned"], and initialize reports the effective retentionDays and maxSessions as _meta["nanocoder/retention"].
    • ACP clients can now turn tools off for a single session. Send _meta: {"nanocoder/disabledTools": ["browser"]} on session/new, session/load or session/resume, for example to stop Nanocoder's built-in browser when the editor provides its own. The names are added to the user's own disabledTools, never replacing it, and apply to that session only: the tools are left out of the tool list and the prompt, a call the model makes to one anyway is refused and nothing runs, and subagents the session starts respect the same list. The response _meta reports the list in effect under the same key so a client can verify it. The list is not saved with the session and the user's config files are never read or changed for this. The approval policy the response reports no longer lists a tool the session has turned off. Sessions that send nothing are unchanged.
    • ACP clients can now follow each subagent run on its own. Nanocoder sends a _nanocoder/subagent notification as every run starts, progresses and ends (completed, failed or cancelled), with a stable childRunId, the parentRunId (empty for a child of the turn), the parent agent tool call, the subagent's name, progress counts and its result or error. A new _nanocoder/cancelSubagent request cancels one run by childRunId without ending the turn: the run reports cancelled, the parent agent call gets a "Subagent was cancelled" result and carries on, and cance
  2. v1.31.0nanocoder v1.31.02026-09-26 · 2026-09-26 20:08 UTC
    查看更新说明

    What's Changed

    • Added a first-class provider template for Cheaper Inference, an OpenAI-compatible gateway, to the /settings providers wizard. Selecting it fills in the base URL (https://api.cheaperinference.com/v1) so only an API key and a model name are needed, and the wizard can fetch the account's model list over the standard /models endpoint.
    • Added a showAgentBashOutput preference (/settings → Behavior → Tool Results and Thinking). By default a completed card for a command the agent runs shows the command and its status, and the command output is not kept; with compact tool display on, the card collapses into a tally line. This preference shows the output on that card, whether compact tool display is on or off, and for failed commands too. Commands you type yourself (!command) always show their output and are unaffected.
    • Publish a JSON Schema for agents.config.json as schemas/agents.config.schema.json. It is generated deterministically from the on-disk DiskConfig type (pnpm run generate:schema), ships with an Ajv validation suite plus a CI drift check, and enables editor autocompletion — either by dropping the $schema key into your config or by wiring up the schema via jsonValidation / a JSON Schema mapping in your editor.
    • Added automatic session titles. A session keeps its opening prompt as the title, and when that prompt is too thin to be useful the agent generates a descriptive name once, after the first turn that ran a tool or the first follow-up message. Manual renames are never overwritten.

    Titling runs in the ACP agent, so it applies to the VS Code extension and other ACP clients; the CLI keeps its heuristic title. It uses the session's own model by default - set sessions.titleModel / sessions.titleProvider to point it at a cheaper or local one, or sessions.smartTitles: false to turn it off. Pointing titleProvider at a different provider sends it the opening user turns and a summary of the tools that ran, which includes file paths and bash command strings.

    Two things worth knowing: the tokens a title costs are billed by the provider but are not counted in /usage, since the call is made outside the conversation loop that builds usage records; and existing sessions are retitled from their first message on their next autosave, which is a one-time visible reshuffle of the history list.

    Also fixed the CLI's autosave deriving the session title from the latest user message and rewriting it on every save, which overwrote titles in the store the VS Code extension reads from. Closes #808.

    • Added Anthropic prompt caching. The system prompt, tool schemas, and conversation history are now marked with cache breakpoints, so multi-turn sessions read the stable prefix back out of cache instead of paying full price for it every turn. Cost reporting is cache-aware throughout: /usage and the per-response indicator price cache reads and writes at their own rates instead of billing every cache hit at the full input rate, and the per-response indicator surfaces the cached token count alongside the total. Opt out with "promptCaching": false on the provider config. Closes #888.
    • Fix multi-line paste submitting the prompt partway through.

    Nanocoder never enabled bracketed paste, so the terminal delivered a paste as bare bytes and the carriage return at each line break reached Ink's keypress parser as Enter. Pasting two lines sent the first line to the model and left the second in the input box. Paste handling relied entirely on heuristics (input rate, size, line count) that only ever saw text which had already made it into the buffer.

    DECSET 2004 is now enabled in both screen modes. Paste payloads are lifted off stdin before Ink sees them and delivered to the input as a single event, so a pasted newline can no longer submit. The old heuristics remain as a fallback for terminals without bracketed paste support.

    Fullscreen mode enables mouse reporting for wheel scrolling, which takes cli

  3. v1.30.0nanocoder v1.30.02026-08-26 · 2026-08-26 13:27 UTC
    查看更新说明

    What's Changed

    • Added first-class provider template for Groq to the setup wizard.
    • Added first-class provider template for OrcaRouter to the setup wizard.
    • Added a /commit slash command that generates Conventional Commit messages from staged Git diffs using the active LLM client. Thanks to @DeepamJha. Closes #757.
    • Consolidated upload actions under a single '+' menu in the VS Code webview to reduce UI clutter and improve scalability for future attachment types.
    • Added context attachment functionality with UI for file/folder chips and drag-and-drop support.
    • Added Settings Tab to the VS Code extension webview for configuring providers and behavior directly from the UI.
    • list_directory no longer includes file sizes by default — they cost an lstat syscall per file plus output tokens for information that's rarely needed just to orient in a directory. Pass showSizes=true to opt back in, or use read_file with metadata_only=true for a single file's size.
    • Added a per-response token usage and estimated cost indicator. Every assistant message in the CLI now ends with a subtle gray footer showing the provider-reported token count and estimated cost (e.g. Tokens: 4.2k | ~$0.01), computed from models.dev pricing; the cost segment is omitted for local/free models and the footer falls back to the previous client-side estimate when the provider reports no usage. The VS Code extension shows the same indicator under each finished response, fed by the per-turn usage now returned on the ACP prompt response. Note: the estimate prices all input tokens at the standard rate — cache read/write discounts are not factored in, so costs can be overstated for providers with prompt caching. Closes #756.
    • Moved the rest of nanocoder's configuration into the /settings menu, so you can set things up without editing .json files by hand. Settings are grouped into Appearance, Input, Behavior, Providers, MCP, and Advanced tabs. New menu items let you set the default mode, auto-compact, sessions, reasoning traces, tool auto-approval, and a Web Search API key; view your configured providers and MCP servers before opening the setup wizards; open the Tune Model and Connect IDE wizards; and see the active NANOCODER_* environment variables. Advanced also includes an in-app JSON editor for agents.config.json: edit strings with the cursor inside the quotes, flip booleans with the arrow keys, and save atomically (a crash can't leave a half-written file).
    • Sunset /setup-providers and /setup-mcp in favour of /settings. Both retired names still work for now — they open the matching /settings tab with a notice instead of erroring. /settings now takes a tab argument (/settings providers, /settings mcp), MCP has its own settings tab, and provider edits made from settings apply to the running session instead of waiting for the next launch. Selecting a provider or MCP server in settings now opens that entry's edit/delete choice directly, with a separate row for adding a new one.
    • Added editor code lenses to the VS Code extension: every function, method, constructor and class now carries Explain Code and Generate Tests links, and clicking one reveals the chat view and sends that symbol - instruction, file:startLine-endLine and the source, fenced with the document language - as a prompt. Symbols come from the language server, so no per-language parsing is involved, and the lenses can be turned off with nanocoder.codeLens. Long symbols are capped before being inlined, so a lens click on a large class cannot spend a whole context window on one turn. Also fixes a pre-existing hang where sending a message while a tool approval was still pending left the composer spinning forever. Closes #750.
    • Added @ mention autocomplete to the VS Code extension's chat composer: typing @ opens a floating dropdown of workspace files, folders and open editors, and selecting one attaches it as a context chip. Search runs on the extension host,
  4. v1.29.0nanocoder v1.29.02026-07-26 · 2026-07-26 19:22 UTC
    查看更新说明

    What's Changed

    • Added the ability to attach to a running subagent session from the terminal UI for interactive debugging. This feature allows users to inspect exactly what a subagent is doing in real-time, including streaming text and reasoning. You can press Ctrl+S while a subagent is running to attach to it, cycle between multiple running subagents, and press Esc to detach.

    • Added privacy-aware prompt scrubbing. A new PrivacyContext scrubs sensitive content from prompts before they leave your machine, with tool-argument rehydration and privacy session support, a /privacy command to inspect what is being scrubbed, and automated scrubbing telemetry notifications. Thanks to @akramcodez.

    • Added an interactive questions system for plan mode, so the agent can ask structured questions while planning instead of guessing. Thanks to @akramcodez. Closes #96.

    • Added mode-specific provider and model configuration, so each development mode can use its own provider and model. Thanks to @akramcodez. Closes #277.

    • Added dual TUI screen modes, with a more reliable /clear and graceful exit handling. Thanks to @llupRisinglll.

    • Added multiline cursor navigation and word-jump in the input box. Thanks to @llupRisinglll.

    • Added --resume / --continue CLI session flags. --continue (-c) resumes the most recent session for the current directory, and --resume [id] (-r) resumes a session by id, list index, or last, with a bare --resume opening the session picker at startup. Thanks to @llupRisinglll.

    • Added a fuzzy search filter to the /model picker, with a capped, centered scrolling window so large model catalogs no longer overflow the terminal and the current model is preselected. Thanks to @rakshith1928. Closes #683.

    • Added PDF and DOCX support to read_file via get-md, so those documents can be read directly. Thanks to @akramcodez.

    • Added a doctor diagnostic command that checks your setup and reports common configuration problems. Thanks to @Dhirenderchoudhary. Closes #609.

    • Added a retry command to re-run the last user turn. Thanks to @Dhirenderchoudhary. Closes #608.

    • Added message queueing while the agent is busy so you can type ahead. Queued messages can be recalled before streaming, are truncated properly on narrow terminals, and no longer double-dispatch. Thanks to @Dhirenderchoudhary. Closes #597, #598.

    • Added estimated dollar cost tracking to /usage, with a per-provider cost breakdown and a cumulative per-call cost history. Thanks to @rakshith1928. Closes #602.

    • Added a --json output flag to the non-interactive plain run path. Thanks to @OMEE-Y.

    • Added a diff_edit tool for nano-profile models. Thanks to @Dhirenderchoudhary. Closes #604.

    • Added automatic diagnostics after file edits, surfacing errors introduced by an edit right away. Thanks to @2409324124. Closes #538.

    • Added the foundation for semantic memory (storage layer and initial wiring), groundwork for upcoming memory features. Thanks to @Dhirenderchoudhary.

    • Reworked the client to a stateless API with history-boundary rehydration, improving conversation reliability. Thanks to @akramcodez.

    • Added a Together AI provider template and docs, and MiniMax Coding now defaults to MiniMax-M3. Thanks to @octo-patch. Added Atomic Chat local provider configuration docs. Thanks to @yanalialiuk.

    • Fix: nanocoder.tune loading and configuration precedence from agents.config.json now resolve correctly. Thanks to @rakshith1928. Closes #648.

    • Fix: patch malformed SSE termination strings from providers, preventing stream parsing errors. Thanks to @akramcodez. Closes #614.

    • Fix: bound slash command completions so the menu no longer overflows. Thanks to @2409324124. Closes #624.

    • Fix: decouple console log verbosity from NODE_ENV and quiet noisy LSP discovery logs. Thanks to @A-S-Manoj. Closes #606.

    • Fix: **removed the `s

  5. v1.28.1nanocoder v1.28.12026-06-28 · 2026-06-28 20:45 UTC
    查看更新说明

    What's Changed

    • Added image attachments on user messages. Paste an image from the clipboard with Ctrl+V (via osascript on macOS, wl-paste/xclip on Linux, PowerShell on Windows), drag an image file into the terminal, or type a path - quoted, unquoted, and macOS backslash-escaped paths are all recognised, and http(s) URLs are left untouched. Attachments (PNG/JPEG/GIF/WebP, up to 10 MB) show above the input box and Ctrl+X removes the last one; references are stripped from the text and sent as image parts to vision-capable models. A missing clipboard tool now logs a debug breadcrumb instead of silently no-op'ing. Thanks to @ragini-pandey. Closes #572.

    • Added skill promotion and demotion. Skills can now be promoted and demoted between project and personal scope, with a --move flag to relocate rather than copy the skill files.

    • Fix: slash commands now run with their arguments. Once a space is typed after a slash command, the completion menu hides so Enter submits the full command with its arguments instead of selecting a completion and dropping everything after the command name.

    • Fix: the chat view no longer snaps to the bottom when a slash command completion menu opens. The completion and file-suggestion menus now render inside the bounded input layout, so the container expands without disrupting the window height calculation that previously forced the history to scroll in smaller terminals. Thanks to @Dhirenderchoudhary. Closes #581.

    • Fix: empty frontmatter blocks are recognised instead of leaking --- markers into the body or throwing. splitFrontmatter now matches an empty block, and extractRawFrontmatter uses the shared parseYamlObject helper so an empty subagent frontmatter flows through to validation and surfaces a clear name is required error. Thanks to @Fadhlan. Closes #592.

    • Fix: ask_user unwraps label-as-key option objects, so options expressed as a { label: value } map render as readable choices.

    • Fix: surface real network errors instead of mislabeling them as context overflow. A failed request from a network error is no longer misreported as exceeding the context window.

    • Fix: size MoE models by total parameter count, not active count, when auto-resolving the tool profile, so mixture-of-experts models get the correct tune.

    • Fix: number formatting on the /copy command output.

    • Docs: clarified MCP tool profile visibility and documented the image-attachments feature. Thanks to @zerone0x. Closes #593.

    If there are any problems, feedback or thoughts please drop an issue or message us through Discord! Thank you for using Nanocoder.

    Installation

    npm install -g @nanocollective/nanocoder
    

    Usage

    nanocoder
    

    Full Changelog: https://github.com/Nano-Collective/nanocoder/compare/v1.28.0...v1.28.1

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    Nanocoder

    简体中文 繁體中文

    An open coding agent for your terminal, built by a community collective rather than a company. Bring your own model, keep your code on your machine, and owe nothing to anyone.

    Built by the Nano Collective, a community collective building AI tooling not for profit, but for the community. Nanocoder runs agentic coding on the model of your choice: local models via Ollama, or any OpenAI-compatible API such as OpenRouter, Requesty, Anthropic, and Google. You decide which provider runs your code and where your data goes. No closed-source features and no paid tiers gating the useful parts: privacy-respecting, local-first, and open for all.

    Typing SVG

    Example


    Build Status Coverage Version NPM Downloads NPM License Repo Size Stars Forks

    Quick Start

    npm install -g @nanocollective/nanocoder
    nanocoder
    

    Also available via Homebrew and Nix Flakes.

    CLI Flags

    Specify provider, model, and starting mode directly:

    # Non-interactive mode with specific provider/model
    nanocoder --provider openrouter --model google/gemini-3.1-flash run "analyze src/app.ts"
    
    # Interactive mode starting with specific provider
    nanocoder --provider ollama --model llama3.1
    
    # Flags can appear before or after 'run' command
    nanocoder run --provider openrouter "refactor database module"
    
    # Boot directly into a development mode (normal, auto-accept, yolo, plan, architect)
    nanocoder --mode yolo
    nanocoder --mode plan run "audit the auth module"
    
    # Inline mode (native terminal scrollback) instead of the fullscreen default
    nanocoder --no-alt-screen
    
    # Review a branch or PR for bugs, security issues, and style violations
    nanocoder review main
    nanocoder review 42
    
    # Open a PR in an isolated worktree for an interactive coding session
    nanocoder worktree 42
    

    Note: nanocoder review is diff-only v1 and requires an interactive terminal (TTY). It cannot be used with pipes or redirection and its output cannot currently be captured to a file — see #1287.

    nanocoder worktree <PR-number> requires Git, an authenticated gh CLI, and an interactive terminal. It creates a sibling directory named <repository>-pr-<number>, checks out the PR head on a local nanocoder/pr-<number> branch, and starts Nanocoder there. The original working tree is left alone. Both the worktree and branch remain after Nanocoder exits; remove them with git worktree remove <path> and git branch -d nanocoder/pr-<number> when finished. An existing directory or branch is never reused or overwritten.

    Screen Modes

    Nanocoder supports two rendering modes, mirroring what Claude Code and Codex ship:

    • Fullscreen (default) — a fixed-height layout on the alternate screen buffer with in-app scrolling: PgUp/PgDn, with a scroll indicator and automatic snap-back to bottom on new output. Mouse reporting can be toggled with --mouse / --no-mouse or in preferences.
    • Inline (--no-alt-screen flag, or "alternateScreen": false in preferences) — renders on the main screen; finished messages print once into the terminal's native scrollback, so your terminal's scrollbar, mouse wheel, and search work as usual. The transcript stays in the terminal after you exit.

    In both modes, /clear fully resets the terminal to a fresh welcome banner, and exiting (Ctrl+C or /exit) erases the input UI cleanly instead of leaving a dead input box. Inline mode leaves the transcript in your scrollback; fullscreen mode restores the terminal to what it showed before Nanocoder started, so the transcript is not kept on screen (use /resume or /export to get it back).

    Documentation

    Full documentation is available online at docs.nanocollective.org or in the docs/ folder:

    • Getting Started - Installation, setup, and first steps
    • Configuration - AI providers, MCP servers, preferences, logging, timeouts
    • Features - Skills (commands, subagents, tools, event triggers), lifecycle hooks, the per-project daemon, checkpointing, development modes, task management, and more
    • Commands Reference - Complete list of built-in slash commands
    • Keyboard Shortcuts - Full shortcut reference
    • Community - Contributing, Discord, and how to help

    Why a collective

    Nanocoder is built by the Nano Collective rather than a company, and that shapes the tool itself. There are no paid tiers, no telemetry quietly shipping your prompts somewhere, and no roadmap steered by what monetises best — the people building it are the people using it. Building in the open as a collective means the harness stays multi-provider on principle: you are never locked to one vendor's model, and the conventions, tests, and release standards are shared across every Nano Collective project so the work stays legible and contributable.

    It is also bigger than one tool. The collective is assembling an open ecosystem of AI tooling — see the other projects — and contributors who show up now help shape what that becomes.

    Sponsors

    Nanocoder is built not for profit, but for the community, and that work is funded by sponsors. Become one.

    Community

    The Nano Collective is a community collective building AI tooling for the community, not for profit. We'd love your help.