Discover and explore top open-source AI tools and projects—updated daily.
lsm1103Claude Code CLI restored from source maps for local research
New!
Top 94.9% on SourcePulse
This project reconstructs and provides a runnable, albeit unofficial, version of the Claude Code CLI by restoring its complete TypeScript source code from the public npm package's source maps. It targets researchers and developers interested in studying the internal workings of the Claude Code CLI, offering a local development environment for analysis.
How It Works
This repository leverages source maps from the @anthropic-ai/claude-code npm package to reverse-engineer the original TypeScript codebase. It utilizes the Bun runtime (version ≥ 1.3.5) for dependency management and execution, aiming to provide a functional CLI environment that mirrors the original's capabilities as closely as possible, with compatibility shims for unrecoverable modules.
Quick Start & Requirements
bun installbun run devbun run versionHighlighted Details
Maintenance & Community
No specific details regarding maintainers, community channels (like Discord/Slack), or roadmaps are provided in the README.
Licensing & Compatibility
The repository is explicitly stated as unofficial and for research/learning purposes only. Source code copyright belongs to Anthropic. Commercial use is prohibited. Compatibility with closed-source linking or commercial applications is not applicable due to these restrictions.
Limitations & Caveats
This is an unofficial restoration and may not perfectly replicate the original Claude Code CLI's behavior due to source map limitations. Type-only files, build-time generated files, private wrappers, native bindings, dynamic imports, and resource files might be missing or degraded. The shims/ directory contains replacements for unrecoverable modules, indicating potential functional differences. Use is strictly limited to technical research and learning.
4 days ago
Inactive