opencodekit 0.21.10 → 0.22.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -1
- package/dist/template/.opencode/AGENTS.md +116 -487
- package/dist/template/.opencode/README.md +1 -1
- package/dist/template/.opencode/agent/build.md +56 -396
- package/dist/template/.opencode/agent/explore.md +0 -1
- package/dist/template/.opencode/agent/review.md +0 -1
- package/dist/template/.opencode/agent/scout.md +0 -1
- package/dist/template/.opencode/agent/vision.md +0 -1
- package/dist/template/.opencode/command/clarify.md +48 -0
- package/dist/template/.opencode/command/commit.md +53 -0
- package/dist/template/.opencode/command/fix.md +56 -0
- package/dist/template/.opencode/command/improve-architecture.md +55 -0
- package/dist/template/.opencode/command/init.md +88 -68
- package/dist/template/.opencode/command/refactor.md +66 -0
- package/dist/template/.opencode/command/test.md +66 -0
- package/dist/template/.opencode/dcp.jsonc +13 -2
- package/dist/template/.opencode/memory/README.md +3 -5
- package/dist/template/.opencode/memory/_templates/adr.md +45 -0
- package/dist/template/.opencode/memory/project/gotchas.md +1 -1
- package/dist/template/.opencode/memory/session-context.md +1 -1
- package/dist/template/.opencode/plugin/README.md +1 -1
- package/dist/template/.opencode/plugin/guard.ts +62 -0
- package/dist/template/.opencode/plugin/{lib/memory-admin-tools.ts → memory/admin.ts} +4 -4
- package/dist/template/.opencode/plugin/{lib → memory}/capture.ts +1 -1
- package/dist/template/.opencode/plugin/{lib → memory}/compile.ts +2 -2
- package/dist/template/.opencode/plugin/{lib → memory}/context.ts +1 -1
- package/dist/template/.opencode/plugin/{lib → memory}/curator.ts +1 -1
- package/dist/template/.opencode/plugin/{lib → memory}/db/observations.ts +102 -3
- package/dist/template/.opencode/plugin/{lib → memory}/db/schema.ts +43 -1
- package/dist/template/.opencode/plugin/{lib → memory}/db/types.ts +22 -0
- package/dist/template/.opencode/plugin/{lib/memory-db.ts → memory/db.ts} +1 -1
- package/dist/template/.opencode/plugin/{lib → memory}/distill.ts +1 -1
- package/dist/template/.opencode/plugin/{lib/memory-helpers.ts → memory/helpers.ts} +5 -1
- package/dist/template/.opencode/plugin/{lib/memory-hooks.ts → memory/hooks.ts} +1 -1
- package/dist/template/.opencode/plugin/{lib → memory}/index-generator.ts +2 -2
- package/dist/template/.opencode/plugin/{lib → memory}/inject.ts +1 -1
- package/dist/template/.opencode/plugin/{lib → memory}/lint.ts +2 -2
- package/dist/template/.opencode/plugin/memory/tools.ts +322 -0
- package/dist/template/.opencode/plugin/{lib → memory}/validate.ts +2 -2
- package/dist/template/.opencode/plugin/memory.ts +7 -17
- package/dist/template/.opencode/plugin/srcwalk.ts +721 -0
- package/dist/template/.opencode/skill/agent-code-quality-gate/SKILL.md +98 -0
- package/dist/template/.opencode/skill/behavioral-kernel/SKILL.md +52 -0
- package/dist/template/.opencode/skill/browser-testing-with-devtools/SKILL.md +85 -0
- package/dist/template/.opencode/skill/code-cleanup/SKILL.md +114 -0
- package/dist/template/.opencode/skill/code-navigation/SKILL.md +142 -0
- package/dist/template/.opencode/skill/code-review-and-quality/SKILL.md +131 -0
- package/dist/template/.opencode/skill/debugging-and-error-recovery/SKILL.md +109 -0
- package/dist/template/.opencode/skill/deep-module-design/SKILL.md +207 -0
- package/dist/template/.opencode/skill/git-workflow-and-versioning/SKILL.md +77 -0
- package/dist/template/.opencode/skill/grill-me/SKILL.md +140 -0
- package/dist/template/.opencode/skill/memory-system/SKILL.md +9 -10
- package/dist/template/.opencode/skill/planning-and-task-breakdown/SKILL.md +116 -0
- package/dist/template/.opencode/skill/shipping-and-launch/SKILL.md +95 -0
- package/dist/template/.opencode/skill/source-driven-development/SKILL.md +103 -0
- package/dist/template/.opencode/skill/spec-driven-development/SKILL.md +121 -0
- package/dist/template/.opencode/skill/srcwalk/SKILL.md +161 -0
- package/dist/template/.opencode/skill/ubiquitous-language/SKILL.md +184 -0
- package/package.json +1 -1
- package/dist/template/.opencode/AGENT_ALIGNMENT.md +0 -564
- package/dist/template/.opencode/agent/painter.md +0 -83
- package/dist/template/.opencode/command/compound.md +0 -240
- package/dist/template/.opencode/command/curate.md +0 -299
- package/dist/template/.opencode/command/handoff.md +0 -149
- package/dist/template/.opencode/command/health.md +0 -356
- package/dist/template/.opencode/command/init-context.md +0 -297
- package/dist/template/.opencode/command/init-user.md +0 -125
- package/dist/template/.opencode/command/iterate.md +0 -200
- package/dist/template/.opencode/command/lfg.md +0 -173
- package/dist/template/.opencode/command/resume.md +0 -78
- package/dist/template/.opencode/command/status.md +0 -126
- package/dist/template/.opencode/command/ui-slop-check.md +0 -169
- package/dist/template/.opencode/plugin/lib/memory-tools.ts +0 -535
- package/dist/template/.opencode/skill/agent-evals/SKILL.md +0 -208
- package/dist/template/.opencode/skill/anti-ai-slop/SKILL.md +0 -76
- package/dist/template/.opencode/skill/augment-context-engine/SKILL.md +0 -122
- package/dist/template/.opencode/skill/augment-context-engine/mcp.json +0 -6
- package/dist/template/.opencode/skill/brand-asset-protocol/SKILL.md +0 -222
- package/dist/template/.opencode/skill/code-search-patterns/SKILL.md +0 -224
- package/dist/template/.opencode/skill/code-simplification/SKILL.md +0 -211
- package/dist/template/.opencode/skill/context-condensation/SKILL.md +0 -149
- package/dist/template/.opencode/skill/context-initialization/SKILL.md +0 -69
- package/dist/template/.opencode/skill/context-management/SKILL.md +0 -390
- package/dist/template/.opencode/skill/deep-research/SKILL.md +0 -384
- package/dist/template/.opencode/skill/design-direction-advisor/SKILL.md +0 -139
- package/dist/template/.opencode/skill/dispatching-parallel-agents/SKILL.md +0 -191
- package/dist/template/.opencode/skill/executing-plans/SKILL.md +0 -247
- package/dist/template/.opencode/skill/figma-go/SKILL.md +0 -65
- package/dist/template/.opencode/skill/finishing-a-development-branch/SKILL.md +0 -357
- package/dist/template/.opencode/skill/full-output-enforcement/SKILL.md +0 -62
- package/dist/template/.opencode/skill/gh-address-comments/SKILL.md +0 -29
- package/dist/template/.opencode/skill/gh-address-comments/scripts/fetch_comments.py +0 -237
- package/dist/template/.opencode/skill/gh-fix-ci/SKILL.md +0 -38
- package/dist/template/.opencode/skill/gh-fix-ci/scripts/inspect_pr_checks.py +0 -509
- package/dist/template/.opencode/skill/hi-fi-prototype-html/SKILL.md +0 -253
- package/dist/template/.opencode/skill/html-deck-export/SKILL.md +0 -189
- package/dist/template/.opencode/skill/index-knowledge/SKILL.md +0 -413
- package/dist/template/.opencode/skill/memory-grounding/SKILL.md +0 -68
- package/dist/template/.opencode/skill/playwriter/SKILL.md +0 -158
- package/dist/template/.opencode/skill/portless/SKILL.md +0 -109
- package/dist/template/.opencode/skill/prd/SKILL.md +0 -146
- package/dist/template/.opencode/skill/prd-task/SKILL.md +0 -182
- package/dist/template/.opencode/skill/prd-task/references/prd-schema.json +0 -124
- package/dist/template/.opencode/skill/prompt-leverage/SKILL.md +0 -90
- package/dist/template/.opencode/skill/prompt-leverage/references/framework.md +0 -91
- package/dist/template/.opencode/skill/prompt-leverage/scripts/augment_prompt.py +0 -157
- package/dist/template/.opencode/skill/receiving-code-review/SKILL.md +0 -263
- package/dist/template/.opencode/skill/reconcile/SKILL.md +0 -183
- package/dist/template/.opencode/skill/reflection-checkpoints/SKILL.md +0 -183
- package/dist/template/.opencode/skill/requesting-code-review/SKILL.md +0 -443
- package/dist/template/.opencode/skill/requesting-code-review/references/specialist-profiles.md +0 -108
- package/dist/template/.opencode/skill/requesting-code-review/review.md +0 -160
- package/dist/template/.opencode/skill/rtk-command-compression/SKILL.md +0 -134
- package/dist/template/.opencode/skill/screenshot/SKILL.md +0 -48
- package/dist/template/.opencode/skill/screenshot/scripts/ensure_macos_permissions.sh +0 -54
- package/dist/template/.opencode/skill/screenshot/scripts/macos_display_info.swift +0 -22
- package/dist/template/.opencode/skill/screenshot/scripts/macos_permissions.swift +0 -40
- package/dist/template/.opencode/skill/screenshot/scripts/macos_window_info.swift +0 -126
- package/dist/template/.opencode/skill/screenshot/scripts/take_screenshot.ps1 +0 -163
- package/dist/template/.opencode/skill/screenshot/scripts/take_screenshot.py +0 -585
- package/dist/template/.opencode/skill/security-threat-model/SKILL.md +0 -36
- package/dist/template/.opencode/skill/security-threat-model/references/prompt-template.md +0 -255
- package/dist/template/.opencode/skill/security-threat-model/references/security-controls-and-assets.md +0 -32
- package/dist/template/.opencode/skill/sharing-skills/SKILL.md +0 -214
- package/dist/template/.opencode/skill/skill-creator/SKILL.md +0 -181
- package/dist/template/.opencode/skill/skill-installer/SKILL.md +0 -58
- package/dist/template/.opencode/skill/skill-installer/scripts/github_utils.py +0 -21
- package/dist/template/.opencode/skill/skill-installer/scripts/install-skill-from-github.py +0 -313
- package/dist/template/.opencode/skill/skill-installer/scripts/list-skills.py +0 -106
- package/dist/template/.opencode/skill/swarm-coordination/SKILL.md +0 -244
- package/dist/template/.opencode/skill/swarm-coordination/references/architecture.md +0 -39
- package/dist/template/.opencode/skill/swarm-coordination/references/delegation-worker-protocol.md +0 -145
- package/dist/template/.opencode/skill/swarm-coordination/references/dependency-graph.md +0 -50
- package/dist/template/.opencode/skill/swarm-coordination/references/drift-check.md +0 -90
- package/dist/template/.opencode/skill/swarm-coordination/references/integration-beads.md +0 -20
- package/dist/template/.opencode/skill/swarm-coordination/references/launch-flow.md +0 -186
- package/dist/template/.opencode/skill/swarm-coordination/references/reconciler.md +0 -172
- package/dist/template/.opencode/skill/swarm-coordination/references/tier-enforcement.md +0 -78
- package/dist/template/.opencode/skill/swarm-coordination/references/tmux-integration.md +0 -134
- package/dist/template/.opencode/skill/systematic-debugging/SKILL.md +0 -402
- package/dist/template/.opencode/skill/terse-output-mode/SKILL.md +0 -95
- package/dist/template/.opencode/skill/think-in-code/SKILL.md +0 -136
- package/dist/template/.opencode/skill/ux-quality-gates/SKILL.md +0 -137
- package/dist/template/.opencode/skill/v1-run/SKILL.md +0 -175
- package/dist/template/.opencode/skill/v1-run/mcp.json +0 -6
- package/dist/template/.opencode/skill/verification-gates/SKILL.md +0 -63
- package/dist/template/.opencode/skill/visual-analysis/SKILL.md +0 -154
- package/dist/template/.opencode/skill/web-design-guidelines/SKILL.md +0 -46
- package/dist/template/.opencode/skill/workspace-setup/SKILL.md +0 -76
- package/dist/template/.opencode/skill/writing-plans/SKILL.md +0 -320
- /package/dist/template/.opencode/plugin/{lib → memory}/compact.ts +0 -0
- /package/dist/template/.opencode/plugin/{lib → memory}/db/graph.ts +0 -0
- /package/dist/template/.opencode/plugin/{lib → memory}/db/maintenance.ts +0 -0
- /package/dist/template/.opencode/plugin/{lib → memory}/db/pipeline.ts +0 -0
- /package/dist/template/.opencode/plugin/{lib → memory}/notify.ts +0 -0
- /package/dist/template/.opencode/plugin/{lib → memory}/operation-log.ts +0 -0
|
@@ -1,384 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: deep-research
|
|
3
|
-
description: >
|
|
4
|
-
Use when analyzing unfamiliar code, implementing complex features, or entering thorough research mode.
|
|
5
|
-
Provides structured LSP exploration (all 9 operations), memory-first protocol, and confidence-scored findings.
|
|
6
|
-
Integrates with scout agent deep mode and research command --thorough flag.
|
|
7
|
-
version: 1.0.0
|
|
8
|
-
tags: [research, workflow]
|
|
9
|
-
dependencies: []
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
# Deep Research - Comprehensive Code Understanding
|
|
13
|
-
|
|
14
|
-
## When to Use
|
|
15
|
-
|
|
16
|
-
- **Complex implementation**: Feature touches 3+ files or unfamiliar modules
|
|
17
|
-
- **Thorough mode**: `/research <topic> --thorough` or scout deep mode
|
|
18
|
-
- **Pre-edit understanding**: Before modifying code you don't fully understand
|
|
19
|
-
- **Architecture exploration**: Understanding how systems connect
|
|
20
|
-
- **Debugging**: Tracing behavior through multiple layers
|
|
21
|
-
|
|
22
|
-
## When NOT to Use
|
|
23
|
-
|
|
24
|
-
- Quick syntax lookup (use quick mode instead)
|
|
25
|
-
- Well-understood code with obvious changes
|
|
26
|
-
- Time-constrained fixes (accept lower confidence)
|
|
27
|
-
|
|
28
|
-
## Core Protocol
|
|
29
|
-
|
|
30
|
-
### Phase 1: Memory First (Skip External If Found)
|
|
31
|
-
|
|
32
|
-
```typescript
|
|
33
|
-
// Search past research on this topic
|
|
34
|
-
memory_search({ query: "<topic keywords>", limit: 5 });
|
|
35
|
-
|
|
36
|
-
// Check for related observations
|
|
37
|
-
memory_search({ query: "<topic> gotchas patterns", limit: 3 });
|
|
38
|
-
|
|
39
|
-
// Load relevant project context
|
|
40
|
-
memory_read({ file: "project/architecture" });
|
|
41
|
-
memory_read({ file: "project/gotchas" });
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
**Stop condition**: If memory returns high-confidence findings on this exact topic, synthesize and skip to documentation. Only proceed to exploration if:
|
|
45
|
-
|
|
46
|
-
- No relevant memory found
|
|
47
|
-
- Memory findings are outdated or incomplete
|
|
48
|
-
- Question requires fresh analysis
|
|
49
|
-
|
|
50
|
-
### Phase 2: LSP Exploration (Delegate to Explore Agent)
|
|
51
|
-
|
|
52
|
-
**Delegate to explore agent** for comprehensive LSP analysis instead of manual operations:
|
|
53
|
-
|
|
54
|
-
```typescript
|
|
55
|
-
task({
|
|
56
|
-
subagent_type: "explore",
|
|
57
|
-
description: "LSP analysis of <target>",
|
|
58
|
-
prompt: `Very thorough LSP analysis of <symbol/module>.
|
|
59
|
-
|
|
60
|
-
Target files:
|
|
61
|
-
- src/path/to/file.ts
|
|
62
|
-
- src/related/module.ts
|
|
63
|
-
|
|
64
|
-
Questions to answer:
|
|
65
|
-
1. What is the type signature of <symbol>?
|
|
66
|
-
2. What calls this function? (incoming calls)
|
|
67
|
-
3. What does this function call? (outgoing calls)
|
|
68
|
-
4. Where is this symbol referenced across the codebase?
|
|
69
|
-
5. Are there interface implementations to consider?
|
|
70
|
-
|
|
71
|
-
Return structured findings with file:line references.`,
|
|
72
|
-
});
|
|
73
|
-
```
|
|
74
|
-
|
|
75
|
-
The explore agent will run:
|
|
76
|
-
|
|
77
|
-
- `documentSymbol` - File structure overview
|
|
78
|
-
- `goToDefinition` - Symbol definitions
|
|
79
|
-
- `findReferences` - All usages across codebase
|
|
80
|
-
- `hover` - Type info and documentation
|
|
81
|
-
- `workspaceSymbol` - Workspace-wide search
|
|
82
|
-
- Call hierarchy (incoming/outgoing calls)
|
|
83
|
-
|
|
84
|
-
**When to run LSP manually instead:**
|
|
85
|
-
|
|
86
|
-
- Single symbol lookup (quick mode)
|
|
87
|
-
- Explore agent unavailable
|
|
88
|
-
- Need specific operation only
|
|
89
|
-
|
|
90
|
-
### Phase 3: Pattern Discovery
|
|
91
|
-
|
|
92
|
-
```typescript
|
|
93
|
-
// Find similar patterns in codebase (use project's file extension: *.ts, *.py, *.rs, *.go, *.java, etc.)
|
|
94
|
-
grep({ pattern: "<relevant pattern>", include: "*.<ext>" });
|
|
95
|
-
|
|
96
|
-
// Locate related files
|
|
97
|
-
glob({ pattern: "src/**/*<topic>*" });
|
|
98
|
-
|
|
99
|
-
// Check tests for usage examples (adapt glob to project conventions)
|
|
100
|
-
// JS/TS: **/*.test.ts, **/*.spec.ts | Python: **/test_*.py | Rust: **/tests/**
|
|
101
|
-
// Go: **/*_test.go | Java: **/src/test/**/*.java
|
|
102
|
-
glob({ pattern: "**/*test*" });
|
|
103
|
-
grep({ pattern: "<function name>", include: "*test*" });
|
|
104
|
-
```
|
|
105
|
-
|
|
106
|
-
### Phase 4: External Research (If Needed)
|
|
107
|
-
|
|
108
|
-
Only if internal exploration doesn't answer the question:
|
|
109
|
-
|
|
110
|
-
```typescript
|
|
111
|
-
// Official docs
|
|
112
|
-
context7({ operation: "resolve", libraryName: "<lib>" });
|
|
113
|
-
context7({ operation: "query", libraryId: "<id>", topic: "<specific question>" });
|
|
114
|
-
|
|
115
|
-
// Real-world patterns (adapt language parameter to project)
|
|
116
|
-
codesearch({ query: "<API usage pattern>", tokensNum: 5000 });
|
|
117
|
-
grepsearch({ query: "<code pattern>", language: "<project language>" });
|
|
118
|
-
```
|
|
119
|
-
|
|
120
|
-
## Confidence Levels
|
|
121
|
-
|
|
122
|
-
Score every finding:
|
|
123
|
-
|
|
124
|
-
| Level | Criteria | Action |
|
|
125
|
-
| ---------- | ------------------------------------------ | -------------------- |
|
|
126
|
-
| **High** | LSP confirmed + tests exist + docs match | Proceed confidently |
|
|
127
|
-
| **Medium** | LSP confirmed but untested or undocumented | Proceed with caution |
|
|
128
|
-
| **Low** | Inference only, no LSP/test confirmation | Verify before using |
|
|
129
|
-
| **None** | Speculation without evidence | Discard |
|
|
130
|
-
|
|
131
|
-
## Stop Conditions
|
|
132
|
-
|
|
133
|
-
Stop research when ANY of these are true:
|
|
134
|
-
|
|
135
|
-
- All questions answered with Medium+ confidence
|
|
136
|
-
- Tool budget exhausted (~100 calls for thorough)
|
|
137
|
-
- Last 5 tool calls yielded no new insights
|
|
138
|
-
- Blocked and need human input
|
|
139
|
-
|
|
140
|
-
## Tool Budget Guidelines
|
|
141
|
-
|
|
142
|
-
| Mode | Tool Calls | Use Case |
|
|
143
|
-
| -------- | ---------- | ---------------------------------- |
|
|
144
|
-
| Quick | ~10 | Single question, syntax lookup |
|
|
145
|
-
| Default | ~30 | Moderate exploration |
|
|
146
|
-
| Thorough | ~100+ | Comprehensive analysis, new domain |
|
|
147
|
-
|
|
148
|
-
Track your tool count and stop at budget.
|
|
149
|
-
|
|
150
|
-
## Output Template
|
|
151
|
-
|
|
152
|
-
Document findings in structured format:
|
|
153
|
-
|
|
154
|
-
```markdown
|
|
155
|
-
# Deep Research: [Topic]
|
|
156
|
-
|
|
157
|
-
**Mode:** thorough
|
|
158
|
-
**Tool calls:** [N]
|
|
159
|
-
**Duration:** [time]
|
|
160
|
-
|
|
161
|
-
## Questions Addressed
|
|
162
|
-
|
|
163
|
-
1. [Q1] → Answered (High confidence)
|
|
164
|
-
2. [Q2] → Partial (Medium confidence)
|
|
165
|
-
3. [Q3] → Unanswered (needs: [what would resolve])
|
|
166
|
-
|
|
167
|
-
## LSP Findings
|
|
168
|
-
|
|
169
|
-
### Symbol: [name]
|
|
170
|
-
|
|
171
|
-
**Location:** `src/path/file.ts:42`
|
|
172
|
-
**Type:** [type signature from hover]
|
|
173
|
-
|
|
174
|
-
**Callers (incoming):**
|
|
175
|
-
|
|
176
|
-
- `src/a.ts:10` - [context]
|
|
177
|
-
- `src/b.ts:25` - [context]
|
|
178
|
-
|
|
179
|
-
**Dependencies (outgoing):**
|
|
180
|
-
|
|
181
|
-
- `src/utils.ts:15` - [what it calls]
|
|
182
|
-
|
|
183
|
-
**References:** [N] usages across [M] files
|
|
184
|
-
|
|
185
|
-
---
|
|
186
|
-
|
|
187
|
-
## Pattern Analysis
|
|
188
|
-
|
|
189
|
-
### Pattern 1: [Name]
|
|
190
|
-
|
|
191
|
-
**Files:** `src/a.ts`, `src/b.ts`
|
|
192
|
-
**Confidence:** High
|
|
193
|
-
**Evidence:** [LSP + grep findings]
|
|
194
|
-
|
|
195
|
-
[Description of pattern]
|
|
196
|
-
|
|
197
|
-
---
|
|
198
|
-
|
|
199
|
-
## Key Findings
|
|
200
|
-
|
|
201
|
-
### [Finding 1]
|
|
202
|
-
|
|
203
|
-
**Confidence:** High
|
|
204
|
-
**Sources:** LSP goToDefinition, findReferences
|
|
205
|
-
**Evidence:** `src/file.ts:42-56`
|
|
206
|
-
|
|
207
|
-
[Finding with code evidence]
|
|
208
|
-
|
|
209
|
-
---
|
|
210
|
-
|
|
211
|
-
## Recommendations
|
|
212
|
-
|
|
213
|
-
Based on LSP analysis:
|
|
214
|
-
|
|
215
|
-
1. [Recommendation 1] - because [LSP evidence]
|
|
216
|
-
2. [Recommendation 2] - because [pattern found]
|
|
217
|
-
|
|
218
|
-
## Open Items
|
|
219
|
-
|
|
220
|
-
- [Remaining question] - needs: [specific tool/info]
|
|
221
|
-
```
|
|
222
|
-
|
|
223
|
-
## Integration Points
|
|
224
|
-
|
|
225
|
-
### Scout Agent Deep Mode
|
|
226
|
-
|
|
227
|
-
When scout enters deep mode, load this skill:
|
|
228
|
-
|
|
229
|
-
```typescript
|
|
230
|
-
skill({ name: "deep-research" });
|
|
231
|
-
```
|
|
232
|
-
|
|
233
|
-
Scout then follows the protocol for external + internal analysis.
|
|
234
|
-
|
|
235
|
-
### Research Command --thorough
|
|
236
|
-
|
|
237
|
-
When `/research <topic> --thorough` is invoked:
|
|
238
|
-
|
|
239
|
-
```typescript
|
|
240
|
-
skill({ name: "deep-research" });
|
|
241
|
-
// Follow full protocol with ~100 tool budget
|
|
242
|
-
```
|
|
243
|
-
|
|
244
|
-
### Pre-Edit Verification
|
|
245
|
-
|
|
246
|
-
Before any complex edit:
|
|
247
|
-
|
|
248
|
-
```typescript
|
|
249
|
-
skill({ name: "deep-research" });
|
|
250
|
-
// Run Phase 2 (LSP) on all symbols being modified
|
|
251
|
-
// Proceed only when all 9 operations complete
|
|
252
|
-
```
|
|
253
|
-
|
|
254
|
-
## Workflow Example
|
|
255
|
-
|
|
256
|
-
**Scenario:** Understanding authentication middleware before adding rate limiting.
|
|
257
|
-
|
|
258
|
-
```typescript
|
|
259
|
-
// Phase 1: Memory check
|
|
260
|
-
memory_search({ query: "authentication middleware rate limiting" });
|
|
261
|
-
memory_read({ file: "project/architecture" });
|
|
262
|
-
|
|
263
|
-
// Phase 2: Delegate LSP exploration to explore agent
|
|
264
|
-
task({
|
|
265
|
-
subagent_type: "explore",
|
|
266
|
-
description: "Analyze auth middleware",
|
|
267
|
-
prompt: `Very thorough LSP analysis of authentication middleware.
|
|
268
|
-
|
|
269
|
-
Target: src/middleware/auth.ts
|
|
270
|
-
|
|
271
|
-
Questions:
|
|
272
|
-
1. What functions are exported from auth.ts?
|
|
273
|
-
2. What calls the auth middleware? (incoming calls)
|
|
274
|
-
3. What does it depend on? (outgoing calls)
|
|
275
|
-
4. Are there existing rate limiting patterns?
|
|
276
|
-
|
|
277
|
-
Return file:line references for all findings.`,
|
|
278
|
-
});
|
|
279
|
-
|
|
280
|
-
// Phase 3: Pattern discovery (parallel with Phase 2)
|
|
281
|
-
grep({ pattern: "middleware", include: "*.<ext>" });
|
|
282
|
-
grep({ pattern: "rateLimit", include: "*.<ext>" });
|
|
283
|
-
glob({ pattern: "src/middleware/*" });
|
|
284
|
-
|
|
285
|
-
// Phase 4: External (if patterns unclear)
|
|
286
|
-
context7({ operation: "resolve", libraryName: "express" });
|
|
287
|
-
context7({ operation: "query", libraryId: "/expressjs/express", topic: "middleware" });
|
|
288
|
-
|
|
289
|
-
// Document findings
|
|
290
|
-
write({
|
|
291
|
-
filePath: ".beads/artifacts/<id>/research.md",
|
|
292
|
-
content: "# Deep Research: Auth Middleware...",
|
|
293
|
-
});
|
|
294
|
-
```
|
|
295
|
-
|
|
296
|
-
## Anti-Patterns
|
|
297
|
-
|
|
298
|
-
### DON'T: Skip LSP Exploration
|
|
299
|
-
|
|
300
|
-
```typescript
|
|
301
|
-
// Bad: Reading file without LSP analysis
|
|
302
|
-
read({ filePath: "src/auth.ts" });
|
|
303
|
-
// Then immediately editing...
|
|
304
|
-
|
|
305
|
-
// Good: Delegate to explore agent first
|
|
306
|
-
task({
|
|
307
|
-
subagent_type: "explore",
|
|
308
|
-
description: "Analyze auth.ts",
|
|
309
|
-
prompt: "Very thorough LSP analysis of src/auth.ts...",
|
|
310
|
-
});
|
|
311
|
-
// Then edit with understanding
|
|
312
|
-
```
|
|
313
|
-
|
|
314
|
-
### DON'T: Ignore Memory
|
|
315
|
-
|
|
316
|
-
```typescript
|
|
317
|
-
// Bad: Jumping straight to exploration
|
|
318
|
-
grep({ pattern: "auth", include: "*.ts" });
|
|
319
|
-
|
|
320
|
-
// Good: Check memory first
|
|
321
|
-
memory_search({ query: "authentication patterns" });
|
|
322
|
-
// Only explore if memory doesn't answer
|
|
323
|
-
```
|
|
324
|
-
|
|
325
|
-
### DON'T: Mix Confidence Levels
|
|
326
|
-
|
|
327
|
-
```typescript
|
|
328
|
-
// Bad: Treating speculation as fact
|
|
329
|
-
"This function definitely handles X"; // Without LSP verification
|
|
330
|
-
|
|
331
|
-
// Good: Explicit confidence
|
|
332
|
-
"Based on LSP findReferences (High confidence): This function is called from...";
|
|
333
|
-
"Inference (Low confidence): This might also handle X, needs verification";
|
|
334
|
-
```
|
|
335
|
-
|
|
336
|
-
### DON'T: Exceed Budget Without Stopping
|
|
337
|
-
|
|
338
|
-
```typescript
|
|
339
|
-
// Bad: 150 tool calls on thorough mode
|
|
340
|
-
// Keep going indefinitely...
|
|
341
|
-
|
|
342
|
-
// Good: Track and stop
|
|
343
|
-
// Tool call 95: Still finding new insights, continue
|
|
344
|
-
// Tool call 100: Stopping at budget, documenting partial findings
|
|
345
|
-
```
|
|
346
|
-
|
|
347
|
-
## Success Criteria
|
|
348
|
-
|
|
349
|
-
Research is complete when:
|
|
350
|
-
|
|
351
|
-
- [ ] Memory checked before exploration
|
|
352
|
-
- [ ] All 9 LSP operations run on target symbols
|
|
353
|
-
- [ ] Confidence scores assigned to all findings
|
|
354
|
-
- [ ] Tool budget respected
|
|
355
|
-
- [ ] Findings documented with evidence
|
|
356
|
-
- [ ] Open items listed with resolution paths
|
|
357
|
-
|
|
358
|
-
## Quick Reference
|
|
359
|
-
|
|
360
|
-
```
|
|
361
|
-
PROTOCOL:
|
|
362
|
-
1. Memory first → skip if found
|
|
363
|
-
2. Delegate LSP to @explore (very thorough)
|
|
364
|
-
3. Patterns → grep + glob (parallel)
|
|
365
|
-
4. External → only if needed
|
|
366
|
-
|
|
367
|
-
DELEGATION:
|
|
368
|
-
task({ subagent_type: "explore", prompt: "Very thorough LSP analysis..." })
|
|
369
|
-
|
|
370
|
-
CONFIDENCE:
|
|
371
|
-
High = LSP + tests + docs
|
|
372
|
-
Medium = LSP only
|
|
373
|
-
Low = inference
|
|
374
|
-
None = discard
|
|
375
|
-
|
|
376
|
-
BUDGET:
|
|
377
|
-
quick ~10 | default ~30 | thorough ~100
|
|
378
|
-
|
|
379
|
-
STOP WHEN:
|
|
380
|
-
- Questions answered (Medium+)
|
|
381
|
-
- Budget exhausted
|
|
382
|
-
- 5 calls with no new insights
|
|
383
|
-
- Blocked on human input
|
|
384
|
-
```
|
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: design-direction-advisor
|
|
3
|
-
description: Use when the user's design brief is vague ("make it look good", "design something", "I don't know what style I want", "make me a nice-looking page") OR when no brand context exists. Recommends 3 differentiated directions from 5 design schools × 20 named designer philosophies (Pentagram, Field.io, Kenya Hara, Sagmeister, etc.) with parallel visual demos so the user can choose by seeing, not imagining.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Design Direction Advisor (Fallback Mode)
|
|
7
|
-
|
|
8
|
-
> Adapted from `huashu-design`. When you don't have brand context and the user's brief is too vague to execute, **don't guess from generic intuition** — that produces AI slop. Convert ambiguity into structured choice.
|
|
9
|
-
|
|
10
|
-
## When to Trigger
|
|
11
|
-
|
|
12
|
-
- Vague briefs: "make it look good", "design something", "make me a page", "I don't know what I want"
|
|
13
|
-
- User explicitly asks: "recommend a style", "give me some directions", "pick a philosophy", "show me different styles"
|
|
14
|
-
- No design context exists: no design system, no brand kit, no Figma, no reference site
|
|
15
|
-
- User says "I don't know what style I want either"
|
|
16
|
-
|
|
17
|
-
## When to Skip
|
|
18
|
-
|
|
19
|
-
- User already provided clear references (Figma / screenshots / brand spec) → run `brand-asset-protocol` instead
|
|
20
|
-
- User already specified the direction ("Apple Silicon launch event style") → go directly to execution
|
|
21
|
-
- Small fix or specific tool call ("convert this HTML to PDF") → skip
|
|
22
|
-
- Uncertain → use the lightest version: list 3 directions in 2 sentences each and let the user pick. Don't generate demos prematurely.
|
|
23
|
-
|
|
24
|
-
## The 8-Phase Flow
|
|
25
|
-
|
|
26
|
-
### Phase 1 — Deep-Understand the Need
|
|
27
|
-
|
|
28
|
-
Ask up to **3** focused questions (skip if already clear):
|
|
29
|
-
|
|
30
|
-
- Target audience?
|
|
31
|
-
- Core message?
|
|
32
|
-
- Emotional tone?
|
|
33
|
-
- Output format? (web page / slide / animation / app mockup)
|
|
34
|
-
|
|
35
|
-
### Phase 2 — Advisor-Style Restatement (~150 words)
|
|
36
|
-
|
|
37
|
-
In your own words, restate: the essential need, audience, scenario, emotional tone. End with: _"Based on this understanding, I've prepared 3 design directions for you."_
|
|
38
|
-
|
|
39
|
-
This forces alignment before generation. If the restatement is wrong, the user corrects you cheaply.
|
|
40
|
-
|
|
41
|
-
### Phase 3 — Recommend 3 Differentiated Philosophies
|
|
42
|
-
|
|
43
|
-
Each direction must include:
|
|
44
|
-
|
|
45
|
-
- **Named designer or studio** — "Kenya Hara-style Eastern minimalism," not just "minimalism"
|
|
46
|
-
- 50-100 words explaining _why this designer fits your brief_
|
|
47
|
-
- 3-4 signature visual features
|
|
48
|
-
- 3-5 vibe keywords
|
|
49
|
-
- Optional reference work
|
|
50
|
-
|
|
51
|
-
**Differentiation rule (non-negotiable):** the 3 directions must come from **3 different schools** for clear visual contrast.
|
|
52
|
-
|
|
53
|
-
### The 5 Schools × 20 Philosophies
|
|
54
|
-
|
|
55
|
-
| School | Vibe | Best as | Designers (pick 1 per recommendation) |
|
|
56
|
-
| ------------------------------------ | --------------------------------------- | ------------------------------- | ----------------------------------------------------------------- |
|
|
57
|
-
| **Information Architecture (01-04)** | Rational, data-driven, restrained | Safe / professional choice | Pentagram (Bierut), Stamen Design, Information Architects, Fathom |
|
|
58
|
-
| **Motion Poetics (05-08)** | Dynamic, immersive, technical aesthetic | Bold / cutting-edge choice | Locomotive, Active Theory, Field.io, Resn |
|
|
59
|
-
| **Minimalism (09-12)** | Order, whitespace, refinement | Safe / premium choice | Experimental Jetset, Müller-Brockmann, Build, Sagmeister & Walsh |
|
|
60
|
-
| **Experimental Avant-garde (13-16)** | Generative art, visual impact | Bold / innovative choice | Zach Lieberman, Raven Kwok, Ash Thorp, Territory Studio |
|
|
61
|
-
| **Eastern Philosophy (17-20)** | Warm, poetic, contemplative | Differentiation / unique choice | Takram, Kenya Hara, Irma Boom, Neo Shen |
|
|
62
|
-
|
|
63
|
-
❌ **Forbidden**: recommending 2 or more from the same school. Insufficient differentiation = user can't tell them apart.
|
|
64
|
-
|
|
65
|
-
A good triplet typically pairs **one safe + one bold + one differentiating** choice.
|
|
66
|
-
|
|
67
|
-
### Phase 4 — Show Reference Examples (Visual Anchor)
|
|
68
|
-
|
|
69
|
-
Before generating live demos, **show 2-3 reference images per direction** if you can fetch them (search the designer's known projects). The user calibrates "yes, that vibe" or "no, not what I meant" against real work, not your description.
|
|
70
|
-
|
|
71
|
-
Phrasing: _"Before I spin up live demos, here's how each style looks in similar scenarios →"_ then show references.
|
|
72
|
-
|
|
73
|
-
### Phase 5 — Generate 3 Visual Demos
|
|
74
|
-
|
|
75
|
-
> **Core principle: seeing beats describing.** Don't make the user imagine — show them.
|
|
76
|
-
|
|
77
|
-
For each of the 3 directions, generate one demo using the user's **real content/topic**, not lorem ipsum.
|
|
78
|
-
|
|
79
|
-
- **If parallel subagents are supported:** dispatch 3 in parallel (file-disjoint, see AGENTS.md "Parallel Execution Rules")
|
|
80
|
-
- **If serial:** generate one at a time, all 3 before showing
|
|
81
|
-
|
|
82
|
-
| Style type | Demo path |
|
|
83
|
-
| ----------------- | ----------------------------------------------------------------- |
|
|
84
|
-
| HTML-friendly | Generate full HTML → screenshot via Playwright |
|
|
85
|
-
| AI-image-friendly | Use image generation (e.g. nano-banana-pro) with style DNA prompt |
|
|
86
|
-
| Hybrid | HTML layout + AI-generated illustrations slotted in |
|
|
87
|
-
|
|
88
|
-
Save HTML to `_temp/design-demos/demo-<style>.html`. Screenshot to `_temp/design-demos/demo-<style>.png`. Show all 3 screenshots together.
|
|
89
|
-
|
|
90
|
-
```bash
|
|
91
|
-
# Reference command
|
|
92
|
-
npx playwright screenshot file:///<absolute-path>.html out.png --viewport-size=1200,900
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
### Phase 6 — User Chooses
|
|
96
|
-
|
|
97
|
-
Options to present:
|
|
98
|
-
|
|
99
|
-
- **Pick one** to deepen
|
|
100
|
-
- **Mix** ("A's palette + C's layout")
|
|
101
|
-
- **Tweak** specific aspects of one
|
|
102
|
-
- **Restart** → return to Phase 3 with refined understanding
|
|
103
|
-
|
|
104
|
-
### Phase 7 — Generate Production Prompt (if AI image-driven)
|
|
105
|
-
|
|
106
|
-
Structure: `[design philosophy constraint] + [content description] + [technical params]`
|
|
107
|
-
|
|
108
|
-
- ✅ Use **specific features**, not style names: "Kenya Hara whitespace + terracotta orange #C04A1A," not "minimalist"
|
|
109
|
-
- ✅ Include HEX colors, ratios, space allocation, output spec
|
|
110
|
-
- ❌ Avoid AI slop list (see `anti-ai-slop` skill)
|
|
111
|
-
|
|
112
|
-
### Phase 8 — Hand Off to Main Build
|
|
113
|
-
|
|
114
|
-
Direction confirmed → return to the main implementation flow (`hi-fi-prototype-html`, `frontend-design`, etc.). You now have **explicit design context** — no longer guessing.
|
|
115
|
-
|
|
116
|
-
## Lightweight Variant (Time-Pressured)
|
|
117
|
-
|
|
118
|
-
When the user is in a rush:
|
|
119
|
-
|
|
120
|
-
- Skip Phase 4 references
|
|
121
|
-
- Skip Phase 5 demos
|
|
122
|
-
- Just present 3 named directions in 2 sentences each
|
|
123
|
-
- Let user pick by name
|
|
124
|
-
|
|
125
|
-
This trades signal-fidelity for speed but still beats "generic AI default."
|
|
126
|
-
|
|
127
|
-
## Why This Beats "Just Make a Reasonable Default"
|
|
128
|
-
|
|
129
|
-
1. **Generic default = AI slop** (see `anti-ai-slop`). It dilutes brand identity to the average of all training data.
|
|
130
|
-
2. **Named designer references** give the user concrete vocabulary to push back ("more like Pentagram, less like Sagmeister").
|
|
131
|
-
3. **3 differentiated demos** convert vague preferences into testable choices in one round, instead of N rounds of "looks ok but not quite right."
|
|
132
|
-
4. **The advisor restatement (Phase 2)** catches misunderstandings before any pixel is committed — the cheapest possible correction point.
|
|
133
|
-
|
|
134
|
-
## Pairs Well With
|
|
135
|
-
|
|
136
|
-
- `brand-asset-protocol` — runs **after** direction is locked, when brand assets must be sourced
|
|
137
|
-
- `anti-ai-slop` — keeps each demo from collapsing into the AI default
|
|
138
|
-
- `hi-fi-prototype-html` — production target after direction is chosen
|
|
139
|
-
- `brainstorming` — for non-visual, non-design ambiguity
|