c4-reverse-engineer

Generate C4 context, container, and component diagrams from a codebase.

Updated Apr 19, 2026
One-click install
npx skills add https://github.com/jewzaam/jewzaam-reviews --skill c4-reverse-engineer
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: c4-reverse-engineer
Source: https://github.com/jewzaam/jewzaam-reviews/tree/main/skills/c4-reverse-engineer
Command: npx skills add https://github.com/jewzaam/jewzaam-reviews --skill c4-reverse-engineer

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires jsonschema, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Reverse-engineer C4 architecture diagrams (Context, Container, Component) and a behavioral specification from a codebase. Produces documentation of WHAT the system does — not how it's coded.

Core Features & Use Cases

  • Generate C4 context, container, and component diagrams directly from an existing codebase with no source changes.
  • Produce a behavioral specification that describes system behavior for documentation and onboarding.
  • Validate findings against a structured workflow (pre-fetch, phases, and markdown deliverables) to ensure consistency between code and diagrams.

Quick Start

Provide the codebase path and request a full C4 reverse-engineering report.

Frequently Asked Questions about c4-reverse-engineer

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

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

C4 architecture diagrams are generated by inferring context, container, and component structures directly from the codebase. This produces behavioral specifications and visual documentation without requiring any source code modifications.

What is reverse-engineering code into C4 context and component diagrams?

Reverse-engineering code into C4 diagrams is the process of analyzing a codebase to extract its system architecture. It identifies system behavior and maps it into Context, Container, and Component views for onboarding and documentation.

Can I create architecture documentation for onboarding without modifying my source code?

Yes, you can create architecture documentation without modifying source code by inferring the architecture from the existing codebase. This generates behavioral specifications and C4 diagrams describing what the system does rather than how it is coded.

How to validate that inferred architecture diagrams align with the actual code evidence?

To validate inferred architecture diagrams against code evidence, use a deterministic, phase-based workflow with pre-fetch and validation templates. This enforces consistency between the generated C4 diagrams and the actual source code structure.

Does C4 reverse-engineering work for codebases of varying sizes?

Yes, C4 reverse-engineering is applicable to codebases of varying sizes. It enforces a structured workflow using subagents to process the codebase, ensuring accurate context, container, and component diagrams regardless of scale.