What's new
0.4.0 — the engine refactor. CoreCoder is now built around a single idea: a coding agent you can actually read end to end — the nanoGPT of coding agents, ~1,000 lines of pure Python.
- Engine refactor. The agent loop, context manager, session handling and tool layer were reworked so the whole thing reads top to bottom. Same end-to-end loop: reads and writes files, runs shell, spawns sub-agents, compacts context in three tiers, and reports the tokens and dollars a run burned.
- A bilingual source-reading series. Eight essays (English + 中文) that walk the codebase line by line, reading how production agents like Claude Code work through CoreCoder's minimal reimplementation.
- Broader tests. 86 tests, all green, including Windows CI coverage and the harder edge cases — streamed tool-call stitching, context-compaction invariants, session-id safety.
- Fixes. Avoid default session-id collisions; sanitize saved session ids.
Compatibility
Nothing changes about how you run it. The default openai backend and the litellm extra both keep working; OpenAI-compatible endpoints (DeepSeek, Qwen, Kimi, Ollama, …) are unchanged.
Install
pip install -U corecoder # default
pip install -U 'corecoder[litellm]' # with LiteLLM