project-analyze

Multi-phase iterative project analysis with Mermaid diagrams. Generates architecture reports, design reports, method analysis reports. Use when analyzing codebases, understanding project structure, reviewing architecture, exploring design patterns, or documenting system components. Triggers on "analyze project", "architecture report", "design analysis", "code structure", "system overview".

allowed_tools: Task, AskUserQuestion, Read, Bash, Glob, Grep, Write

$ Installieren

git clone https://github.com/catlog22/Claude-Code-Workflow /tmp/Claude-Code-Workflow && cp -r /tmp/Claude-Code-Workflow/.claude/skills/project-analyze ~/.claude/skills/Claude-Code-Workflow

// tip: Run this command in your terminal to install the skill


name: project-analyze description: Multi-phase iterative project analysis with Mermaid diagrams. Generates architecture reports, design reports, method analysis reports. Use when analyzing codebases, understanding project structure, reviewing architecture, exploring design patterns, or documenting system components. Triggers on "analyze project", "architecture report", "design analysis", "code structure", "system overview". allowed-tools: Task, AskUserQuestion, Read, Bash, Glob, Grep, Write

Project Analysis Skill

Generate comprehensive project analysis reports through multi-phase iterative workflow.

Architecture Overview

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  Context-Optimized Architecture                                  โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚                                                                  โ”‚
โ”‚  Phase 1: Requirements      โ†’ analysis-config.json              โ”‚
โ”‚           โ†“                                                      โ”‚
โ”‚  Phase 2: Exploration       โ†’ ๅˆๆญฅๆŽข็ดข๏ผŒ็กฎๅฎš่Œƒๅ›ด                  โ”‚
โ”‚           โ†“                                                      โ”‚
โ”‚  Phase 3: Parallel Agents   โ†’ sections/section-*.md (็›ดๆŽฅๅ†™MD)   โ”‚
โ”‚               โ†“ ่ฟ”ๅ›ž็ฎ€่ฆJSON                                     โ”‚
โ”‚  Phase 3.5: Consolidation   โ†’ consolidation-summary.md          โ”‚
โ”‚           Agent                 โ†“ ่ฟ”ๅ›ž่ดจ้‡่ฏ„ๅˆ†+้—ฎ้ข˜ๅˆ—่กจ          โ”‚
โ”‚           โ†“                                                      โ”‚
โ”‚  Phase 4: Assembly          โ†’ ๅˆๅนถMD + ่ดจ้‡้™„ๅฝ•                  โ”‚
โ”‚           โ†“                                                      โ”‚
โ”‚  Phase 5: Refinement        โ†’ ๆœ€็ปˆๆŠฅๅ‘Š                           โ”‚
โ”‚                                                                  โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Key Design Principles

  1. Agent ็›ดๆŽฅ่พ“ๅ‡บ MD: ้ฟๅ… JSON โ†’ MD ่ฝฌๆข็š„ไธŠไธ‹ๆ–‡ๅผ€้”€
  2. ็ฎ€่ฆ่ฟ”ๅ›ž: Agent ๅช่ฟ”ๅ›ž่ทฏๅพ„+ๆ‘˜่ฆ๏ผŒไธ่ฟ”ๅ›žๅฎŒๆ•ดๅ†…ๅฎน
  3. ๆฑ‡ๆ€ป Agent: ็‹ฌ็ซ‹ Agent ่ดŸ่ดฃ่ทจ็ซ ่Š‚้—ฎ้ข˜ๆฃ€ๆต‹ๅ’Œ่ดจ้‡่ฏ„ๅˆ†
  4. ๅผ•็”จๅˆๅนถ: Phase 4 ่ฏปๅ–ๆ–‡ไปถๅˆๅนถ๏ผŒไธๅœจไธŠไธ‹ๆ–‡ไธญไผ ้€’
  5. ๆฎต่ฝๅผๆ่ฟฐ: ็ฆๆญขๆธ…ๅ•็ฝ—ๅˆ—๏ผŒๅฑ‚ๅฑ‚้€’่ฟ›๏ผŒๅฎข่ง‚ๅญฆๆœฏ่กจ่พพ

