Today, I came across the leaked Claude Code CLI source package.
My first reaction was that it was probably just another joke. After checking it, it turned out to be real. I downloaded the package and spent some time reading through it.
The obvious part is the legal and ethical boundary: leaked source should not be republished. That part is not ambiguous.
But after reading it, I also felt there were a lot of runtime ideas worth studying:
So instead of republishing anything, I built a small project from scratch based on what I learned from those runtime patterns:
Claude Code-lite
GitHub: https://github.com/goozi/claude-code-lite
This is not a Claude Code clone.
It is not an open-source replacement.
And it is definitely not a repackaged version of leaked code.
The project is positioned as:
a small, hackable, local-first coding agent CLI runtime for learning and extension
The goal is to keep the codebase small enough to read and modify, while still being structurally useful for people building their own coding agents.
Current version supports:
So this is already beyond a toy skeleton. It is a minimal usable agent CLI.
A lot of agent projects fall into one of two buckets:
I wanted something in the middle:
If you are working on:
then this repo might be useful as a reference point.
The parts I care most about in this repo are not UI polish. They are runtime boundaries:
query() and turn lifecycleThat is also why I wrote extra docs around architecture and core interfaces, instead of only shipping code.
At least for now, I am explicitly not trying to build:
I would rather keep it readable than prematurely complete.
Likely next areas:
GitHub:
https://github.com/goozi/claude-code-lite
If you are building something similar, I would be interested in feedback on the runtime structure, especially around provider abstraction, permissions, and session lifecycle.
这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。
V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。
V2EX is a community of developers, designers and creative people.