opencastle 0.1.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.
Files changed (224) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +215 -0
  3. package/bin/cli.mjs +69 -0
  4. package/dist/cli/adapters/claude-code.d.ts +22 -0
  5. package/dist/cli/adapters/claude-code.d.ts.map +1 -0
  6. package/dist/cli/adapters/claude-code.js +237 -0
  7. package/dist/cli/adapters/claude-code.js.map +1 -0
  8. package/dist/cli/adapters/cursor.d.ts +20 -0
  9. package/dist/cli/adapters/cursor.d.ts.map +1 -0
  10. package/dist/cli/adapters/cursor.js +231 -0
  11. package/dist/cli/adapters/cursor.js.map +1 -0
  12. package/dist/cli/adapters/vscode.d.ts +20 -0
  13. package/dist/cli/adapters/vscode.d.ts.map +1 -0
  14. package/dist/cli/adapters/vscode.js +132 -0
  15. package/dist/cli/adapters/vscode.js.map +1 -0
  16. package/dist/cli/copy.d.ts +14 -0
  17. package/dist/cli/copy.d.ts.map +1 -0
  18. package/dist/cli/copy.js +62 -0
  19. package/dist/cli/copy.js.map +1 -0
  20. package/dist/cli/dashboard.d.ts +3 -0
  21. package/dist/cli/dashboard.d.ts.map +1 -0
  22. package/dist/cli/dashboard.js +183 -0
  23. package/dist/cli/dashboard.js.map +1 -0
  24. package/dist/cli/diff.d.ts +3 -0
  25. package/dist/cli/diff.d.ts.map +1 -0
  26. package/dist/cli/diff.js +27 -0
  27. package/dist/cli/diff.js.map +1 -0
  28. package/dist/cli/eject.d.ts +3 -0
  29. package/dist/cli/eject.d.ts.map +1 -0
  30. package/dist/cli/eject.js +27 -0
  31. package/dist/cli/eject.js.map +1 -0
  32. package/dist/cli/init.d.ts +3 -0
  33. package/dist/cli/init.d.ts.map +1 -0
  34. package/dist/cli/init.js +92 -0
  35. package/dist/cli/init.js.map +1 -0
  36. package/dist/cli/manifest.d.ts +14 -0
  37. package/dist/cli/manifest.d.ts.map +1 -0
  38. package/dist/cli/manifest.js +34 -0
  39. package/dist/cli/manifest.js.map +1 -0
  40. package/dist/cli/mcp.d.ts +14 -0
  41. package/dist/cli/mcp.d.ts.map +1 -0
  42. package/dist/cli/mcp.js +35 -0
  43. package/dist/cli/mcp.js.map +1 -0
  44. package/dist/cli/prompt.d.ts +12 -0
  45. package/dist/cli/prompt.d.ts.map +1 -0
  46. package/dist/cli/prompt.js +104 -0
  47. package/dist/cli/prompt.js.map +1 -0
  48. package/dist/cli/run/adapters/claude-code.d.ts +16 -0
  49. package/dist/cli/run/adapters/claude-code.d.ts.map +1 -0
  50. package/dist/cli/run/adapters/claude-code.js +82 -0
  51. package/dist/cli/run/adapters/claude-code.js.map +1 -0
  52. package/dist/cli/run/adapters/copilot.d.ts +16 -0
  53. package/dist/cli/run/adapters/copilot.d.ts.map +1 -0
  54. package/dist/cli/run/adapters/copilot.js +84 -0
  55. package/dist/cli/run/adapters/copilot.js.map +1 -0
  56. package/dist/cli/run/adapters/cursor.d.ts +16 -0
  57. package/dist/cli/run/adapters/cursor.d.ts.map +1 -0
  58. package/dist/cli/run/adapters/cursor.js +81 -0
  59. package/dist/cli/run/adapters/cursor.js.map +1 -0
  60. package/dist/cli/run/adapters/index.d.ts +14 -0
  61. package/dist/cli/run/adapters/index.d.ts.map +1 -0
  62. package/dist/cli/run/adapters/index.js +35 -0
  63. package/dist/cli/run/adapters/index.js.map +1 -0
  64. package/dist/cli/run/executor.d.ts +15 -0
  65. package/dist/cli/run/executor.d.ts.map +1 -0
  66. package/dist/cli/run/executor.js +249 -0
  67. package/dist/cli/run/executor.js.map +1 -0
  68. package/dist/cli/run/reporter.d.ts +10 -0
  69. package/dist/cli/run/reporter.d.ts.map +1 -0
  70. package/dist/cli/run/reporter.js +112 -0
  71. package/dist/cli/run/reporter.js.map +1 -0
  72. package/dist/cli/run/schema.d.ts +28 -0
  73. package/dist/cli/run/schema.d.ts.map +1 -0
  74. package/dist/cli/run/schema.js +511 -0
  75. package/dist/cli/run/schema.js.map +1 -0
  76. package/dist/cli/run.d.ts +6 -0
  77. package/dist/cli/run.d.ts.map +1 -0
  78. package/dist/cli/run.js +123 -0
  79. package/dist/cli/run.js.map +1 -0
  80. package/dist/cli/stack-config.d.ts +12 -0
  81. package/dist/cli/stack-config.d.ts.map +1 -0
  82. package/dist/cli/stack-config.js +146 -0
  83. package/dist/cli/stack-config.js.map +1 -0
  84. package/dist/cli/types.d.ts +169 -0
  85. package/dist/cli/types.d.ts.map +1 -0
  86. package/dist/cli/types.js +2 -0
  87. package/dist/cli/types.js.map +1 -0
  88. package/dist/cli/update.d.ts +3 -0
  89. package/dist/cli/update.d.ts.map +1 -0
  90. package/dist/cli/update.js +50 -0
  91. package/dist/cli/update.js.map +1 -0
  92. package/package.json +48 -0
  93. package/src/cli/adapters/claude-code.ts +287 -0
  94. package/src/cli/adapters/cursor.ts +377 -0
  95. package/src/cli/adapters/vscode.ts +168 -0
  96. package/src/cli/copy.ts +79 -0
  97. package/src/cli/dashboard.ts +225 -0
  98. package/src/cli/diff.ts +44 -0
  99. package/src/cli/eject.ts +39 -0
  100. package/src/cli/init.ts +120 -0
  101. package/src/cli/manifest.ts +45 -0
  102. package/src/cli/mcp.ts +49 -0
  103. package/src/cli/prompt.ts +115 -0
  104. package/src/cli/run/adapters/claude-code.ts +95 -0
  105. package/src/cli/run/adapters/copilot.ts +97 -0
  106. package/src/cli/run/adapters/cursor.ts +94 -0
  107. package/src/cli/run/adapters/index.ts +40 -0
  108. package/src/cli/run/executor.ts +292 -0
  109. package/src/cli/run/reporter.ts +129 -0
  110. package/src/cli/run/schema.ts +595 -0
  111. package/src/cli/run.ts +137 -0
  112. package/src/cli/stack-config.ts +180 -0
  113. package/src/cli/types.ts +207 -0
  114. package/src/cli/update.ts +75 -0
  115. package/src/dashboard/astro.config.mjs +6 -0
  116. package/src/dashboard/package-lock.json +5455 -0
  117. package/src/dashboard/package.json +14 -0
  118. package/src/dashboard/public/data/delegations.ndjson +35 -0
  119. package/src/dashboard/public/data/panels.ndjson +13 -0
  120. package/src/dashboard/public/data/sessions.ndjson +50 -0
  121. package/src/dashboard/public/icon-192.png +0 -0
  122. package/src/dashboard/scripts/generate-seed-data.ts +355 -0
  123. package/src/dashboard/src/layouts/Layout.astro +25 -0
  124. package/src/dashboard/src/pages/index.astro +1070 -0
  125. package/src/dashboard/src/styles/dashboard.css +1078 -0
  126. package/src/dashboard/tsconfig.json +6 -0
  127. package/src/orchestrator/agent-workflows/README.md +22 -0
  128. package/src/orchestrator/agent-workflows/bug-fix.md +128 -0
  129. package/src/orchestrator/agent-workflows/data-pipeline.md +145 -0
  130. package/src/orchestrator/agent-workflows/database-migration.md +159 -0
  131. package/src/orchestrator/agent-workflows/feature-implementation.md +223 -0
  132. package/src/orchestrator/agent-workflows/performance-optimization.md +125 -0
  133. package/src/orchestrator/agent-workflows/refactoring.md +142 -0
  134. package/src/orchestrator/agent-workflows/schema-changes.md +164 -0
  135. package/src/orchestrator/agent-workflows/security-audit.md +148 -0
  136. package/src/orchestrator/agent-workflows/shared-delivery-phase.md +33 -0
  137. package/src/orchestrator/agents/api-designer.agent.md +68 -0
  138. package/src/orchestrator/agents/architect.agent.md +129 -0
  139. package/src/orchestrator/agents/content-engineer.agent.md +57 -0
  140. package/src/orchestrator/agents/copywriter.agent.md +95 -0
  141. package/src/orchestrator/agents/data-expert.agent.md +63 -0
  142. package/src/orchestrator/agents/database-engineer.agent.md +62 -0
  143. package/src/orchestrator/agents/developer.agent.md +66 -0
  144. package/src/orchestrator/agents/devops-expert.agent.md +57 -0
  145. package/src/orchestrator/agents/documentation-writer.agent.md +60 -0
  146. package/src/orchestrator/agents/performance-expert.agent.md +58 -0
  147. package/src/orchestrator/agents/release-manager.agent.md +72 -0
  148. package/src/orchestrator/agents/researcher.agent.md +145 -0
  149. package/src/orchestrator/agents/reviewer.agent.md +62 -0
  150. package/src/orchestrator/agents/security-expert.agent.md +64 -0
  151. package/src/orchestrator/agents/seo-specialist.agent.md +67 -0
  152. package/src/orchestrator/agents/team-lead.agent.md +644 -0
  153. package/src/orchestrator/agents/testing-expert.agent.md +85 -0
  154. package/src/orchestrator/agents/ui-ux-expert.agent.md +63 -0
  155. package/src/orchestrator/copilot-instructions.md +3 -0
  156. package/src/orchestrator/customizations/AGENT-EXPERTISE.md +325 -0
  157. package/src/orchestrator/customizations/AGENT-FAILURES.md +69 -0
  158. package/src/orchestrator/customizations/AGENT-PERFORMANCE.md +58 -0
  159. package/src/orchestrator/customizations/DISPUTES.md +162 -0
  160. package/src/orchestrator/customizations/KNOWLEDGE-GRAPH.md +10 -0
  161. package/src/orchestrator/customizations/LESSONS-LEARNED.md +70 -0
  162. package/src/orchestrator/customizations/README.md +59 -0
  163. package/src/orchestrator/customizations/agents/agent-registry.md +46 -0
  164. package/src/orchestrator/customizations/agents/skill-matrix.md +142 -0
  165. package/src/orchestrator/customizations/logs/README.md +181 -0
  166. package/src/orchestrator/customizations/logs/delegations.ndjson +1 -0
  167. package/src/orchestrator/customizations/logs/panels.ndjson +1 -0
  168. package/src/orchestrator/customizations/logs/sessions.ndjson +1 -0
  169. package/src/orchestrator/customizations/project/docs-structure.md +23 -0
  170. package/src/orchestrator/customizations/project/tracker-config.md +45 -0
  171. package/src/orchestrator/customizations/project.instructions.md +64 -0
  172. package/src/orchestrator/customizations/stack/api-config.md +37 -0
  173. package/src/orchestrator/customizations/stack/cms-config.md +26 -0
  174. package/src/orchestrator/customizations/stack/data-pipeline-config.md +41 -0
  175. package/src/orchestrator/customizations/stack/database-config.md +44 -0
  176. package/src/orchestrator/customizations/stack/deployment-config.md +45 -0
  177. package/src/orchestrator/customizations/stack/testing-config.md +56 -0
  178. package/src/orchestrator/instructions/ai-optimization.instructions.md +143 -0
  179. package/src/orchestrator/instructions/general.instructions.md +194 -0
  180. package/src/orchestrator/mcp.json +55 -0
  181. package/src/orchestrator/prompts/bootstrap-customizations.prompt.md +235 -0
  182. package/src/orchestrator/prompts/brainstorm.prompt.md +115 -0
  183. package/src/orchestrator/prompts/bug-fix.prompt.md +141 -0
  184. package/src/orchestrator/prompts/create-skill.prompt.md +103 -0
  185. package/src/orchestrator/prompts/generate-task-spec.prompt.md +154 -0
  186. package/src/orchestrator/prompts/implement-feature.prompt.md +124 -0
  187. package/src/orchestrator/prompts/metrics-report.prompt.md +142 -0
  188. package/src/orchestrator/prompts/quick-refinement.prompt.md +137 -0
  189. package/src/orchestrator/prompts/resolve-pr-comments.prompt.md +100 -0
  190. package/src/orchestrator/skills/accessibility-standards/SKILL.md +164 -0
  191. package/src/orchestrator/skills/agent-hooks/SKILL.md +147 -0
  192. package/src/orchestrator/skills/agent-memory/SKILL.md +144 -0
  193. package/src/orchestrator/skills/api-patterns/SKILL.md +106 -0
  194. package/src/orchestrator/skills/browser-testing/SKILL.md +203 -0
  195. package/src/orchestrator/skills/code-commenting/SKILL.md +133 -0
  196. package/src/orchestrator/skills/contentful-cms/SKILL.md +43 -0
  197. package/src/orchestrator/skills/context-map/SKILL.md +135 -0
  198. package/src/orchestrator/skills/convex-database/SKILL.md +80 -0
  199. package/src/orchestrator/skills/data-engineering/SKILL.md +99 -0
  200. package/src/orchestrator/skills/deployment-infrastructure/SKILL.md +49 -0
  201. package/src/orchestrator/skills/documentation-standards/SKILL.md +85 -0
  202. package/src/orchestrator/skills/fast-review/SKILL.md +327 -0
  203. package/src/orchestrator/skills/frontend-design/SKILL.md +42 -0
  204. package/src/orchestrator/skills/jira-management/SKILL.md +168 -0
  205. package/src/orchestrator/skills/memory-merger/SKILL.md +123 -0
  206. package/src/orchestrator/skills/nextjs-patterns/SKILL.md +75 -0
  207. package/src/orchestrator/skills/nx-workspace/SKILL.md +192 -0
  208. package/src/orchestrator/skills/panel-majority-vote/SKILL.md +184 -0
  209. package/src/orchestrator/skills/panel-majority-vote/panel-report.template.md +38 -0
  210. package/src/orchestrator/skills/performance-optimization/SKILL.md +101 -0
  211. package/src/orchestrator/skills/react-development/SKILL.md +117 -0
  212. package/src/orchestrator/skills/sanity-cms/SKILL.md +18 -0
  213. package/src/orchestrator/skills/security-hardening/SKILL.md +118 -0
  214. package/src/orchestrator/skills/self-improvement/SKILL.md +137 -0
  215. package/src/orchestrator/skills/seo-patterns/SKILL.md +40 -0
  216. package/src/orchestrator/skills/session-checkpoints/SKILL.md +205 -0
  217. package/src/orchestrator/skills/slack-notifications/SKILL.md +211 -0
  218. package/src/orchestrator/skills/strapi-cms/SKILL.md +43 -0
  219. package/src/orchestrator/skills/supabase-database/SKILL.md +24 -0
  220. package/src/orchestrator/skills/task-management/SKILL.md +143 -0
  221. package/src/orchestrator/skills/team-lead-reference/SKILL.md +317 -0
  222. package/src/orchestrator/skills/teams-notifications/SKILL.md +249 -0
  223. package/src/orchestrator/skills/testing-workflow/SKILL.md +134 -0
  224. package/src/orchestrator/skills/validation-gates/SKILL.md +100 -0
