Skip to content

Commit fdd4189

Browse files
author
chenbo
committed
Add OpenCode TUI sidecar launcher
1 parent 4329af0 commit fdd4189

43 files changed

Lines changed: 10023 additions & 7674 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agent-context/architecture.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,16 @@ This document is generated from static repository signals. Treat it as a startin
99
- Internal modules: 28
1010

1111
## Important Modules
12+
- `test`: test contains 38 files and depends on analyzers, benchmarks, cli, config, core, harness, integrations, mcp, outputs, retrievers.
1213
- `outputs`: outputs contains 27 files and depends on core, harness, integrations.
13-
- `test`: test contains 36 files and depends on analyzers, benchmarks, cli, config, core, harness, integrations, mcp, outputs, retrievers.
1414
- `core`: core contains 18 files and depends on analyzers, config, llm, outputs.
1515
- `harness`: harness contains 9 files and depends on core, outputs, sandbox.
1616
- `retrievers`: retrievers contains 7 files and depends on core, integrations, outputs.
1717
- `benchmarks`: benchmarks contains 25 files and depends on core, harness, outputs.
1818
- `analyzers`: analyzers contains 6 files and depends on core.
19+
- `integrations`: integrations contains 4 files and depends on core, outputs, retrievers.
1920
- `benchmarks/fixtures/small-ts-app`: benchmarks/fixtures/small-ts-app contains 13 files.
20-
- `cli`: cli contains 3 files and depends on benchmarks, config, core, harness, integrations, outputs, retrievers.
21-
- `benchmarks/fixtures/monorepo/packages/api`: benchmarks/fixtures/monorepo/packages/api contains 5 files and depends on benchmarks/fixtures/monorepo/packages/config.
21+
- `cli`: cli contains 4 files and depends on benchmarks, config, core, harness, integrations, outputs, retrievers.
2222

2323
## Agent Guidance
2424
- Start with `AGENTS.md`, then read `key-files.md` for the highest-signal files.

.agent-context/contracts/architecture.contract.json

