instructa/find-duplicate-ownership
Find duplicate ownership, hidden second sources of truth, and contract drift in layered codebases. Use when reviewing normalization, validation, defaulting, canonicalization, persistence mapping, runtime-vs-durable state, duplicated helpers, query or cache ownership, or any "who owns this rule?" architecture question. Especially useful for SSOT audits across frontend, backend, shared core, and adapter layers, and when the user explicitly asks for duplicate-ownership exploration with subagents.
npx skills add https://github.com/instructa/agent-skills --skill find-duplicate-ownership
Audit the codebase for multiply-owned rules instead of blindly grepping normalize.
Classify each case as real SSOT drift, local dedupe cleanup, legitimate boundary work, or legitimate domain constraint.
Narrow by feature, contract, package, service, or file slice when possible.
Good targets: session state, persistence contracts, runtime geometry, provider options, path helpers, JSON canonicalization.
Use these buckets:
architecture / SSOT bug: same business rule owned in more than one layerlocal dedupe cleanup: same helper semantics copied nearbylegitimate boundary adapter: wire, vendor, or untrusted input transformation with one clear ownerlegitimate domain constraint: runtime clamp, math, security, or path logic that cannot be removed architecturallyLook for:
Do not flag these by default:
Always answer:
Only use subagents when the user explicitly asks for them or asks for parallel exploration.
Reusable read-only agent definitions live in this skill's agents/ directory:
ownership-taxonomy-mapper.tomlUse first for broad slice mapping and taxonomy.
duplicate-ownership-explorer.tomlUse one per independent slice: persistence, runtime state, contracts, helpers, adapters.
ssot-judge.tomlUse after explorers when you need one strict verdict on winning owner and hard-cut cleanup.
Recommended fan-out:
Tell subagents:
For each finding, return:
Order findings by severity, then finish with a prioritized backlog by impact versus effort.
Use prompt patterns from references/audit-prompts.md.
rg normalize.Take instructa/find-duplicate-ownership from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.