Alirezarezvani claude md enhancer

From Horonomos-laps/Yana-AI · View interactive version

Alirezarezvani claude md enhancer is an AI agent skill from the GitHub repository Horonomos-laps/Yana-AI. Analyzes, generates, and enhances CLAUDE.md files for any project type using best practices, modular architecture support, and tech stack customization. Use when setting up new projects, improving existing CLAUDE.md files, or establishing AI-assisted development standards.

How to use this skill

Skill file

CLAUDE.md File Enhancer

This skill provides comprehensive CLAUDE.md file generation and enhancement for Claude Code projects. It analyzes existing files, validates against best practices, and generates customized guidelines tailored to your project type, tech stack, and team size.

Capabilities

Input Requirements

For Analysis and Enhancement

Provide existing CLAUDE.md file content or file path:

{
  "mode": "enhance",
  "file_path": "CLAUDE.md",
  "content": "[existing CLAUDE.md content]",
  "project_context": {
    "type": "web_app",
    "tech_stack": ["typescript", "react", "node", "postgresql"],
    "team_size": "small",
    "phase": "mvp"
  }
}

For New File Generation

Provide project context:

{
  "mode": "create",
  "project_context": {
    "type": "api",
    "tech_stack": ["python", "fastapi", "postgresql", "docker"],
    "team_size": "medium",
    "phase": "production",
    "workflows": ["tdd", "cicd", "documentation_first"]
  },
  "modular": true,
  "subdirectories": ["backend", "database", "docs"]
}

Context Parameters

Output Formats

Analysis Report

{
  "analysis": {
    "file_size": 450,
    "line_count": 320,
    "sections_found": [
      "Quick Navigation",
      "Core Principles",
      "Tech Stack",
      "Workflow Instructions"
    ],
    "missing_sections": [
      "Testing Requirements",
      "Error Handling Patterns"
    ],
    "issues": [
      {
        "type": "length_warning",
        "severity": "medium",
        "message": "File exceeds recommended 300 lines (320 lines)"
      },
      {
        "type": "missing_section",
        "severity": "low",
        "message": "Consider adding 'Testing Requirements' section"
      }
    ],
    "quality_score": 75,
    "recommendations": [
      "Split into modular files (backend/CLAUDE.md, frontend/CLAUDE.md)",
      "Add testing requirements section",
      "Reduce root file to <150 lines"
    ]
  }
}

Generated Content

Complete CLAUDE.md file content or specific sections to add:

# CLAUDE.md

This file provides guidance for Claude Code when working with this project.

## Quick Navigation

- [Backend Guidelines](backend/CLAUDE.md)
- [Frontend Guidelines](frontend/CLAUDE.md)
- [Database Operations](database/CLAUDE.md)
- [CI/CD Workflows](.github/CLAUDE.md)

## Core Principles

1. **Test-Driven Development**: Write tests before implementation
2. **Type Safety First**: Use TypeScript strict mode throughout
3. **Component Composition**: Favor small, reusable components
4. **Error Handling**: Always handle errors with proper logging
5. **Documentation Updates**: Keep docs in sync with code changes

[... additional sections based on template ...]

How to Use

Example 1: Initialize CLAUDE.md for New Project (Interactive)

Hey Claudeβ€”I just added the "claude-md-enhancer" skill. I don't have a CLAUDE.md file yet. Can you help me create one for this project?