@@ -0,0 +1,162 @@
1
+ ````markdown
2
+ # Dispute Records
3
+
4
+ Structured escalation records created when agents exhaust all automated resolution paths. Unlike the Dead Letter Queue (simple failure log), disputes are **formal action items for humans** — they package conflicting perspectives, prior attempts, and resolution options so a human can make an informed decision.
5
+
6
+ > **Review this file at the start of each session.** Pending disputes may block downstream work and need human input before proceeding.
7
+
8
+ ---
9
+
10
+ ## When to Create a Dispute
11
+
12
+ Create a dispute record when **any** of these occur:
13
+
14
+ | Trigger | Typical Path |
15
+ |---------|-------------|
16
+ | Panel review BLOCKs 3 times | Fast review 3x FAIL → Panel → Panel 3x BLOCK → **Dispute** |
17
+ | Agent and reviewer fundamentally disagree on approach | Agent retries with reviewer feedback but keeps failing because the feedback conflicts with other constraints → **Dispute** |
18
+ | Conflicting acceptance criteria | Reviewer flags an issue, but fixing it would violate another acceptance criterion → **Dispute** |
19
+ | Architectural ambiguity | Multiple valid approaches exist, automated agents can't converge → **Dispute** |
20
+ | External dependency blocks resolution | Fix requires upstream library change, API access, or infrastructure action → **Dispute** |
21
+
22
+ **Do NOT create a dispute for:**
23
+ - Simple tool errors (MCP server down, build timeout) → use the DLQ
24
+ - Scope creep → use the DLQ with a redirect
25
+ - First or second failure → retry automatically
26
+
27
+ ## Dispute Record Format
28
+
29
+ ```markdown
30
+ ### DSP-XXX: Short description of the disagreement
31
+
32
+ | Field | Value |
33
+ |-------|-------|
34
+ | **Date** | YYYY-MM-DD |
35
+ | **Priority** | `critical` / `high` / `medium` / `low` |
36
+ | **Linear Issue** | PRJ-XX |
37
+ | **Trigger** | `panel-3x-block` / `approach-conflict` / `criteria-conflict` / `architectural-ambiguity` / `external-dependency` |
38
+ | **Implementing Agent** | Agent name |
39
+ | **Reviewing Agent(s)** | Agent name(s) |
40
+ | **Attempts** | Total attempts (fast review + panel) |
41
+ | **Est. Tokens Spent** | ~XXK across all attempts |
42
+ | **Status** | `pending` / `resolved` / `deferred` |
43
+
44
+ #### Context
45
+
46
+ Brief description of the task and what was being implemented.
47
+
48
+ #### Agent's Position
49
+
50
+ What the implementing agent produced and why it believes the approach is correct.
51
+ Include specific file paths and code references.
52
+
53
+ #### Reviewer's Position
54
+
55
+ What the reviewer(s) flagged and why they believe changes are needed.
56
+ Include the specific MUST-FIX items from the last review attempt.
57
+
58
+ #### Attempt History
59
+
60
+ | # | Type | Verdict | Key Feedback |
61
+ |---|------|---------|-------------|
62
+ | 1 | Fast review | FAIL | [one-line summary] |
63
+ | 2 | Fast review | FAIL | [one-line summary] |
64
+ | 3 | Fast review | FAIL → escalate | [one-line summary] |
65
+ | 4 | Panel (attempt 1) | BLOCK (1/3 PASS) | [one-line summary] |
66
+ | 5 | Panel (attempt 2) | BLOCK (0/3 PASS) | [one-line summary] |
67
+ | 6 | Panel (attempt 3) | BLOCK (1/3 PASS) | [one-line summary] |
68
+
69
+ #### Resolution Options
70
+
71
+ Present 2-3 concrete options for the human decision-maker:
72
+
73
+ 1. **Option A: [Accept agent's approach]** — Rationale: ... Risk: ...
74
+ 2. **Option B: [Accept reviewer's feedback]** — Rationale: ... Risk: ...
75
+ 3. **Option C: [Alternative approach]** — Rationale: ... Risk: ...
76
+
77
+ #### Recommended Action
78
+
79
+ Which option the Team Lead recommends and why. Include specific next steps:
80
+ - [ ] Human decides on option A/B/C
81
+ - [ ] If A: merge as-is, create follow-up ticket for reviewer concerns
82
+ - [ ] If B: re-delegate with explicit instruction to [specific change]
83
+ - [ ] If C: [describe the alternative path]
84
+
85
+ #### Artifacts
86
+
87
+ Links to evidence for human review:
88
+ - Panel report: `customizations/logs/panel/[panel-key].md`
89
+ - Review log entries: `customizations/logs/reviews.ndjson` (filter by issue)
90
+ - Changed files: [list of files in the last attempt]
91
+ - DLQ entry (if any): `DLQ-XXX`
92
+ ```
93
+
94
+ ## Priority Guidelines
95
+
96
+ | Priority | Criteria | Expected Human Response Time |
97
+ |----------|----------|------------------------------|
98
+ | `critical` | Blocks other in-progress work; overnight run stopped | Same day |
99
+ | `high` | Blocks the current feature; no workaround | Within 2 days |
100
+ | `medium` | Feature can proceed without this subtask | Within 1 week |
101
+ | `low` | Nice-to-have; deferrable | Next planning session |
102
+
103
+ ## Lifecycle
104
+
105
+ ```
106
+ ┌──────────────────────────────────────┐
107
+ │ Automated resolution exhausted │
108
+ │ (3x panel BLOCK or approach conflict)│
109
+ └──────────────┬───────────────────────┘
110
+
111
+
112
+ ┌──────────────────────────────────────┐
113
+ │ Team Lead creates dispute record │
114
+ │ Status: pending │
115
+ │ Logs to disputes.ndjson │
116
+ │ Links to Linear issue │
117
+ └──────────────┬───────────────────────┘
118
+
119
+
120
+ ┌──────────────────────────────────────┐
121
+ │ Human reviews dispute │
122
+ │ Picks resolution option │
123
+ │ Updates Status → resolved/deferred │
124
+ └──────────────┬───────────────────────┘
125
+
126
+ ┌─────────┴──────────┐
127
+ ▼ ▼
128
+ resolved deferred
129
+ (re-delegate (create follow-up
130
+ with human's ticket, continue
131
+ decision) with other work)
132
+ ```
133
+
134
+ ## Integration with DLQ
135
+
136
+ Disputes and DLQ entries serve different purposes:
137
+
138
+ | | Dead Letter Queue | Dispute Record |
139
+ |--|-------------------|----------------|
140
+ | **Purpose** | Diagnostic failure log | Actionable human decision |
141
+ | **When** | Tool errors, timeouts, simple failures | Unresolvable agent/reviewer conflicts |
142
+ | **Action** | Retry or investigate root cause | Human picks a resolution option |
143
+ | **Urgency** | Can wait for pattern analysis | Needs human input to unblock |
144
+ | **File** | `AGENT-FAILURES.md` | `DISPUTES.md` (this file) |
145
+
146
+ A dispute MAY reference a DLQ entry if the dispute escalated from a logged failure. Use the `DLQ-XXX` ID in the Artifacts section.
147
+
148
+ ---
149
+
150
+ ## Disputes
151
+
152
+ <!-- Disputes are appended here by the Team Lead during sessions.
153
+ Start numbering from DSP-001. -->
154
+
155
+ ---
156
+
157
+ ## Index
158
+
159
+ | ID | Date | Priority | Trigger | Linear Issue | Status |
160
+ |----|------|----------|---------|-------------|--------|
161
+
162
+ ````
@@ -0,0 +1,10 @@
1
+ # Knowledge Graph
2
+
3
+ <!-- Append-only relationship log capturing structured connections between files, agents, patterns, decisions, bugs, and lessons.
4
+ Used by the Team Lead to discover file dependencies, match agents to tasks, and surface relevant context during delegation.
5
+ See the agent-memory skill for the full protocol, entity types, and relationship types. -->
6
+
7
+ ## Relationships
8
+
9
+ | Source | Relationship | Target | Added | Context |
10
+ |--------|-------------|--------|-------|---------|
@@ -0,0 +1,70 @@
1
+ ````markdown
2
+ # Lessons Learned
3
+
4
+ Structured log of tool/command pitfalls, workarounds, and correct approaches discovered through agent execution. **Every agent** must read this file before starting work and must add entries when they discover a new pitfall through trial-and-error.
5
+
6
+ > **This file is the collective memory of the agent team.** It prevents repeating the same mistakes across sessions.
7
+
8
+ ---
9
+
10
+ ## How to Use This File
11
+
12
+ ### Before starting work
13
+
14
+ 1. Read the **entire file** (or at minimum, the sections relevant to your task)
15
+ 2. Apply any relevant lessons to your approach **before** attempting commands or tool calls
16
+
17
+ ### When to add a new entry
18
+
19
+ Add a lesson when **any** of these occur:
20
+ - A command, tool call, or API call fails and you had to retry with a different approach
21
+ - You discover a parameter, syntax, or configuration quirk not documented elsewhere
22
+ - A workaround is needed for a third-party tool, MCP server, or platform limitation
23
+ - An approach that seems obvious turns out to be wrong
24
+
25
+ ### Entry format
26
+
27
+ ```markdown
28
+ ### LES-XXX: Short descriptive title
29
+
30
+ | Field | Value |
31
+ |-------|-------|
32
+ | **Category** | `linear` / `mcp-tools` / `nx-commands` / `terminal` / `next-js` / `sanity` / `supabase` / `git` / `vercel` / `browser-testing` / `general` |
33
+ | **Added** | YYYY-MM-DD |
34
+ | **Severity** | `high` (blocks work) / `medium` (wastes 5+ min) / `low` (minor annoyance) |
35
+
36
+ **Problem:** What went wrong and what error or unexpected behavior was observed.
37
+
38
+ **Wrong approach:** The obvious/intuitive approach that fails.
39
+
40
+ **Correct approach:** The working solution.
41
+
42
+ **Why:** Root cause explanation (if known).
43
+ ```
44
+
45
+ ---
46
+
47
+ ## Lessons
48
+
49
+ <!-- Lessons are appended here by agents during sessions.
50
+ Start numbering from LES-001. -->
51
+
52
+ ---
53
+
54
+ ## Index by Category
55
+
56
+ | Category | Lessons |
57
+ |----------|---------|
58
+ | `linear` | — |
59
+ | `mcp-tools` | — |
60
+ | `nx-commands` | — |
61
+ | `terminal` | — |
62
+ | `next-js` | — |
63
+ | `sanity` | — |
64
+ | `supabase` | — |
65
+ | `git` | — |
66
+ | `vercel` | — |
67
+ | `browser-testing` | — |
68
+ | `general` | — |
69
+
70
+ ````
@@ -0,0 +1,59 @@
1
+ # Customizations
2
+
3
+ Project-specific configuration for the AI agent framework. Everything in this folder is **particular to this project** — the rest of the orchestrator directory (instructions, skills, agents, prompts, workflows) is designed to be project-agnostic and reusable across repositories.
4
+
5
+ ## Why this exists
6
+
7
+ Skills and instructions contain generic methodology (how to write migrations, how to test in a browser, how to run a panel review). This folder holds the concrete values those skills operate on — project IDs, table schemas, team UUIDs, endpoint inventories, and similar configuration that changes per project.
8
+
9
+ Skills reference these files with relative links like `../../customizations/stack/api-config.md`, so agents automatically load project context when they load a skill.
10
+
11
+ ## Contents
12
+
13
+ | File | Purpose |
14
+ |------|---------|
15
+ | `project.instructions.md` | High-level project context — apps, libraries, tech stack, ports, URLs |
16
+ | `LESSONS-LEARNED.md` | Knowledge base of retries, workarounds, and gotchas — read before every session |
17
+ | `AGENT-FAILURES.md` | Dead letter queue for failed agent delegations |
18
+ | `AGENT-PERFORMANCE.md` | Agent success tracking, log query recipes, performance metrics |
19
+ | `AGENT-EXPERTISE.md` | Structured tracking of agent strengths/weaknesses across sessions |
20
+ | `KNOWLEDGE-GRAPH.md` | Append-only relationship log for file dependencies, patterns, decisions |
21
+
22
+ ### `agents/` — Agent framework config
23
+
24
+ | File | Purpose |
25
+ |------|---------|
26
+ | `agent-registry.md` | Specialist agents with model tier assignments and scope examples |
27
+ | `skill-matrix.md` | Maps capability slots to concrete skill names per agent role |
28
+
29
+ ### `stack/` — Tech stack config
30
+
31
+ | File | Purpose |
32
+ |------|---------|
33
+ | _(created by `bootstrap-customizations` prompt based on detected technologies)_ | |
34
+
35
+ ### `project/` — Project management config
36
+
37
+ | File | Purpose |
38
+ |------|---------|
39
+ | `docs-structure.md` | `docs/` directory tree and documentation practices |
40
+ | _(task tracker config created by `bootstrap-customizations` prompt)_ | |
41
+
42
+ ### `logs/` — Append-only NDJSON session logs
43
+
44
+ Structured machine-readable logs appended automatically by agents during sessions, delegations, and panel reviews.
45
+
46
+ | File | Purpose |
47
+ |------|---------|
48
+ | `README.md` | Schema documentation for the NDJSON log files |
49
+ | `sessions.ndjson` | Structured session log entries |
50
+ | `delegations.ndjson` | Structured delegation log entries |
51
+ | `panels.ndjson` | Structured panel review log entries |
52
+
53
+ ## When to update
54
+
55
+ Update these files when the project changes — new tables, new API routes, new apps, new Linear labels, etc. The skills themselves should rarely need editing; changing a project ID or adding a table column is a customization change, not a skill change.
56
+
57
+ ## Bootstrap
58
+
59
+ Run the `bootstrap-customizations` prompt to auto-discover the project's structure and populate these files. It will scan for frameworks, databases, CMS, deployment config, and task tracking, then generate the appropriate `stack/` and `project/` files.
@@ -0,0 +1,46 @@
1
+ ````markdown
2
+ # Agent Registry
3
+
4
+ Project-specific agent-to-model assignments and scope examples referenced by the `team-lead-reference` skill.
5
+
6
+ <!-- Populated by the `bootstrap-customizations` prompt based on project structure. -->
7
+
8
+ ## Specialist Agent Registry
9
+
10
+ | Agent | Model | Tier | Best For |
11
+ |-------|-------|------|----------|
12
+ | **Developer** | Gemini 3.1 Pro | Standard | Full-stack feature implementation, pages, components, routing, API routes |
13
+ | **Testing Expert** | GPT-5.3-Codex | Utility | E2E tests, browser validation, terminal-heavy test loops |
14
+ | **Content Engineer** | Gemini 3.1 Pro | Standard | CMS schema, GROQ queries, MCP tool coordination |
15
+ | **Database Engineer** | Gemini 3.1 Pro | Standard | Migrations, RLS policies, SQL optimization |
16
+ | **UI/UX Expert** | Gemini 3.1 Pro | Standard | Components, styling, accessibility |
17
+ | **Performance Expert** | Gemini 3.1 Pro | Standard | Bundle size, Core Web Vitals, profiling |
18
+ | **Security Expert** | Claude Opus 4.6 | Premium | Auth, RLS audits, headers, precision analysis |
19
+ | **Data Expert** | GPT-5.3-Codex | Utility | ETL pipelines, scrapers, terminal-heavy data import |
20
+ | **DevOps Expert** | GPT-5.3-Codex | Utility | Deployments, cron jobs, terminal-heavy infrastructure |
21
+ | **Documentation Writer** | GPT-5 mini | Economy | Docs, roadmaps, ADRs (cost-effective) |
22
+ | **Architect** | Claude Opus 4.6 | Premium | Architecture decisions, critical review, expert reasoning |
23
+ | **Reviewer** | GPT-5 mini | Economy | Mandatory fast review after every delegation, code correctness checks |
24
+ | **Researcher** | GPT-5 mini | Economy | Codebase exploration, pattern discovery, git archaeology, pre-implementation research |
25
+ | **Copywriter** | GPT-5 mini | Economy | UI microcopy, marketing text, email templates |
26
+ | **SEO Specialist** | GPT-5 mini | Economy | Meta tags, structured data, sitemaps |
27
+ | **API Designer** | Gemini 3.1 Pro | Standard | API route architecture, endpoint conventions |
28
+ | **Release Manager** | GPT-5.3-Codex | Utility | Pre-release verification, changelog generation |
29
+
30
+ ## Deepen-Plan Scope Examples
31
+
32
+ <!-- Customize these paths to match your project structure.
33
+ When running the Deepen-Plan protocol, split research by domain: -->
34
+
35
+ ```
36
+ Researcher A: "Research database/backend aspects of [feature]"
37
+ Scope: <database-migrations-dir>/, <server-libs>/
38
+
39
+ Researcher B: "Research frontend/UI aspects of [feature]"
40
+ Scope: <ui-libs>/, <app-dir>/
41
+
42
+ Researcher C: "Research CMS/content aspects of [feature]"
43
+ Scope: <cms-dir>/, <queries-lib>/
44
+ ```
45
+
46
+ ````
@@ -0,0 +1,142 @@
1
+ ````markdown
2
+ # Skill Matrix
3
+
4
+ Maps abstract technology capabilities to concrete skill implementations. Agents reference **capability slots** instead of hardcoded technology skills — when the stack changes, update the bindings here and all agents automatically resolve to the correct skill.
5
+
6
+ **Process/methodology skills** (session checkpoints, validation gates, self-improvement, etc.) are referenced directly in agent files — they don't go through the matrix.
7
+
8
+ ## How It Works
9
+
10
+ ```
11
+ Agent file Skill Matrix Skill file
12
+ ┌──────────────┐ ┌──────────────┐ ┌──────────────┐
13
+ │ Developer │ │ framework: │ │ nextjs- │
14
+ │ needs: │──lookup──▶│ nextjs │──load────▶│ patterns │
15
+ │ framework │ │ │ │ │
16
+ │ ui-library │ │ ui-library: │ │ react- │
17
+ │ api-layer │ │ react │──load────▶│ development │
18
+ │ │ │ │ │ │
19
+ │ │ │ api-layer: │ │ api- │
20
+ │ │ │ nextjs-api │──load────▶│ patterns │
21
+ │ │ │ │ │ │
22
+ └──────────────┘ └──────────────┘ └──────────────┘
23
+ ```
24
+
25
+ 1. **Agents** declare which capability slots they need (e.g., `framework`, `database`)
26
+ 2. **This matrix** maps each slot to the current technology and its skill file
27
+ 3. **When delegating**, resolve slots through this matrix to load the correct skill
28
+ 4. **To switch tech**, update only the binding row — no agent files change
29
+
30
+ ## Stack Bindings
31
+
32
+ <!-- Populated by the `bootstrap-customizations` prompt based on detected technologies. -->
33
+
34
+ ### Primary Stack
35
+
36
+ | Slot | Technology | Skill | Description |
37
+ |------|-----------|-------|-------------|
38
+ | `language` | | _(general.instructions.md)_ | Primary programming language, type system |
39
+ | `ui-library` | | | Component architecture, hooks, state, styling |
40
+ | `framework` | | | SSR/SSG, routing, layouts, Server/Client Components |
41
+ | `database` | | | Schema, migrations, auth flow, roles |
42
+ | `cms` | | | Document types, queries, schema management |
43
+ | `deployment` | | | Hosting, cron jobs, env vars, caching, headers |
44
+ | `monorepo` | | | Task running, caching, affected commands, generators |
45
+
46
+ ### Tooling
47
+
48
+ | Slot | Technology | Skill | Description |
49
+ |------|-----------|-------|-------------|
50
+ | `api-layer` | | | API routes, validation, search architecture |
51
+ | `data-pipeline` | | | ETL, scraping, data processing |
52
+ | `testing` | | | Unit/integration tests, coverage, test planning |
53
+ | `e2e-testing` | | | Browser automation, viewport testing, visual validation |
54
+
55
+ ### Disciplines
56
+
57
+ | Slot | Approach | Skill | Description |
58
+ |------|---------|-------|-------------|
59
+ | `performance` | | `performance-optimization` | Bundle size, rendering, caching, profiling |
60
+ | `security` | | `security-hardening` | Auth, headers, input validation, vulnerability mgmt |
61
+ | `accessibility` | WCAG 2.2 Level AA | `accessibility-standards` | Keyboard nav, screen readers, contrast, semantics |
62
+ | `design-system` | | `frontend-design` | Design thinking, typography, color, motion, layout |
63
+ | `seo` | | `seo-patterns` | Technical SEO patterns for meta tags, JSON-LD, sitemaps, URL strategy |
64
+
65
+ ## Agent Capability Matrix
66
+
67
+ Each row shows which capability slots an agent needs (resolved through this matrix) and which process skills it uses directly.
68
+
69
+ | Agent | Capability Slots | Direct Skills |
70
+ |-------|-----------------|---------------|
71
+ | **Developer** | `framework`, `ui-library`, `api-layer` | `validation-gates` |
72
+ | **Database Engineer** | `database`, `security` | — |
73
+ | **UI/UX Expert** | `design-system`, `ui-library`, `accessibility` | `e2e-testing`¹ |
74
+ | **Content Engineer** | `cms` | — |
75
+ | **Testing Expert** | `e2e-testing`, `testing` | `validation-gates` |
76
+ | **Security Expert** | `security`, `database` | — |
77
+ | **Data Expert** | `data-pipeline` | — |
78
+ | **DevOps Expert** | `deployment` | — |
79
+ | **Performance Expert** | `performance` | — |
80
+ | **Architect** | `monorepo` | `documentation-standards` |
81
+ | **Copywriter** | `cms` | `documentation-standards` |
82
+ | **SEO Specialist** | `framework`, `cms`, `seo` | — |
83
+ | **API Designer** | `api-layer`, `framework`, `security` | — |
84
+ | **Release Manager** | `monorepo`, `deployment` | `validation-gates`, `documentation-standards` |
85
+ | **Documentation Writer** | — | `documentation-standards`, `code-commenting` |
86
+ | **Researcher** | — | `context-map`, `self-improvement` |
87
+ | **Team Lead** | — | `team-lead-reference`, `task-management`, `session-checkpoints`, `validation-gates`, `fast-review`, `panel-majority-vote`, `context-map`, `memory-merger`, `agent-hooks` |
88
+
89
+ ¹ UI/UX Expert uses `e2e-testing` as a utility (viewport resize commands) — resolved through the matrix like other slots.
90
+
91
+ ## Process Skills (Always Direct)
92
+
93
+ These are methodology/workflow skills — not tied to any technology. Referenced directly in agent files, never through capability slots.
94
+
95
+ | Skill | Purpose |
96
+ |-------|---------|
97
+ | `self-improvement` | Lessons-learned protocol, retry documentation |
98
+ | `session-checkpoints` | Session state saving, resuming, forking |
99
+ | `context-map` | File impact mapping before complex changes |
100
+ | `panel-majority-vote` | 3-reviewer quality gate (PASS/BLOCK) |
101
+ | `memory-merger` | Graduate lessons into permanent skills/instructions |
102
+ | `code-commenting` | Self-documenting code patterns, annotation tags |
103
+ | `agent-hooks` | Agent lifecycle hooks (session-start, session-end, etc.) |
104
+ | `agent-memory` | Agent expertise tracking, cross-session knowledge graph |
105
+ | `task-management` | Linear board conventions, issue naming, priorities |
106
+ | `team-lead-reference` | Team Lead orchestration reference, model routing |
107
+ | `fast-review` | Mandatory single-reviewer gate after every delegation |
108
+ | `validation-gates` | Shared validation gate definitions (lint, test, build) |
109
+ | `documentation-standards` | Documentation templates, formatting rules |
110
+
111
+ ## Switching Technologies
112
+
113
+ ### Example: Supabase → Convex
114
+
115
+ 1. Create a new skill: `skills/convex-database/SKILL.md`
116
+ 2. Update this matrix: `database` row → Technology: `Convex`, Skill: `convex-database`
117
+ 3. Update `project.instructions.md` to reflect the new tech stack
118
+ 4. **No agent files change** — Database Engineer, Security Expert still reference the `database` slot
119
+
120
+ ### Example: React → Svelte + Next.js → SvelteKit
121
+
122
+ 1. Create skills: `skills/svelte-development/SKILL.md`, `skills/sveltekit-patterns/SKILL.md`
123
+ 2. Update matrix: `ui-library` → `Svelte` / `svelte-development`
124
+ 3. Update matrix: `framework` → `SvelteKit` / `sveltekit-patterns`
125
+ 4. Update `project.instructions.md` and `general.instructions.md`
126
+ 5. **No agent files change** — Developer, UI/UX Expert still reference `framework` and `ui-library` slots
127
+
128
+ ### Example: Jest → Vitest
129
+
130
+ 1. Create skill: `skills/vitest-workflow/SKILL.md`
131
+ 2. Update matrix: `testing` → `Vitest` / `vitest-workflow`
132
+ 3. **No agent files change** — Testing Expert still references the `testing` slot
133
+
134
+ ## Design Principles
135
+
136
+ 1. **Single source of truth** — Technology choices live here, not scattered across agent files
137
+ 2. **Agents are stack-agnostic** — They describe *what* they need, not *which* tool they use
138
+ 3. **Swap without rewriting** — Changing one matrix row updates every agent that uses that slot
139
+ 4. **Process skills are stable** — Methodology doesn't change with technology; direct references are fine
140
+ 5. **Capability slots are composable** — Agents can combine any slots (e.g., Security Expert needs both `security` + `database`)
141
+
142
+ ````
@@ -0,0 +1,181 @@
1
+ # Agent Session Logs
2
+
3
+ Append-only NDJSON logs for agent activity tracking. Each file stores one JSON object per line.
4
+
5
+ ## Files
6
+
7
+ | File | Appended by | Schema |
8
+ |------|------------|--------|
9
+ | `sessions.ndjson` | All agents (via self-improvement protocol) | Session record |
10
+ | `delegations.ndjson` | Team Lead agent | Delegation record |
11
+ | `reviews.ndjson` | Team Lead (via fast-review skill) | Fast review record |
12
+ | `panels.ndjson` | Panel runner (via panel majority vote skill) | Panel record |
13
+ | `disputes.ndjson` | Team Lead (via dispute protocol) | Dispute record |
14
+
15
+ ## Session Record Schema
16
+
17
+ ```json
18
+ {
19
+ "timestamp": "2026-02-25T14:30:00Z",
20
+ "agent": "Developer",
21
+ "model": "gpt-5.3-codex",
22
+ "task": "PRJ-57: Fix header component",
23
+ "linear_issue": "PRJ-57",
24
+ "outcome": "success",
25
+ "duration_min": 12,
26
+ "files_changed": 5,
27
+ "retries": 0,
28
+ "lessons_added": [],
29
+ "discoveries": []
30
+ }
31
+ ```
32
+
33
+ | Field | Type | Required | Description |
34
+ |-------|------|----------|-------------|
35
+ | `timestamp` | `string` | Yes | ISO 8601 datetime (YYYY-MM-DDTHH:MM:SSZ) |
36
+ | `agent` | `string` | Yes | Agent name from the registry |
37
+ | `model` | `string` | Yes | Model used (e.g., `claude-opus-4-6`, `gpt-5.3-codex`) |
38
+ | `task` | `string` | Yes | Short description of the task performed |
39
+ | `linear_issue` | `string` | No | Issue ID if applicable (e.g., `PRJ-57`) |
40
+ | `outcome` | `string` | Yes | `success`, `partial`, `failed` |
41
+ | `duration_min` | `number` | No | Estimated session duration in minutes |
42
+ | `files_changed` | `number` | No | Number of files created/modified |
43
+ | `retries` | `number` | No | Number of retried operations |
44
+ | `lessons_added` | `string[]` | No | Lesson IDs added (e.g., `["LES-015"]`) |
45
+ | `discoveries` | `string[]` | No | Issues discovered (issue IDs or KNOWN-ISSUES IDs) |
46
+
47
+ ## Delegation Record Schema
48
+
49
+ ```json
50
+ {
51
+ "timestamp": "2026-02-25T14:30:00Z",
52
+ "session_id": "feat/prj-57",
53
+ "agent": "Developer",
54
+ "model": "gpt-5.3-codex",
55
+ "tier": "fast",
56
+ "mechanism": "sub-agent",
57
+ "linear_issue": "PRJ-57",
58
+ "outcome": "success",
59
+ "retries": 0,
60
+ "phase": 2,
61
+ "file_partition": ["src/components/", "src/pages/"]
62
+ }
63
+ ```
64
+
65
+ | Field | Type | Required | Description |
66
+ |-------|------|----------|-------------|
67
+ | `timestamp` | `string` | Yes | ISO 8601 datetime (YYYY-MM-DDTHH:MM:SSZ) |
68
+ | `session_id` | `string` | Yes | Branch name or feature identifier |
69
+ | `agent` | `string` | Yes | Agent name delegated to |
70
+ | `model` | `string` | Yes | Model used |
71
+ | `tier` | `string` | Yes | `economy`, `fast`, `standard`, `premium` |
72
+ | `mechanism` | `string` | Yes | `sub-agent` or `background` |
73
+ | `linear_issue` | `string` | No | Issue ID |
74
+ | `outcome` | `string` | Yes | `success`, `partial`, `failed`, `redirected` |
75
+ | `retries` | `number` | No | Times re-delegated |
76
+ | `phase` | `number` | No | Execution phase number |
77
+ | `file_partition` | `string[]` | No | Directories/files assigned |
78
+
79
+ ## Fast Review Record Schema
80
+
81
+ ```json
82
+ {
83
+ "timestamp": "2026-02-28T14:30:00Z",
84
+ "linear_issue": "PRJ-42",
85
+ "agent": "Developer",
86
+ "reviewer_model": "gpt-5-mini",
87
+ "verdict": "pass",
88
+ "attempt": 1,
89
+ "issues_critical": 0,
90
+ "issues_major": 0,
91
+ "issues_minor": 2,
92
+ "confidence": "high",
93
+ "escalated": false,
94
+ "duration_sec": 45
95
+ }
96
+ ```
97
+
98
+ | Field | Type | Required | Description |
99
+ |-------|------|----------|-------------|
100
+ | `timestamp` | `string` | Yes | ISO 8601 datetime (YYYY-MM-DDTHH:MM:SSZ) |
101
+ | `linear_issue` | `string` | No | Issue ID if applicable |
102
+ | `agent` | `string` | Yes | Agent whose output was reviewed |
103
+ | `reviewer_model` | `string` | Yes | Model used for the reviewer (e.g., `gpt-5-mini`) |
104
+ | `verdict` | `string` | Yes | `pass` or `fail` |
105
+ | `attempt` | `number` | Yes | Review attempt number (1, 2, or 3) |
106
+ | `issues_critical` | `number` | Yes | Count of critical severity issues |
107
+ | `issues_major` | `number` | Yes | Count of major severity issues |
108
+ | `issues_minor` | `number` | Yes | Count of minor severity issues |
109
+ | `confidence` | `string` | Yes | Reviewer self-reported confidence: `low`, `medium`, `high` |
110
+ | `escalated` | `boolean` | Yes | Whether this review triggered escalation to panel |
111
+ | `duration_sec` | `number` | No | Review duration in seconds |
112
+
113
+ ## Panel Record Schema
114
+
115
+ ```json
116
+ {
117
+ "timestamp": "2026-02-25T14:30:00Z",
118
+ "panel_key": "instruction-refactoring",
119
+ "verdict": "pass",
120
+ "pass_count": 3,
121
+ "block_count": 0,
122
+ "must_fix": 0,
123
+ "should_fix": 5,
124
+ "reviewer_model": "claude-opus-4-6",
125
+ "weighted": false,
126
+ "attempt": 1,
127
+ "linear_issue": "PRJ-57",
128
+ "artifacts_count": 14,
129
+ "report_path": "customizations/logs/panel/instruction-refactoring.md"
130
+ }
131
+ ```
132
+
133
+ | Field | Type | Required | Description |
134
+ |-------|------|----------|-------------|
135
+ | `timestamp` | `string` | Yes | ISO 8601 datetime (YYYY-MM-DDTHH:MM:SSZ) |
136
+ | `panel_key` | `string` | Yes | Filesystem-safe panel identifier |
137
+ | `verdict` | `string` | Yes | `pass` or `block` |
138
+ | `pass_count` | `number` | Yes | Number of reviewers who voted PASS |
139
+ | `block_count` | `number` | Yes | Number of reviewers who voted BLOCK |
140
+ | `must_fix` | `number` | Yes | Total MUST-FIX items across all reviewers |
141
+ | `should_fix` | `number` | Yes | Total SHOULD-FIX items across all reviewers |
142
+ | `reviewer_model` | `string` | Yes | Model used for reviewers |
143
+ | `weighted` | `boolean` | Yes | Whether performance-weighted voting was applied |
144
+ | `attempt` | `number` | Yes | Attempt number (1 = first try) |
145
+ | `linear_issue` | `string` | No | Issue ID if applicable |
146
+ | `artifacts_count` | `number` | No | Number of artifacts reviewed |
147
+ | `report_path` | `string` | No | Path to the full panel report |
148
+
149
+ ## Dispute Record Schema
150
+
151
+ ```json
152
+ {
153
+ "timestamp": "2026-02-28T16:00:00Z",
154
+ "dispute_id": "DSP-001",
155
+ "linear_issue": "PRJ-42",
156
+ "priority": "high",
157
+ "trigger": "panel-3x-block",
158
+ "implementing_agent": "Developer",
159
+ "reviewing_agents": ["Reviewer", "Panel (3x)"],
160
+ "total_attempts": 6,
161
+ "est_tokens_spent": 120000,
162
+ "status": "pending",
163
+ "resolution_option_chosen": null,
164
+ "resolved_at": null
165
+ }
166
+ ```
167
+
168
+ | Field | Type | Required | Description |
169
+ |-------|------|----------|-------------|
170
+ | `timestamp` | `string` | Yes | ISO 8601 datetime when dispute was created |
171
+ | `dispute_id` | `string` | Yes | Dispute ID (e.g., `DSP-001`) |
172
+ | `linear_issue` | `string` | No | Issue ID if applicable |
173
+ | `priority` | `string` | Yes | `critical`, `high`, `medium`, `low` |
174
+ | `trigger` | `string` | Yes | `panel-3x-block`, `approach-conflict`, `criteria-conflict`, `architectural-ambiguity`, `external-dependency` |
175
+ | `implementing_agent` | `string` | Yes | Agent that attempted the implementation |
176
+ | `reviewing_agents` | `string[]` | Yes | Agents that reviewed (e.g., `["Reviewer", "Panel (3x)"]`) |
177
+ | `total_attempts` | `number` | Yes | Sum of fast review + panel attempts |
178
+ | `est_tokens_spent` | `number` | No | Estimated tokens spent across all attempts |
179
+ | `status` | `string` | Yes | `pending`, `resolved`, `deferred` |
180
+ | `resolution_option_chosen` | `string` | No | Which option the human chose (null if pending) |
181
+ | `resolved_at` | `string` | No | ISO 8601 datetime when resolved (null if pending) |