@agimon-ai/po 0.0.0-alpha.104 → 0.0.0-alpha.106
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/catalog/index.json +62 -60
- package/dist/package.cjs +1 -1
- package/dist/package.mjs +1 -1
- package/dist/src/builders/server/bundlerService.cjs +14 -2
- package/dist/src/builders/server/bundlerService.cjs.map +1 -1
- package/dist/src/builders/server/bundlerService.mjs +12 -0
- package/dist/src/builders/server/bundlerService.mjs.map +1 -1
- package/dist/src/builders/server/idleRestart.cjs +47 -17
- package/dist/src/builders/server/idleRestart.cjs.map +1 -1
- package/dist/src/builders/server/idleRestart.mjs +47 -17
- package/dist/src/builders/server/idleRestart.mjs.map +1 -1
- package/dist/src/builders/server/packageReloadCheck.cjs +39 -0
- package/dist/src/builders/server/packageReloadCheck.cjs.map +1 -1
- package/dist/src/builders/server/packageReloadCheck.mjs +39 -1
- package/dist/src/builders/server/packageReloadCheck.mjs.map +1 -1
- package/dist/src/builders/server/runtime.cjs +85 -11
- package/dist/src/builders/server/runtime.cjs.map +1 -1
- package/dist/src/builders/server/runtime.mjs +89 -15
- package/dist/src/builders/server/runtime.mjs.map +1 -1
- package/dist/src/builders/web/bundle.cjs +1 -0
- package/dist/src/builders/web/bundle.cjs.map +1 -1
- package/dist/src/builders/web/bundle.d.mts +3 -0
- package/dist/src/builders/web/bundle.d.mts.map +1 -1
- package/dist/src/builders/web/bundle.mjs +1 -0
- package/dist/src/builders/web/bundle.mjs.map +1 -1
- package/dist/src/builders/web/webPluginManifest.cjs +7 -1
- package/dist/src/builders/web/webPluginManifest.cjs.map +1 -1
- package/dist/src/builders/web/webPluginManifest.d.mts +6 -17
- package/dist/src/builders/web/webPluginManifest.d.mts.map +1 -1
- package/dist/src/builders/web/webPluginManifest.mjs +7 -1
- package/dist/src/builders/web/webPluginManifest.mjs.map +1 -1
- package/dist/src/composition/layerPackageInstaller/index.cjs +7 -0
- package/dist/src/composition/layerPackageInstaller/index.cjs.map +1 -1
- package/dist/src/composition/layerPackageInstaller/index.d.mts.map +1 -1
- package/dist/src/composition/layerPackageInstaller/index.mjs +7 -1
- package/dist/src/composition/layerPackageInstaller/index.mjs.map +1 -1
- package/package.json +27 -27
package/dist/catalog/index.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"version": 1,
|
|
3
3
|
"packages": {
|
|
4
4
|
"@agimon-ai/po": {
|
|
5
|
-
"version": "0.0.0-alpha.
|
|
5
|
+
"version": "0.0.0-alpha.106",
|
|
6
6
|
"dependencies": [
|
|
7
7
|
"@agimon-ai/po-approval",
|
|
8
8
|
"@agimon-ai/po-artifact",
|
|
@@ -28,14 +28,14 @@
|
|
|
28
28
|
]
|
|
29
29
|
},
|
|
30
30
|
"@agimon-ai/po-approval": {
|
|
31
|
-
"version": "0.0.0-alpha.
|
|
31
|
+
"version": "0.0.0-alpha.105",
|
|
32
32
|
"dependencies": [
|
|
33
33
|
"@agimon-ai/po-core",
|
|
34
34
|
"@agimon-ai/po-web-components"
|
|
35
35
|
]
|
|
36
36
|
},
|
|
37
37
|
"@agimon-ai/po-artifact": {
|
|
38
|
-
"version": "0.0.0-alpha.
|
|
38
|
+
"version": "0.0.0-alpha.104",
|
|
39
39
|
"dependencies": [
|
|
40
40
|
"@agimon-ai/po-core",
|
|
41
41
|
"@agimon-ai/po-web-components",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
]
|
|
44
44
|
},
|
|
45
45
|
"@agimon-ai/po-author": {
|
|
46
|
-
"version": "0.0.0-alpha.
|
|
46
|
+
"version": "0.0.0-alpha.105",
|
|
47
47
|
"dependencies": [
|
|
48
48
|
"@agimon-ai/po-artifact",
|
|
49
49
|
"@agimon-ai/po-core",
|
|
@@ -53,7 +53,7 @@
|
|
|
53
53
|
]
|
|
54
54
|
},
|
|
55
55
|
"@agimon-ai/po-autocompact": {
|
|
56
|
-
"version": "0.0.0-alpha.
|
|
56
|
+
"version": "0.0.0-alpha.105",
|
|
57
57
|
"dependencies": [
|
|
58
58
|
"@agimon-ai/po-artifact",
|
|
59
59
|
"@agimon-ai/po-config",
|
|
@@ -62,24 +62,24 @@
|
|
|
62
62
|
]
|
|
63
63
|
},
|
|
64
64
|
"@agimon-ai/po-autostop": {
|
|
65
|
-
"version": "0.0.0-alpha.
|
|
65
|
+
"version": "0.0.0-alpha.105",
|
|
66
66
|
"dependencies": [
|
|
67
67
|
"@agimon-ai/po-core"
|
|
68
68
|
]
|
|
69
69
|
},
|
|
70
70
|
"@agimon-ai/po-browse": {
|
|
71
|
-
"version": "0.0.1-alpha.
|
|
71
|
+
"version": "0.0.1-alpha.103",
|
|
72
72
|
"dependencies": [
|
|
73
73
|
"@agimon-ai/po-core",
|
|
74
74
|
"@agimon-ai/po-web-components"
|
|
75
75
|
]
|
|
76
76
|
},
|
|
77
77
|
"@agimon-ai/po-build": {
|
|
78
|
-
"version": "0.0.0-alpha.
|
|
78
|
+
"version": "0.0.0-alpha.105",
|
|
79
79
|
"dependencies": []
|
|
80
80
|
},
|
|
81
81
|
"@agimon-ai/po-cache": {
|
|
82
|
-
"version": "0.0.0-alpha.
|
|
82
|
+
"version": "0.0.0-alpha.105",
|
|
83
83
|
"dependencies": [
|
|
84
84
|
"@agimon-ai/po-config",
|
|
85
85
|
"@agimon-ai/po-core",
|
|
@@ -87,22 +87,23 @@
|
|
|
87
87
|
]
|
|
88
88
|
},
|
|
89
89
|
"@agimon-ai/po-calendar": {
|
|
90
|
-
"version": "0.0.1-alpha.
|
|
90
|
+
"version": "0.0.1-alpha.64",
|
|
91
91
|
"dependencies": [
|
|
92
92
|
"@agimon-ai/po-config",
|
|
93
93
|
"@agimon-ai/po-core",
|
|
94
94
|
"@agimon-ai/po-db",
|
|
95
95
|
"@agimon-ai/po-minor-mode",
|
|
96
|
+
"@agimon-ai/po-profile",
|
|
96
97
|
"@agimon-ai/po-web-components",
|
|
97
98
|
"@agimon-ai/po-web-security"
|
|
98
99
|
]
|
|
99
100
|
},
|
|
100
101
|
"@agimon-ai/po-claude-bridge": {
|
|
101
|
-
"version": "0.1.1-alpha.
|
|
102
|
+
"version": "0.1.1-alpha.85",
|
|
102
103
|
"dependencies": []
|
|
103
104
|
},
|
|
104
105
|
"@agimon-ai/po-codemode": {
|
|
105
|
-
"version": "0.0.1-alpha.
|
|
106
|
+
"version": "0.0.1-alpha.78",
|
|
106
107
|
"dependencies": [
|
|
107
108
|
"@agimon-ai/po-config",
|
|
108
109
|
"@agimon-ai/po-core",
|
|
@@ -110,7 +111,7 @@
|
|
|
110
111
|
]
|
|
111
112
|
},
|
|
112
113
|
"@agimon-ai/po-computer-use": {
|
|
113
|
-
"version": "0.0.0-alpha.
|
|
114
|
+
"version": "0.0.0-alpha.105",
|
|
114
115
|
"dependencies": [
|
|
115
116
|
"@agimon-ai/po-config",
|
|
116
117
|
"@agimon-ai/po-core",
|
|
@@ -120,26 +121,26 @@
|
|
|
120
121
|
]
|
|
121
122
|
},
|
|
122
123
|
"@agimon-ai/po-config": {
|
|
123
|
-
"version": "0.0.0-alpha.
|
|
124
|
+
"version": "0.0.0-alpha.105",
|
|
124
125
|
"dependencies": [
|
|
125
126
|
"@agimon-ai/po-core",
|
|
126
127
|
"@agimon-ai/po-web-components"
|
|
127
128
|
]
|
|
128
129
|
},
|
|
129
130
|
"@agimon-ai/po-core": {
|
|
130
|
-
"version": "0.0.0-alpha.
|
|
131
|
+
"version": "0.0.0-alpha.105",
|
|
131
132
|
"dependencies": [
|
|
132
133
|
"@agimon-ai/po-web-security"
|
|
133
134
|
]
|
|
134
135
|
},
|
|
135
136
|
"@agimon-ai/po-db": {
|
|
136
|
-
"version": "0.0.0-alpha.
|
|
137
|
+
"version": "0.0.0-alpha.105",
|
|
137
138
|
"dependencies": [
|
|
138
139
|
"@agimon-ai/po-core"
|
|
139
140
|
]
|
|
140
141
|
},
|
|
141
142
|
"@agimon-ai/po-domain": {
|
|
142
|
-
"version": "0.0.0-alpha.
|
|
143
|
+
"version": "0.0.0-alpha.105",
|
|
143
144
|
"dependencies": [
|
|
144
145
|
"@agimon-ai/po-config",
|
|
145
146
|
"@agimon-ai/po-core",
|
|
@@ -147,7 +148,7 @@
|
|
|
147
148
|
]
|
|
148
149
|
},
|
|
149
150
|
"@agimon-ai/po-edit": {
|
|
150
|
-
"version": "0.0.0-alpha.
|
|
151
|
+
"version": "0.0.0-alpha.105",
|
|
151
152
|
"dependencies": [
|
|
152
153
|
"@agimon-ai/po-core",
|
|
153
154
|
"@agimon-ai/po-hashline",
|
|
@@ -156,7 +157,7 @@
|
|
|
156
157
|
]
|
|
157
158
|
},
|
|
158
159
|
"@agimon-ai/po-file-edit": {
|
|
159
|
-
"version": "0.0.0-alpha.
|
|
160
|
+
"version": "0.0.0-alpha.105",
|
|
160
161
|
"dependencies": [
|
|
161
162
|
"@agimon-ai/po-config",
|
|
162
163
|
"@agimon-ai/po-core",
|
|
@@ -166,7 +167,7 @@
|
|
|
166
167
|
]
|
|
167
168
|
},
|
|
168
169
|
"@agimon-ai/po-git": {
|
|
169
|
-
"version": "0.0.0-alpha.
|
|
170
|
+
"version": "0.0.0-alpha.105",
|
|
170
171
|
"dependencies": [
|
|
171
172
|
"@agimon-ai/po-core",
|
|
172
173
|
"@agimon-ai/po-session",
|
|
@@ -175,7 +176,7 @@
|
|
|
175
176
|
]
|
|
176
177
|
},
|
|
177
178
|
"@agimon-ai/po-goal": {
|
|
178
|
-
"version": "0.0.0-alpha.
|
|
179
|
+
"version": "0.0.0-alpha.105",
|
|
179
180
|
"dependencies": [
|
|
180
181
|
"@agimon-ai/po-core",
|
|
181
182
|
"@agimon-ai/po-minor-mode",
|
|
@@ -184,7 +185,7 @@
|
|
|
184
185
|
]
|
|
185
186
|
},
|
|
186
187
|
"@agimon-ai/po-grep": {
|
|
187
|
-
"version": "0.0.0-alpha.
|
|
188
|
+
"version": "0.0.0-alpha.105",
|
|
188
189
|
"dependencies": [
|
|
189
190
|
"@agimon-ai/po-core",
|
|
190
191
|
"@agimon-ai/po-hashline",
|
|
@@ -193,26 +194,27 @@
|
|
|
193
194
|
]
|
|
194
195
|
},
|
|
195
196
|
"@agimon-ai/po-hashline": {
|
|
196
|
-
"version": "0.0.0-alpha.
|
|
197
|
+
"version": "0.0.0-alpha.105",
|
|
197
198
|
"dependencies": []
|
|
198
199
|
},
|
|
199
200
|
"@agimon-ai/po-help": {
|
|
200
|
-
"version": "0.0.0-alpha.
|
|
201
|
+
"version": "0.0.0-alpha.105",
|
|
201
202
|
"dependencies": [
|
|
202
203
|
"@agimon-ai/po-core",
|
|
203
204
|
"@agimon-ai/po-minor-mode",
|
|
204
|
-
"@agimon-ai/po-web-components"
|
|
205
|
+
"@agimon-ai/po-web-components",
|
|
206
|
+
"@agimon-ai/po-web-security"
|
|
205
207
|
]
|
|
206
208
|
},
|
|
207
209
|
"@agimon-ai/po-identity": {
|
|
208
|
-
"version": "0.0.2-alpha.
|
|
210
|
+
"version": "0.0.2-alpha.52",
|
|
209
211
|
"dependencies": [
|
|
210
212
|
"@agimon-ai/po-core",
|
|
211
213
|
"@agimon-ai/po-web-security"
|
|
212
214
|
]
|
|
213
215
|
},
|
|
214
216
|
"@agimon-ai/po-image-gen": {
|
|
215
|
-
"version": "0.0.0-alpha.
|
|
217
|
+
"version": "0.0.0-alpha.104",
|
|
216
218
|
"dependencies": [
|
|
217
219
|
"@agimon-ai/po-core",
|
|
218
220
|
"@agimon-ai/po-web-components",
|
|
@@ -220,7 +222,7 @@
|
|
|
220
222
|
]
|
|
221
223
|
},
|
|
222
224
|
"@agimon-ai/po-ios": {
|
|
223
|
-
"version": "0.0.1-alpha.
|
|
225
|
+
"version": "0.0.1-alpha.40",
|
|
224
226
|
"dependencies": [
|
|
225
227
|
"@agimon-ai/po-artifact",
|
|
226
228
|
"@agimon-ai/po-config",
|
|
@@ -230,7 +232,7 @@
|
|
|
230
232
|
]
|
|
231
233
|
},
|
|
232
234
|
"@agimon-ai/po-log": {
|
|
233
|
-
"version": "0.0.0-alpha.
|
|
235
|
+
"version": "0.0.0-alpha.105",
|
|
234
236
|
"dependencies": [
|
|
235
237
|
"@agimon-ai/po-core",
|
|
236
238
|
"@agimon-ai/po-web-components",
|
|
@@ -238,7 +240,7 @@
|
|
|
238
240
|
]
|
|
239
241
|
},
|
|
240
242
|
"@agimon-ai/po-major-mode": {
|
|
241
|
-
"version": "0.0.0-alpha.
|
|
243
|
+
"version": "0.0.0-alpha.105",
|
|
242
244
|
"dependencies": [
|
|
243
245
|
"@agimon-ai/po-config",
|
|
244
246
|
"@agimon-ai/po-core",
|
|
@@ -246,7 +248,7 @@
|
|
|
246
248
|
]
|
|
247
249
|
},
|
|
248
250
|
"@agimon-ai/po-mcp": {
|
|
249
|
-
"version": "0.0.0-alpha.
|
|
251
|
+
"version": "0.0.0-alpha.105",
|
|
250
252
|
"dependencies": [
|
|
251
253
|
"@agimon-ai/po-config",
|
|
252
254
|
"@agimon-ai/po-core",
|
|
@@ -257,43 +259,43 @@
|
|
|
257
259
|
]
|
|
258
260
|
},
|
|
259
261
|
"@agimon-ai/po-mcp-proxy": {
|
|
260
|
-
"version": "0.0.1-alpha.
|
|
262
|
+
"version": "0.0.1-alpha.84",
|
|
261
263
|
"dependencies": []
|
|
262
264
|
},
|
|
263
265
|
"@agimon-ai/po-minor-mode": {
|
|
264
|
-
"version": "0.0.0-alpha.
|
|
266
|
+
"version": "0.0.0-alpha.105",
|
|
265
267
|
"dependencies": [
|
|
266
268
|
"@agimon-ai/po-core"
|
|
267
269
|
]
|
|
268
270
|
},
|
|
269
271
|
"@agimon-ai/po-model-guidance": {
|
|
270
|
-
"version": "0.0.0-alpha.
|
|
272
|
+
"version": "0.0.0-alpha.105",
|
|
271
273
|
"dependencies": [
|
|
272
274
|
"@agimon-ai/po-config",
|
|
273
275
|
"@agimon-ai/po-core"
|
|
274
276
|
]
|
|
275
277
|
},
|
|
276
278
|
"@agimon-ai/po-native-components": {
|
|
277
|
-
"version": "0.0.0-alpha.
|
|
279
|
+
"version": "0.0.0-alpha.105",
|
|
278
280
|
"dependencies": [
|
|
279
281
|
"@agimon-ai/po-web-components"
|
|
280
282
|
]
|
|
281
283
|
},
|
|
282
284
|
"@agimon-ai/po-network": {
|
|
283
|
-
"version": "0.0.2-alpha.
|
|
285
|
+
"version": "0.0.2-alpha.52",
|
|
284
286
|
"dependencies": [
|
|
285
287
|
"@agimon-ai/po-core",
|
|
286
288
|
"@agimon-ai/po-web-security"
|
|
287
289
|
]
|
|
288
290
|
},
|
|
289
291
|
"@agimon-ai/po-notification": {
|
|
290
|
-
"version": "0.0.0-alpha.
|
|
292
|
+
"version": "0.0.0-alpha.105",
|
|
291
293
|
"dependencies": [
|
|
292
294
|
"@agimon-ai/po-core"
|
|
293
295
|
]
|
|
294
296
|
},
|
|
295
297
|
"@agimon-ai/po-plan": {
|
|
296
|
-
"version": "0.0.0-alpha.
|
|
298
|
+
"version": "0.0.0-alpha.105",
|
|
297
299
|
"dependencies": [
|
|
298
300
|
"@agimon-ai/po-config",
|
|
299
301
|
"@agimon-ai/po-core",
|
|
@@ -303,7 +305,7 @@
|
|
|
303
305
|
]
|
|
304
306
|
},
|
|
305
307
|
"@agimon-ai/po-profile": {
|
|
306
|
-
"version": "0.0.0-alpha.
|
|
308
|
+
"version": "0.0.0-alpha.105",
|
|
307
309
|
"dependencies": [
|
|
308
310
|
"@agimon-ai/po-config",
|
|
309
311
|
"@agimon-ai/po-core",
|
|
@@ -311,7 +313,7 @@
|
|
|
311
313
|
]
|
|
312
314
|
},
|
|
313
315
|
"@agimon-ai/po-prompt": {
|
|
314
|
-
"version": "0.0.0-alpha.
|
|
316
|
+
"version": "0.0.0-alpha.105",
|
|
315
317
|
"dependencies": [
|
|
316
318
|
"@agimon-ai/po-core",
|
|
317
319
|
"@agimon-ai/po-web-components",
|
|
@@ -319,7 +321,7 @@
|
|
|
319
321
|
]
|
|
320
322
|
},
|
|
321
323
|
"@agimon-ai/po-read": {
|
|
322
|
-
"version": "0.0.0-alpha.
|
|
324
|
+
"version": "0.0.0-alpha.105",
|
|
323
325
|
"dependencies": [
|
|
324
326
|
"@agimon-ai/po-config",
|
|
325
327
|
"@agimon-ai/po-core",
|
|
@@ -329,7 +331,7 @@
|
|
|
329
331
|
]
|
|
330
332
|
},
|
|
331
333
|
"@agimon-ai/po-runner": {
|
|
332
|
-
"version": "0.0.0-alpha.
|
|
334
|
+
"version": "0.0.0-alpha.105",
|
|
333
335
|
"dependencies": [
|
|
334
336
|
"@agimon-ai/po-core",
|
|
335
337
|
"@agimon-ai/po-ui",
|
|
@@ -338,13 +340,13 @@
|
|
|
338
340
|
]
|
|
339
341
|
},
|
|
340
342
|
"@agimon-ai/po-sandbox": {
|
|
341
|
-
"version": "0.0.0-alpha.
|
|
343
|
+
"version": "0.0.0-alpha.105",
|
|
342
344
|
"dependencies": [
|
|
343
345
|
"@agimon-ai/po-core"
|
|
344
346
|
]
|
|
345
347
|
},
|
|
346
348
|
"@agimon-ai/po-session": {
|
|
347
|
-
"version": "0.0.0-alpha.
|
|
349
|
+
"version": "0.0.0-alpha.105",
|
|
348
350
|
"dependencies": [
|
|
349
351
|
"@agimon-ai/po-config",
|
|
350
352
|
"@agimon-ai/po-core",
|
|
@@ -352,7 +354,7 @@
|
|
|
352
354
|
]
|
|
353
355
|
},
|
|
354
356
|
"@agimon-ai/po-skill": {
|
|
355
|
-
"version": "0.0.0-alpha.
|
|
357
|
+
"version": "0.0.0-alpha.105",
|
|
356
358
|
"dependencies": [
|
|
357
359
|
"@agimon-ai/po-config",
|
|
358
360
|
"@agimon-ai/po-core",
|
|
@@ -361,7 +363,7 @@
|
|
|
361
363
|
]
|
|
362
364
|
},
|
|
363
365
|
"@agimon-ai/po-style-system": {
|
|
364
|
-
"version": "0.0.0-alpha.
|
|
366
|
+
"version": "0.0.0-alpha.105",
|
|
365
367
|
"dependencies": [
|
|
366
368
|
"@agimon-ai/po-core",
|
|
367
369
|
"@agimon-ai/po-web-components",
|
|
@@ -369,7 +371,7 @@
|
|
|
369
371
|
]
|
|
370
372
|
},
|
|
371
373
|
"@agimon-ai/po-task": {
|
|
372
|
-
"version": "0.0.0-alpha.
|
|
374
|
+
"version": "0.0.0-alpha.105",
|
|
373
375
|
"dependencies": [
|
|
374
376
|
"@agimon-ai/po-core",
|
|
375
377
|
"@agimon-ai/po-ui",
|
|
@@ -377,7 +379,7 @@
|
|
|
377
379
|
]
|
|
378
380
|
},
|
|
379
381
|
"@agimon-ai/po-team": {
|
|
380
|
-
"version": "0.0.0-alpha.
|
|
382
|
+
"version": "0.0.0-alpha.105",
|
|
381
383
|
"dependencies": [
|
|
382
384
|
"@agimon-ai/po-cache",
|
|
383
385
|
"@agimon-ai/po-config",
|
|
@@ -389,7 +391,7 @@
|
|
|
389
391
|
]
|
|
390
392
|
},
|
|
391
393
|
"@agimon-ai/po-template-advanced": {
|
|
392
|
-
"version": "0.0.0-alpha.
|
|
394
|
+
"version": "0.0.0-alpha.105",
|
|
393
395
|
"dependencies": [
|
|
394
396
|
"@agimon-ai/po-core",
|
|
395
397
|
"@agimon-ai/po-web-components",
|
|
@@ -397,7 +399,7 @@
|
|
|
397
399
|
]
|
|
398
400
|
},
|
|
399
401
|
"@agimon-ai/po-template-elegant": {
|
|
400
|
-
"version": "0.0.0-alpha.
|
|
402
|
+
"version": "0.0.0-alpha.105",
|
|
401
403
|
"dependencies": [
|
|
402
404
|
"@agimon-ai/po-core",
|
|
403
405
|
"@agimon-ai/po-web-components",
|
|
@@ -405,7 +407,7 @@
|
|
|
405
407
|
]
|
|
406
408
|
},
|
|
407
409
|
"@agimon-ai/po-ui": {
|
|
408
|
-
"version": "0.0.0-alpha.
|
|
410
|
+
"version": "0.0.0-alpha.105",
|
|
409
411
|
"dependencies": [
|
|
410
412
|
"@agimon-ai/po-core",
|
|
411
413
|
"@agimon-ai/po-hashline",
|
|
@@ -414,7 +416,7 @@
|
|
|
414
416
|
]
|
|
415
417
|
},
|
|
416
418
|
"@agimon-ai/po-user-feedback": {
|
|
417
|
-
"version": "0.0.0-alpha.
|
|
419
|
+
"version": "0.0.0-alpha.105",
|
|
418
420
|
"dependencies": [
|
|
419
421
|
"@agimon-ai/po-core",
|
|
420
422
|
"@agimon-ai/po-minor-mode",
|
|
@@ -423,14 +425,14 @@
|
|
|
423
425
|
]
|
|
424
426
|
},
|
|
425
427
|
"@agimon-ai/po-vault": {
|
|
426
|
-
"version": "0.0.0-alpha.
|
|
428
|
+
"version": "0.0.0-alpha.105",
|
|
427
429
|
"dependencies": [
|
|
428
430
|
"@agimon-ai/po-core",
|
|
429
431
|
"@agimon-ai/po-db"
|
|
430
432
|
]
|
|
431
433
|
},
|
|
432
434
|
"@agimon-ai/po-vibe-lint": {
|
|
433
|
-
"version": "0.0.1-alpha.
|
|
435
|
+
"version": "0.0.1-alpha.74",
|
|
434
436
|
"dependencies": [
|
|
435
437
|
"@agimon-ai/po-config",
|
|
436
438
|
"@agimon-ai/po-core",
|
|
@@ -440,7 +442,7 @@
|
|
|
440
442
|
]
|
|
441
443
|
},
|
|
442
444
|
"@agimon-ai/po-voice": {
|
|
443
|
-
"version": "0.0.0-alpha.
|
|
445
|
+
"version": "0.0.0-alpha.105",
|
|
444
446
|
"dependencies": [
|
|
445
447
|
"@agimon-ai/po-config",
|
|
446
448
|
"@agimon-ai/po-core",
|
|
@@ -452,11 +454,11 @@
|
|
|
452
454
|
]
|
|
453
455
|
},
|
|
454
456
|
"@agimon-ai/po-web-components": {
|
|
455
|
-
"version": "0.0.0-alpha.
|
|
457
|
+
"version": "0.0.0-alpha.105",
|
|
456
458
|
"dependencies": []
|
|
457
459
|
},
|
|
458
460
|
"@agimon-ai/po-web-dashboard": {
|
|
459
|
-
"version": "0.0.0-alpha.
|
|
461
|
+
"version": "0.0.0-alpha.105",
|
|
460
462
|
"dependencies": [
|
|
461
463
|
"@agimon-ai/po-core",
|
|
462
464
|
"@agimon-ai/po-web-components",
|
|
@@ -464,18 +466,18 @@
|
|
|
464
466
|
]
|
|
465
467
|
},
|
|
466
468
|
"@agimon-ai/po-web-search": {
|
|
467
|
-
"version": "0.0.0-alpha.
|
|
469
|
+
"version": "0.0.0-alpha.104",
|
|
468
470
|
"dependencies": [
|
|
469
471
|
"@agimon-ai/po-core",
|
|
470
472
|
"@agimon-ai/po-web-components"
|
|
471
473
|
]
|
|
472
474
|
},
|
|
473
475
|
"@agimon-ai/po-web-security": {
|
|
474
|
-
"version": "0.0.0-alpha.
|
|
476
|
+
"version": "0.0.0-alpha.105",
|
|
475
477
|
"dependencies": []
|
|
476
478
|
},
|
|
477
479
|
"@agimon-ai/po-workflow": {
|
|
478
|
-
"version": "0.0.0-alpha.
|
|
480
|
+
"version": "0.0.0-alpha.105",
|
|
479
481
|
"dependencies": [
|
|
480
482
|
"@agimon-ai/po-core",
|
|
481
483
|
"@agimon-ai/po-ui",
|
package/dist/package.cjs
CHANGED
package/dist/package.mjs
CHANGED
|
@@ -2,15 +2,17 @@ const require_runtime = require("../../../_virtual/_rolldown/runtime.cjs");
|
|
|
2
2
|
const require_builders_cli_extensionAssembler_index = require("../../../builders/cli/extensionAssembler/index.cjs");
|
|
3
3
|
const require_packageUrl = require("./packageUrl.cjs");
|
|
4
4
|
const require_index = require("../web/index.cjs");
|
|
5
|
+
const require_index$1 = require("../../composition/layerPackageInstaller/index.cjs");
|
|
5
6
|
const require_sessionComposition = require("../cli/sessionComposition.cjs");
|
|
6
7
|
const require_mcpBundle = require("./mcpBundle.cjs");
|
|
7
|
-
const require_index$
|
|
8
|
+
const require_index$2 = require("./index.cjs");
|
|
8
9
|
const require_packageReloadCheck = require("./packageReloadCheck.cjs");
|
|
9
10
|
let _agimon_ai_po_core_apiContracts = require("@agimon-ai/po-core/apiContracts");
|
|
10
11
|
let node_path = require("node:path");
|
|
11
12
|
node_path = require_runtime.__toESM(node_path, 1);
|
|
12
13
|
let _agimon_ai_po_config_majorModes = require("@agimon-ai/po-config/majorModes");
|
|
13
14
|
let _agimon_ai_po_core_platform = require("@agimon-ai/po-core/platform");
|
|
15
|
+
let _agimon_ai_po_core_serverPlugin = require("@agimon-ai/po-core/serverPlugin");
|
|
14
16
|
//#region src/builders/server/bundlerService.ts
|
|
15
17
|
const MANIFEST_FIELDS = [
|
|
16
18
|
"poServer",
|
|
@@ -104,6 +106,7 @@ function createBundlerService(options) {
|
|
|
104
106
|
const memo = memoFor(root);
|
|
105
107
|
return shared(() => memo.packageEntries, (value) => memo.packageEntries = value, async () => {
|
|
106
108
|
const load = ++entriesLoads;
|
|
109
|
+
const shippedPackages = await require_index$1.catalogPackageNames(options.environment);
|
|
107
110
|
const selected = compositions(root);
|
|
108
111
|
const roots = await Promise.all(selected.map(async (composition) => ({
|
|
109
112
|
majorMode: composition.majorMode?.name,
|
|
@@ -111,8 +114,15 @@ function createBundlerService(options) {
|
|
|
111
114
|
})));
|
|
112
115
|
await options.onCompositions?.(root, selected, [...new Set(roots.flatMap((entry) => entry.roots))]);
|
|
113
116
|
const entries = [];
|
|
114
|
-
for (const { declaration, module, owners } of await require_index$
|
|
117
|
+
for (const { declaration, module, owners } of await require_index$2.serverPackageCandidates(selected, options.onNotice, options.files)) {
|
|
115
118
|
let apiContract;
|
|
119
|
+
let webMetadata;
|
|
120
|
+
const poWeb = (await manifestOf(declaration.packageDir))?.poWeb;
|
|
121
|
+
if (poWeb !== null && typeof poWeb === "object" && !Array.isArray(poWeb)) {
|
|
122
|
+
const brain = poWeb.brain;
|
|
123
|
+
webMetadata = (0, _agimon_ai_po_core_serverPlugin.parsePoWebBrainMetadata)(brain);
|
|
124
|
+
if (brain !== void 0 && webMetadata === void 0) options.onNotice?.(`${declaration.packageName}: invalid poWeb.brain metadata unavailable`);
|
|
125
|
+
}
|
|
116
126
|
try {
|
|
117
127
|
if (!options.files) throw new Error("No file service");
|
|
118
128
|
const entry = JSON.parse((0, _agimon_ai_po_core_platform.getOrThrow)(await options.files.readTextFile(node_path.default.join(declaration.packageDir, "package.json"), _agimon_ai_po_core_platform.BACKGROUND_CONTEXT))).poServer?.contracts?.dist;
|
|
@@ -128,7 +138,9 @@ function createBundlerService(options) {
|
|
|
128
138
|
}
|
|
129
139
|
entries.push({
|
|
130
140
|
apiContract,
|
|
141
|
+
...webMetadata === void 0 ? {} : { webMetadata },
|
|
131
142
|
packageName: declaration.packageName,
|
|
143
|
+
origin: require_builders_cli_extensionAssembler_index.isFixedHostPackage(declaration.packageName) || shippedPackages?.has(declaration.packageName) ? "po" : shippedPackages === void 0 ? "unknown" : "personal",
|
|
132
144
|
entry: declaration.entry,
|
|
133
145
|
module,
|
|
134
146
|
url: await packageUrls.urlFor(module),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bundlerService.cjs","names":["createPackageUrls","createLiveModuleCache","createPackageReloadCheck","rootCompositions","loadMajorModesConfig","resolveLayers","compositionPackageRoots","serverPackageCandidates","getOrThrow","path","BACKGROUND_CONTEXT","parseApiContract","isFixedHostPackage","mcpPluginCandidates"],"sources":["../../../../src/builders/server/bundlerService.ts"],"sourcesContent":["import path from 'node:path';\n\nimport { loadMajorModesConfig, resolveLayers } from '@agimon-ai/po-config/majorModes';\nimport { parseApiContract, type PoApiContract } from '@agimon-ai/po-core/apiContracts';\nimport type { LiveMcpPluginEntry } from '@agimon-ai/po-core/mcpFacet';\nimport type { PoApiScope } from '@agimon-ai/po-core/packageApi';\nimport { BACKGROUND_CONTEXT, getOrThrow } from '@agimon-ai/po-core/platform';\nimport type { FileSystem } from '@agimon-ai/po-core/platform';\nimport type { LiveServerPackageEntry } from '@agimon-ai/po-core/serverPlugin';\n\nimport { type ExtensionComposition, isFixedHostPackage } from '../cli/extensionAssembler';\nimport { rootCompositions } from '../cli/sessionComposition';\nimport { compositionPackageRoots } from '../web';\nimport { serverPackageCandidates } from './index';\nimport { type McpPluginCandidate, mcpPluginCandidates } from './mcpBundle';\nimport { createLiveModuleCache, createPackageReloadCheck, type ScopeChange } from './packageReloadCheck';\nimport { createPackageUrls } from './packageUrl';\n\nexport interface BundlerServiceOptions {\n readonly files?: FileSystem;\n readonly homeDirectory: string;\n readonly environment: NodeJS.ProcessEnv;\n /** Installed host payload: import its packages in place without writing content snapshots beside them. */\n readonly immutableRoot?: string;\n /** Called after a root's compositions are resolved, so the caller can watch what they read. */\n readonly onCompositions?: (\n root: string,\n compositions: readonly ExtensionComposition[],\n packageRoots: readonly string[],\n ) => void | Promise<void>;\n /** Reports a package left out of a root's load, so one broken package never stops the rest. */\n readonly onNotice?: (message: string) => void;\n}\n\nconst MANIFEST_FIELDS = ['poServer', 'poWeb', 'poNative'] as const;\n\n/** Whether any server, web or native block of a package manifest names the global scope. */\nfunction declaresGlobalScope(manifest: Record<string, unknown>): boolean {\n return MANIFEST_FIELDS.some((field) => {\n const value = manifest[field];\n const blocks: unknown[] = Array.isArray(value) ? value : value === undefined ? [] : [value];\n return blocks.some((block) => {\n const scopes = (block as { scopes?: unknown } | null)?.scopes;\n return Array.isArray(scopes) && scopes.includes('global');\n });\n });\n}\n\nexport interface RootSelection {\n readonly root: string;\n readonly majorMode: string;\n readonly activeLayers: string[];\n}\n\ninterface RootMcp {\n readonly candidates: McpPluginCandidate[];\n readonly entries: LiveMcpPluginEntry[];\n}\n\ninterface RootMemo {\n compositions?: ExtensionComposition[];\n selection?: RootSelection;\n packageEntries?: Promise<LiveServerPackageEntry[]>;\n mcp?: Promise<RootMcp>;\n}\n\n/** One root's package roots per major mode, from the entries load that started last. */\ninterface PreparedRoots {\n readonly load: number;\n readonly roots: { majorMode: string | undefined; roots: string[] }[];\n}\n\n/**\n * Process-level owner of what Po compiles and loads: content-addressed package URLs, the\n * live module cache, the poison set, per-scope reload tracking, and a per-root memo of the\n * compositions and entries a root selects. Every reader shares one computation until\n * `invalidate`; the caller decides when (a finished sync or a watched change).\n */\nexport function createBundlerService(options: BundlerServiceOptions) {\n /** Mutable packages get content-addressed URLs; the host's installed payload imports in place. */\n const packageUrls = createPackageUrls({ immutableRoot: options.immutableRoot, files: options.files });\n /** URLs whose live import timed out or threw; skipped by every loader until the content changes. */\n const poisoned = new Set<string>();\n /** Imports each content-addressed URL once, so a reload imports only what changed. */\n const importer = createLiveModuleCache();\n /** The package identities each mounted global and workspace scope last loaded. */\n const reloadCheck = createPackageReloadCheck();\n const memos = new Map<string, RootMemo>();\n /**\n * Kept outside the memo, because a watched change invalidates while other scope checks are\n * between awaiting `packageEntries` and reading `packageRoots`; they keep the roots that load\n * prepared until a newer load replaces them.\n */\n const preparedRoots = new Map<string, PreparedRoots>();\n let entriesLoads = 0;\n const memoFor = (root: string): RootMemo => {\n let memo = memos.get(root);\n if (memo === undefined) {\n memo = {};\n memos.set(root, memo);\n }\n return memo;\n };\n /** A pending load shared by every reader; a failed one is dropped so the next reader retries. */\n const shared = <T>(\n read: () => Promise<T> | undefined,\n write: (value: Promise<T> | undefined) => void,\n load: () => Promise<T>,\n ) => {\n const existing = read();\n if (existing !== undefined) return existing;\n const loading = load();\n write(loading);\n loading.catch(() => {\n if (read() === loading) write(undefined);\n });\n return loading;\n };\n\n /**\n * Every composition the root's config can select, one per major mode, resolved live.\n * A package sync has not prepared yet is left out with a diagnostic.\n */\n const compositions = (root: string): ExtensionComposition[] => {\n const memo = memoFor(root);\n if (memo.compositions === undefined) {\n memo.compositions = rootCompositions({\n root,\n homeDirectory: options.homeDirectory,\n environment: options.environment,\n tolerateUnsynced: true,\n });\n }\n return memo.compositions;\n };\n\n const defaultSelection = (root: string): RootSelection => {\n const memo = memoFor(root);\n if (memo.selection === undefined) {\n const config = loadMajorModesConfig(root, options.homeDirectory, options.environment);\n const majorMode = config.defaultMajorMode;\n memo.selection = { root, majorMode, activeLayers: resolveLayers(config, majorMode) };\n }\n return memo.selection;\n };\n\n /** The root's server package entries, each with the URL its current package content imports from. */\n const packageEntries = (root: string): Promise<LiveServerPackageEntry[]> => {\n const memo = memoFor(root);\n return shared(\n () => memo.packageEntries,\n (value) => (memo.packageEntries = value),\n async () => {\n const load = ++entriesLoads;\n const selected = compositions(root);\n const roots = await Promise.all(\n selected.map(async (composition) => ({\n majorMode: composition.majorMode?.name,\n roots: await compositionPackageRoots([composition], options.files),\n })),\n );\n await options.onCompositions?.(root, selected, [...new Set(roots.flatMap((entry) => entry.roots))]);\n const entries: LiveServerPackageEntry[] = [];\n for (const { declaration, module, owners } of await serverPackageCandidates(\n selected,\n options.onNotice,\n options.files,\n )) {\n let apiContract: PoApiContract | undefined;\n try {\n if (!options.files) throw new Error('No file service');\n const manifest = JSON.parse(\n getOrThrow(\n await options.files.readTextFile(path.join(declaration.packageDir, 'package.json'), BACKGROUND_CONTEXT),\n ),\n );\n const entry: unknown = manifest.poServer?.contracts?.dist;\n if (typeof entry !== 'string' || !entry.startsWith('./') || entry.includes('..') || /[\\\\%?#]/u.test(entry))\n throw new Error('Invalid contract entry');\n const built = getOrThrow(\n await options.files.canonicalPath(path.join(declaration.packageDir, entry), BACKGROUND_CONTEXT),\n );\n const root = getOrThrow(await options.files.canonicalPath(declaration.packageDir, BACKGROUND_CONTEXT));\n const relative = path.relative(root, built);\n if (relative.startsWith('..') || path.isAbsolute(relative)) throw new Error('Contract escapes package');\n const module = (await importer(await packageUrls.urlFor(built))) as { default?: unknown };\n apiContract = parseApiContract(module.default);\n } catch {\n // Missing contracts fail closed for federation, but do not break ordinary local APIs.\n apiContract = undefined;\n }\n entries.push({\n apiContract,\n packageName: declaration.packageName,\n entry: declaration.entry,\n module,\n url: await packageUrls.urlFor(module),\n scopes: declaration.scopes,\n owners,\n // A manifest alone cannot make Po fatal: only a fixed host package may be required.\n required: declaration.required === true && isFixedHostPackage(declaration.packageName),\n });\n }\n // A load that started earlier but finished later never replaces a newer load's roots.\n if ((preparedRoots.get(root)?.load ?? 0) < load) preparedRoots.set(root, { load, roots });\n return entries;\n },\n );\n };\n\n const manifestOf = async (packageRoot: string): Promise<Record<string, unknown> | undefined> => {\n if (!options.files) return undefined;\n const text = await options.files.readTextFile(path.join(packageRoot, 'package.json'), BACKGROUND_CONTEXT);\n if (!text.ok) return undefined;\n try {\n return JSON.parse(text.value) as Record<string, unknown>;\n } catch (error) {\n options.onNotice?.(`'${packageRoot}' manifest is not JSON: ${String(error)}`);\n return undefined;\n }\n };\n /** The root's MCP plugin candidates and their entries with current URLs. */\n const mcpEntries = (root: string): Promise<RootMcp> => {\n const memo = memoFor(root);\n return shared(\n () => memo.mcp,\n (value) => (memo.mcp = value),\n async () => {\n const candidates = await mcpPluginCandidates(compositions(root), options.files);\n const entries: LiveMcpPluginEntry[] = [];\n for (const { declaration, module, owners } of candidates)\n entries.push({\n packageName: declaration.packageName,\n ...(declaration.ui === undefined ? {} : { widgets: declaration.ui.widgets }),\n entry: declaration.entry,\n module,\n url: await packageUrls.urlFor(module),\n owners,\n });\n return { candidates, entries };\n },\n );\n };\n\n /**\n * What a global or workspace scope loads: one identity per server package entry in that scope.\n * The URL changes with package content; `selection` carries ownership and the root's\n * default mode, so a modes.yaml change that selects a package in or out is reloaded too.\n */\n const scopeIdentities = (root: string, scope: PoApiScope, entries: readonly LiveServerPackageEntry[]) => {\n const { majorMode, activeLayers } = defaultSelection(root);\n return entries\n .filter((entry) => entry.scopes.includes(scope))\n .map((entry) => ({\n module: entry.module,\n url: entry.url,\n selection: JSON.stringify([entry.owners, entry.required === true, majorMode, activeLayers]),\n }));\n };\n\n return {\n packageUrls,\n poisoned,\n importer,\n compositions,\n defaultSelection,\n packageEntries,\n mcpEntries,\n /**\n * Every package root the root's config can select, over all its major modes or only `majorMode`'s,\n * as the latest `packageEntries` load prepared them; an `invalidate` keeps them until the next load.\n */\n packageRoots: (root: string, majorMode?: string): string[] => {\n const prepared = preparedRoots.get(root);\n if (prepared === undefined)\n throw new Error(`Package roots for '${root}' have not been prepared; await packageEntries first.`);\n return [\n ...new Set(\n prepared.roots\n .filter((entry) => majorMode === undefined || entry.majorMode === majorMode)\n .flatMap((entry) => entry.roots),\n ),\n ];\n },\n /** How the scope's current entries differ from what it last committed. */\n diffScope: async (key: string, root: string, scope: PoApiScope): Promise<ScopeChange> =>\n reloadCheck.diff(key, scopeIdentities(root, scope, await packageEntries(root))),\n /** Records what a scope installed, so the next diff compares against it; `failed` packages are retried. */\n commitScope: (\n key: string,\n root: string,\n scope: PoApiScope,\n entries: readonly LiveServerPackageEntry[],\n failed: ReadonlySet<string> = new Set(),\n ): void =>\n reloadCheck.commit(\n key,\n scopeIdentities(root, scope, entries),\n new Set(entries.filter((entry) => failed.has(entry.packageName)).map((entry) => entry.module)),\n ),\n forgetScope: (key: string): void => reloadCheck.forget(key),\n /** Drops every root's memo; the next reader recomputes from disk. */\n invalidate: (): void => memos.clear(),\n /**\n * The packages a root's default selection offers the global scope: each that declares the global scope,\n * and whether it has a global server entry there. Fixed host packages always come from the global composition.\n */\n globalPackages: async (\n root: string,\n ): Promise<{ readonly name: string; readonly packageRoot: string; readonly server: boolean }[]> => {\n const entries = await packageEntries(root);\n const { majorMode, activeLayers } = defaultSelection(root);\n const selected = (preparedRoots.get(root)?.roots ?? [])\n .filter((entry) => entry.majorMode === majorMode)\n .flatMap((entry) => entry.roots);\n const packages: { name: string; packageRoot: string; server: boolean }[] = [];\n for (const packageRoot of new Set(selected)) {\n const manifest = await manifestOf(packageRoot);\n const name = manifest?.name;\n if (manifest === undefined || typeof name !== 'string' || isFixedHostPackage(name)) continue;\n if (!declaresGlobalScope(manifest)) continue;\n const server = entries.some(\n (entry) =>\n entry.packageName === name &&\n entry.scopes.includes('global') &&\n entry.owners.some(\n (owner) =>\n owner.majorMode === majorMode && (owner.layer === 'default' || activeLayers.includes(owner.layer)),\n ),\n );\n packages.push({ name, packageRoot, server });\n }\n return packages;\n },\n };\n}\n\nexport type BundlerService = ReturnType<typeof createBundlerService>;\n"],"mappings":";;;;;;;;;;;;;;AAkCA,MAAM,kBAAkB;CAAC;CAAY;CAAS;AAAU;;AAGxD,SAAS,oBAAoB,UAA4C;CACvE,OAAO,gBAAgB,MAAM,UAAU;EACrC,MAAM,QAAQ,SAAS;EAEvB,QAD0B,MAAM,QAAQ,KAAK,IAAI,QAAQ,UAAU,KAAA,IAAY,CAAC,IAAI,CAAC,KAAK,EAAA,CA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AAY,OACV,KACA,gBAAgB,MAAM,OAAO,OAAO,GACpC,IAAI,IAAI,QAAQ,QAAQ,UAAU,OAAO,IAAI,MAAM,WAAW,CAAC,CAAC,CAAC,KAAK,UAAU,MAAM,MAAM,CAAC,CAC/F;EACF,cAAc,QAAsB,YAAY,OAAO,GAAG;;EAE1D,kBAAwB,MAAM,MAAM;;;;;EAKpC,gBAAgB,OACd,SACiG;GACjG,MAAM,UAAU,MAAM,eAAe,IAAI;GACzC,MAAM,EAAE,WAAW,iBAAiB,iBAAiB,IAAI;GACzD,MAAM,YAAY,cAAc,IAAI,IAAI,CAAC,EAAE,SAAS,CAAC,EAAA,CAClD,QAAQ,UAAU,MAAM,cAAc,SAAS,CAAC,CAChD,SAAS,UAAU,MAAM,KAAK;GACjC,MAAM,WAAqE,CAAC;GAC5E,KAAK,MAAM,eAAe,IAAI,IAAI,QAAQ,GAAG;IAC3C,MAAM,WAAW,MAAM,WAAW,WAAW;IAC7C,MAAM,OAAO,UAAU;IACvB,IAAI,aAAa,KAAA,KAAa,OAAO,SAAS,YAAYD,8CAAAA,mBAAmB,IAAI,GAAG;IACpF,IAAI,CAAC,oBAAoB,QAAQ,GAAG;IACpC,MAAM,SAAS,QAAQ,MACpB,UACC,MAAM,gBAAgB,QACtB,MAAM,OAAO,SAAS,QAAQ,KAC9B,MAAM,OAAO,MACV,UACC,MAAM,cAAc,cAAc,MAAM,UAAU,aAAa,aAAa,SAAS,MAAM,KAAK,EACpG,CACJ;IACA,SAAS,KAAK;KAAE;KAAM;KAAa;IAAO,CAAC;GAC7C;GACA,OAAO;EACT;CACF;AACF"}
|
|
1
|
+
{"version":3,"file":"bundlerService.cjs","names":["createPackageUrls","createLiveModuleCache","createPackageReloadCheck","rootCompositions","loadMajorModesConfig","resolveLayers","catalogPackageNames","compositionPackageRoots","serverPackageCandidates","parseWebMetadata","getOrThrow","path","BACKGROUND_CONTEXT","parseApiContract","isFixedHostPackage","mcpPluginCandidates"],"sources":["../../../../src/builders/server/bundlerService.ts"],"sourcesContent":["import path from 'node:path';\n\nimport { loadMajorModesConfig, resolveLayers } from '@agimon-ai/po-config/majorModes';\nimport { parseApiContract, type PoApiContract } from '@agimon-ai/po-core/apiContracts';\nimport type { LiveMcpPluginEntry } from '@agimon-ai/po-core/mcpFacet';\nimport type { PoApiScope } from '@agimon-ai/po-core/packageApi';\nimport { BACKGROUND_CONTEXT, getOrThrow } from '@agimon-ai/po-core/platform';\nimport type { FileSystem } from '@agimon-ai/po-core/platform';\nimport {\n parsePoWebBrainMetadata as parseWebMetadata,\n type LiveServerPackageEntry,\n} from '@agimon-ai/po-core/serverPlugin';\nexport { parsePoWebBrainMetadata as parseWebMetadata } from '@agimon-ai/po-core/serverPlugin';\n\nimport { catalogPackageNames } from '../../composition/layerPackageInstaller';\nimport { type ExtensionComposition, isFixedHostPackage } from '../cli/extensionAssembler';\nimport { rootCompositions } from '../cli/sessionComposition';\nimport { compositionPackageRoots } from '../web';\nimport { serverPackageCandidates } from './index';\nimport { type McpPluginCandidate, mcpPluginCandidates } from './mcpBundle';\nimport { createLiveModuleCache, createPackageReloadCheck, type ScopeChange } from './packageReloadCheck';\nimport { createPackageUrls } from './packageUrl';\n\nexport interface BundlerServiceOptions {\n readonly files?: FileSystem;\n readonly homeDirectory: string;\n readonly environment: NodeJS.ProcessEnv;\n /** Installed host payload: import its packages in place without writing content snapshots beside them. */\n readonly immutableRoot?: string;\n /** Called after a root's compositions are resolved, so the caller can watch what they read. */\n readonly onCompositions?: (\n root: string,\n compositions: readonly ExtensionComposition[],\n packageRoots: readonly string[],\n ) => void | Promise<void>;\n /** Reports a package left out of a root's load, so one broken package never stops the rest. */\n readonly onNotice?: (message: string) => void;\n}\n\nconst MANIFEST_FIELDS = ['poServer', 'poWeb', 'poNative'] as const;\n\n/** Whether any server, web or native block of a package manifest names the global scope. */\nfunction declaresGlobalScope(manifest: Record<string, unknown>): boolean {\n return MANIFEST_FIELDS.some((field) => {\n const value = manifest[field];\n const blocks: unknown[] = Array.isArray(value) ? value : value === undefined ? [] : [value];\n return blocks.some((block) => {\n const scopes = (block as { scopes?: unknown } | null)?.scopes;\n return Array.isArray(scopes) && scopes.includes('global');\n });\n });\n}\n\nexport interface RootSelection {\n readonly root: string;\n readonly majorMode: string;\n readonly activeLayers: string[];\n}\n\ninterface RootMcp {\n readonly candidates: McpPluginCandidate[];\n readonly entries: LiveMcpPluginEntry[];\n}\n\ninterface RootMemo {\n compositions?: ExtensionComposition[];\n selection?: RootSelection;\n packageEntries?: Promise<LiveServerPackageEntry[]>;\n mcp?: Promise<RootMcp>;\n}\n\n/** One root's package roots per major mode, from the entries load that started last. */\ninterface PreparedRoots {\n readonly load: number;\n readonly roots: { majorMode: string | undefined; roots: string[] }[];\n}\n\n/**\n * Process-level owner of what Po compiles and loads: content-addressed package URLs, the\n * live module cache, the poison set, per-scope reload tracking, and a per-root memo of the\n * compositions and entries a root selects. Every reader shares one computation until\n * `invalidate`; the caller decides when (a finished sync or a watched change).\n */\nexport function createBundlerService(options: BundlerServiceOptions) {\n /** Mutable packages get content-addressed URLs; the host's installed payload imports in place. */\n const packageUrls = createPackageUrls({ immutableRoot: options.immutableRoot, files: options.files });\n /** URLs whose live import timed out or threw; skipped by every loader until the content changes. */\n const poisoned = new Set<string>();\n /** Imports each content-addressed URL once, so a reload imports only what changed. */\n const importer = createLiveModuleCache();\n /** The package identities each mounted global and workspace scope last loaded. */\n const reloadCheck = createPackageReloadCheck();\n const memos = new Map<string, RootMemo>();\n /**\n * Kept outside the memo, because a watched change invalidates while other scope checks are\n * between awaiting `packageEntries` and reading `packageRoots`; they keep the roots that load\n * prepared until a newer load replaces them.\n */\n const preparedRoots = new Map<string, PreparedRoots>();\n let entriesLoads = 0;\n const memoFor = (root: string): RootMemo => {\n let memo = memos.get(root);\n if (memo === undefined) {\n memo = {};\n memos.set(root, memo);\n }\n return memo;\n };\n /** A pending load shared by every reader; a failed one is dropped so the next reader retries. */\n const shared = <T>(\n read: () => Promise<T> | undefined,\n write: (value: Promise<T> | undefined) => void,\n load: () => Promise<T>,\n ) => {\n const existing = read();\n if (existing !== undefined) return existing;\n const loading = load();\n write(loading);\n loading.catch(() => {\n if (read() === loading) write(undefined);\n });\n return loading;\n };\n\n /**\n * Every composition the root's config can select, one per major mode, resolved live.\n * A package sync has not prepared yet is left out with a diagnostic.\n */\n const compositions = (root: string): ExtensionComposition[] => {\n const memo = memoFor(root);\n if (memo.compositions === undefined) {\n memo.compositions = rootCompositions({\n root,\n homeDirectory: options.homeDirectory,\n environment: options.environment,\n tolerateUnsynced: true,\n });\n }\n return memo.compositions;\n };\n\n const defaultSelection = (root: string): RootSelection => {\n const memo = memoFor(root);\n if (memo.selection === undefined) {\n const config = loadMajorModesConfig(root, options.homeDirectory, options.environment);\n const majorMode = config.defaultMajorMode;\n memo.selection = { root, majorMode, activeLayers: resolveLayers(config, majorMode) };\n }\n return memo.selection;\n };\n\n /** The root's server package entries, each with the URL its current package content imports from. */\n const packageEntries = (root: string): Promise<LiveServerPackageEntry[]> => {\n const memo = memoFor(root);\n return shared(\n () => memo.packageEntries,\n (value) => (memo.packageEntries = value),\n async () => {\n const load = ++entriesLoads;\n const shippedPackages = await catalogPackageNames(options.environment);\n const selected = compositions(root);\n const roots = await Promise.all(\n selected.map(async (composition) => ({\n majorMode: composition.majorMode?.name,\n roots: await compositionPackageRoots([composition], options.files),\n })),\n );\n await options.onCompositions?.(root, selected, [...new Set(roots.flatMap((entry) => entry.roots))]);\n const entries: LiveServerPackageEntry[] = [];\n for (const { declaration, module, owners } of await serverPackageCandidates(\n selected,\n options.onNotice,\n options.files,\n )) {\n let apiContract: PoApiContract | undefined;\n let webMetadata: LiveServerPackageEntry['webMetadata'];\n const packageManifest = await manifestOf(declaration.packageDir);\n const poWeb = packageManifest?.poWeb;\n if (poWeb !== null && typeof poWeb === 'object' && !Array.isArray(poWeb)) {\n const brain = (poWeb as Record<string, unknown>).brain;\n webMetadata = parseWebMetadata(brain);\n if (brain !== undefined && webMetadata === undefined)\n options.onNotice?.(`${declaration.packageName}: invalid poWeb.brain metadata unavailable`);\n }\n try {\n if (!options.files) throw new Error('No file service');\n const manifest = JSON.parse(\n getOrThrow(\n await options.files.readTextFile(path.join(declaration.packageDir, 'package.json'), BACKGROUND_CONTEXT),\n ),\n );\n const entry: unknown = manifest.poServer?.contracts?.dist;\n if (typeof entry !== 'string' || !entry.startsWith('./') || entry.includes('..') || /[\\\\%?#]/u.test(entry))\n throw new Error('Invalid contract entry');\n const built = getOrThrow(\n await options.files.canonicalPath(path.join(declaration.packageDir, entry), BACKGROUND_CONTEXT),\n );\n const root = getOrThrow(await options.files.canonicalPath(declaration.packageDir, BACKGROUND_CONTEXT));\n const relative = path.relative(root, built);\n if (relative.startsWith('..') || path.isAbsolute(relative)) throw new Error('Contract escapes package');\n const module = (await importer(await packageUrls.urlFor(built))) as { default?: unknown };\n apiContract = parseApiContract(module.default);\n } catch {\n // Missing contracts fail closed for federation, but do not break ordinary local APIs.\n apiContract = undefined;\n }\n entries.push({\n apiContract,\n ...(webMetadata === undefined ? {} : { webMetadata }),\n packageName: declaration.packageName,\n origin:\n isFixedHostPackage(declaration.packageName) || shippedPackages?.has(declaration.packageName)\n ? 'po'\n : shippedPackages === undefined\n ? 'unknown'\n : 'personal',\n entry: declaration.entry,\n module,\n url: await packageUrls.urlFor(module),\n scopes: declaration.scopes,\n owners,\n // A manifest alone cannot make Po fatal: only a fixed host package may be required.\n required: declaration.required === true && isFixedHostPackage(declaration.packageName),\n });\n }\n // A load that started earlier but finished later never replaces a newer load's roots.\n if ((preparedRoots.get(root)?.load ?? 0) < load) preparedRoots.set(root, { load, roots });\n return entries;\n },\n );\n };\n\n const manifestOf = async (packageRoot: string): Promise<Record<string, unknown> | undefined> => {\n if (!options.files) return undefined;\n const text = await options.files.readTextFile(path.join(packageRoot, 'package.json'), BACKGROUND_CONTEXT);\n if (!text.ok) return undefined;\n try {\n return JSON.parse(text.value) as Record<string, unknown>;\n } catch (error) {\n options.onNotice?.(`'${packageRoot}' manifest is not JSON: ${String(error)}`);\n return undefined;\n }\n };\n /** The root's MCP plugin candidates and their entries with current URLs. */\n const mcpEntries = (root: string): Promise<RootMcp> => {\n const memo = memoFor(root);\n return shared(\n () => memo.mcp,\n (value) => (memo.mcp = value),\n async () => {\n const candidates = await mcpPluginCandidates(compositions(root), options.files);\n const entries: LiveMcpPluginEntry[] = [];\n for (const { declaration, module, owners } of candidates)\n entries.push({\n packageName: declaration.packageName,\n ...(declaration.ui === undefined ? {} : { widgets: declaration.ui.widgets }),\n entry: declaration.entry,\n module,\n url: await packageUrls.urlFor(module),\n owners,\n });\n return { candidates, entries };\n },\n );\n };\n\n /**\n * What a global or workspace scope loads: one identity per server package entry in that scope.\n * The URL changes with package content; `selection` carries ownership and the root's\n * default mode, so a modes.yaml change that selects a package in or out is reloaded too.\n */\n const scopeIdentities = (root: string, scope: PoApiScope, entries: readonly LiveServerPackageEntry[]) => {\n const { majorMode, activeLayers } = defaultSelection(root);\n return entries\n .filter((entry) => entry.scopes.includes(scope))\n .map((entry) => ({\n module: entry.module,\n url: entry.url,\n selection: JSON.stringify([entry.owners, entry.required === true, majorMode, activeLayers]),\n }));\n };\n\n return {\n packageUrls,\n poisoned,\n importer,\n compositions,\n defaultSelection,\n packageEntries,\n mcpEntries,\n /**\n * Every package root the root's config can select, over all its major modes or only `majorMode`'s,\n * as the latest `packageEntries` load prepared them; an `invalidate` keeps them until the next load.\n */\n packageRoots: (root: string, majorMode?: string): string[] => {\n const prepared = preparedRoots.get(root);\n if (prepared === undefined)\n throw new Error(`Package roots for '${root}' have not been prepared; await packageEntries first.`);\n return [\n ...new Set(\n prepared.roots\n .filter((entry) => majorMode === undefined || entry.majorMode === majorMode)\n .flatMap((entry) => entry.roots),\n ),\n ];\n },\n /** How the scope's current entries differ from what it last committed. */\n diffScope: async (key: string, root: string, scope: PoApiScope): Promise<ScopeChange> =>\n reloadCheck.diff(key, scopeIdentities(root, scope, await packageEntries(root))),\n /** Records what a scope installed, so the next diff compares against it; `failed` packages are retried. */\n commitScope: (\n key: string,\n root: string,\n scope: PoApiScope,\n entries: readonly LiveServerPackageEntry[],\n failed: ReadonlySet<string> = new Set(),\n ): void =>\n reloadCheck.commit(\n key,\n scopeIdentities(root, scope, entries),\n new Set(entries.filter((entry) => failed.has(entry.packageName)).map((entry) => entry.module)),\n ),\n forgetScope: (key: string): void => reloadCheck.forget(key),\n /** Drops every root's memo; the next reader recomputes from disk. */\n invalidate: (): void => memos.clear(),\n /**\n * The packages a root's default selection offers the global scope: each that declares the global scope,\n * and whether it has a global server entry there. Fixed host packages always come from the global composition.\n */\n globalPackages: async (\n root: string,\n ): Promise<{ readonly name: string; readonly packageRoot: string; readonly server: boolean }[]> => {\n const entries = await packageEntries(root);\n const { majorMode, activeLayers } = defaultSelection(root);\n const selected = (preparedRoots.get(root)?.roots ?? [])\n .filter((entry) => entry.majorMode === majorMode)\n .flatMap((entry) => entry.roots);\n const packages: { name: string; packageRoot: string; server: boolean }[] = [];\n for (const packageRoot of new Set(selected)) {\n const manifest = await manifestOf(packageRoot);\n const name = manifest?.name;\n if (manifest === undefined || typeof name !== 'string' || isFixedHostPackage(name)) continue;\n if (!declaresGlobalScope(manifest)) continue;\n const server = entries.some(\n (entry) =>\n entry.packageName === name &&\n entry.scopes.includes('global') &&\n entry.owners.some(\n (owner) =>\n owner.majorMode === majorMode && (owner.layer === 'default' || activeLayers.includes(owner.layer)),\n ),\n );\n packages.push({ name, packageRoot, server });\n }\n return packages;\n },\n };\n}\n\nexport type BundlerService = ReturnType<typeof createBundlerService>;\n"],"mappings":";;;;;;;;;;;;;;;;AAuCA,MAAM,kBAAkB;CAAC;CAAY;CAAS;AAAU;;AAGxD,SAAS,oBAAoB,UAA4C;CACvE,OAAO,gBAAgB,MAAM,UAAU;EACrC,MAAM,QAAQ,SAAS;EAEvB,QAD0B,MAAM,QAAQ,KAAK,IAAI,QAAQ,UAAU,KAAA,IAAY,CAAC,IAAI,CAAC,KAAK,EAAA,CAC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