Skip to content
c3-container-design logo

C3 Container Level Exploration

c3-container-design

Use when changes affect component organization, technology stack, or cross-container communication - triggered by new components, pattern changes, or needing to map external interfaces to internal components

SKILL.md

Full skill instructions

C3 Container Level Exploration

⛔ CRITICAL GATE: Load Parent Context + Current Container First

STOP - Before ANY container-level work, execute:

# Load parent Context (REQUIRED - containers inherit from here)
cat .c3/​README.md 2>/​dev/​null || echo "NO_CONTEXT"

# Load current container (if exists)
cat .c3/​c3-{N}-*/​README.md 2>/​dev/​null || echo "NO_CONTAINER_DOC"

# Load settings
cat .c3/​settings.yaml 2>/​dev/​null || echo "NO_SETTINGS"

Based on output:

  • If "NO_CONTEXT" → STOP. Context must exist first. Escalate to c3-context-design.
  • If container doc exists → Read it completely before proposing changes
  • Extract from Context: boundary, protocols, actors, cross-cutting concerns for this container

⚠️ DO NOT read ADRs unless user specifically asks:

  • Container work focuses on current structure, not historical decisions
  • ADRs add unnecessary context → hallucination risk
  • Only read: Context, this Container, sibling Containers (if coordination needed)

Why this gate exists: Containers INHERIT from Context. Proposing changes without understanding inherited constraints causes conflicts.

Self-check before proceeding:

  • I executed the commands above
  • I read parent Context doc
  • I know what constraints this container inherits
  • I read existing container doc (if exists)

Overview

The Container level is the architectural command center of C3:

  • Full context awareness from above (inherits from Context)
  • Complete control over component responsibilities below
  • Mediator for all interactions

Position: MIDDLE (c3-{N}) | Parent: Context (c3-0) | Children: Components (c3-{N}NN)

📁 File Location: Container is .c3/​c3-{N}-{slug}/​README.md - a folder with README inside.

Announce: "I'm using the c3-container-design skill to explore Container-level impact."


The Principle

Upper layer defines WHAT. Lower layer implements HOW.

At Container level:

  • Context defines WHAT I am (my existence, my responsibility)
  • I define WHAT components exist and WHAT they do
  • Component implements my definitions (HOW it works)
  • I do NOT define how components work internally - that's Component's job

Integrity rules:

  • I must be listed in Context before I can exist
  • Components cannot exist without being listed in my inventory

Container Archetypes

ArchetypeRelationshipTypical Components
ServiceCreates/​processesHandlers, Services, Adapters
DataStores/​structuresSchema, Indexes, Migrations
BoundaryInterface to externalContract, Client, Fallback
PlatformOperates on containersCI/​CD, Deployment, Networking

Include/​Exclude

Include (Container Level)Exclude (Push Up/​Down)
Component responsibilitiesWHY container exists (Context)
Component relationshipsHOW components work internally (Component)
Data flows between componentsCode references
Business flowsFile paths
Inner patterns

Litmus test: "Is this about WHAT components do and HOW they relate to each other?"


Exploration Process

Phase 1: Verify Inheritance

From loaded Context, extract for this container:

  • Boundary: What can/​cannot access
  • Protocols: What we implement (provider/​consumer)
  • Actors: Who we serve
  • Cross-cutting: Patterns we must follow (auth, logging, errors)

Phase 2: Analyze Change Impact

DirectionAction
UpstreamNew protocol/​boundary violation → Escalate to c3-context-design
IsolatedStack/​pattern/​API/​org change → Document here
AdjacentComponent-to-component impact → Coordinate
DownstreamNew/​changed components → Delegate to c3-component-design

Phase 3: Socratic Discovery

By archetype:

  • Service: Responsibility? Key components? Critical flows?
  • Data: Engine/​version? Schema? Access patterns?
  • Boundary: Contract? Client? Fallback?
  • Platform: Processes? Affected containers?

Template

See container-template.md for complete structure with frontmatter, diagrams, and examples.

Required sections:

  1. Inherited From Context
  2. Overview
  3. Technology Stack
  4. Architecture - External Relationships (diagram + interface mapping table)
  5. Architecture - Internal Structure (diagram with Foundation/​Business layering)
  6. Component Layering Rules
  7. Components table
  8. Key Flows

Diagram Requirements

Container level REQUIRES two diagrams:

  1. External Relationships - Shows connections to other containers/​external systems
  2. Internal Structure - Shows how components relate to each other

Use Mermaid only - no ASCII art.


⛔ Enforcement Harnesses

Harness 1: Template Fidelity

Rule: Output MUST match template structure exactly.

Required sections (in order):

  1. Frontmatter (id, c3-version, title, type, parent, summary)
  2. Inherited From Context
  3. Overview
  4. Technology Stack
  5. Architecture - External Relationships (diagram REQUIRED)
  6. Architecture - Internal Structure (diagram REQUIRED)
  7. Components
  8. Key Flows

🚩 Red Flags:

  • Sections missing or reordered
  • Only one diagram (need BOTH)
  • Missing "Inherited From Context" section

Harness 2: Two Diagrams Required

Rule: Container docs MUST have both External and Internal diagrams.

# Verify both diagrams exist
grep -c '```mermaid' .c3/​c3-{N}-*/​README.md  # Should be >= 2

Verification Checklist

Before claiming completion, execute:

# Verify container doc exists in correct location
ls .c3/​c3-*-*/​README.md

# Verify frontmatter
grep -E "^id:|^type:|^parent:" .c3/​c3-{N}-*/​README.md

