Generates C4 architecture diagrams using Mermaid syntax, covering all four levels plus dynamic flow diagrams. The workflow is straightforward: it analyzes your codebase, creates diagrams at the right abstraction level, and outputs markdown files with context. The guidance here is solid, especially the emphasis on stopping at container diagrams for most teams since component and deployment diagrams often add more noise than value. Includes practical syntax examples for people, systems, containers, components, boundaries, and relationships. The styling options help when labels overlap, which happens more often than you'd think. Good for documenting existing systems or designing new ones when stakeholders need visual artifacts.

skills.sh installs
430
GitHub stars
33.2K
last updated
Aug 21, 2026

Install

$ npx -y skills add davila7/claude-code-templates --skill c4-architecture --agent claude-code

Installs into .claude/skills of the current project.

Files

C4 Architecture Documentation

Generate software architecture documentation using C4 model diagrams in Mermaid syntax.

Workflow

  1. Understand scope - Determine which C4 level(s) are needed based on audience
  2. Analyze codebase - Explore the system to identify components, containers, and relationships
  3. Generate diagrams - Create Mermaid C4 diagrams at appropriate abstraction levels
  4. Document - Write diagrams to markdown files with explanatory context

C4 Diagram Levels

Select the appropriate level based on the documentation need:

LevelDiagram TypeAudienceShowsWhen to Create
1C4ContextEveryoneSystem + external actorsAlways (required)
2C4ContainerTechnicalApps, databases, servicesAlways (required)
3C4ComponentDevelopersInternal componentsOnly if adds value
4C4DeploymentDevOpsInfrastructure nodesFor production systems
-C4DynamicTechnicalRequest flows (numbered)For complex workflows

Sponsors

Details

Repository
github.com/davila7/claude-code-templates
Categories
Frontend Development, Documentation, Code Review & Quality
First seen
Jun 3, 2026

More from davila7/claude-code-templates

All 618
1rstackjs avatarmigrate-to-rstestrstackjs/agent-skillsMigrate Jest or Vitest projects to Rstest. Use when asked to move from Jest/Vitest to Rstest, replace `jest`/`vi` APIs with `@rstest/core`, translate config int427skills.sh installs
2brightdata avatardata-feedsbrightdata/skillsExtract structured data from 40+ supported platforms (Amazon, LinkedIn, Instagram, TikTok, Facebook, YouTube, Reddit, and more) via the Bright Data CLI (`bdata 425skills.sh installs
3thvroyal avatarkimi-pdfthvroyal/kimi-skillsProfessional PDF solution. Create PDFs using HTML+Paged.js (academic papers, reports, documents). Process existing PDFs using Python (read, extract, merge, spli423skills.sh installs
4wedsamuel1230 avatararduino-project-builderwedsamuel1230/arduino-skillsBuild complete, production-ready Arduino projects (environmental monitors, robot controllers, IoT devices, automation systems). Assembles multi-component system421skills.sh installs
5onewave-ai avatarlinkedin-post-optimizeronewave-ai/claude-skillsProfessional narrative style with line breaks, hashtag strategy, and hooks in first 2 lines to avoid truncation420skills.sh installs
6tencentcloudbase avatarcloudbase-agent-tstencentcloudbase/skillsBuild and deploy AI agents with Cloudbase Agent (TypeScript), a TypeScript SDK implementing the AG-UI protocol. Use when: (1) deploying agent servers with @clou420skills.sh installs