clean-architecture

clean-architecture is a skill for Claude Code from nathankim0/clean-architecture-skills. It costs 48 tokens per session (1,775 once invoked), scanned A, original, MIT.

A code-review guide based on Clean Architecture principles, including separate layers, inward-pointing dependencies, and SOLID design rules.

In plain words
What is it for?
Use it to review a project structure, check layer boundaries, examine dependency direction, or plan a new feature with Clean Architecture.
Why use it?
It helps identify architecture problems before dependencies and responsibilities become difficult to change.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the clean-architecture plugin — 1 skill shipped together

Good fit Use it to review a project structure, check layer boundaries, examine dependency direction, or plan a new feature with Clean Architecture.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/nathankim0/clean-architecture-skills/clean-architecture
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add nathankim0/clean-architecture-skills --skill clean-architecture
Clone the repo
git clone --depth 1 https://github.com/nathankim0/clean-architecture-skills

Made for: Claude Code.

Or install clean-architecture, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for clean-architecture

README.md
[![agentmods](https://agentmods.dev/badge/skills/nathankim0/clean-architecture-skills/clean-architecture/github.svg)](https://agentmods.dev/skills/nathankim0/clean-architecture-skills/clean-architecture)
Your own site
<a href="https://agentmods.dev/skills/nathankim0/clean-architecture-skills/clean-architecture"><img src="https://agentmods.dev/badge/skills/nathankim0/clean-architecture-skills/clean-architecture/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for clean-architecture

Your own site · 80×15
<a href="https://agentmods.dev/skills/nathankim0/clean-architecture-skills/clean-architecture"><img src="https://agentmods.dev/badge/skills/nathankim0/clean-architecture-skills/clean-architecture.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 48 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,775 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00048 $0.01775
Opus 5 $0.00024 $0.00888
Sonnet 5 $0.00010 $0.00355
Haiku 4.5 $0.00005 $0.00178

Measured 12d ago against content hash 9d167179af37, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

clean-architecture scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/clean-architecture/skills/clean-architecture/SKILL.md · 276 lines

How it starts

The opening of the file, as written. The whole thing — 276 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Clean Architecture Review Skill

Overview

This skill analyzes and reviews code based on Robert C. Martin's (Uncle Bob) Clean Architecture principles.

When to Use

  • When user requests "clean architecture" review
  • When asked about "architecture review", "dependency check", or "layer separation"
  • When designing new features with clean architecture

Instructions

1. Project Structure Analysis

First, understand the project's directory structure:

  • Check if layers are separated
  • Examine module/package structure
  • Identify dependency direction

2. The Dependency Rule

Core Principle: Source code dependencies must only point inward (toward higher-level policies).

┌─────────────────────────────────────────────────────────┐
│                  Frameworks & Drivers                    │
│  ┌─────────────────────────────────────────────────┐    │
│  │              Interface Adapters                  │    │
│  │  ┌─────────────────────────────────────────┐    │    │
│  │  │              Use Cases                   │    │    │
│  │  │  ┌─────────────────────────────────┐    │    │    │
│  │  │  │           Entities              │    │    │    │
│  │  │  └─────────────────────────────────┘    │    │    │
│  │  └─────────────────────────────────────────┘    │    │
│  └─────────────────────────────────────────────────┘    │
└─────────────────────────────────────────────────────────┘
                    ← Dependencies flow inward

Checklist:

  • Do inner layers avoid referencing outer layers?
  • Are Entities unaware of Use Cases, Adapters, and Infrastructure?
  • Do Use Cases avoid directly referencing Adapters or Infrastructure?
  • Is DIP applied when crossing boundaries?

2-1. Crossing Boundaries

The flow of control and source code dependency can point in opposite directions.

Controller → Use Case → Presenter
     ↓           ↓           ↑
[dependency] [dependency] [inverted!]

Example: When Use Case needs to call Presenter

  • Directly referencing Presenter from Use Case violates the dependency rule
  • Solution: Define Output Port (interface) inside Use Case, Presenter implements it

Read the full file on GitHub · 276 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 276 lines · 48 tokens per session scan A 9d167179af37

Subscribe to this mod's changes

clean-architecture is a skill published in the GitHub repository nathankim0/clean-architecture-skills (89 stars, last pushed 7mo ago), licensed MIT. It adds 48 tokens to every session and 1,775 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.