ClaudeForge — Auto-Generate CLAUDE.md for Any Project
Generate and maintain CLAUDE.md files automatically. Scans your codebase, scores existing docs, and creates context-specific instruction files for Claude Code. MIT, 340+ stars.
What it is
ClaudeForge is a CLI tool that automatically generates and maintains CLAUDE.md files for any project. It scans your codebase, analyzes the project structure, scores existing documentation, and produces context-specific instruction files that help Claude Code understand your project. The result is a CLAUDE.md that gives Claude accurate context about your tech stack, conventions, and constraints.
ClaudeForge is for developers who use Claude Code and want to maximize its effectiveness by providing structured project context without writing CLAUDE.md files manually.
The project is actively maintained with regular releases and a growing user community. Documentation covers common use cases, and the open-source nature means you can inspect the source code, contribute fixes, and adapt the tool to your specific requirements.
How it saves time or tokens
Writing a good CLAUDE.md by hand requires understanding what Claude Code needs to know and keeping it updated as the project evolves. ClaudeForge automates both: it detects your language, framework, build system, test setup, and directory structure, then generates instructions that reduce Claude Code's guessing and token-wasting exploration.
How to use
- Install ClaudeForge via the install script or download the binary.
- Run
claudeforgein your project root to generate a CLAUDE.md. - Review the generated file and customize it if needed.
Example
# Install ClaudeForge
curl -fsSL https://raw.githubusercontent.com/alirezarezvani/ClaudeForge/main/install.sh | bash
# Generate CLAUDE.md for your project
cd /path/to/your/project
claudeforge
# Score an existing CLAUDE.md
claudeforge score
# Regenerate with a specific focus
claudeforge --focus backend
Related on TokRepo
- AI Tools for Coding -- Developer tools for AI-assisted coding
- AI Tools for Documentation -- Documentation generation tools
Common pitfalls
- ClaudeForge generates a starting point, not a finished product. Review the output and add project-specific rules (e.g., forbidden patterns, deployment procedures) that static analysis cannot detect.
- Running ClaudeForge on a monorepo produces a generic top-level CLAUDE.md. For monorepos, run it in each package directory to generate targeted context files.
- The generated CLAUDE.md may include stale information if your project structure changed since the last run. Re-run ClaudeForge periodically or after major refactors.
Before adopting this tool, evaluate whether it fits your team's existing workflow. Read the official documentation thoroughly, and start with a small proof-of-concept rather than a full migration. Community forums, GitHub issues, and Stack Overflow are valuable resources when you encounter edge cases not covered in the documentation.
Frequently Asked Questions
ClaudeForge analyzes the project language, framework, package manager, build system, test framework, directory structure, and existing documentation. It uses this information to generate a CLAUDE.md with relevant instructions and constraints.
ClaudeForge supports projects in Python, JavaScript/TypeScript, Go, Rust, Java, and other common languages. It detects the language from file extensions, package files, and build configuration.
A CLAUDE.md file provides instructions and context for Claude Code. It tells Claude about your project structure, coding conventions, deployment procedures, and constraints. Claude Code reads this file automatically when working in your project.
Yes. The claudeforge score command evaluates your existing CLAUDE.md against best practices for completeness, accuracy, and specificity. It suggests improvements to make Claude Code more effective.
Yes. ClaudeForge is open source under the MIT license. The source code and documentation are available on GitHub.
Citations (3)
- ClaudeForge GitHub— ClaudeForge generates CLAUDE.md files automatically
- Anthropic Claude Code Documentation— CLAUDE.md provides project context for Claude Code
- ClaudeForge README— Codebase scanning and documentation scoring
Related on TokRepo
Source & Thanks
Created by Alireza Rezvani. Licensed under MIT.
ClaudeForge — ⭐ 340+
Thanks to Alireza for building a tool that makes Claude Code adoption significantly easier.
Discussion
Related Assets
NAPI-RS — Build Node.js Native Addons in Rust
Write high-performance Node.js native modules in Rust with automatic TypeScript type generation and cross-platform prebuilt binaries.
Mamba — Fast Cross-Platform Package Manager
A drop-in conda replacement written in C++ that resolves environments in seconds instead of minutes.
Plasmo — The Browser Extension Framework
Build, test, and publish browser extensions for Chrome, Firefox, and Edge using React or Vue with hot-reload and automatic manifest generation.