最小的 Claude 代码替代方案。单个 Python 文件,无依赖项,约 250 行。
Minimal Claude Code alternative. Single Python file, zero dependencies, ~250 lines.
Built using Claude Code, then used to build itself.
read, write, edit, glob, grep, bashexport ANTHROPIC_API_KEY="your-key"
python nanocode.py
Use OpenRouter to access any model:
export OPENROUTER_API_KEY="your-key"
python nanocode.py
To use a different model:
export OPENROUTER_API_KEY="your-key"
export MODEL="openai/gpt-5.2"
python nanocode.py
/c - Clear conversation/q or exit - Quitread
Read file with line numbers, offset/limit
write
Write content to file
edit
Replace string in file (must be unique)
glob
Find files by pattern, sorted by mtime
grep
Search files for regex
bash
Run shell command
────────────────────────────────────────
❯ what files are here?
────────────────────────────────────────
⏺ Glob(**/*.py)
⎿ nanocode.py
⏺ There's one Python file: nanocode.py
MIT
暂无开放 Issues,或尚未同步最近议题。