yacosta738/agent-harness/codebase-architecture
Claude Code and agent skill by yacosta738/agent-harness
- community
Checking that the SKILL.md file is still in the repository.
Use when the user asks to improve architecture, refactor complex
Install
npx vskill@latest install yacosta738/agent-harness/codebase-architectureSKILL.md
Codebase Architecture Audit & Improvement
Use this skill to identify architectural friction and propose deepening opportunities — refactoring paths that turn shallow modules into deep, high-leverage modules.
The primary goals are testability, isolation, and AI-navigability.
1. Glossary (Strict Vocabulary)
Use these terms exactly. Consistent language is crucial to avoid ambiguity. Do not substitute with generic terms like "component," "service," or "API".
- Module: Anything with an interface and an implementation (function, class,
package, slice).
- Interface: Everything a caller must know to use the module correctly (types, invariants,
ordering constraints, error modes, configuration). Not just the type signature.
- Implementation: The code inside a module.
- Depth: Leverage at the interface. A module is deep when a large amount
of behavior sits behind a small interface. A module is shallow when the interface is nearly as complex as the implementation.
- Seam: A place where you can alter behavior without editing in that place.
The location where an interface lives.
- Adapter: A concrete thing that satisfies an interface at a seam (describes
a role, not substance).
- Leverage: What callers get from depth.
- Locality: What maintainers get from depth (change, bugs, and knowledge
concentrate in one place).
Core Principles
- The Deletion Test: Imagine deleting the module. If complexity vanishes, it
was a shallow pass-through.
- The Seam Test: Can you swap the implementation without touching callers? If
not, the interface leaks.
- The Test Harness Test: Can you test the module in isolation? If not, it's
coupled.
2. Audit Workflow
Step 1: Map the Modules
Identify the major modules in the area of concern. For each module, note:
- Its interface (what callers see)
- Its implementation (what it does internally)
- Its dependencies (what it calls)
Step 2: Measure Depth
For each module, ask:
- Interface complexity: How much must a caller know?
- Implementation complexity: How much does the module do?
- Depth ratio: Implementation complexity / Interface complexity
High-depth modules are good. Low-depth modules are candidates for deepening.
Step 3: Identify Shallow Modules
Look for:
- Pass-through modules: Functions that just call another function with minor
transformation.
- Configuration wrappers: Modules that exist only to hold config.
- Getter/setter classes: Classes that are just bags of fields.
- Orchestrators: Modules that coordinate other modules but add no logic.
Step 4: Propose Deepening
For each shallow module, propose one of:
- Inline it: If it adds no value, delete it and move logic to caller.
- Absorb it: Merge it into a deeper neighbor module.
- Deepen it: Add more behavior behind the same interface.
- Reframe it: Change the interface to hide more implementation.
3. Deepening Patterns
Pattern: Inline Pass-Through
Before:
After: Delete getUser, call userRepository.findById directly.
Pattern: Absorb Configuration
Before:
After:
Pattern: Deepen by Adding Behavior
Before:
After:
Pattern: Reframe Interface to Hide Implementation
Before:
After:
4. Output Format
Present findings as:
5. When NOT to Deepen
- Stable, well-understood pass-throughs: If a module is a stable adapter
between two systems, leave it.
- Framework requirements: If the framework demands a certain structure, don't
fight it.
- Performance-critical paths: If inlining would hurt performance, keep the
module.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/workflow/codebase-architecture/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/yacosta738/agent-harness/codebase-architecture)