Skip to content

strobelpierre/init-agent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🧬 init-agent

Stop writing bad CLAUDE.md files.

A Claude Code skill that analyzes your codebase and generates production-grade CLAUDE.md configurations β€” with verified commands, real architecture, and safety guardrails your team actually needs.

License: MIT Claude Code Skill GitHub stars


The Problem

Most CLAUDE.md files are garbage.

They're either hallucinated β€” listing build commands that don't exist. Generic β€” "write clean code" and "follow best practices" could apply to literally any repo. Or copy-pasted from a template that knows nothing about your project's actual architecture, test setup, or danger zones.

The result? Your AI coding assistant runs commands that fail, misunderstands your codebase, and has zero awareness of the operations that could take down production.

Your team deserves safer guardrails.


What init-agent Does Differently

  • Verified commands only. Every build, test, and lint command is confirmed against your actual package.json, Makefile, Cargo.toml, or equivalent. If it can't find it, it doesn't include it.
  • Project-specific, not generic. Every line in the generated CLAUDE.md is specific to your codebase. No filler. No boilerplate wisdom.
  • Adaptive depth. A simple CLI tool gets a concise config. A monorepo with database migrations, multiple services, and deployment pipelines gets comprehensive coverage. Complexity matches complexity.
  • Safety-first generation. Destructive operations β€” migrations, force pushes, secret management, deployment scripts β€” get explicit guardrails automatically.

Before & After

❌ Typical CLAUDE.md βœ… init-agent Output
# CLAUDE.md

## Overview
This is a TypeScript monorepo.

## Development
- Follow best practices
- Write clean, readable code
- Use TypeScript for type safety
- Run tests before committing
# CLAUDE.md

## Build & Test
- `pnpm install` β€” install all workspace deps
- `pnpm -F @app/api build` β€” build API service
- `pnpm -F @app/api test` β€” run API tests (vitest)
- `pnpm lint` β€” ESLint across all packages

## Architecture
- Monorepo: apps/api (Express + Prisma),
  apps/web (Next.js), packages/shared
- API routes defined in apps/api/src/routes/,
  each file = one resource
- Shared types in packages/shared/src/types.ts
  are the contract between API and web

## Safety
- NEVER run `prisma migrate reset` β€” drops
  production data if connected to prod
- NEVER push directly to main β€” deploy pipeline
  auto-triggers on merge
- Database migrations require review: generate
  with `prisma migrate dev`, never `--force`

Quick Start

One-liner install

mkdir -p .claude/skills/init-agent && curl -sL https://raw.githubusercontent.com/strobelpierre/init-agent/main/.claude/skills/init-agent/SKILL.md -o .claude/skills/init-agent/SKILL.md

Manual install

git clone https://github.com/strobelpierre/init-agent.git
cp -r init-agent/.claude/skills/init-agent .claude/skills/

Then run it

Open Claude Code in your project and type:

/init-agent

That's it. The skill walks you through a structured process to generate or improve your CLAUDE.md.


Features

  • πŸ” Smart detection β€” Automatically detects whether a CLAUDE.md exists and adapts its approach
  • 🎯 Adaptive interview β€” Asks questions one by one, scaling depth to your project's complexity
  • βœ… Command verification β€” Every command is confirmed against actual config files before inclusion
  • πŸ›‘οΈ Safety guardrails β€” Destructive operations get explicit constraints automatically
  • βš–οΈ Proportional output β€” Simple projects get concise configs; complex ones get comprehensive coverage
  • πŸ”„ Evolution, not replacement β€” Existing good rules are preserved and enhanced, never blindly overwritten
  • 🧠 Thinking protocol β€” Built-in reasoning sequence: verify β†’ assess risk β†’ decompose

How It Works

detect β†’ interview β†’ analyze β†’ strategize β†’ generate
Step What happens
Detect Checks if a CLAUDE.md already exists and evaluates its quality
Interview Asks targeted questions, one at a time, adapting to project complexity
Analyze Identifies strengths, weaknesses, risk zones, and criticality level
Strategize Plans targeted improvements (existing file) or full design (new file)
Generate Produces a verified, project-specific CLAUDE.md with safety constraints

Why This Matters

For teams: A bad CLAUDE.md is worse than no CLAUDE.md. When your AI assistant confidently runs a hallucinated npm run deploy or misses a critical safety constraint around database migrations, the cost isn't just a failed command β€” it's a production incident waiting to happen. init-agent eliminates that risk by verifying every command and surfacing every danger zone.

For production: Generic advice like "follow best practices" gives your AI agent zero useful information. What it needs is the specific architecture of your codebase, the actual commands that work in your build system, and the exact operations that are dangerous in your infrastructure. init-agent reads your project and delivers exactly that.

For the ecosystem: CLAUDE.md is becoming infrastructure. As more teams adopt agentic coding workflows with Claude Code, the quality of these configuration files directly impacts code quality, safety, and velocity. init-agent raises the floor for everyone.


Works With Any Project

Project types: Monorepos, REST/GraphQL APIs, frontends (React, Vue, Svelte), full-stack apps, CLI tools, libraries, infrastructure-as-code, microservices.

Languages & ecosystems: TypeScript/JavaScript, Python, Rust, Go, Java, Ruby, C#, and more. If it has a build system, init-agent can analyze it.

Build tools: npm, pnpm, yarn, pip, poetry, cargo, make, gradle, maven, turborepo, nx β€” whatever your project uses.


⭐ Like it? Star it.

If init-agent saved you from a bad CLAUDE.md, give it a star. It helps others find it.


Contributing

Contributions are welcome. If you've found an edge case, a project type that isn't handled well, or a way to make the generated configs better β€” open an issue or submit a PR.

License

MIT β€” Pierre Strobel, 2026

About

🧬 Stop writing bad CLAUDE.md files. A Claude Code skill that generates production-grade CLAUDE.md configurations with verified commands, real architecture, and safety guardrails.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors