generate-claude-md

generate-claude-md is a command for Claude Code from Yassinello/claude-plugin-prd-workflow. It costs 21 tokens per session (2,376 once invoked), scanned A, original, MIT.

A command that creates a CLAUDE.md guide by examining a codebase. The guide records project structure, technologies, development commands, coding conventions, and testing practices.

In plain words
What is it for?
Use it to detect the framework, libraries, folders, style tools, databases, test setup, and commands used to develop and check the project.
Why use it?
It saves time spent documenting a project manually and gives Claude Code context about how the codebase works.

Command for Claude Code

Written for Claude Code: installed under .claude/. Also seen: mentions CLAUDE.md; mentions Claude Code.

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is import { Button } from '../Button'.

Good fit Use it to detect the framework, libraries, folders, style tools, databases, test setup, and commands used to develop and check the project.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/Yassinello/claude-plugin-prd-workflow
agentmods
npx agentmods add commands/yassinello/claude-plugin-prd-workflow/generate-claude-md

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for generate-claude-md

README.md
[![agentmods](https://agentmods.dev/badge/commands/yassinello/claude-plugin-prd-workflow/generate-claude-md/github.svg)](https://agentmods.dev/commands/yassinello/claude-plugin-prd-workflow/generate-claude-md)
Your own site
<a href="https://agentmods.dev/commands/yassinello/claude-plugin-prd-workflow/generate-claude-md"><img src="https://agentmods.dev/badge/commands/yassinello/claude-plugin-prd-workflow/generate-claude-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for generate-claude-md

Your own site · 80×15
<a href="https://agentmods.dev/commands/yassinello/claude-plugin-prd-workflow/generate-claude-md"><img src="https://agentmods.dev/badge/commands/yassinello/claude-plugin-prd-workflow/generate-claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 21 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,376 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00021 $0.02376
Opus 5 $0.00010 $0.01188
Sonnet 5 $0.00004 $0.00475
Haiku 4.5 $0.00002 $0.00238

Measured 9d ago against content hash 6afcad176999, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

generate-claude-md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/generate-claude-md.md · 370 lines

How it starts

The opening of the file, as written. The whole thing — 370 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Generate CLAUDE.md Command

Auto-generate a comprehensive CLAUDE.md file that helps Claude Code understand your project.

Purpose

Create a well-structured CLAUDE.md file by automatically detecting:

  • Tech stack and framework
  • Project structure and patterns
  • Development commands
  • Code style conventions
  • Testing approach

Workflow

Step 1: Analyze Codebase

Detect Tech Stack:

# Check for framework indicators
- package.json → Node.js project
  - "next": "14.x" → Next.js 14
  - "react": "18.x" → React 18
  - "@types/node" → TypeScript

- requirements.txt → Python project
  - "fastapi" → FastAPI
  - "django" → Django

- Gemfile → Ruby project
  - "rails" → Ruby on Rails

- go.mod → Go project

Detect Patterns:

  • Directory structure (src/, app/, components/, etc.)
  • Testing framework (vitest, jest, pytest, etc.)
  • Styling (Tailwind, CSS Modules, styled-components)
  • State management (Zustand, Redux, Jotai)
  • ORM/Database (Prisma, TypeORM, SQLAlchemy)

Step 2: Extract Development Commands

# From package.json "scripts"
npm run dev → Development server
npm run build → Production build
npm run test → Run tests
npm run lint → Linting

# From Makefile
make dev
make test

# From Justfile
just dev
just build

Step 3: Generate Structured CLAUDE.md

Template Sections:

  1. Project Overview

    • One-line description
    • Tech stack summary
  2. Tech Stack

    • Framework + version
    • Language + version
    • Key dependencies
  3. Architecture & Patterns

    • Architectural pattern (MVC, Clean Architecture, etc.)
    • Data flow patterns
    • Component structure
  4. Directory Structure

    • Key directories explained
    • File organization conventions
  5. Development Commands

    • Common commands with descriptions
    • Test commands
    • Build commands
  6. Code Style & Conventions

    • Component patterns
    • Naming conventions
    • Import order
    • Formatting rules
  7. Testing Approach

    • Test framework
    • Coverage requirements
    • Test file location conventions

Read the full file on GitHub · 370 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 370 lines · 21 tokens per session scan A 6afcad176999

Subscribe to this mod's changes

generate-claude-md is a command published in the GitHub repository Yassinello/claude-plugin-prd-workflow (12 stars, last pushed 9mo ago), licensed MIT. It adds 21 tokens to every session and 2,376 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.