Execution Flow

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚  Phase 1: Requirements Discovery                                โ”‚
โ”‚  โ†’ Read: phases/01-requirements-discovery.md                    โ”‚
โ”‚  โ†’ Collect: report type, depth level, scope, focus areas        โ”‚
โ”‚  โ†’ Output: analysis-config.json                                 โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Phase 2: Project Exploration                                   โ”‚
โ”‚  โ†’ Read: phases/02-project-exploration.md                       โ”‚
โ”‚  โ†’ Launch: parallel exploration agents                          โ”‚
โ”‚  โ†’ Output: exploration context for Phase 3                      โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Phase 3: Deep Analysis (Parallel Agents)                       โ”‚
โ”‚  โ†’ Read: phases/03-deep-analysis.md                             โ”‚
โ”‚  โ†’ Reference: specs/quality-standards.md                        โ”‚
โ”‚  โ†’ Each Agent: ๅˆ†ๆžไปฃ็  โ†’ ็›ดๆŽฅๅ†™ sections/section-*.md          โ”‚
โ”‚  โ†’ Return: {"status", "output_file", "summary", "cross_notes"}  โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Phase 3.5: Consolidation (New!)                                โ”‚
โ”‚  โ†’ Read: phases/03.5-consolidation.md                           โ”‚
โ”‚  โ†’ Input: Agent ่ฟ”ๅ›ž็š„็ฎ€่ฆไฟกๆฏ + cross_module_notes             โ”‚
โ”‚  โ†’ Analyze: ไธ€่‡ดๆ€ง/ๅฎŒๆ•ดๆ€ง/ๅ…ณ่”ๆ€ง/่ดจ้‡ๆฃ€ๆŸฅ                        โ”‚
โ”‚  โ†’ Output: consolidation-summary.md                             โ”‚
โ”‚  โ†’ Return: {"quality_score", "issues", "stats"}                 โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Phase 4: Report Generation                                     โ”‚
โ”‚  โ†’ Read: phases/04-report-generation.md                         โ”‚
โ”‚  โ†’ Check: ๅฆ‚ๆœ‰ errors๏ผŒๆ็คบ็”จๆˆทๅค„็†                              โ”‚
โ”‚  โ†’ Merge: Executive Summary + sections/*.md + ่ดจ้‡้™„ๅฝ•          โ”‚
โ”‚  โ†’ Output: {TYPE}-REPORT.md                                     โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Phase 5: Iterative Refinement                                  โ”‚
โ”‚  โ†’ Read: phases/05-iterative-refinement.md                      โ”‚
โ”‚  โ†’ Reference: specs/quality-standards.md                        โ”‚
โ”‚  โ†’ Loop: ๅ‘็Žฐ้—ฎ้ข˜ โ†’ ๆ้—ฎ โ†’ ไฟฎๅค โ†’ ้‡ๆ–ฐๆฃ€ๆŸฅ                       โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Report Types

TypeOutputAgentsFocus
architectureARCHITECTURE-REPORT.md5System structure, modules, dependencies
designDESIGN-REPORT.md4Patterns, classes, interfaces
methodsMETHODS-REPORT.md4Algorithms, critical paths, APIs
comprehensiveCOMPREHENSIVE-REPORT.mdAllAll above combined

Agent Configuration by Report Type

Architecture Report

AgentOutput FileSection
overviewsection-overview.mdSystem Overview
layerssection-layers.mdLayer Analysis
dependenciessection-dependencies.mdModule Dependencies
dataflowsection-dataflow.mdData Flow
entrypointssection-entrypoints.mdEntry Points

Design Report

AgentOutput FileSection
patternssection-patterns.mdDesign Patterns
classessection-classes.mdClass Relationships
interfacessection-interfaces.mdInterface Contracts
statesection-state.mdState Management

Methods Report

AgentOutput FileSection
algorithmssection-algorithms.mdCore Algorithms
pathssection-paths.mdCritical Code Paths
apissection-apis.mdPublic API Reference
logicsection-logic.mdComplex Logic

Directory Setup

// ็”Ÿๆˆๆ—ถ้—ดๆˆณ็›ฎๅฝ•ๅ
const timestamp = new Date().toISOString().slice(0,19).replace(/[-:T]/g, '');
const dir = `.workflow/.scratchpad/analyze-${timestamp}`;

// Windows (cmd)
Bash(`mkdir "${dir}\\sections"`);
Bash(`mkdir "${dir}\\iterations"`);

// Unix/macOS
// Bash(`mkdir -p "${dir}/sections" "${dir}/iterations"`);

Output Structure

.workflow/.scratchpad/analyze-{timestamp}/
โ”œโ”€โ”€ analysis-config.json          # Phase 1
โ”œโ”€โ”€ sections/                     # Phase 3 (Agent ็›ดๆŽฅๅ†™ๅ…ฅ)
โ”‚   โ”œโ”€โ”€ section-overview.md
โ”‚   โ”œโ”€โ”€ section-layers.md
โ”‚   โ”œโ”€โ”€ section-dependencies.md
โ”‚   โ””โ”€โ”€ ...
โ”œโ”€โ”€ consolidation-summary.md      # Phase 3.5
โ”œโ”€โ”€ {TYPE}-REPORT.md              # Final Output
โ””โ”€โ”€ iterations/                   # Phase 5
    โ”œโ”€โ”€ v1.md
    โ””โ”€โ”€ v2.md

Reference Documents

DocumentPurpose
phases/01-requirements-discovery.mdUser interaction, config collection
phases/02-project-exploration.mdInitial exploration
phases/03-deep-analysis.mdParallel agent analysis
phases/03.5-consolidation.mdCross-section consolidation
phases/04-report-generation.mdReport assembly
phases/05-iterative-refinement.mdQuality refinement
specs/quality-standards.mdQuality gates, standards
specs/writing-style.mdๆฎต่ฝๅผๅญฆๆœฏๅ†™ไฝœ่ง„่Œƒ
../_shared/mermaid-utils.mdShared Mermaid utilities