Best for
- Use when the user wants to assess, evaluate, or review the architecture, design quality, dependency structure, coupling, cohesion, or technical debt of an existing part of the codebase.
testdouble/han/han-coding/skills/architectural-analysis/SKILL.md
Performs deep architectural analysis of a specified module, directory, or feature area by examining structural coupling, data flow, concurrency patterns, risk, and SOLID alignment. Use when the user wants to assess, evaluate, or review the architecture, design quality, dependency structure, coupling, cohesion, or technical debt of an existing part of the codebase. Not for investigating specific bugs, runtime errors, or failures — use investigate. Not for test planning — use automated-test-planni
Decision brief
As your first action, use the Read tool on .han/config.md inside the personal config directory path above. A read that returns no file is no personal configuration: continue silently. When that file or the project .han/config.md probe supplies content, apply it per config-rule.m…
Compatibility matrix
| Platform | Status | Evidence | What to check |
|---|---|---|---|
| Codex | Not declared | No explicit evidence | Portability before use |
| Claude Code | Not declared | No explicit evidence | Portability before use |
| Cursor | Not declared | No explicit evidence | Portability before use |
| Gemini CLI | Not declared | No explicit evidence | Portability before use |
Installation
The source command is displayed only when detected. A safe inspection prompt is always available so your agent can explain every action before execution.
npx skills add https://github.com/testdouble/han --skill "han-coding/skills/architectural-analysis"Inspect the Agent Skill "architectural-analysis" from https://github.com/testdouble/han/blob/55e15f752b12f6f90923eb38f7cd25e8e51bf07b/han-coding/skills/architectural-analysis/SKILL.md at commit 55e15f752b12f6f90923eb38f7cd25e8e51bf07b. List every install step, command, network request, credential, file read/write, external action, and rollback step. Explain whether it fits my task. Do not install or execute anything until I approve.
Workflow
Bind $size. If the user passed small, medium, large, or dynamic as the first positional argument, bind $size to it. Anything else is part of the focus-area context, not a size; bind $size to the literal none provided.
Run targeted Grep and Glob over the focus area to detect which domains the code actually touches. These signals drive both the size band and the roster:
Synthesis spine — dispatched at every size:
Launch every discovery agent on the roster in a single message with one Agent call per agent so they run concurrently: han-core:structural-analyst, han-core:behavioral-analyst, and whichever of han-core:concurrency-analyst, han-core:adversarial-security-analyst, han-core:data-en…
Collect the full verbatim output from every discovery agent. Preserve every numbered item and its prefix exactly: S (structural), B (behavioral), C (concurrency), SEC- (security), DOR- (devops), and han-core:data-engineer's own finding IDs. Do not renumber, summarize, or drop it…
Permission review
No configured static risk pattern was detected
This is not proof of safety. Runtime behavior, indirect dependencies, and hidden external systems are outside the static scan.
Evidence record
| Signal | Value | Evidence type | Meaning |
|---|---|---|---|
| Quality score | 86/100 | Computed | Documentation, specificity, maintenance, and trust rules |
| Repository stars | 181 | Source | Repository attention, not individual Skill quality |
| Compatibility | 0 platforms | Source | Declared in the catalog source record |
| Usage guide | automated source guide | Editorial | Generated or reviewed according to the visible evidence level |
Pinned source
which git 2>/dev/null || echo "not installed"find . -maxdepth 1 -name "CLAUDE.md" -type ffind . -maxdepth 3 -name "project-discovery.md" -type fecho "${CLAUDE_CONFIG_DIR:-$HOME/.claude}"cat .han/config.md 2>/dev/null || echo ""As your first action, use the Read tool on .han/config.md inside the personal config directory path above. A read
that returns no file is no personal configuration: continue silently. When that file or the project .han/config.md
probe supplies content, apply it per config-rule.md, which governs precedence
between the two files, relative-path resolution, and what to do with a file that reads but cannot be used.
Read these before dispatching anything. They constrain every step below.
han-core:structural-analyst,
han-core:behavioral-analyst, han-core:risk-analyst, and han-core:software-architect run at every size BECAUSE
structure, runtime behavior, risk-of-inaction, and SOLID synthesis are the irreducible core of an architectural read.
Every other specialist is added only when the focus area's signals warrant it and the size band allows it, BECAUSE
dispatching an agent whose domain the code does not touch burns tokens and dilutes the report with low-signal
findings.han-core:software-architect (and
han-core:system-architect when dispatched) produce pseudocode sketches for proposed boundaries. Implementation is a
separate, later step.han-core:software-architect defers cross-service / bounded-context
/ trust-boundary findings rather than absorbing them. han-core:system-architect is added to the roster only at large
size and only when a boundary-crossing seam is actually present. When it is not dispatched, those deferrals are
surfaced in the report so the user can dispatch han-core:system-architect separately.han-communication:readability-guidance and applies it, holding one audience
above the writing: the engineer weighing the module's design and deciding whether to change it. Scope that frame per
section so the technical specifics that reader needs — file paths, finding IDs, exact conditions, pseudocode — are
preserved, never simplified away.Bind $size. If the user passed small, medium, large, or dynamic as the first positional argument, bind
$size to it. Anything else is part of the focus-area context, not a size; bind $size to the literal
none provided.
Resolve the focus area. Take the remaining argument and conversation context as the focus area. Confirm it resolves
to real files using Glob and Read. Identify the boundary: which files and directories the focus area includes, and
one layer of neighbors in each direction (what it imports, what imports it). If the focus area does not resolve to
actual files, stop and ask the user to clarify it before going further. If no focus area was supplied at all, ask the
user to name one — do not proceed against the whole codebase.
Resolve project context. If CLAUDE.md is present (see Project Context), read its ## Project Discovery section
for conventions. Fall back to project-discovery.md if present. These resolve language, framework, and convention
questions so the agents infer less. If neither exists, the agents fall back to surrounding-code inference — note this in
the agent briefs.
Note git availability. Read the git installed value from Project Context. If it is empty or reads not installed,
git is unavailable: the analysts will skip churn- and recency-based reasoning and the report must state this. If it
shows a path, the analysts may use git history for churn and likelihood evidence.
State the driving concern, if any. If the user named a concern ("I suspect a race in the retry queue", "we want to split this module"), capture it. It biases every agent's attention without narrowing scope. Pass it into every brief.
Run targeted Grep and Glob over the focus area to detect which domains the code actually touches. These signals
drive both the size band and the roster:
async/await, Promises, threads, goroutines, workers, channels, mutexes/locks, semaphores,
queues, Promise.all, WaitGroup, thread pools, atomic types.Classify the size. Default to small. Escalate only when a band's signal is clearly present; when a signal is borderline, stay at the smaller band.
$size is large.Apply the size override. If $size is not none provided, use it: a band value is the band and skips the
signal-based classification above, while dynamic forces the signal-based classification even when the project config
sets a default band. If $size is none provided and the project config supplies a band via default-swarm-size
(per the config rule in ../../references/config-rule.md), use that band, skip the
signal-based classification, and announce the config as the source. In every case still select specialists by signal
(a large band does not dispatch agents whose domain the code never touches). A conversational override ("run this
large") is equivalent to $size.
Synthesis spine — dispatched at every size:
han-core:structural-analyst — static structure: module boundaries, coupling, dependency direction, abstractions,
duplication. Emits S# findings.han-core:behavioral-analyst — runtime behavior: data flow, error propagation, state management, integration
boundaries. Emits B# findings.han-core:risk-analyst — scores the S/B/C findings for risk of inaction (likelihood, severity, blast radius,
reversibility). Emits R# items. Runs after the discovery wave.han-core:software-architect — synthesizes all upstream findings into intra-codebase recommendations grounded in
cohesion, coupling, and SOLID, with pseudocode sketches. Emits A# items. Runs last.Signal-selected discovery specialists — added when the signal is present and the band allows:
| Specialist | Add when | Min band |
|---|---|---|
han-core:concurrency-analyst (C#) | Concurrency signal present | Small |
han-core:adversarial-security-analyst (SEC-###) | Security signal present | Medium |
han-core:data-engineer | Data signal present | Medium |
han-core:devops-engineer (DOR-###) | DevOps signal present | Medium |
han-core:on-call-engineer (OCE-###) | On-call resilience signal present: application source in the focus area has outbound calls, retry logic, queue/buffer handling, async/await code, error-handling on a production path, fan-out loops, idempotency surfaces, or new production code paths whose failure would page someone | Medium |
han-core:codebase-explorer | Unfamiliar-area signal present | Large |
han-core:system-architect (SA#) | System-seam signal present | Large |
Roster caps by band: small runs the spine plus han-core:concurrency-analyst only (3–4 agents); medium adds one
or two of
{han-core:adversarial-security-analyst, han-core:data-engineer, han-core:devops-engineer, han-core:on-call-engineer}
by signal (4–6 agents); large adds the remaining signalled specialists, han-core:codebase-explorer if the area is
unfamiliar, and han-core:system-architect if a system-seam signal is present (6–9 agents). If more than the cap's
worth of specialists are signalled, keep the band's count and prefer the specialists covering the strongest signals;
note the omitted domains in the executive summary so the user can re-run larger. When both han-core:devops-engineer
and han-core:on-call-engineer are signalled, prefer han-core:on-call-engineer if the focus area is application
source and han-core:devops-engineer if it is infrastructure or pipelines; include both at large size only.
Extra agents named in the project config's ## Extra Agents list join the signal-selected specialist pool and compete
under the same signals and band caps, per ../../references/config-rule.md: add one
only when a signal in the focus area matches its stated specialty, count it against the band's cap, and skip an entry
that does not resolve to a dispatchable agent with a one-line note.
han-core:system-architect is the only specialist that changes han-core:software-architect's behavior: when
han-core:system-architect is on the roster, han-core:software-architect still defers boundary-crossing findings but
the report carries han-core:system-architect's recommendations for them instead of only listing them as deferred.
Announce the decision in one line before dispatching, with per-specialist justification — for example:
Size: medium. Focus area
src/auth/spans the session and token subsystems; one security signal detected (token handling). Roster (5):han-core:structural-analyst,han-core:behavioral-analyst(spine),han-core:concurrency-analyst(async token refresh detected),han-core:adversarial-security-analyst(token + session handling), thenhan-core:risk-analystandhan-core:software-architect.
State git availability in the same message if git is absent ("git unavailable — churn and recency evidence will be skipped"). Proceed without a blocking confirmation; this analysis is read-only and re-runnable, so a gate here would gate a reversible operation. If the user objects to the roster, honor the adjustment.
Launch every discovery agent on the roster in a single message with one Agent call per agent so they run concurrently:
han-core:structural-analyst, han-core:behavioral-analyst, and whichever of han-core:concurrency-analyst,
han-core:adversarial-security-analyst, han-core:data-engineer, han-core:devops-engineer,
han-core:on-call-engineer, han-core:codebase-explorer are on the roster. Do not launch han-core:risk-analyst,
han-core:software-architect, or han-core:system-architect here — they are the synthesis layer (Steps 6 and 7).
Each brief must contain:
han-core:adversarial-security-analyst, han-core:data-engineer, han-core:devops-engineer, and
han-core:on-call-engineer: scope the brief to the focus area and direct findings at architectural concerns within it
(its domain's structural and behavioral risk), not a general audit of the whole repository. For
han-core:on-call-engineer, the brief must restrict findings to application source files only — infrastructure,
pipelines, and IaC are out of scope.Wait for the entire wave to return before proceeding.
Collect the full verbatim output from every discovery agent. Preserve every numbered item and its prefix exactly: S#
(structural), B# (behavioral), C# (concurrency), SEC-### (security), DOR-### (devops), and
han-core:data-engineer's own finding IDs. Do not renumber, summarize, or drop items — the verbatim output is what the
report carries and what the synthesis layer cross-references.
If han-core:concurrency-analyst reported "no concurrency patterns found", keep that statement verbatim — it is a valid
negative result, not a missing section.
Launch han-core:risk-analyst with one Agent call. Pass it the full verbatim S#, B#, and C# findings (its
documented input contract). Do not pass it the security, data, or devops findings — those specialists already carry
their own severity and impact framing, and han-core:risk-analyst's rubric is built for the
structural/behavioral/concurrency findings that lack inherent severity. The agent emits R# items cross-referencing the
upstream S/B/C findings with likelihood, severity, blast radius, and reversibility. Wait for it to return.
Launch the synthesis layer with one Agent call per architect, in a single message when both are on the roster:
han-core:software-architect — always. Pass it the full verbatim discovery output (S/B/C plus any SEC-###,
DOR-###, and han-core:data-engineer findings) AND the han-core:risk-analyst R# items. It produces A#
intra-codebase recommendations with pseudocode sketches, each cross-referencing upstream findings and naming the
SOLID/cohesion/coupling concern. It defers boundary-crossing findings rather than absorbing them.han-core:system-architect — only when it is on the roster (large size, system-seam signal). Pass it the same
verbatim discovery output and R# items, plus the DOR-### and han-core:data-engineer findings explicitly (its
documented optional inputs). It produces SA# cross-service / bounded-context recommendations and a context-map
sketch.Wait for the synthesis layer to return.
Read references/architectural-analysis-report-template.md. Render it into the report draft; you present it after the readability pass in Step 11. Render rules:
sections_included
in the front matter, and replace its promise in the "How to Read" frame with a single line stating it was not part of
this run (the same way gap-analysis handles optional sections). A small run with no concurrency signal has no
Concurrency section; a run with no security signal has no Security section.han-core:concurrency-analyst ran but found nothing, keep the section
and carry its "no concurrency patterns found" statement — this is a reported result, not an omission.han-core:system-architect was dispatched, render its SA# recommendations
in the System-Architecture Recommendations section. If it was not, omit that section and instead render
han-core:software-architect's deferred boundary-crossing findings under "System-level concerns deferred", with the
one-line note that the user can dispatch han-core:system-architect separately for recommendations at that altitude.Readability. Invoke han-communication:readability-guidance to surface the shared readability standard into your
context. As you write the report's synthesized prose — the Executive Summary, the "How to Read" frame, and the section
prefaces — apply that standard: main point first, descriptive headings, one idea per paragraph with the first sentence
carrying it, numbered lists for steps and bullets for non-sequential items, and progressive disclosure. Finding IDs and
file:line references are citation identifiers; they survive any rewrite and self-check unchanged.
Dispatch han-communication:readability-editor with one Agent call to audit and rewrite the report draft against the
shared readability standard. Pass it the draft report text and the named audience: the engineer weighing the module's
design and deciding whether to change it; the editor reads han-communication's own canonical rule, so pass no rule path.
It preserves every fact and edits prose regions only — never inside code fences, pseudocode sketches, Mermaid or
other diagram bodies, or finding-ID and file:line citation identifiers. Scope its rewrite to the report's synthesized
prose (the Executive Summary, the "How to Read" frame, and the section prefaces); leave every analysis section's
verbatim agent output unchanged. Apply its rewrite. This pass does not touch the discovery, risk, or architect agent
spine (Steps 4–7).
Run the standardized readability self-check (the shared standard is in your context from
han-communication:readability-guidance) over the report's prose regions only — never inside code fences, pseudocode
sketches, diagram bodies, or finding-ID / file:line citation identifiers. Confirm each criterion and fix any failure
before presenting:
Run the readability rule's standardized six-point self-check, which is already in your context from the
readability-guidance invocation above. Correct every failure before presenting. Its fidelity criterion is not
optional: the standard governs how the content is said, never whether a required fact appears.
Present the rendered report directly in the conversation. Close by telling the user, in a short message: the size class
and roster used (and why), git availability, the count of findings by dimension, and any open items — boundary-crossing
concerns deferred to han-core:system-architect, or signalled domains the band cap omitted that would justify a re-run
at a larger size.
Alternatives
coreyhaines31/marketingskills
When the user wants to plan, design, or implement an A/B test or experiment, or build a growth experimentation program. Also use when the user mentions "A/B test," "split test," "experiment," "test this change," "variant copy," "multivariate test," "hypothesis," "should I test this," "which version is better," "test two versions," "statistical significance," "how long should I run this test," "growth experiments," "experiment velocity," "experiment backlog," "ICE score," "experimentation program
JasonColapietro/suede-creator-skills
Suede-owned experimentation discipline for hypotheses, sample sizing, test duration, significance, and repeatable experiment programs. Use when comparing variants, deciding whether a result is reliable, or building an experiment backlog and cadence. NOT FOR: analytics instrumentation (use suede-analytics), post-click conversion diagnosis (use suede-site-alchemy), or writing the variant copy itself (use suede-copy).
narrative-io/narrative-skills-marketplace
Translate a fuzzy analytical question into a rigorous investigation plan. Interrogates the ask, grounds the plan in the available data dictionary, applies analytical best practices, and produces a structured brief of query specifications for a downstream query-writing skill. Plans, does not write SQL. Use when: "why did X drop", "is there a relationship between A and B", "who are our highest-value customers", "what's driving the change in Y", "investigate this trend", "design an analysis for", "
Aperivue/medsci-skills
Interactive sample size calculator for medical research. Decision-tree guided test selection, reproducible R/Python code, effect size interpretation, and IRB-ready justification text. Supports diagnostic accuracy, agreement, proportions, continuous outcomes, survival, ANOVA, logistic regression, and non-inferiority/equivalence designs.