@dotdotgod/opencode 0.0.0-stage → 0.6.6

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 (52) hide show
  1. package/LICENSE +94 -0
  2. package/README.md +84 -2
  3. package/commands/impact.md +26 -0
  4. package/commands/init.md +38 -0
  5. package/commands/load.md +28 -0
  6. package/index.js +1 -0
  7. package/mcp/cli.mjs +7017 -0
  8. package/mcp/impact-state.mjs +133 -0
  9. package/mcp/parsers/IGNORE_LICENSE +21 -0
  10. package/mcp/parsers/LICENSE +21 -0
  11. package/mcp/parsers/TYPESCRIPT_LICENSE +21 -0
  12. package/mcp/parsers/tree-sitter-bash.wasm +0 -0
  13. package/mcp/parsers/tree-sitter-c-sharp.wasm +0 -0
  14. package/mcp/parsers/tree-sitter-cpp.wasm +0 -0
  15. package/mcp/parsers/tree-sitter-css.wasm +0 -0
  16. package/mcp/parsers/tree-sitter-go.wasm +0 -0
  17. package/mcp/parsers/tree-sitter-ini.wasm +0 -0
  18. package/mcp/parsers/tree-sitter-java.wasm +0 -0
  19. package/mcp/parsers/tree-sitter-javascript.wasm +0 -0
  20. package/mcp/parsers/tree-sitter-php.wasm +0 -0
  21. package/mcp/parsers/tree-sitter-powershell.wasm +0 -0
  22. package/mcp/parsers/tree-sitter-python.wasm +0 -0
  23. package/mcp/parsers/tree-sitter-regex.wasm +0 -0
  24. package/mcp/parsers/tree-sitter-ruby.wasm +0 -0
  25. package/mcp/parsers/tree-sitter-rust.wasm +0 -0
  26. package/mcp/parsers/tree-sitter-tsx.wasm +0 -0
  27. package/mcp/parsers/tree-sitter-typescript.wasm +0 -0
  28. package/mcp/parsers/tree-sitter.cjs +4075 -0
  29. package/mcp/parsers/tree-sitter.wasm +0 -0
  30. package/mcp/server.mjs +23716 -0
  31. package/package.json +41 -3
  32. package/server.js +1 -0
  33. package/skills/doc-first-planning/SKILL.md +30 -0
  34. package/skills/document-clarify/SKILL.md +41 -0
  35. package/skills/impact-review/SKILL.md +25 -0
  36. package/skills/project-initializer/SKILL.md +37 -0
  37. package/skills/project-initializer/references/agent-docs.md +42 -0
  38. package/skills/project-initializer/scripts/init_project.sh +525 -0
  39. package/skills/project-initializer/templates/case-and-evidence.json +219 -0
  40. package/skills/project-initializer/templates/dotdotgod.config.json +234 -0
  41. package/skills/project-initializer/templates/policy.json +241 -0
  42. package/skills/project-initializer/templates/portfolio.json +255 -0
  43. package/skills/project-initializer/templates/publication.json +265 -0
  44. package/skills/project-initializer/templates/research.json +287 -0
  45. package/skills/project-initializer/templates/software.json +234 -0
  46. package/skills/project-load/SKILL.md +27 -0
  47. package/src/impact.mjs +25 -0
  48. package/src/index.mjs +17 -0
  49. package/src/location.mjs +7 -0
  50. package/src/mcp.mjs +37 -0
  51. package/src/plan.mjs +65 -0
  52. package/src/resources.mjs +28 -0
