Intent
Explore data or systems to find patterns, relationships, or anomalies that were not explicitly requested or expected. Discovery is open-ended exploration that surfaces novel insights rather than confirming hypotheses.
Success criteria:
- At least one non-obvious finding surfaced
- Significance level assigned to each discovery
- Novelty classified (known, suspected, surprising)
- Methodology documented for reproducibility
Compatible schemas:
schemas/output_schema.yaml
Inputs
| Parameter |
Required |
Type |
Description |
search_space |
Yes |
string|object |
Where to look (files, data, systems, domains) |
discovery_type |
No |
string |
What kind of discovery: relationship, pattern, anomaly, gap, opportunity |
constraints |
No |
object |
Bounds on exploration (time, scope, depth) |
seed_observations |
No |
array |
Initial observations that may hint at discoveries |
Procedure
Define search space boundaries: Establish what is in and out of scope
- File patterns, directories, or data sources
- Conceptual boundaries (domain, time range)
- Depth limits (how many hops of relationships)
Apply discovery heuristics: Use exploration strategies systematically
- Pattern mining: Look for recurring structures, naming conventions, code patterns
- Relationship mapping: Find connections between entities (imports, calls, references)
- Anomaly detection: Identify outliers, inconsistencies, unusual structures
- Gap analysis: Find missing elements, broken links, incomplete patterns
Assess significance: Evaluate each finding's importance
- High: Directly actionable or explains important behavior
- Medium: Useful context or potential issue
- Low: Interesting but not actionable
Classify novelty: Determine how surprising each discovery is
- Known: Documented or widely understood
- Suspected: Hypothesized but not confirmed
- Surprising: Unexpected or counter to assumptions
Identify entities involved: Link discoveries to specific entities
- Files, functions, classes, modules
- People, teams, systems
- Concepts, patterns, architectures
Ground claims: Attach evidence anchors to all discoveries
- Exact locations where patterns occur
- References to related documentation
Synthesize findings: Connect individual discoveries into coherent insights
Output Contract
Return a structured object:
discoveries:
- type: string # relationship, pattern, anomaly, gap, opportunity
description: string # What was discovered
significance: low | medium | high
novelty: known | suspected | surprising
entities_involved: array[string]
location: string # Where found (file:line, path, or reference)
methodology: string # How discovery was conducted
search_space: string # What was explored
confidence: number # 0.0-1.0 confidence in discoveries
evidence_anchors: array[string] # References to supporting evidence
assumptions: array[string] # Conditions that affect findings
Field Definitions
| Field |
Type |
Description |
discoveries |
array |
List of findings with metadata |
discoveries[].type |
string |
Category of discovery |
discoveries[].significance |
enum |
Importance level |
discoveries[].novelty |
enum |
How unexpected the finding is |
methodology |
string |
Exploration approach used |
search_space |
string |
Scope of exploration |
confidence |
number |
0.0-1.0 overall discovery confidence |
evidence_anchors |
array[string] |
References to evidence |
assumptions |
array[string] |
Conditions that could change findings |
Examples
Example 1: Discover Hidden Dependencies
Input:
search_space: "src/"
discovery_type: "relationship"
constraints:
max_depth: 3
focus: "imports and function calls"
Output:
discoveries:
- type: "relationship"
description: "Circular dependency between UserService and AuthService"
significance: high
novelty: surprising
entities_involved:
- "src/services/UserService.ts"
- "src/services/AuthService.ts"
location: "src/services/UserService.ts:12 imports AuthService; src/services/AuthService.ts:8 imports UserService"
- type: "pattern"
description: "All repository classes follow identical initialization pattern with DI container lookup"
significance: medium
novelty: known
entities_involved:
- "src/repositories/*.ts"
location: "src/repositories/"
- type: "anomaly"
description: "PaymentService bypasses standard error handling pattern used by all other services"
significance: high
novelty: suspected
entities_involved:
- "src/services/PaymentService.ts"
location: "src/services/PaymentService.ts:45-78"
- type: "gap"
description: "No unit tests for critical OrderValidation module"
significance: high
novelty: surprising
entities_involved:
- "src/validation/OrderValidation.ts"
location: "tests/ - no corresponding test file"
methodology: "Static analysis of import statements, grep for class instantiation patterns, comparison against test file naming conventions"
search_space: "src/ directory (156 TypeScript files)"
confidence: 0.85
evidence_anchors:
- "src/services/UserService.ts:12"
- "src/services/AuthService.ts:8"
- "src/services/PaymentService.ts:45"
- "tests/:directory-listing"
assumptions:
- "Standard TypeScript import resolution"
- "Test files follow *Spec.ts or *.test.ts convention"
- "All production code is in src/"
Evidence pattern: Grep for import statements, build dependency graph, compare patterns across files.
Example 2: Discover Architecture Patterns
Input:
search_space: "entire codebase"
discovery_type: "pattern"
seed_observations:
- "Some endpoints seem to share similar structure"
Output:
discoveries:
- type: "pattern"
description: "Three distinct architectural styles coexist: MVC in /admin, DDD in /core, and script-style in /legacy"
significance: high
novelty: suspected
entities_involved:
- "/admin/*"
- "/core/*"
- "/legacy/*"
location: "Repository-wide directory structure"
- type: "relationship"
description: "DDD bounded contexts in /core share a common anti-corruption layer for legacy integration"
significance: medium
novelty: surprising
entities_involved:
- "/core/adapters/legacy/"
location: "/core/adapters/legacy/*.ts"
- type: "opportunity"
description: "MVC controllers in /admin could be consolidated - 12 controllers have nearly identical CRUD patterns"
significance: medium
novelty: known
entities_involved:
- "/admin/controllers/*.ts"
location: "/admin/controllers/"
methodology: "Directory structure analysis, pattern matching on file organization, code similarity detection"
search_space: "Full repository (312 files, 4 top-level directories)"
confidence: 0.75
evidence_anchors:
- "/admin/controllers/:pattern-sample"
- "/core/domain/:ddd-structure"
- "/core/adapters/legacy/LegacyAdapter.ts:1-50"
assumptions:
- "Directory structure reflects intentional architecture"
- "Pattern differences are deliberate, not accidental"
Verification
Verification tools: Read (to verify locations), Grep (to confirm patterns exist)
Safety Constraints
mutation: false
requires_checkpoint: false
requires_approval: false
risk: low
Capability-specific rules:
- Do not modify any files during discovery
- Respect scope boundaries - do not explore outside search_space
- Flag discoveries that may reveal sensitive information
- Report uncertainty when findings could be coincidental
Composition Patterns
Commonly follows:
inspect - Discovery often follows initial system observation
search - Discovery extends search results
identify - Discovery finds relationships between identified entities
Commonly precedes:
identify - Discovered entities may need identification
estimate - Discovered patterns may need quantification
compare - Discovered options may need comparison
plan - Discoveries may trigger action planning
Anti-patterns:
- Never use discover for known-item retrieval (use
search)
- Avoid discover for existence checking (use
detect)
- Do not use discover when you already know what to find
Workflow references:
- See
reference/composition_patterns.md#capability-gap-analysis for discover-relationship usage
- See
reference/composition_patterns.md#world-model-build for discovery in modeling
1---2name: discover3description: Find latent patterns, relationships, anomalies, or insights not explicitly specified. Use when exploring unknown structure, finding hidden connections, or uncovering emergent phenomena.4argument-hint: "[search-space] [discovery-type] [constraints]"5disable-model-invocation: false6user-invocable: true7allowed-tools: Read, Grep8context: fork9agent: explore10metadata:11 source: https://skillmd.com/skills/synaptiai/discover12---1314## Intent1516Explore data or systems to find patterns, relationships, or anomalies that were not explicitly requested or expected. Discovery is open-ended exploration that surfaces novel insights rather than confirming hypotheses.1718**Success criteria:**19- At least one non-obvious finding surfaced20- Significance level assigned to each discovery21- Novelty classified (known, suspected, surprising)22- Methodology documented for reproducibility2324**Compatible schemas:**25- `schemas/output_schema.yaml`2627## Inputs2829| Parameter | Required | Type | Description |30|-----------|----------|------|-------------|31| `search_space` | Yes | string\|object | Where to look (files, data, systems, domains) |32| `discovery_type` | No | string | What kind of discovery: relationship, pattern, anomaly, gap, opportunity |33| `constraints` | No | object | Bounds on exploration (time, scope, depth) |34| `seed_observations` | No | array | Initial observations that may hint at discoveries |3536## Procedure37381) **Define search space boundaries**: Establish what is in and out of scope39 - File patterns, directories, or data sources40 - Conceptual boundaries (domain, time range)41 - Depth limits (how many hops of relationships)42432) **Apply discovery heuristics**: Use exploration strategies systematically44 - **Pattern mining**: Look for recurring structures, naming conventions, code patterns45 - **Relationship mapping**: Find connections between entities (imports, calls, references)46 - **Anomaly detection**: Identify outliers, inconsistencies, unusual structures47 - **Gap analysis**: Find missing elements, broken links, incomplete patterns48493) **Assess significance**: Evaluate each finding's importance50 - High: Directly actionable or explains important behavior51 - Medium: Useful context or potential issue52 - Low: Interesting but not actionable53544) **Classify novelty**: Determine how surprising each discovery is55 - Known: Documented or widely understood56 - Suspected: Hypothesized but not confirmed57 - Surprising: Unexpected or counter to assumptions58595) **Identify entities involved**: Link discoveries to specific entities60 - Files, functions, classes, modules61 - People, teams, systems62 - Concepts, patterns, architectures63646) **Ground claims**: Attach evidence anchors to all discoveries65 - Exact locations where patterns occur66 - References to related documentation67687) **Synthesize findings**: Connect individual discoveries into coherent insights6970## Output Contract7172Return a structured object:7374```yaml75discoveries:76 - type: string # relationship, pattern, anomaly, gap, opportunity77 description: string # What was discovered78 significance: low | medium | high79 novelty: known | suspected | surprising80 entities_involved: array[string]81 location: string # Where found (file:line, path, or reference)82methodology: string # How discovery was conducted83search_space: string # What was explored84confidence: number # 0.0-1.0 confidence in discoveries85evidence_anchors: array[string] # References to supporting evidence86assumptions: array[string] # Conditions that affect findings87```8889### Field Definitions9091| Field | Type | Description |92|-------|------|-------------|93| `discoveries` | array | List of findings with metadata |94| `discoveries[].type` | string | Category of discovery |95| `discoveries[].significance` | enum | Importance level |96| `discoveries[].novelty` | enum | How unexpected the finding is |97| `methodology` | string | Exploration approach used |98| `search_space` | string | Scope of exploration |99| `confidence` | number | 0.0-1.0 overall discovery confidence |100| `evidence_anchors` | array[string] | References to evidence |101| `assumptions` | array[string] | Conditions that could change findings |102103## Examples104105### Example 1: Discover Hidden Dependencies106107**Input:**108```yaml109search_space: "src/"110discovery_type: "relationship"111constraints:112 max_depth: 3113 focus: "imports and function calls"114```115116**Output:**117```yaml118discoveries:119 - type: "relationship"120 description: "Circular dependency between UserService and AuthService"121 significance: high122 novelty: surprising123 entities_involved:124 - "src/services/UserService.ts"125 - "src/services/AuthService.ts"126 location: "src/services/UserService.ts:12 imports AuthService; src/services/AuthService.ts:8 imports UserService"127 - type: "pattern"128 description: "All repository classes follow identical initialization pattern with DI container lookup"129 significance: medium130 novelty: known131 entities_involved:132 - "src/repositories/*.ts"133 location: "src/repositories/"134 - type: "anomaly"135 description: "PaymentService bypasses standard error handling pattern used by all other services"136 significance: high137 novelty: suspected138 entities_involved:139 - "src/services/PaymentService.ts"140 location: "src/services/PaymentService.ts:45-78"141 - type: "gap"142 description: "No unit tests for critical OrderValidation module"143 significance: high144 novelty: surprising145 entities_involved:146 - "src/validation/OrderValidation.ts"147 location: "tests/ - no corresponding test file"148methodology: "Static analysis of import statements, grep for class instantiation patterns, comparison against test file naming conventions"149search_space: "src/ directory (156 TypeScript files)"150confidence: 0.85151evidence_anchors:152 - "src/services/UserService.ts:12"153 - "src/services/AuthService.ts:8"154 - "src/services/PaymentService.ts:45"155 - "tests/:directory-listing"156assumptions:157 - "Standard TypeScript import resolution"158 - "Test files follow *Spec.ts or *.test.ts convention"159 - "All production code is in src/"160```161162**Evidence pattern:** Grep for import statements, build dependency graph, compare patterns across files.163164---165166### Example 2: Discover Architecture Patterns167168**Input:**169```yaml170search_space: "entire codebase"171discovery_type: "pattern"172seed_observations:173 - "Some endpoints seem to share similar structure"174```175176**Output:**177```yaml178discoveries:179 - type: "pattern"180 description: "Three distinct architectural styles coexist: MVC in /admin, DDD in /core, and script-style in /legacy"181 significance: high182 novelty: suspected183 entities_involved:184 - "/admin/*"185 - "/core/*"186 - "/legacy/*"187 location: "Repository-wide directory structure"188 - type: "relationship"189 description: "DDD bounded contexts in /core share a common anti-corruption layer for legacy integration"190 significance: medium191 novelty: surprising192 entities_involved:193 - "/core/adapters/legacy/"194 location: "/core/adapters/legacy/*.ts"195 - type: "opportunity"196 description: "MVC controllers in /admin could be consolidated - 12 controllers have nearly identical CRUD patterns"197 significance: medium198 novelty: known199 entities_involved:200 - "/admin/controllers/*.ts"201 location: "/admin/controllers/"202methodology: "Directory structure analysis, pattern matching on file organization, code similarity detection"203search_space: "Full repository (312 files, 4 top-level directories)"204confidence: 0.75205evidence_anchors:206 - "/admin/controllers/:pattern-sample"207 - "/core/domain/:ddd-structure"208 - "/core/adapters/legacy/LegacyAdapter.ts:1-50"209assumptions:210 - "Directory structure reflects intentional architecture"211 - "Pattern differences are deliberate, not accidental"212```213214## Verification215216- [ ] Each discovery has type, significance, and novelty classified217- [ ] At least one discovery has evidence_anchors218- [ ] Methodology is documented and reproducible219- [ ] Search space boundaries are clearly defined220- [ ] Surprising discoveries are supported by multiple evidence points221222**Verification tools:** Read (to verify locations), Grep (to confirm patterns exist)223224## Safety Constraints225226- `mutation`: false227- `requires_checkpoint`: false228- `requires_approval`: false229- `risk`: low230231**Capability-specific rules:**232- Do not modify any files during discovery233- Respect scope boundaries - do not explore outside search_space234- Flag discoveries that may reveal sensitive information235- Report uncertainty when findings could be coincidental236237## Composition Patterns238239**Commonly follows:**240- `inspect` - Discovery often follows initial system observation241- `search` - Discovery extends search results242- `identify` - Discovery finds relationships between identified entities243244**Commonly precedes:**245- `identify` - Discovered entities may need identification246- `estimate` - Discovered patterns may need quantification247- `compare` - Discovered options may need comparison248- `plan` - Discoveries may trigger action planning249250**Anti-patterns:**251- Never use discover for known-item retrieval (use `search`)252- Avoid discover for existence checking (use `detect`)253- Do not use discover when you already know what to find254255**Workflow references:**256- See `reference/composition_patterns.md#capability-gap-analysis` for discover-relationship usage257- See `reference/composition_patterns.md#world-model-build` for discovery in modeling