What Happens:

  1. Claude checks if CLAUDE.md exists (it doesn't)
  2. Claude explores your repository using built-in commands
  3. Claude analyzes: project type, tech stack, team size, workflows
  4. Claude shows discoveries and asks for confirmation
  5. You confirm the settings
  6. Claude creates customized CLAUDE.md file(s)
  7. Claude enhances with best practices

Interactive Flow:

Example 2: Analyze Existing CLAUDE.md

Hey Claudeβ€”I just added the "claude-md-enhancer" skill. Can you analyze my current CLAUDE.md file and tell me what's missing or could be improved?

Example 2: Generate New CLAUDE.md for TypeScript Project

Hey Claudeβ€”I just added the "claude-md-enhancer" skill. Can you create a CLAUDE.md file for my TypeScript React project with a team of 5 developers? We use PostgreSQL, Docker, and follow TDD practices.

Example 3: Enhance Existing File

Hey Claudeβ€”I just added the "claude-md-enhancer" skill. Can you enhance my existing CLAUDE.md by adding missing sections and improving the structure? Here's my current file: [paste content]

Example 4: Generate Modular Architecture

Hey Claudeβ€”I just added the "claude-md-enhancer" skill. Can you create a modular CLAUDE.md setup for my full-stack project? I need separate files for backend (Python/FastAPI), frontend (React), and database (PostgreSQL).

Initialization Workflow (New Projects)

When CLAUDE.md doesn't exist in your project, this skill provides an intelligent initialization workflow:

Workflow Steps

Step 1: Detection

Step 2: Repository Exploration

Step 3: Intelligent Analysis

Step 4: User Confirmation βœ‹

Step 5: File Creation

Step 6: Enhancement

Step 7: Summary

Interactive Example

User: "I need a CLAUDE.md for this project"

Claude: "I'll explore your repository first to understand the project.
        [Explores using built-in commands]

        Based on my exploration, here's what I discovered:

        Project Type: Full-Stack Application
        Tech Stack: TypeScript, React, Node.js, PostgreSQL, Docker
        Team Size: Small (2-9 developers)
        Development Phase: MVP
        Workflows: TDD, CI/CD

        Recommended Structure: Modular architecture
        - Root CLAUDE.md (navigation hub)
        - backend/CLAUDE.md (API guidelines)
        - frontend/CLAUDE.md (React guidelines)

        Would you like me to create these files?"

User: "Yes, please proceed"

Claude: "Creating customized CLAUDE.md files...
        βœ… Created CLAUDE.md (100 lines)
        βœ… Created backend/CLAUDE.md (150 lines)
        βœ… Created frontend/CLAUDE.md (175 lines)

        Your project is ready for AI-assisted development!"

Scripts

workflow.py

Manages the interactive initialization workflow for new projects.

Key Functions:

analyzer.py

Analyzes existing CLAUDE.md files to identify structure, sections, and quality issues.

Key Functions:

validator.py

Validates CLAUDE.md files against best practices and Anthropic guidelines.

Key Functions:

generator.py

Generates new CLAUDE.md content or missing sections based on templates.

Key Functions:

template_selector.py

Selects appropriate template based on project context.

Key Functions:

Best Practices

Critical Validation Rule ⚠️

"Always validate your output against official native examples before declaring complete."

Before finalizing any CLAUDE.md generation:

  1. Compare output against /update-claude-md slash command format
  2. Check official Claude Code documentation for required sections
  3. Verify all native format sections are present (Overview, Project Structure, File Structure, Setup & Installation, Architecture, etc.)
  4. Cross-check against reference examples in examples/ folder

For New Projects

  1. Start with minimal template (50-100 lines) and grow as needed
  2. Use modular architecture for projects with >3 major components
  3. Include tech stack reference immediately
  4. Add workflow instructions before team grows beyond 5 people

For Enhancement

  1. Analyze before modifying - understand current structure first
  2. Preserve custom content - only enhance, don't replace
  3. Validate after changes - ensure improvements don't break existing patterns
  4. Test with Claude Code - verify guidelines work as intended

General Guidelines

  1. Keep root file concise - Max 150 lines, use as navigation hub
  2. Use context-specific files - backend/CLAUDE.md, frontend/CLAUDE.md, etc.
  3. Avoid duplication - Each guideline should appear once
  4. Link to external docs - Don't copy official documentation
  5. Update regularly - Review guidelines quarterly or when stack changes

Limitations

Technical Constraints

Scope Boundaries

When NOT to Use

Template Categories

By Size

By Project Type

By Tech Stack

Quality Metrics

File Quality Score (0-100)

Calculated based on:

Recommendations Priority

Advanced Features

Modular Architecture Support

Automatically generates context-specific files:

project-root/
β”œβ”€β”€ CLAUDE.md                 # Root orchestrator (100-150 lines)
β”œβ”€β”€ backend/
β”‚   └── CLAUDE.md            # Backend-specific (150-200 lines)
β”œβ”€β”€ frontend/
β”‚   └── CLAUDE.md            # Frontend-specific (150-200 lines)
β”œβ”€β”€ database/
β”‚   └── CLAUDE.md            # Database operations (100-150 lines)
└── .github/
    └── CLAUDE.md            # CI/CD workflows (100-150 lines)

Tech Stack Detection

Automatically detects technologies from:

Team Size Adaptation

Adjusts detail level:

References

Version

Version: 1.0.0

Last Updated: November 2025

Compatible: Claude Code 2.0+, Claude Apps, Claude API

Remember: The goal is to make Claude more efficient and context-aware, not to create bureaucracy. Start simple, iterate based on real usage, and automate quality checks where possible.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.