Component Common Domain DetectionSAFE
The secure, validated skill registry for professional AI coding agents. Extend Antigravity, Claude Code, Cursor, Copilot and more with absolute confidence.
Overview
From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.
A skill for identifying duplicate domain functionality across components and suggesting consolidation opportunities to reduce duplication and improve maintainability.
What This Skill Does
This skill analyzes codebases to:
- Identify common namespace patterns (e.g.,
*.notification,*.audit) - Detect shared classes used across multiple components
- Analyze functionality similarity between components
- Assess coupling impact before recommending consolidation
- Suggest consolidation approaches (shared service, shared library, or merge)
- Provide consolidation plans with step-by-step guidance
- Calculate coupling metrics to evaluate consolidation safety
When to Use This Skill
This skill is applied when you:
- Ask to find common domain functionality
- Request identification of duplicate domain logic
- Need help detecting shared classes across components
- Want to analyze consolidation opportunities
- Ask about reducing code duplication
- Discuss component consolidation strategies
- Plan to merge similar components
Key Features
Domain vs Infrastructure Distinction
This skill focuses on domain functionality (business logic), not infrastructure:
- Domain: Notification, auditing, validation, formatting (common to some processes)
- Infrastructure: Logging, metrics, security (common to all processes)
Multiple Detection Strategies
Uses multiple approaches to find common functionality:
- Namespace Pattern Detection: Finds components with common leaf node names
- Shared Class Detection: Identifies classes used across multiple components
- Functionality Analysis: Examines code to verify similarity
Coupling Impact Analysis
Before recommending consolidation, analyzes:
- Current coupling levels (afferent coupling - CA)
- Estimated coupling after consolidation
- Whether consolidation creates coupling bottlenecks
- Safety of consolidation from
069343ba7895OBSERVED · 2026-10-07What it tells the agent
The instruction file, verbatim from the audited commit — this is the text the model reads, and the surface the audit's instruction layer examines. Quoted here so you can judge it without cloning anything.
--- name: component-common-domain-detection description: Finds duplicate business logic spread across multiple components and suggests consolidation. Use when asking "where is this logic duplicated?", "find common code between services", "what can be consolidated?", "detect shared domain logic", or analyzing component overlap before refactoring. Do NOT use for code-level duplication detection (use linters) or dependency analysis (use coupling-analysis). --- # Common Domain Component Detection This skill identifies common domain functionality that is duplicated across multiple components and suggests consolidation opportunities to reduce duplication and improve maintainability. ## How to Use ### Quick Start Request analysis of your codebase: - **"Find common domain functionality across components"** - **"Identify duplicate domain logic that should be consolidated"** - **"Detect shared classes used across multiple components"** - **"Analyze consolidation opportunities for common components"** ### Usage Examples **Example 1: Find Common Functionality** ``` User: "Find common domain functionality across components" The skill will: 1. Scan component namespaces for common patterns 2. Detect shared classes used across components 3. Identify duplicate domain logic 4. Analyze coupling impact of consolidation 5. Suggest consolidation opportunities ``` **Example 2: Detect Duplicate Notification Logic** ``` User: "Are there multiple notification components that should be consolidated?" The skill will: 1. Find all components with notification-related names 2. Analyze their functionality and dependencies 3. Calculate coupling impact if consolidated 4. Recommend consolidation approach ``` **Example 3: Analyze Shared Classes** ``` User: "Find classes that are shared across multiple components" The skill will: 1. Identify classes imported/used by multiple components 2. Classify as domain vs infrastructure functionality 3. Suggest consolidation or shared library approach 4. Assess impact on coupling ``` ### Step-by-Step Process 1. **Scan Components**: Identify components with common namespace patterns 2. **Detect Shared Code**: Find classes/files used across components 3. **Analyze Functionality**: Determine if functionality is truly common 4. **Assess Coupling**: Calculate coupling impact before consolidation 5. **Recommend Actions**: Suggest consolidation or shared library approach ## When to Use Apply this skill when: - After identifying and sizing components (Pattern 1) - Before flattening components (Pattern 3) - When planning to reduce code duplication - Analyzing shared domain logic across the codebase - Preparing for component consolidation - Identifying candidates for shared services or libraries ## Core Concepts ### Domain vs Infrastructure Functionality **Domain Functionality** (candidates for consolidation): - Business processing logic (notification, validation, auditing, formatting) - Common to **some** processes, not all - Examples: Customer notification, ticket auditing, data validation **Infrastructure Functionality** (usually not consolidated here): - Operational concerns (logging, metrics, security) - Common to **all** processes - Examples: Logging, authentication, database connections ### Common Domain Patterns Common domain functionality often appears as: 1. **Namespace Patterns**: Components ending in same leaf node - `*.notification`, `*.audit`, `*.validation`, `*.formatting` - Example: `TicketNotification`, `BillingNotification`, `SurveyNotification` 2. **Shared Classes**: Same class used across multiple components - Example: `SMTPConnection` used by 5 different components - Example: `AuditLogger` used by multiple domain components 3. **Similar Functionality**: Different components doing similar things - Example: Multiple components sending emails with slight variations - Example: Multiple components writing audit logs ### Consolidation Approaches **Shared Service**: - Common functionality becomes a separate service - Other components call this service - Good for: Frequently changing logic, complex operations **Shared Library**: - Common code packaged as library (JAR, DLL, npm package) - Components import and use the library - Good for: Stable functionality, simple utilities **Component Consolidation**: - Merge multiple components into one - Good for: Highly related functionality, low coupling impact ## Analysis Process ### Phase 1: Identify Common Namespace Patterns Scan component namespaces for common leaf node names: 1. **Extract leaf nodes** from all component namespaces - Example: `services/billing/notification` → `notification` - Example: `services/ticket/notification` → `notification` 2. **Group by common leaf nodes** - Find components with same leaf node name - Example: All components ending in `.notification` 3. **Filter out infrastructure patterns** - Exclude: `.util`, `.helper`, `.common` (usually infrastructure) - Focus on: `.notification`, `.audit`, `.validation`, `.formatting` **Example Output**: ```markdown ## Common Namespace Patterns Found **Notification Components**: - services/customer/notification - services/ticket/notification - services/survey/notification **Audit Components**: - services/billing/audit - services/ticket/audit - services/survey/audit ``` ### Phase 2: Detect Shared Classes Find classes/files used across multiple components: 1. **Scan imports/dependencies** in each component - Track which classes are imported from where - Note classes used by multiple components 2. **Identify shared classes** - Classes imported by 2+ components - Exclude infrastructure classes (Logger, Config, etc.) 3. **Classify as domain vs infrastructure** - Domain: Business logic classes (SMTPConnection, AuditLogger) - Infrastructure: Technical utilities (Logger, DatabaseConnection) **Example Output**: ```markdown ## Shared Classes Found **Domain Classes**: - `SMTP
Trust audit
SAFEgrade B · trust 89/100 Nothing in the source contradicts what it says it does. Grade A is reserved for packages that have also passed the behavioural sandbox.
| Layer | What it checks | Result |
|---|---|---|
| L0 | Provenance & inventory | PASS |
| L1 | Static analysis of the code | NA |
| L2 | Instruction surface (what it tells the agent) | PASS |
| L3 | Class-specific surface | PASS |
| L4 | Behavioural (sandbox) | SKIPPED |
What the source does
- Filesystem
- none-observed
- Network
- none-observed
- Shell
- none-observed
- Dependencies
- pinned
- Secrets in source
- none-found
Findings (1)
CLAUDE.md
Gates applied: no_behavioural_pass.
069343ba7895full audit observations/trust-audit/skill/tech-leads-club__component-common-domain-detection.json · Report an issue / request a re-scanAudit history
Every audit this skill has had.
| Date | Source | Verdict | Grade | Score | Change |
|---|---|---|---|---|---|
| 2026-10-07 | 069343ba7895 | SAFE | B | 89 | first audit |
Questions
What does the Component Common Domain Detection skill do?
The secure, validated skill registry for professional AI coding agents. Extend Antigravity, Claude Code, Cursor, Copilot and more with absolute confidence.
Is Component Common Domain Detection safe to install?
The audit found nothing in the source that contradicts what it says it does, and graded it B (89/100). Grade A is held back for packages that have also passed a sandboxed behavioural run, which is why a clean skill reads B.
What can Component Common Domain Detection access on my machine?
The audit observed no filesystem, network or shell use at all in its source.
How current is this page?
The grade is for one exact copy of the source (069343ba7895), read on 2026-10-07. The repository is watched, and a new audit runs when it changes — this is the first audit.