Lines changed: 26 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -105,18 +105,6 @@
105105
}
106106
],
107107
"modules": [
108-
{
109-
"name": "outputs",
110-
"owns": [
111-
"src/outputs/**"
112-
],
113-
"imports": [
114-
"core",
115-
"harness",
116-
"integrations"
117-
],
118-
"summary": "outputs contains 27 files and depends on core, harness, integrations."
119-
},
120108
{
121109
"name": "test",
122110
"owns": [
@@ -134,7 +122,19 @@
134122
"outputs",
135123
"retrievers"
136124
],
137-
"summary": "test contains 36 files and depends on analyzers, benchmarks, cli, config, core, harness, integrations, mcp, outputs, retrievers."
125+
"summary": "test contains 38 files and depends on analyzers, benchmarks, cli, config, core, harness, integrations, mcp, outputs, retrievers."
126+
},
127+
{
128+
"name": "outputs",
129+
"owns": [
130+
"src/outputs/**"
131+
],
132+
"imports": [
133+
"core",
134+
"harness",
135+
"integrations"
136+
],
137+
"summary": "outputs contains 27 files and depends on core, harness, integrations."
138138
},
139139
{
140140
"name": "core",
@@ -196,6 +196,18 @@
196196
],
197197
"summary": "analyzers contains 6 files and depends on core."
198198
},
199+
{
200+
"name": "integrations",
201+
"owns": [
202+
"src/integrations/**"
203+
],
204+
"imports": [
205+
"core",
206+
"outputs",
207+
"retrievers"
208+
],
209+
"summary": "integrations contains 4 files and depends on core, outputs, retrievers."
210+
},
199211
{
200212
"name": "benchmarks/fixtures/small-ts-app",
201213
"owns": [
@@ -218,7 +230,7 @@
218230
"outputs",
219231
"retrievers"
220232
],
221-
"summary": "cli contains 3 files and depends on benchmarks, config, core, harness, integrations, outputs, retrievers."
233+
"summary": "cli contains 4 files and depends on benchmarks, config, core, harness, integrations, outputs, retrievers."
222234
},
223235
{
224236
"name": "benchmarks/fixtures/monorepo/packages/api",
@@ -287,17 +299,6 @@
287299
"imports": [],
288300
"summary": "benchmarks/fixtures/monorepo/packages/config contains 4 files."
289301
},
290-
{
291-
"name": "integrations",
292-
"owns": [
293-
"src/integrations/**"
294-
],
295-
"imports": [
296-
"core",
297-
"retrievers"
298-
],
299-
"summary": "integrations contains 1 file and depends on core, retrievers."
300-
},
301302
{
302303
"name": "root",
303304
"owns": [

.agent-context/contracts/module-boundaries.json

Lines changed: 83 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,53 @@
33
"kind": "module-boundaries",
44
"purpose": "Constrain coding agents from crossing module ownership boundaries without explicit task justification.",
55
"modules": {
6+
"test": {
7+
"owns": [
8+
"test/**"
9+
],
10+
"allowedImports": [
11+
"benchmarks/**",
12+
"benchmarks/fixtures/monorepo/packages/config/**",
13+
"benchmarks/fixtures/monorepo/packages/shared/**",
14+
"src/analyzers/**",
15+
"src/benchmarks/**",
16+
"src/cli/**",
17+
"src/config/**",
18+
"src/core/**",
19+
"src/harness/**",
20+
"src/integrations/**",
21+
"src/mcp/**",
22+
"src/outputs/**",
23+
"src/retrievers/**",
24+
"test/**"
25+
],
26+
"forbiddenImports": [
27+
"**/*.generated.*",
28+
"**/generated/**",
29+
"build/**",
30+
"dist/**",
31+
"src/admin/**",
32+
"src/billing/**",
33+
"src/payment/**",
34+
"src/payments/**"
35+
],
36+
"observedImports": [
37+
"analyzers",
38+
"benchmarks",
39+
"cli",
40+
"config",
41+
"core",
42+
"harness",
43+
"integrations",
44+
"mcp",
45+
"outputs",
46+
"retrievers"
47+
],
48+
"publicFiles": [
49+
"test/fixtures/python-package/src/app/models.py",
50+
"test/fixtures/python-package/src/app/service.py"
51+
]
52+
},
653
"outputs": {
754
"owns": [
855
"src/outputs/**"
@@ -61,53 +108,6 @@
61108
"src/outputs/token-savings.ts"
62109
]
63110
},
64-
"test": {
65-
"owns": [
66-
"test/**"
67-
],
68-
"allowedImports": [
69-
"benchmarks/**",
70-
"benchmarks/fixtures/monorepo/packages/config/**",
71-
"benchmarks/fixtures/monorepo/packages/shared/**",
72-
"src/analyzers/**",
73-
"src/benchmarks/**",
74-
"src/cli/**",
75-
"src/config/**",
76-
"src/core/**",
77-
"src/harness/**",
78-
"src/integrations/**",
79-
"src/mcp/**",
80-
"src/outputs/**",
81-
"src/retrievers/**",
82-
"test/**"
83-
],
84-
"forbiddenImports": [
85-
"**/*.generated.*",
86-
"**/generated/**",
87-
"build/**",
88-
"dist/**",
89-
"src/admin/**",
90-
"src/billing/**",
91-
"src/payment/**",
92-
"src/payments/**"
93-
],
94-
"observedImports": [
95-
"analyzers",
96-
"benchmarks",
97-
"cli",
98-
"config",
99-
"core",
100-
"harness",
101-
"integrations",
102-
"mcp",
103-
"outputs",
104-
"retrievers"
105-
],
106-
"publicFiles": [
107-
"test/fixtures/python-package/src/app/models.py",
108-
"test/fixtures/python-package/src/app/service.py"
109-
]
110-
},
111111
"core": {
112112
"owns": [
113113
"src/core/**"
@@ -310,6 +310,41 @@
310310
"src/analyzers/types.ts"
311311
]
312312
},
313+
"integrations": {
314+
"owns": [
315+
"src/integrations/**"
316+
],
317+
"allowedImports": [
318+
"benchmarks/fixtures/monorepo/packages/config/**",
319+
"benchmarks/fixtures/monorepo/packages/shared/**",
320+
"src/config/**",
321+
"src/core/**",
322+
"src/integrations/**",
323+
"src/outputs/**",
324+
"src/retrievers/**"
325+
],
326+
"forbiddenImports": [
327+
"**/*.generated.*",
328+
"**/generated/**",
329+
"build/**",
330+
"dist/**",
331+
"src/admin/**",
332+
"src/billing/**",
333+
"src/payment/**",
334+
"src/payments/**"
335+
],
336+
"observedImports": [
337+
"core",
338+
"outputs",
339+
"retrievers"
340+
],
341+
"publicFiles": [
342+
"src/integrations/codegraph.ts",
343+
"src/integrations/opencode/launcher.ts",
344+
"src/integrations/opencode/project-init.ts",
345+
"src/integrations/opencode/sidecar-plugin-template.ts"
346+
]
347+
},
313348
"benchmarks/fixtures/small-ts-app": {
314349
"owns": [
315350
"benchmarks/fixtures/small-ts-app/**"
@@ -378,6 +413,7 @@
378413
"retrievers"
379414
],
380415
"publicFiles": [
416+
"src/cli/default-command.ts",
381417
"src/cli/index.ts",
382418
"src/cli/opencode-preset.ts",
383419
"src/cli/task-args.ts"
@@ -587,36 +623,6 @@
587623
"benchmarks/fixtures/monorepo/packages/config/src/loader.ts"
588624
]
589625
},
590-
"integrations": {
591-
"owns": [
592-
"src/integrations/**"
593-
],
594-
"allowedImports": [
595-
"benchmarks/fixtures/monorepo/packages/config/**",
596-
"benchmarks/fixtures/monorepo/packages/shared/**",
597-
"src/config/**",
598-
"src/core/**",
599-
"src/integrations/**",
600-
"src/retrievers/**"
601-
],
602-
"forbiddenImports": [
603-
"**/*.generated.*",
604-
"**/generated/**",
605-
"build/**",
606-
"dist/**",
607-
"src/admin/**",
608-
"src/billing/**",
609-
"src/payment/**",
610-
"src/payments/**"
611-
],
612-
"observedImports": [
613-
"core",
614-
"retrievers"
615-
],
616-
"publicFiles": [
617-
"src/integrations/codegraph.ts"
618-
]
619-
},
620626
"benchmarks/fixtures/monorepo/packages/web": {
621627
"owns": [
622628
"benchmarks/fixtures/monorepo/packages/web/**"

0 commit comments

Comments
 (0)