# Verify BOTH mermaid diagrams exist
mermaid_count=$(grep -c '```mermaid' .c3/​c3-{N}-*/​README.md)
echo "Mermaid diagrams: $mermaid_count (need >= 2)"
  • Critical gate executed (Context + current container loaded)
  • Container is listed in Context's container inventory
  • "Inherited From Context" section populated from parent
  • Template sections present in correct order
  • BOTH diagrams included (External + Internal)
  • Components listed with responsibilities
  • Downstream delegation identified (c3-component-design)

📚 Reading Chain Output

At the end of container work, output a reading chain for components and related containers.

Format:

## 📚 To Go Deeper

This container (c3-N) contains:

**Components to explore:**
├─ c3-N01-{slug} - [responsibility, why it matters]
├─ c3-N02-{slug} - [responsibility, why it matters]
└─ ...

**Parent (inherited constraints):**
└─ c3-0 (Context) - [what this container inherits]

**Sibling containers (if coordination needed):**
└─ c3-M-{slug} - [why coordination matters]

*Reading chain generated from components listed in this Container.*

Rules:

  • List components from the Container's inventory
  • Highlight which components are affected by this change
  • Include parent Context for constraint reference
  • Never include ADRs unless user asked

Change Impact Decision

flowchart TD
    A[Analyze Change] --> B{New protocol or<br/>boundary violation?}
    B -->|yes| C[Escalate to<br/>c3-context-design]
    B -->|no| D{Component org<br/>change?}
    D -->|yes| E[Delegate to<br/>c3-component-design]
    D -->|no| F[Document at<br/>Container level]

Common Rationalizations

ExcuseReality
"One diagram is enough"External + Internal are BOTH required. Different purposes.
"I'll add diagrams later"Diagrams drive understanding. Add during exploration, not after.
"Template too rigid"Template is minimum. Add sections if needed, but don't skip required ones.
"This container is simple"Simple containers still need both diagrams. Just smaller diagrams.
"Inherited section is obvious"Make inheritance explicit. What's obvious to you isn't to readers.
"Layering doesn't apply here"All containers have Foundation → Business layering. Show it.

Common Mistakes

MistakeFix
Missing External Relationships diagramREQUIRED. Maps Context interfaces to owning components.
Missing Internal Structure diagramREQUIRED. Shows Foundation → Business layering.
Not mapping interfaces to componentsAdd table: External Interface | Owning Component | Protocol
Duplicating Context contentReference Context, don't repeat. Show component ownership.
Skipping layering rulesAlways include Foundation/​Business rules table.

Related

  • references/​core-principle.md - The C3 principle
  • defaults.md - Container layer rules
  • references/​container-archetypes.md - Container types
  • references/​diagram-decision-framework.md - When to use which diagram

More skills from majiayu000

xiaohongshu logo
majiayu000/claude-arsenal

xiaohongshu

xiaohongshu

286 148
View
agent-task-conductor logo
majiayu000/claude-skill-registry

agent-task-conductor

Conduct multi-agent task orchestration and workflow coordination.

663 1
View
conductor-setup logo
majiayu000/claude-skill-registry

conductor-setup

Initialize project with Conductor artifacts (product definition,

663 1
View
animation-designer logo
majiayu000/claude-skill-registry

animation-designer

Expert in web animations, transitions, and motion design using Framer Motion and CSS

663 1
View
diagramming logo
majiayu000/claude-skill-registry

diagramming

Creates Mermaid and ASCII diagrams for flowcharts, architecture, ERDs, state machines, mindmaps, and more. Use when user mentions diagram, flowchart, mermaid, ASCII diagram, text diagram, terminal diagram, visualize, C4, mindmap, architecture diagram, sequence diagram, ERD, or needs visual docume...

663 1
View
h3-pg logo
majiayu000/claude-skill-registry-data

h3-pg

PostgreSQL bindings for H3 hexagonal grid system. Use when working with H3 cells in Postgres, including spatial indexing, geometry/geography integration, and raster analysis.

23 1
View
conductor-development logo
majiayu000/claude-skill-registry

conductor-development

Context-Driven Development skill for projects using Conductor. Use this skill when you detect a `conductor/` directory in the project, when working on tasks defined in a `plan.md` file, or when the user asks about tracks, specs, or plans. Automatically applies TDD workflow, tracks task completion...

663 1
View
conductor-status logo
majiayu000/claude-skill-registry

conductor-status

Display project status, active tracks, and next actions

663 1
View
dockerization logo
majiayu000/claude-skill-registry

dockerization

Official Stakpak application containerization standard operating procedure, a step-by-step guidline to properly dockerize applications. This is a rule book curated by the Stakpak Team.

663 1
View

Popular AI tools

Kaiber logo
Video

Kaiber

Generate, edit, and beat-sync AI video with leading models in one workspace.

Paid
View
Vimcal logo
Productivity

Vimcal

The world's fastest calendar for remote work

Free
View

Transform Your Design with AI Designer by ImgCreator.ai

Freemium
View
Akool AI logo
Content & writing

Akool AI

Revolutionizing Video Production with AI-Powered Creativity

Paid
View

Extend an image past the frame and let AI fill the new aspect ratio.

Freemium
View
StarByFace logo
Security

StarByFace

Discover your celebrity doppelgänger with StarByFace!

Free
View
C

ChainClarity explains 700+ crypto whitepapers in plain English, with layered summaries, comparisons, research tools, alerts, and a $4.99 Pro plan.

Freemium
View
Opus Clip logo
Coding & apps

Opus Clip

Opus.ai: Revolutionize Your Web Experience

Free
View