Skip to main content
Archived

This project has been archived by its maintainers, and is no longer receiving any updates.

nanocode-cli

nanocode editing code and running tools

A coding agent I use, maintain, and customize in one Python file.

中文

Safety

Use at your own risk. nanocode can edit files and run shell commands in the environment where it starts. It does not provide sandbox isolation; use a container or VM when needed.

What it is

nanocode does not introduce a new kind of coding agent. It combines familiar features — reading and editing files, running commands, follow-ups, sessions, diffs, MCP, and skills — into a tool I use personally.

It works on real repositories, including its own: I use nanocode to build and maintain nanocode. Everything ships in one Python module, so I can change the behavior directly whenever I want the workflow to work differently.

nanocode resuming a saved session

Resuming a saved session with its conversation and tool history.

Highlights

  • Prompt-cache aware: stable request prefixes let supported providers reuse work and can reach 90–99% cache hit rates; /status shows the reported result.
  • Code navigation: jump to definitions, callers, and implementations with a searchable code index.
  • Live follow-ups: type while the agent works; Enter queues a message for the next model step, while Ctrl-C interrupts the current task.
  • Anchored edits: structured edits use line:hash anchors and reject stale file content.
  • Resumable sessions: conversation, tool calls, diffs, and working memory survive -c or --resume.
  • Built-in diff viewer: /diff shows the latest round and the net session result.
  • MCP and skills: connect Model Context Protocol servers and load Markdown instruction packs on demand.
  • Provider compatibility: OpenAI-compatible APIs and Anthropic.

Install

Requires macOS or Linux, Python 3.11+, and uv.

uv tool install nanocode-cli
nanocode --init-config

Add your provider to ~/.nanocode/config.toml:

[provider]
active = "default"

[provider.default]
url = "https://api.deepseek.com"
key = "sk-..."
model = "deepseek-v4-flash"

Then run:

nanocode

Upgrade with uv tool upgrade nanocode-cli.

Links

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nanocode_cli-0.9.10.tar.gz (119.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nanocode_cli-0.9.10-py3-none-any.whl (117.1 kB view details)

Uploaded Python 3

File details

Details for the file nanocode_cli-0.9.10.tar.gz.

File metadata

  • Download URL: nanocode_cli-0.9.10.tar.gz
  • Upload date:
  • Size: 119.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for nanocode_cli-0.9.10.tar.gz
Algorithm Hash digest
SHA256 2b4d8a79e34b91c0d1338519d9f922fa24314afbcd631166cb011ef81407618b
MD5 85ad7a970cc55ec4bac51a30fecf4902
BLAKE2b-256 5b0dc5e7083866b0038ab6fe9b6534516a352c268cb1c96b8a376b7ab632650c

See more details on using hashes here.

File details

Details for the file nanocode_cli-0.9.10-py3-none-any.whl.

File metadata

  • Download URL: nanocode_cli-0.9.10-py3-none-any.whl
  • Upload date:
  • Size: 117.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.7 {"installer":{"name":"uv","version":"0.11.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for nanocode_cli-0.9.10-py3-none-any.whl
Algorithm Hash digest
SHA256 7f74b7f2db66d929258bd9caca0b5a60a5e073fd8a651ca459b9b817e54e79fb
MD5 bc3720406044e993aaddb09ba7ad5e0c
BLAKE2b-256 8bb5228ac031b69688f42f33fa10322ac5e3d447054d52476cd02f2d3478f4a6

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.9.10 This release

2 files

0.9.9

2 files

0.9.8

2 files

0.9.7

2 files

0.9.6

2 files

0.9.4

2 files

0.9.2

2 files

0.9.1

2 files

0.7.2

2 files

0.7.1

2 files

0.7.0

2 files

0.6.6

2 files

0.6.4

2 files

0.6.3

2 files

0.6.2

2 files

0.6.1

2 files

0.5.7

2 files

0.5.4

2 files

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

0.4.9

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page