architect-detective

architect-detective is a skill for Claude Code from MadAppGang/claude-code. It costs 40 tokens per session (4,104 once invoked), scanned A, original, MIT.

A codebase investigation tool for understanding software structure. It examines the relationships between code elements to reveal layers, dependencies, important building blocks, and unused code.

In plain words
What is it for?
Use it to investigate architecture, find design patterns, map dependencies, locate core abstractions, and identify architectural pillars.
Why use it?
Large systems can be difficult to understand by reading files one at a time. It helps trace how parts of the code connect and identify the structures that matter most.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: names the AskUserQuestion tool; positional $N argument.

Part of the code-analysis plugin — 12 skills, 2 commands, 1 agent shipped together

Good fit Use it to investigate architecture, find design patterns, map dependencies, locate core abstractions, and identify architectural pillars.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/madappgang/claude-code/architect-detective
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 MadAppGang/claude-code --skill architect-detective
Clone the repo
git clone --depth 1 https://github.com/MadAppGang/claude-code

Made for: Claude Code.

Or install code-analysis, the plugin that ships this one along with the rest of its 12 skills, 2 commands, 1 agent.

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 architect-detective

README.md
[![agentmods](https://agentmods.dev/badge/skills/madappgang/claude-code/architect-detective/github.svg)](https://agentmods.dev/skills/madappgang/claude-code/architect-detective)
Your own site
<a href="https://agentmods.dev/skills/madappgang/claude-code/architect-detective"><img src="https://agentmods.dev/badge/skills/madappgang/claude-code/architect-detective/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 architect-detective

Your own site · 80×15
<a href="https://agentmods.dev/skills/madappgang/claude-code/architect-detective"><img src="https://agentmods.dev/badge/skills/madappgang/claude-code/architect-detective.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 4,104 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.00040 $0.04104
Opus 5.5 $0.00016 $0.01642
Sonnet 5.5 $0.00008 $0.00821
Haiku 4.5 $0.00004 $0.00410

Measured 3mo ago against content hash 08bfe5da711b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

architect-detective 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 3mo 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/code-analysis/skills/architect-detective/SKILL.md · 485 lines

How it starts

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

Architect Detective Skill

This skill uses claudemem's AST structural analysis for architecture investigation.

Why Claudemem Works Better for Architecture

Task claudemem Native Tools
Find core abstractions map with PageRank ranking Read all files
Identify design patterns Structural symbol graph Grep patterns
Map dependencies callers/callees chains Manual tracing
Find architectural pillars High-PageRank symbols Unknown

Primary commands:

  • claudemem --agent map "query" - Architecture overview with PageRank
  • claudemem --agent symbol <name> - Exact file:line locations

Architect Detective Skill

Version: 3.3.0 Role: Software Architect Purpose: Deep architectural investigation using AST structural analysis with PageRank and dead-code detection

Role Context

You are investigating this codebase as a Software Architect. Your focus is on:

  • System boundaries - Where modules, services, and layers begin and end
  • Design patterns - Architectural patterns used (MVC, Clean Architecture, DDD, etc.)
  • Dependency flow - How components depend on each other
  • Abstraction layers - Interfaces, contracts, and abstractions
  • Core abstractions - High-PageRank symbols that everything depends on

Why map is Perfect for Architecture

The map command with PageRank shows you:

  • High-PageRank symbols = Core abstractions everything depends on
  • Symbol kinds = classes, interfaces, functions organized by type
  • File distribution = Where architectural layers live
  • Dependency centrality = Which code is most connected

Architect-Focused Commands (v0.3.0)

Architecture Discovery (use map)

# Get high-level architecture overview
claudemem --agent map "architecture layers"
# Find core abstractions (highest PageRank)
claudemem --agent map  # Full map, sorted by importance

# Map specific architectural concerns
claudemem --agent map "service layer business logic"claudemem --agent map "repository data access"claudemem --agent map "controller API endpoints"claudemem --agent map "middleware request handling"```

### Layer Boundary Discovery

```bash

Read the full file on GitHub · 485 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. 3mo ago First seen · 485 lines · 40 tokens per session scan A 08bfe5da711b

Subscribe to this mod's changes

architect-detective is a skill published in the GitHub repository MadAppGang/claude-code (291 stars, last pushed 8mo ago), licensed MIT. It adds 40 tokens to every session and 4,104 once invoked, about $0.0002 per session on Opus 5.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.

Related

architect-detective compared with skills from other repositories

architect-detective next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
architect-detectiveMadAppGang/claude-codeSkill2918mo agoMITA40Claude Code
systematic-debuggingopen-metadata/OpenMetadataSkill16kyesterdayApache-2.0A37Claude Code
log-error-digestzebbern/claude-code-guideSkill4.7ktodayMITA71Claude Code, Codex
observability-audit-sessionsIBM/mcp-context-forgeSkill4.9kyesterdayApache-2.0A64Claude Code, Codex
cwv-optimizeradobe/skillsSkill343yesterdayApache-2.0A112Claude Code
performance-verificationvalkor-ai/loomSkill1.6k2d agoApache-2.0A45Claude Code, Codex
loop-engineeringhuytieu/COG-second-brainSkill1.6kyesterdayMITA63Claude Code