@@ -0,0 +1,219 @@
1
+ {
2
+ "documentation": {
3
+ "root": "docs"
4
+ },
5
+ "memory": {
6
+ "areas": [
7
+ {
8
+ "id": "rules",
9
+ "label": "Agent Rules",
10
+ "paths": [
11
+ "AGENTS.md"
12
+ ],
13
+ "excludePaths": [],
14
+ "scope": "shared",
15
+ "freshness": "fresh",
16
+ "role": "agent-working-rules",
17
+ "priority": 100,
18
+ "includeBodiesByDefault": true
19
+ },
20
+ {
21
+ "id": "agent-entrypoint",
22
+ "label": "Agent Entrypoints",
23
+ "paths": [
24
+ "CLAUDE.md",
25
+ "CODEX.md"
26
+ ],
27
+ "excludePaths": [],
28
+ "scope": "shared",
29
+ "freshness": "fresh",
30
+ "role": "agent-specific-entrypoint",
31
+ "priority": 85,
32
+ "includeBodiesByDefault": true
33
+ },
34
+ {
35
+ "id": "project-overview",
36
+ "label": "Project Overview",
37
+ "paths": [
38
+ "README.md"
39
+ ],
40
+ "excludePaths": [],
41
+ "scope": "shared",
42
+ "freshness": "fresh",
43
+ "role": "project-map",
44
+ "priority": 85,
45
+ "includeBodiesByDefault": true
46
+ },
47
+ {
48
+ "id": "docs-index",
49
+ "label": "Docs Index",
50
+ "paths": [
51
+ "docs/README.md"
52
+ ],
53
+ "excludePaths": [],
54
+ "scope": "shared",
55
+ "freshness": "fresh",
56
+ "role": "documentation-routing-map",
57
+ "priority": 90,
58
+ "includeBodiesByDefault": true
59
+ },
60
+ {
61
+ "id": "case",
62
+ "label": "Case Record",
63
+ "paths": [
64
+ "docs/case/**"
65
+ ],
66
+ "excludePaths": [],
67
+ "scope": "shared",
68
+ "freshness": "fresh",
69
+ "role": "case-truth-and-open-questions",
70
+ "priority": 85,
71
+ "includeBodiesByDefault": true
72
+ },
73
+ {
74
+ "id": "evidence",
75
+ "label": "Evidence and Grounds",
76
+ "paths": [
77
+ "docs/evidence/**"
78
+ ],
79
+ "excludePaths": [],
80
+ "scope": "shared",
81
+ "freshness": "fresh",
82
+ "role": "factual-and-legal-support",
83
+ "priority": 80,
84
+ "includeBodiesByDefault": true
85
+ },
86
+ {
87
+ "id": "outputs",
88
+ "label": "Case Outputs",
89
+ "paths": [
90
+ "docs/outputs/**"
91
+ ],
92
+ "excludePaths": [],
93
+ "scope": "shared",
94
+ "freshness": "fresh",
95
+ "role": "case-outputs",
96
+ "priority": 75,
97
+ "includeBodiesByDefault": true
98
+ },
99
+ {
100
+ "id": "active-plan",
101
+ "label": "Active Plans",
102
+ "paths": [
103
+ "docs/plan/**"
104
+ ],
105
+ "excludePaths": [],
106
+ "scope": "local",
107
+ "freshness": "fresh",
108
+ "role": "active-task-intent",
109
+ "priority": 95,
110
+ "includeBodiesByDefault": true
111
+ },
112
+ {
113
+ "id": "archive-map",
114
+ "label": "Archive Map",
115
+ "paths": [
116
+ "docs/archive/README.md"
117
+ ],
118
+ "excludePaths": [],
119
+ "scope": "local",
120
+ "freshness": "stale",
121
+ "role": "historical-memory-map",
122
+ "priority": 65,
123
+ "includeBodiesByDefault": true
124
+ },
125
+ {
126
+ "id": "archive-body",
127
+ "label": "Archive Body",
128
+ "paths": [
129
+ "docs/archive/**"
130
+ ],
131
+ "excludePaths": [
132
+ "docs/archive/README.md"
133
+ ],
134
+ "scope": "local",
135
+ "freshness": "stale",
136
+ "role": "historical-memory-body",
137
+ "priority": 20,
138
+ "includeBodiesByDefault": false
139
+ },
140
+ {
141
+ "id": "docs",
142
+ "label": "Project Documentation",
143
+ "paths": [
144
+ "docs/**"
145
+ ],
146
+ "excludePaths": [],
147
+ "scope": "shared",
148
+ "freshness": "fresh",
149
+ "role": "project-documentation",
150
+ "priority": 60,
151
+ "includeBodiesByDefault": true
152
+ }
153
+ ]
154
+ },
155
+ "traceability": {
156
+ "required": [
157
+ "docs/case/**",
158
+ "docs/outputs/**"
159
+ ],
160
+ "exclude": [
161
+ "**/README.md"
162
+ ],
163
+ "keys": [
164
+ {
165
+ "key": "basedOn",
166
+ "label": "Based on",
167
+ "description": "Canonical case records, evidence, or grounds supporting the document.",
168
+ "target": "path",
169
+ "relation": "based_on",
170
+ "weight": 4
171
+ },
172
+ {
173
+ "key": "relatedDocs",
174
+ "label": "Related docs",
175
+ "description": "Documents needed to interpret the record.",
176
+ "target": "path",
177
+ "relation": "related_doc",
178
+ "weight": 2
179
+ }
180
+ ]
181
+ },
182
+ "validation": {
183
+ "markdown": {
184
+ "maxLines": 200,
185
+ "maxChars": 10000,
186
+ "exclude": [],
187
+ "filename": {
188
+ "warnNumberedSeries": true,
189
+ "allow": []
190
+ }
191
+ }
192
+ },
193
+ "impactRanking": {
194
+ "semantic": {
195
+ "enabled": true,
196
+ "threshold": 0.5,
197
+ "topKPerFile": 5
198
+ }
199
+ },
200
+ "referenceExpansion": {
201
+ "fuzzy": {
202
+ "lowSignal": {
203
+ "add": [],
204
+ "remove": []
205
+ }
206
+ }
207
+ },
208
+ "load": {
209
+ "pinnedPaths": [],
210
+ "pinnedBodies": [],
211
+ "documentationSummary": {
212
+ "exclude": [
213
+ "docs/plan",
214
+ "docs/archive"
215
+ ]
216
+ }
217
+ },
218
+ "planMode": {}
219
+ }
@@ -0,0 +1,234 @@
1
+ {
2
+ "documentation": {
3
+ "root": "docs"
4
+ },
5
+ "memory": {
6
+ "areas": [
7
+ {
8
+ "id": "rules",
9
+ "label": "Agent Rules",
10
+ "paths": [
11
+ "AGENTS.md"
12
+ ],
13
+ "excludePaths": [],
14
+ "scope": "shared",
15
+ "freshness": "fresh",
16
+ "role": "agent-working-rules",
17
+ "priority": 100,
18
+ "includeBodiesByDefault": true
19
+ },
20
+ {
21
+ "id": "agent-entrypoint",
22
+ "label": "Agent Entrypoints",
23
+ "paths": [
24
+ "CLAUDE.md",
25
+ "CODEX.md"
26
+ ],
27
+ "excludePaths": [],
28
+ "scope": "shared",
29
+ "freshness": "fresh",
30
+ "role": "agent-specific-entrypoint",
31
+ "priority": 85,
32
+ "includeBodiesByDefault": true
33
+ },
34
+ {
35
+ "id": "project-overview",
36
+ "label": "Project Overview",
37
+ "paths": [
38
+ "README.md"
39
+ ],
40
+ "excludePaths": [],
41
+ "scope": "shared",
42
+ "freshness": "fresh",
43
+ "role": "project-map",
44
+ "priority": 85,
45
+ "includeBodiesByDefault": true
46
+ },
47
+ {
48
+ "id": "docs-index",
49
+ "label": "Docs Index",
50
+ "paths": [
51
+ "docs/README.md"
52
+ ],
53
+ "excludePaths": [],
54
+ "scope": "shared",
55
+ "freshness": "fresh",
56
+ "role": "documentation-routing-map",
57
+ "priority": 90,
58
+ "includeBodiesByDefault": true
59
+ },
60
+ {
61
+ "id": "spec",
62
+ "label": "Product Specs",
63
+ "paths": [
64
+ "docs/spec/**"
65
+ ],
66
+ "excludePaths": [],
67
+ "scope": "shared",
68
+ "freshness": "fresh",
69
+ "role": "behavior-truth",
70
+ "priority": 80,
71
+ "includeBodiesByDefault": true
72
+ },
73
+ {
74
+ "id": "architecture",
75
+ "label": "Architecture",
76
+ "paths": [
77
+ "docs/arch/**"
78
+ ],
79
+ "excludePaths": [],
80
+ "scope": "shared",
81
+ "freshness": "fresh",
82
+ "role": "architecture-rationale",
83
+ "priority": 75,
84
+ "includeBodiesByDefault": true
85
+ },
86
+ {
87
+ "id": "test",
88
+ "label": "Tests",
89
+ "paths": [
90
+ "docs/test/**"
91
+ ],
92
+ "excludePaths": [],
93
+ "scope": "shared",
94
+ "freshness": "fresh",
95
+ "role": "verification-knowledge",
96
+ "priority": 70,
97
+ "includeBodiesByDefault": true
98
+ },
99
+ {
100
+ "id": "active-plan",
101
+ "label": "Active Plans",
102
+ "paths": [
103
+ "docs/plan/**"
104
+ ],
105
+ "excludePaths": [],
106
+ "scope": "local",
107
+ "freshness": "fresh",
108
+ "role": "active-task-intent",
109
+ "priority": 95,
110
+ "includeBodiesByDefault": true
111
+ },
112
+ {
113
+ "id": "archive-map",
114
+ "label": "Archive Map",
115
+ "paths": [
116
+ "docs/archive/README.md"
117
+ ],
118
+ "excludePaths": [],
119
+ "scope": "local",
120
+ "freshness": "stale",
121
+ "role": "historical-memory-map",
122
+ "priority": 65,
123
+ "includeBodiesByDefault": true
124
+ },
125
+ {
126
+ "id": "archive-body",
127
+ "label": "Archive Body",
128
+ "paths": [
129
+ "docs/archive/**"
130
+ ],
131
+ "excludePaths": [
132
+ "docs/archive/README.md"
133
+ ],
134
+ "scope": "local",
135
+ "freshness": "stale",
136
+ "role": "historical-memory-body",
137
+ "priority": 20,
138
+ "includeBodiesByDefault": false
139
+ },
140
+ {
141
+ "id": "docs",
142
+ "label": "Project Documentation",
143
+ "paths": [
144
+ "docs/**"
145
+ ],
146
+ "excludePaths": [],
147
+ "scope": "shared",
148
+ "freshness": "fresh",
149
+ "role": "project-documentation",
150
+ "priority": 60,
151
+ "includeBodiesByDefault": true
152
+ }
153
+ ]
154
+ },
155
+ "traceability": {
156
+ "required": [
157
+ "docs/spec/**"
158
+ ],
159
+ "exclude": [
160
+ "**/README.md"
161
+ ],
162
+ "keys": [
163
+ {
164
+ "key": "implementedBy",
165
+ "label": "Implemented by",
166
+ "description": "Files that implement the behavior.",
167
+ "target": "path",
168
+ "relation": "implemented_by",
169
+ "weight": 4
170
+ },
171
+ {
172
+ "key": "verifiedBy",
173
+ "label": "Verified by",
174
+ "description": "Tests or maintained verification documents.",
175
+ "target": "path",
176
+ "relation": "verified_by",
177
+ "weight": 4
178
+ },
179
+ {
180
+ "key": "relatedDocs",
181
+ "label": "Related docs",
182
+ "description": "Documents needed to interpret the behavior.",
183
+ "target": "path",
184
+ "relation": "related_doc",
185
+ "weight": 3
186
+ },
187
+ {
188
+ "key": "designDecisions",
189
+ "label": "Design decisions",
190
+ "description": "Maintained architecture or design decision documents that constrain the behavior.",
191
+ "target": "path",
192
+ "relation": "design_decision",
193
+ "weight": 3
194
+ }
195
+ ]
196
+ },
197
+ "validation": {
198
+ "markdown": {
199
+ "maxLines": 200,
200
+ "maxChars": 10000,
201
+ "exclude": [],
202
+ "filename": {
203
+ "warnNumberedSeries": true,
204
+ "allow": []
205
+ }
206
+ }
207
+ },
208
+ "impactRanking": {
209
+ "semantic": {
210
+ "enabled": true,
211
+ "threshold": 0.5,
212
+ "topKPerFile": 5
213
+ }
214
+ },
215
+ "referenceExpansion": {
216
+ "fuzzy": {
217
+ "lowSignal": {
218
+ "add": [],
219
+ "remove": []
220
+ }
221
+ }
222
+ },
223
+ "load": {
224
+ "pinnedPaths": [],
225
+ "pinnedBodies": [],
226
+ "documentationSummary": {
227
+ "exclude": [
228
+ "docs/plan",
229
+ "docs/archive"
230
+ ]
231
+ }
232
+ },
233
+ "planMode": {}
234
+ }
@@ -0,0 +1,241 @@
1
+ {
2
+ "documentation": {
3
+ "root": "docs"
4
+ },
5
+ "memory": {
6
+ "areas": [
7
+ {
8
+ "id": "rules",
9
+ "label": "Agent Rules",
10
+ "paths": [
11
+ "AGENTS.md"
12
+ ],
13
+ "excludePaths": [],
14
+ "scope": "shared",
15
+ "freshness": "fresh",
16
+ "role": "agent-working-rules",
17
+ "priority": 100,
18
+ "includeBodiesByDefault": true
19
+ },
20
+ {
21
+ "id": "agent-entrypoint",
22
+ "label": "Agent Entrypoints",
23
+ "paths": [
24
+ "CLAUDE.md",
25
+ "CODEX.md"
26
+ ],
27
+ "excludePaths": [],
28
+ "scope": "shared",
29
+ "freshness": "fresh",
30
+ "role": "agent-specific-entrypoint",
31
+ "priority": 85,
32
+ "includeBodiesByDefault": true
33
+ },
34
+ {
35
+ "id": "project-overview",
36
+ "label": "Project Overview",
37
+ "paths": [
38
+ "README.md"
39
+ ],
40
+ "excludePaths": [],
41
+ "scope": "shared",
42
+ "freshness": "fresh",
43
+ "role": "project-map",
44
+ "priority": 85,
45
+ "includeBodiesByDefault": true
46
+ },
47
+ {
48
+ "id": "docs-index",
49
+ "label": "Docs Index",
50
+ "paths": [
51
+ "docs/README.md"
52
+ ],
53
+ "excludePaths": [],
54
+ "scope": "shared",
55
+ "freshness": "fresh",
56
+ "role": "documentation-routing-map",
57
+ "priority": 90,
58
+ "includeBodiesByDefault": true
59
+ },
60
+ {
61
+ "id": "policy",
62
+ "label": "Policy Documents",
63
+ "paths": [
64
+ "docs/policy/**"
65
+ ],
66
+ "excludePaths": [],
67
+ "scope": "shared",
68
+ "freshness": "fresh",
69
+ "role": "policy-output",
70
+ "priority": 95,
71
+ "includeBodiesByDefault": true
72
+ },
73
+ {
74
+ "id": "sections",
75
+ "label": "Policy Sections",
76
+ "paths": [
77
+ "docs/sections/**"
78
+ ],
79
+ "excludePaths": [],
80
+ "scope": "shared",
81
+ "freshness": "fresh",
82
+ "role": "policy-source-sections",
83
+ "priority": 90,
84
+ "includeBodiesByDefault": true
85
+ },
86
+ {
87
+ "id": "evidence",
88
+ "label": "Policy Evidence",
89
+ "paths": [
90
+ "docs/evidence/**",
91
+ "docs/report/**"
92
+ ],
93
+ "excludePaths": [],
94
+ "scope": "shared",
95
+ "freshness": "fresh",
96
+ "role": "policy-evidence",
97
+ "priority": 80,
98
+ "includeBodiesByDefault": true
99
+ },
100
+ {
101
+ "id": "outputs",
102
+ "label": "Submission Outputs",
103
+ "paths": [
104
+ "docs/outputs/**"
105
+ ],
106
+ "excludePaths": [],
107
+ "scope": "shared",
108
+ "freshness": "fresh",
109
+ "role": "policy-submission-output",
110
+ "priority": 75,
111
+ "includeBodiesByDefault": true
112
+ },
113
+ {
114
+ "id": "active-plan",
115
+ "label": "Active Plans",
116
+ "paths": [
117
+ "docs/plan/**"
118
+ ],
119
+ "excludePaths": [],
120
+ "scope": "local",
121
+ "freshness": "fresh",
122
+ "role": "active-task-intent",
123
+ "priority": 95,
124
+ "includeBodiesByDefault": true
125
+ },
126
+ {
127
+ "id": "archive-map",
128
+ "label": "Archive Map",
129
+ "paths": [
130
+ "docs/archive/README.md"
131
+ ],
132
+ "excludePaths": [],
133
+ "scope": "local",
134
+ "freshness": "stale",
135
+ "role": "historical-memory-map",
136
+ "priority": 65,
137
+ "includeBodiesByDefault": true
138
+ },
139
+ {
140
+ "id": "archive-body",
141
+ "label": "Archive Body",
142
+ "paths": [
143
+ "docs/archive/**"
144
+ ],
145
+ "excludePaths": [
146
+ "docs/archive/README.md"
147
+ ],
148
+ "scope": "local",
149
+ "freshness": "stale",
150
+ "role": "historical-memory-body",
151
+ "priority": 20,
152
+ "includeBodiesByDefault": false
153
+ },
154
+ {
155
+ "id": "docs",
156
+ "label": "Project Documentation",
157
+ "paths": [
158
+ "docs/**"
159
+ ],
160
+ "excludePaths": [],
161
+ "scope": "shared",
162
+ "freshness": "fresh",
163
+ "role": "project-documentation",
164
+ "priority": 60,
165
+ "includeBodiesByDefault": true
166
+ }
167
+ ]
168
+ },
169
+ "traceability": {
170
+ "required": [
171
+ "docs/sections/**",
172
+ "docs/outputs/**"
173
+ ],
174
+ "exclude": [
175
+ "**/README.md"
176
+ ],
177
+ "keys": [
178
+ {
179
+ "key": "supportedBy",
180
+ "label": "Supported by",
181
+ "description": "Evidence, source sections, or research supporting the proposal.",
182
+ "target": "path",
183
+ "relation": "supported_by",
184
+ "weight": 4
185
+ },
186
+ {
187
+ "key": "integratedInto",
188
+ "label": "Integrated into",
189
+ "description": "Integrated proposals or briefs that use this policy section.",
190
+ "target": "path",
191
+ "relation": "integrated_into",
192
+ "weight": 4
193
+ },
194
+ {
195
+ "key": "relatedDocs",
196
+ "label": "Related docs",
197
+ "description": "Documents needed to interpret the policy.",
198
+ "target": "path",
199
+ "relation": "related_doc",
200
+ "weight": 2
201
+ }
202
+ ]
203
+ },
204
+ "validation": {
205
+ "markdown": {
206
+ "maxLines": 200,
207
+ "maxChars": 10000,
208
+ "exclude": [],
209
+ "filename": {
210
+ "warnNumberedSeries": true,
211
+ "allow": []
212
+ }
213
+ }
214
+ },
215
+ "impactRanking": {
216
+ "semantic": {
217
+ "enabled": true,
218
+ "threshold": 0.5,
219
+ "topKPerFile": 5
220
+ }
221
+ },
222
+ "referenceExpansion": {
223
+ "fuzzy": {
224
+ "lowSignal": {
225
+ "add": [],
226
+ "remove": []
227
+ }
228
+ }
229
+ },
230
+ "load": {
231
+ "pinnedPaths": [],
232
+ "pinnedBodies": [],
233
+ "documentationSummary": {
234
+ "exclude": [
235
+ "docs/plan",
236
+ "docs/archive"
237
+ ]
238
+ }
239
+ },
240
+ "planMode": {}
241
+ }