oneie 3.4.2 → 3.6.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/.claude/agents/agent-director.md +902 -22
- package/.claude/agents/agent-onboard-example-output.md +600 -0
- package/.claude/agents/agent-onboard.md +576 -0
- package/.claude/commands/ONBOARDING_ENHANCEMENT_SUMMARY.md +266 -0
- package/.claude/commands/one.md +411 -10
- package/.claude/commands/release.md +64 -3
- package/CLAUDE.md +55 -69
- package/dist/commands/init.d.ts +5 -6
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +101 -101
- package/dist/commands/init.js.map +1 -1
- package/dist/index.js +6 -5
- package/dist/index.js.map +1 -1
- package/dist/utils/installation-setup.d.ts +24 -1
- package/dist/utils/installation-setup.d.ts.map +1 -1
- package/dist/utils/installation-setup.js +85 -1
- package/dist/utils/installation-setup.js.map +1 -1
- package/dist/utils/launch-claude.d.ts +6 -0
- package/dist/utils/launch-claude.d.ts.map +1 -0
- package/dist/utils/launch-claude.js +51 -0
- package/dist/utils/launch-claude.js.map +1 -0
- package/dist/utils/validation.d.ts +48 -0
- package/dist/utils/validation.d.ts.map +1 -0
- package/dist/utils/validation.js +73 -0
- package/dist/utils/validation.js.map +1 -0
- package/folders.yaml +1 -1
- package/one/.obsidian/app.json +8 -0
- package/one/.obsidian/appearance.json +1 -0
- package/one/.obsidian/community-plugins.json +3 -0
- package/one/.obsidian/core-plugins.json +33 -0
- package/one/.obsidian/plugins/easy-bake/main.js +361 -0
- package/one/.obsidian/plugins/easy-bake/manifest.json +11 -0
- package/one/.obsidian/plugins/easy-bake/styles.css +10 -0
- package/one/.obsidian/workspace.json +240 -0
- package/one/connections/workflow-onboarding.md +683 -0
- package/one/events/CART-DRAWER-INTEGRATION-GUIDE.md +354 -0
- package/one/events/CRITICAL-FIXES-COMPLETE.md +504 -0
- package/one/events/DEPLOYMENT.md +178 -0
- package/one/events/ECOMMERCE-DEMO-PLAN.md +225 -0
- package/one/events/ECOMMERCE-LIVE-DEMO.md +363 -0
- package/one/events/ECOMMERCE-TEMPLATE-COMPLETE.md +735 -0
- package/one/events/ECOMMERCE-TEMPLATES-SUMMARY.md +923 -0
- package/one/events/GRADIENT-TEXT-PERMANENT-FIX.md +223 -0
- package/one/events/HANDOFF.md +313 -0
- package/one/events/IMPLEMENTATION-SUMMARY-FINAL.md +503 -0
- package/one/events/IMPLEMENTATION_SUMMARY.md +529 -0
- package/one/events/LANDING-PAGE-EXAMPLE-OUTPUT.md +666 -0
- package/one/events/LANDING-PAGE-IMPLEMENTATION.md +642 -0
- package/one/events/LANDING-PAGE-QUICKSTART.md +407 -0
- package/one/events/MULTI-ONTOLOGY-COMPLETE-GUIDE.md +1627 -0
- package/one/events/MULTI-ONTOLOGY-IMPLEMENTATION-COMPLETE.md +573 -0
- package/one/events/ONBOARDING-IMPLEMENTATION-COMPLETE copy.md +398 -0
- package/one/events/ONTOLOGY-TUTORIALS-SUMMARY.md +525 -0
- package/one/events/ONTOLOGY-TYPE-GENERATOR-SUMMARY.md +455 -0
- package/one/events/ONTOLOGY_DISCOVERY_IMPLEMENTATION.md +486 -0
- package/one/events/ONTOLOGY_DISCOVERY_QUICKSTART.md +203 -0
- package/one/events/SECURITY-AUDIT-FIXES.md +376 -0
- package/one/events/SECURITY-SCAN-COMPLETE.md +281 -0
- package/one/events/SHOP-BUILD-STATUS.md +114 -0
- package/one/events/SHOP-PREMIUM-UPDATE.md +149 -0
- package/one/events/SITE-WIDE-GRADIENT-FIX.md +299 -0
- package/one/events/STORE-PRODUCTION-READY-STATUS.md +359 -0
- package/one/events/STRIPE-PAYMENT-METHODS-GUIDE.md +429 -0
- package/one/events/agent-director-enhancement-summary.md +386 -0
- package/one/events/agent-onboard-implementation-summary.md +457 -0
- package/one/events/clean-agent-ontology-cleanup-report.md +353 -0
- package/one/events/landing-page-generator.md +458 -0
- package/one/events/onboarding-implementation-complete.md +505 -0
- package/one/events/release.md +254 -0
- package/one/events/separate-implementation-status.md +537 -0
- package/one/groups/nine-padle-contents.baked.md +1252 -0
- package/one/groups/nine-padle-contents.md +6 -0
- package/one/knowledge/100-inference-quick-reference.md +431 -0
- package/one/knowledge/agent-onboard-usage.md +612 -0
- package/one/knowledge/cli-claude-handoff.md +718 -0
- package/one/knowledge/installation-folders.md +45 -1
- package/one/knowledge/ontology-blog.yaml +31 -0
- package/one/knowledge/ontology-cheatsheet.md +591 -0
- package/one/knowledge/ontology-community.yaml +42 -0
- package/one/knowledge/ontology-core-universal.md +722 -0
- package/one/knowledge/ontology-core.yaml +50 -0
- package/one/knowledge/ontology-courses.yaml +53 -0
- package/one/knowledge/ontology-creator.md +376 -0
- package/one/knowledge/ontology-developer-guide.md +789 -0
- package/one/knowledge/ontology-education.md +920 -0
- package/one/knowledge/ontology-index.md +354 -0
- package/one/knowledge/ontology-migration-guide.md +811 -0
- package/one/knowledge/ontology-minimal.yaml +1 -1
- package/one/knowledge/ontology-portfolio.yaml +31 -0
- package/one/knowledge/ontology-quickstart.md +576 -0
- package/one/knowledge/ontology-shop.yaml +121 -0
- package/one/knowledge/ontology-tokens.yaml +32 -0
- package/one/knowledge/ontology-tutorial.md +434 -0
- package/one/knowledge/ontology-video-script.md +890 -0
- package/one/things/docs/ecommerce/ARCHITECTURE-DIAGRAM.md +467 -0
- package/one/things/docs/ecommerce/CONVERSION-ELEMENTS-IMPLEMENTATION.md +408 -0
- package/one/things/docs/ecommerce/CONVERSION-ELEMENTS-SUMMARY.md +369 -0
- package/one/things/docs/ecommerce/CONVERSION-UX-IMPLEMENTATION-SUMMARY.md +396 -0
- package/one/things/docs/ecommerce/FEATURE-SUMMARY.md +468 -0
- package/one/things/docs/ecommerce/IMPLEMENTATION-NOTES.md +582 -0
- package/one/things/docs/ecommerce/INTEGRATION-EXAMPLE.md +449 -0
- package/one/things/docs/ecommerce/QUICK-START.md +368 -0
- package/one/things/docs/ecommerce/URGENCY-IMPLEMENTATION-SUMMARY.md +498 -0
- package/one/things/docs/ecommerce/URGENCY-QUICK-REFERENCE.md +237 -0
- package/one/things/docs/ecommerce/USAGE-EXAMPLE.astro +171 -0
- package/one/things/docs/ecommerce/demo.astro +309 -0
- package/one/things/plans/agent-director-100-inference-plans.md +410 -0
- package/one/things/plans/dual-website-strategy.md +612 -0
- package/one/things/plans/feature-based-sites.md +821 -0
- package/one/things/plans/multi-ontology-architecture.md +836 -0
- package/one/things/plans/onboarding.md +32 -0
- package/one/things/plans/separate.md +15 -17
- package/one/things/plans/start-new.md +738 -0
- package/one/things/templates.md +254 -0
- package/one/things/todo.md +23 -5
- package/package.json +2 -2
- package/one/things/claude/hooks/agent-hook-manager.js +0 -525
- package/one/things/claude/hooks/agent-load-balancer.js +0 -271
- package/one/things/claude/hooks/agent-request-interceptor.js +0 -70
- package/one/things/claude/hooks/cascade-feedback.js +0 -297
- package/one/things/claude/hooks/cascade-integration-hooks.js +0 -648
- package/one/things/claude/hooks/continuous-improvement-monitor.js +0 -510
- package/one/things/claude/hooks/file-organization-engine.js +0 -427
- package/one/things/claude/hooks/file-organization-monitor.js +0 -269
- package/one/things/claude/hooks/hook-config-manager.js +0 -202
- package/one/things/claude/hooks/hook-orchestrator.js +0 -662
- package/one/things/claude/hooks/hook-performance-report.js +0 -120
- package/one/things/claude/hooks/mcp-cascade-integration.js +0 -816
- package/one/things/claude/hooks/memory-optimizer.js +0 -510
- package/one/things/claude/hooks/ontology-compliance.js +0 -394
- package/one/things/claude/hooks/ontology-hook-manager.js +0 -316
- package/one/things/claude/hooks/ontology-validation-engine.js +0 -317
- package/one/things/claude/hooks/performance-monitoring-hook.js +0 -422
- package/one/things/claude/hooks/quality-scoring-engine.js +0 -834
- package/one/things/claude/hooks/simple-load-balancer.js +0 -238
- package/one/things/claude/hooks/startup-optimizer.js +0 -625
- package/one/things/claude/hooks/story-scoring-system.js +0 -445
- package/one/things/claude/hooks/story-validation-engine.js +0 -473
- package/one/things/claude/hooks/structure-synchronizer.js +0 -194
- package/one/things/claude/hooks/sub-agent-output-validator.js +0 -647
- package/one/things/claude/hooks/sub-agent-validation-hook.js +0 -343
- package/one/things/claude/hooks/trinity-validation-system.js +0 -392
- package/one/things/plans/organizations-to-groups.md +0 -705
|
@@ -0,0 +1,431 @@
|
|
|
1
|
+
# 100-Inference Plan Generation - Quick Reference
|
|
2
|
+
|
|
3
|
+
**For:** Developers extending agent-director
|
|
4
|
+
**Version:** 2.0.0
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## Feature Library Structure
|
|
9
|
+
|
|
10
|
+
```typescript
|
|
11
|
+
const FEATURE_DEFINITION = {
|
|
12
|
+
"feature-key": {
|
|
13
|
+
name: "Display Name",
|
|
14
|
+
description: "What this feature does",
|
|
15
|
+
inferences: [start, end], // Where in 1-100
|
|
16
|
+
specialist: "agent-name", // Which agent builds it
|
|
17
|
+
duration: "~X min", // Time estimate
|
|
18
|
+
cost: "$X", // Cost estimate
|
|
19
|
+
required: true|false, // Must be included?
|
|
20
|
+
dependencies: ["other-feature"], // What it needs
|
|
21
|
+
status: "available"|"existing", // Implementation status
|
|
22
|
+
ontology: {
|
|
23
|
+
things: ["entity_types"],
|
|
24
|
+
connections: ["relationship_types"],
|
|
25
|
+
events: ["event_types"],
|
|
26
|
+
knowledge: ["knowledge_types"]
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## Inference Ranges
|
|
35
|
+
|
|
36
|
+
**Foundation (Required):**
|
|
37
|
+
- 1-10: Landing page
|
|
38
|
+
- 11-20: Authentication
|
|
39
|
+
- 21-30: Multi-tenant groups
|
|
40
|
+
|
|
41
|
+
**User Features:**
|
|
42
|
+
- 31-40: Content/Projects/Integrations
|
|
43
|
+
- 41-50: Memberships/Repos/Email
|
|
44
|
+
- 51-60: Revenue/Pipelines/Community
|
|
45
|
+
|
|
46
|
+
**AI & Advanced:**
|
|
47
|
+
- 61-70: AI agents
|
|
48
|
+
- 71-80: RAG/Knowledge/Design
|
|
49
|
+
- 81-90: Search/Performance/Analytics
|
|
50
|
+
|
|
51
|
+
**Always Included:**
|
|
52
|
+
- 91-100: Deployment & Documentation
|
|
53
|
+
|
|
54
|
+
---
|
|
55
|
+
|
|
56
|
+
## Adding a New Feature
|
|
57
|
+
|
|
58
|
+
### Step 1: Define Feature
|
|
59
|
+
|
|
60
|
+
```typescript
|
|
61
|
+
// Add to appropriate category (CREATOR_FEATURES, DEVELOPER_FEATURES, etc.)
|
|
62
|
+
const NEW_FEATURES = {
|
|
63
|
+
"my-feature": {
|
|
64
|
+
name: "My Feature",
|
|
65
|
+
description: "What it does",
|
|
66
|
+
inferences: [31, 40], // Find available range
|
|
67
|
+
specialist: "agent-builder",
|
|
68
|
+
duration: "~15 min",
|
|
69
|
+
cost: "$0",
|
|
70
|
+
dependencies: ["multi-tenant-groups"], // What it needs
|
|
71
|
+
status: "available",
|
|
72
|
+
ontology: {
|
|
73
|
+
things: ["my_entity"],
|
|
74
|
+
connections: ["my_relationship"],
|
|
75
|
+
events: ["my_event"],
|
|
76
|
+
knowledge: ["my_pattern"]
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
};
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
### Step 2: Map Ontology
|
|
83
|
+
|
|
84
|
+
**Always include:**
|
|
85
|
+
- **things**: What entities are created?
|
|
86
|
+
- **connections**: How do they relate?
|
|
87
|
+
- **events**: What actions are logged?
|
|
88
|
+
- **knowledge**: What's learned/searched?
|
|
89
|
+
|
|
90
|
+
### Step 3: Test
|
|
91
|
+
|
|
92
|
+
```bash
|
|
93
|
+
# Test feature individually
|
|
94
|
+
agent-director generate-plan --features "my-feature"
|
|
95
|
+
|
|
96
|
+
# Test with dependencies
|
|
97
|
+
agent-director generate-plan --features "my-feature,ai-agents"
|
|
98
|
+
|
|
99
|
+
# Verify output
|
|
100
|
+
cat .onboarding.json
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
---
|
|
104
|
+
|
|
105
|
+
## Dependency Resolution
|
|
106
|
+
|
|
107
|
+
**Rules:**
|
|
108
|
+
1. Foundation features (landing-page, auth, groups) have no dependencies
|
|
109
|
+
2. All other features must depend on at least one foundation feature
|
|
110
|
+
3. Circular dependencies are invalid
|
|
111
|
+
4. Missing dependencies auto-resolved
|
|
112
|
+
|
|
113
|
+
**Example:**
|
|
114
|
+
```typescript
|
|
115
|
+
// User selects: ["ai-agents"]
|
|
116
|
+
// Auto-resolves to: ["landing-page", "authentication", "multi-tenant-groups", "ai-agents"]
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
---
|
|
120
|
+
|
|
121
|
+
## Specialist Agent Mapping
|
|
122
|
+
|
|
123
|
+
| Specialist | Responsibilities | Inference Ranges |
|
|
124
|
+
|-----------|-----------------|------------------|
|
|
125
|
+
| agent-frontend | Astro pages, React components, UI/UX | 1-10, 21-30, 71-80 |
|
|
126
|
+
| agent-backend | Convex queries/mutations, schemas | 11-20, 41-60, 71-90 |
|
|
127
|
+
| agent-builder | Full-stack features (backend + frontend) | 31-40, 61-70 |
|
|
128
|
+
| agent-integrator | External APIs, protocols, webhooks | 31-60 |
|
|
129
|
+
| agent-designer | Wireframes, design systems, components | 71-80 |
|
|
130
|
+
| agent-ops | Deployment, monitoring, performance | 51-60, 81-100 |
|
|
131
|
+
| existing | Already implemented, no build needed | 11-20 (auth) |
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
## Execution Plan Structure
|
|
136
|
+
|
|
137
|
+
```typescript
|
|
138
|
+
interface ExecutionPlan {
|
|
139
|
+
version: "1.0.0",
|
|
140
|
+
organizationName: string,
|
|
141
|
+
createdAt: number,
|
|
142
|
+
plan: {
|
|
143
|
+
phases: Phase[],
|
|
144
|
+
totalInferences: number,
|
|
145
|
+
currentInference: number,
|
|
146
|
+
completedInferences: number[],
|
|
147
|
+
estimates: {
|
|
148
|
+
duration: string, // "60 minutes (~1 hours)"
|
|
149
|
+
cost: string, // "$0.00"
|
|
150
|
+
inferences: number // 60
|
|
151
|
+
}
|
|
152
|
+
},
|
|
153
|
+
progress: {
|
|
154
|
+
status: "pending" | "in_progress" | "completed",
|
|
155
|
+
startedAt?: number,
|
|
156
|
+
completedAt?: number,
|
|
157
|
+
currentPhase?: string,
|
|
158
|
+
errors?: Error[]
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
---
|
|
164
|
+
|
|
165
|
+
## Progress Tracking
|
|
166
|
+
|
|
167
|
+
### Update Progress
|
|
168
|
+
|
|
169
|
+
```typescript
|
|
170
|
+
function updateProgress(update: Partial<ProgressUpdate>): void {
|
|
171
|
+
const plan = readOnboardingJson();
|
|
172
|
+
plan.progress = { ...plan.progress, ...update };
|
|
173
|
+
|
|
174
|
+
// Calculate percentage
|
|
175
|
+
const pct = (plan.plan.completedInferences.length / plan.plan.totalInferences) * 100;
|
|
176
|
+
|
|
177
|
+
writeOnboardingJson(plan);
|
|
178
|
+
|
|
179
|
+
// Emit event
|
|
180
|
+
emitEvent({
|
|
181
|
+
type: "progress_updated",
|
|
182
|
+
metadata: { percentage: pct, currentInference: plan.plan.currentInference }
|
|
183
|
+
});
|
|
184
|
+
}
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
### Mark Phase Complete
|
|
188
|
+
|
|
189
|
+
```typescript
|
|
190
|
+
function markPhaseComplete(phase: Phase): void {
|
|
191
|
+
updateProgress({
|
|
192
|
+
currentInference: phase.inferences.end,
|
|
193
|
+
completedInferences: range(phase.inferences.start, phase.inferences.end),
|
|
194
|
+
currentPhase: null // Clear current phase
|
|
195
|
+
});
|
|
196
|
+
|
|
197
|
+
emitEvent({
|
|
198
|
+
type: "phase_complete",
|
|
199
|
+
targetId: phase.featureKey,
|
|
200
|
+
metadata: { phaseName: phase.name, duration: "actual time" }
|
|
201
|
+
});
|
|
202
|
+
}
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
---
|
|
206
|
+
|
|
207
|
+
## Event-Driven Coordination
|
|
208
|
+
|
|
209
|
+
### Events Emitted
|
|
210
|
+
|
|
211
|
+
| Event | When | Metadata |
|
|
212
|
+
|-------|------|----------|
|
|
213
|
+
| `plan_generated` | Plan created | totalInferences, estimates |
|
|
214
|
+
| `phase_started` | Phase begins | phaseName, inferences, specialist |
|
|
215
|
+
| `progress_updated` | Inference completes | percentage, currentInference |
|
|
216
|
+
| `phase_complete` | Phase finishes | phaseName, duration, quality |
|
|
217
|
+
| `phase_failed` | Phase errors | phaseName, error, attempts |
|
|
218
|
+
| `plan_complete` | All done | totalDuration, qualityScore |
|
|
219
|
+
|
|
220
|
+
### Events Watched
|
|
221
|
+
|
|
222
|
+
| Event | Action |
|
|
223
|
+
|-------|--------|
|
|
224
|
+
| `implementation_complete` | Trigger quality check |
|
|
225
|
+
| `quality_check_complete` | Mark phase complete or retry |
|
|
226
|
+
| `solution_proposed` | Retry failed phase |
|
|
227
|
+
|
|
228
|
+
---
|
|
229
|
+
|
|
230
|
+
## Error Handling
|
|
231
|
+
|
|
232
|
+
### Retry Pattern
|
|
233
|
+
|
|
234
|
+
```typescript
|
|
235
|
+
async function executePhaseWithRetry(phase: Phase): Promise<void> {
|
|
236
|
+
let attempt = 0;
|
|
237
|
+
|
|
238
|
+
while (attempt < 3) {
|
|
239
|
+
try {
|
|
240
|
+
await executePhase(phase);
|
|
241
|
+
return; // Success
|
|
242
|
+
} catch (error) {
|
|
243
|
+
attempt++;
|
|
244
|
+
|
|
245
|
+
if (attempt >= 3) {
|
|
246
|
+
// Delegate to problem solver
|
|
247
|
+
await emitEvent({ type: "phase_failed", ... });
|
|
248
|
+
await waitForEvent("solution_proposed");
|
|
249
|
+
attempt = 0; // Reset after manual fix
|
|
250
|
+
} else {
|
|
251
|
+
// Exponential backoff
|
|
252
|
+
await sleep(Math.pow(2, attempt) * 1000);
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
---
|
|
260
|
+
|
|
261
|
+
## Parallel Execution
|
|
262
|
+
|
|
263
|
+
### Detection Rules
|
|
264
|
+
|
|
265
|
+
Phases can run in parallel if:
|
|
266
|
+
1. No shared dependencies
|
|
267
|
+
2. No overlapping inference ranges
|
|
268
|
+
3. Different specialists (optional optimization)
|
|
269
|
+
|
|
270
|
+
### Example
|
|
271
|
+
|
|
272
|
+
```typescript
|
|
273
|
+
// These can run in parallel:
|
|
274
|
+
Phase A: "content-publishing" (Infer 31-40, agent-frontend)
|
|
275
|
+
Phase B: "membership-tiers" (Infer 41-50, agent-backend)
|
|
276
|
+
|
|
277
|
+
// These CANNOT (overlap):
|
|
278
|
+
Phase A: "ai-agents" (Infer 61-70)
|
|
279
|
+
Phase B: "rag-knowledge" (Infer 71-80, depends on content)
|
|
280
|
+
```
|
|
281
|
+
|
|
282
|
+
---
|
|
283
|
+
|
|
284
|
+
## Cost Estimation
|
|
285
|
+
|
|
286
|
+
### Parse Cost String
|
|
287
|
+
|
|
288
|
+
```typescript
|
|
289
|
+
function parseCost(costString: string): number {
|
|
290
|
+
// "$0" → 0
|
|
291
|
+
// "$0.10 - $1.00" → 0.55 (average)
|
|
292
|
+
const matches = costString.match(/\$(\d+\.?\d*)/g);
|
|
293
|
+
if (!matches) return 0;
|
|
294
|
+
|
|
295
|
+
const costs = matches.map(m => parseFloat(m.replace('$', '')));
|
|
296
|
+
return costs.reduce((a, b) => a + b, 0) / costs.length;
|
|
297
|
+
}
|
|
298
|
+
```
|
|
299
|
+
|
|
300
|
+
---
|
|
301
|
+
|
|
302
|
+
## Common Patterns
|
|
303
|
+
|
|
304
|
+
### Read Feature Selections
|
|
305
|
+
|
|
306
|
+
```typescript
|
|
307
|
+
const selections = JSON.parse(fs.readFileSync('.onboarding.json'));
|
|
308
|
+
const selectedFeatures = selections.selectedFeatures;
|
|
309
|
+
```
|
|
310
|
+
|
|
311
|
+
### Resolve Dependencies
|
|
312
|
+
|
|
313
|
+
```typescript
|
|
314
|
+
const resolved = new Set<string>();
|
|
315
|
+
const queue = [...selectedFeatures];
|
|
316
|
+
|
|
317
|
+
while (queue.length > 0) {
|
|
318
|
+
const feature = queue.shift()!;
|
|
319
|
+
if (resolved.has(feature)) continue;
|
|
320
|
+
|
|
321
|
+
resolved.add(feature);
|
|
322
|
+
queue.push(...ALL_FEATURES[feature].dependencies);
|
|
323
|
+
}
|
|
324
|
+
```
|
|
325
|
+
|
|
326
|
+
### Generate Plan
|
|
327
|
+
|
|
328
|
+
```typescript
|
|
329
|
+
const plan = {
|
|
330
|
+
phases: resolved.map(key => ({
|
|
331
|
+
name: ALL_FEATURES[key].name,
|
|
332
|
+
featureKey: key,
|
|
333
|
+
inferences: {
|
|
334
|
+
start: ALL_FEATURES[key].inferences[0],
|
|
335
|
+
end: ALL_FEATURES[key].inferences[1]
|
|
336
|
+
},
|
|
337
|
+
specialist: ALL_FEATURES[key].specialist,
|
|
338
|
+
duration: ALL_FEATURES[key].duration,
|
|
339
|
+
cost: ALL_FEATURES[key].cost,
|
|
340
|
+
status: "pending",
|
|
341
|
+
ontology: ALL_FEATURES[key].ontology
|
|
342
|
+
})),
|
|
343
|
+
totalInferences: calculateTotal(resolved),
|
|
344
|
+
currentInference: 1,
|
|
345
|
+
completedInferences: [],
|
|
346
|
+
estimates: calculateEstimates(resolved)
|
|
347
|
+
};
|
|
348
|
+
```
|
|
349
|
+
|
|
350
|
+
---
|
|
351
|
+
|
|
352
|
+
## Testing Checklist
|
|
353
|
+
|
|
354
|
+
- [ ] Feature has unique key
|
|
355
|
+
- [ ] Inference range doesn't overlap with others
|
|
356
|
+
- [ ] Dependencies are valid (exist in library)
|
|
357
|
+
- [ ] Ontology mapping is complete (all 6 dimensions)
|
|
358
|
+
- [ ] Duration estimate is realistic
|
|
359
|
+
- [ ] Cost estimate includes all resources
|
|
360
|
+
- [ ] Specialist agent can handle the work
|
|
361
|
+
- [ ] Plan generates without errors
|
|
362
|
+
- [ ] Execution completes successfully
|
|
363
|
+
- [ ] Progress tracking updates correctly
|
|
364
|
+
|
|
365
|
+
---
|
|
366
|
+
|
|
367
|
+
## Debugging
|
|
368
|
+
|
|
369
|
+
### View Current Plan
|
|
370
|
+
|
|
371
|
+
```bash
|
|
372
|
+
cat .onboarding.json | jq '.plan'
|
|
373
|
+
```
|
|
374
|
+
|
|
375
|
+
### Check Progress
|
|
376
|
+
|
|
377
|
+
```bash
|
|
378
|
+
cat .onboarding.json | jq '.progress'
|
|
379
|
+
```
|
|
380
|
+
|
|
381
|
+
### List All Features
|
|
382
|
+
|
|
383
|
+
```typescript
|
|
384
|
+
Object.keys(ALL_FEATURES).forEach(key => {
|
|
385
|
+
const f = ALL_FEATURES[key];
|
|
386
|
+
console.log(`${key}: Infer ${f.inferences[0]}-${f.inferences[1]} (${f.specialist})`);
|
|
387
|
+
});
|
|
388
|
+
```
|
|
389
|
+
|
|
390
|
+
### Validate Dependencies
|
|
391
|
+
|
|
392
|
+
```typescript
|
|
393
|
+
Object.entries(ALL_FEATURES).forEach(([key, feature]) => {
|
|
394
|
+
feature.dependencies.forEach(dep => {
|
|
395
|
+
if (!ALL_FEATURES[dep]) {
|
|
396
|
+
console.error(`ERROR: ${key} depends on missing feature: ${dep}`);
|
|
397
|
+
}
|
|
398
|
+
});
|
|
399
|
+
});
|
|
400
|
+
```
|
|
401
|
+
|
|
402
|
+
---
|
|
403
|
+
|
|
404
|
+
## Quick Commands
|
|
405
|
+
|
|
406
|
+
```bash
|
|
407
|
+
# Generate plan from selections
|
|
408
|
+
agent-director generate-plan --features "landing-page,ai-agents"
|
|
409
|
+
|
|
410
|
+
# Execute plan
|
|
411
|
+
agent-director execute-plan
|
|
412
|
+
|
|
413
|
+
# Show progress
|
|
414
|
+
agent-director show-progress
|
|
415
|
+
|
|
416
|
+
# Resume from inference N
|
|
417
|
+
agent-director resume --from 50
|
|
418
|
+
|
|
419
|
+
# Add feature to running plan
|
|
420
|
+
agent-director add-feature "semantic-search"
|
|
421
|
+
|
|
422
|
+
# Mark phase complete
|
|
423
|
+
agent-director mark-complete "ai-agents"
|
|
424
|
+
```
|
|
425
|
+
|
|
426
|
+
---
|
|
427
|
+
|
|
428
|
+
**Need Help?**
|
|
429
|
+
- Read: `/.claude/agents/agent-director.md`
|
|
430
|
+
- See: `/one/things/plans/agent-director-100-inference-plans.md`
|
|
431
|
+
- Example: `/.onboarding-plan.json.example`
|