c4

Generate Mermaid-based C4 Context and Container diagrams from a project codebase.

Updated Apr 15, 2026
One-click install
npx skills add https://github.com/AAbdulghany/fms --skill c4-aabdulghany
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: c4
Source: https://github.com/AAbdulghany/fms/tree/main/.claude/skills/c4
Command: npx skills add https://github.com/AAbdulghany/fms --skill c4-aabdulghany

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Generates up-to-date C4 architecture diagrams (Context and Container) directly from a project's codebase, removing manual diagram labor.

Core Features & Use Cases

  • Reads a repository to produce Mermaid-based C4 Context (L1) and C4 Container (L2) diagrams.
  • Writes diagrams to the project's documentation locations or framework-wide paths, honoring portfolio templates when present.
  • Supports onboarding and architecture refresh workflows by regenerating diagrams after structural changes.

Quick Start

Invoke the skill on a project to generate its C4 context and container diagrams in Mermaid format.

Frequently Asked Questions about c4

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate C4 architecture diagrams from a codebase?

To generate C4 architecture diagrams from a codebase, you can use a skill that parses the repository structure and produces Mermaid-based C4 Context and Container diagrams. It writes the generated files directly to the project's documentation locations.

Can I create Mermaid C4 Context and Container diagrams automatically?

Yes, you can create Mermaid C4 Context and Container diagrams automatically by invoking the skill on a project. It reads the repository to produce L1 and L2 diagrams, removing manual diagram labor.

Does this skill work for multi-repo or single-repo projects?

This skill works for both multi-repo and single-repo projects where architecture diagrams are needed on demand. It resolves target output paths via portfolio helpers and writes files to the appropriate framework locations.

When should I regenerate C4 architecture diagrams?

You should regenerate C4 architecture diagrams during onboarding, architecture reviews, or documentation refresh workflows after structural changes. This ensures the C4 Context and Container diagrams remain up-to-date with the current codebase.

What is the best way to document software architecture without manual diagramming?

The best way to document software architecture without manual diagramming is to generate diagrams directly from the codebase. This approach produces Mermaid-based C4 diagrams and honors portfolio templates when present.

Do I need portfolio templates to generate C4 diagrams?

You do not need portfolio templates to generate C4 diagrams, but the skill honors them when they are present. It writes diagrams to the project's documentation locations or framework-wide paths based on the available templates.