@agimon-ai/po 0.0.0-alpha.3 → 0.0.0-alpha.31
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/LICENSE +149 -21
- package/README.md +20 -14
- package/dist/bin/cli.cjs +37 -14
- package/dist/bin/cli.cjs.map +1 -1
- package/dist/bin/cli.mjs +34 -14
- package/dist/bin/cli.mjs.map +1 -1
- package/dist/bin/{doomRunner.cjs → poRunner.cjs} +5 -5
- package/dist/bin/poRunner.cjs.map +1 -0
- package/dist/bin/{doomRunner.d.mts → poRunner.d.mts} +2 -2
- package/dist/bin/poRunner.d.mts.map +1 -0
- package/dist/bin/{doomRunner.mjs → poRunner.mjs} +5 -5
- package/dist/bin/poRunner.mjs.map +1 -0
- package/dist/builders/cli/extensionAssembler/index.cjs +14 -13
- package/dist/builders/cli/extensionAssembler/index.cjs.map +1 -1
- package/dist/builders/cli/extensionAssembler/index.d.mts +1 -1
- package/dist/builders/cli/extensionAssembler/index.d.mts.map +1 -1
- package/dist/builders/cli/extensionAssembler/index.mjs +15 -14
- package/dist/builders/cli/extensionAssembler/index.mjs.map +1 -1
- package/dist/catalog/index.json +78 -82
- package/dist/cli.cjs +1 -1
- package/dist/cli.mjs +1 -1
- package/dist/config.cjs +7 -7
- package/dist/config.d.mts +3 -3
- package/dist/config.mjs +3 -3
- package/dist/extensions/server.cjs +11 -7
- package/dist/extensions/server.cjs.map +1 -1
- package/dist/extensions/server.d.mts +2 -2
- package/dist/extensions/server.d.mts.map +1 -1
- package/dist/extensions/server.mjs +12 -8
- package/dist/extensions/server.mjs.map +1 -1
- package/dist/harnessState.d.mts +2 -2
- package/dist/index.cjs +15 -10
- package/dist/index.d.mts +5 -3
- package/dist/index.mjs +8 -6
- package/dist/nativeAutomation.cjs +3 -0
- package/dist/nativeAutomation.d.mts +2 -0
- package/dist/nativeAutomation.mjs +1 -0
- package/dist/projectTrust.cjs +2 -2
- package/dist/projectTrust.d.mts +2 -2
- package/dist/projectTrust.mjs +1 -1
- package/dist/repository.cjs +2 -1
- package/dist/repository.d.mts +2 -2
- package/dist/repository.mjs +1 -1
- package/dist/src/bin/agentDirectory.cjs +14 -48
- package/dist/src/bin/agentDirectory.cjs.map +1 -1
- package/dist/src/bin/agentDirectory.mjs +14 -49
- package/dist/src/bin/agentDirectory.mjs.map +1 -1
- package/dist/src/builders/apiContractExport/index.cjs +8 -8
- package/dist/src/builders/apiContractExport/index.cjs.map +1 -1
- package/dist/src/builders/apiContractExport/index.mjs +10 -10
- package/dist/src/builders/apiContractExport/index.mjs.map +1 -1
- package/dist/src/builders/cli/entryResolution.cjs +3 -3
- package/dist/src/builders/cli/entryResolution.cjs.map +1 -1
- package/dist/src/builders/cli/entryResolution.mjs +3 -3
- package/dist/src/builders/cli/entryResolution.mjs.map +1 -1
- package/dist/src/builders/cli/harnessContext.cjs +14 -9
- package/dist/src/builders/cli/harnessContext.cjs.map +1 -1
- package/dist/src/builders/cli/harnessContext.d.mts.map +1 -1
- package/dist/src/builders/cli/harnessContext.mjs +14 -9
- package/dist/src/builders/cli/harnessContext.mjs.map +1 -1
- package/dist/src/builders/hooks/index.cjs +3 -46
- package/dist/src/builders/hooks/index.cjs.map +1 -1
- package/dist/src/builders/hooks/index.mjs +4 -45
- package/dist/src/builders/hooks/index.mjs.map +1 -1
- package/dist/src/builders/isolate/compile.cjs +134 -0
- package/dist/src/builders/isolate/compile.cjs.map +1 -0
- package/dist/src/builders/isolate/compile.mjs +129 -0
- package/dist/src/builders/isolate/compile.mjs.map +1 -0
- package/dist/src/builders/isolate/index.cjs +162 -0
- package/dist/src/builders/isolate/index.cjs.map +1 -0
- package/dist/src/builders/isolate/index.mjs +159 -0
- package/dist/src/builders/isolate/index.mjs.map +1 -0
- package/dist/src/builders/isolate/membrane.cjs +179 -0
- package/dist/src/builders/isolate/membrane.cjs.map +1 -0
- package/dist/src/builders/isolate/membrane.mjs +179 -0
- package/dist/src/builders/isolate/membrane.mjs.map +1 -0
- package/dist/src/builders/native/index.cjs +23 -0
- package/dist/src/builders/native/index.cjs.map +1 -1
- package/dist/src/builders/native/index.d.mts.map +1 -1
- package/dist/src/builders/native/index.mjs +23 -2
- package/dist/src/builders/native/index.mjs.map +1 -1
- package/dist/src/builders/server/backgroundSync.cjs +13 -1
- package/dist/src/builders/server/backgroundSync.cjs.map +1 -1
- package/dist/src/builders/server/backgroundSync.mjs +13 -1
- package/dist/src/builders/server/backgroundSync.mjs.map +1 -1
- package/dist/src/builders/server/bundlerService.cjs +151 -0
- package/dist/src/builders/server/bundlerService.cjs.map +1 -0
- package/dist/src/builders/server/bundlerService.mjs +151 -0
- package/dist/src/builders/server/bundlerService.mjs.map +1 -0
- package/dist/src/builders/server/computerUseBinding.cjs +20 -3
- package/dist/src/builders/server/computerUseBinding.cjs.map +1 -1
- package/dist/src/builders/server/computerUseBinding.mjs +20 -3
- package/dist/src/builders/server/computerUseBinding.mjs.map +1 -1
- package/dist/src/builders/server/computerUseRecordings.cjs +1 -1
- package/dist/src/builders/server/computerUseRecordings.cjs.map +1 -1
- package/dist/src/builders/server/computerUseRecordings.mjs +1 -1
- package/dist/src/builders/server/computerUseRecordings.mjs.map +1 -1
- package/dist/src/builders/server/defaultWorkspace.cjs +1 -1
- package/dist/src/builders/server/defaultWorkspace.cjs.map +1 -1
- package/dist/src/builders/server/defaultWorkspace.mjs +2 -2
- package/dist/src/builders/server/defaultWorkspace.mjs.map +1 -1
- package/dist/src/builders/server/idleRestart.cjs +3 -3
- package/dist/src/builders/server/idleRestart.cjs.map +1 -1
- package/dist/src/builders/server/idleRestart.mjs +3 -3
- package/dist/src/builders/server/idleRestart.mjs.map +1 -1
- package/dist/src/builders/server/index.cjs +6 -6
- package/dist/src/builders/server/index.cjs.map +1 -1
- package/dist/src/builders/server/index.mjs +6 -6
- package/dist/src/builders/server/index.mjs.map +1 -1
- package/dist/src/builders/server/logSink.cjs +3 -3
- package/dist/src/builders/server/logSink.cjs.map +1 -1
- package/dist/src/builders/server/logSink.mjs +2 -2
- package/dist/src/builders/server/logSink.mjs.map +1 -1
- package/dist/src/builders/server/mcpBundle.cjs.map +1 -1
- package/dist/src/builders/server/mcpBundle.d.mts +2 -2
- package/dist/src/builders/server/mcpBundle.mjs.map +1 -1
- package/dist/src/builders/server/packageUrl.cjs +7 -5
- package/dist/src/builders/server/packageUrl.cjs.map +1 -1
- package/dist/src/builders/server/packageUrl.mjs +7 -5
- package/dist/src/builders/server/packageUrl.mjs.map +1 -1
- package/dist/src/builders/server/runtime.cjs +198 -187
- package/dist/src/builders/server/runtime.cjs.map +1 -1
- package/dist/src/builders/server/runtime.mjs +203 -191
- package/dist/src/builders/server/runtime.mjs.map +1 -1
- package/dist/src/builders/server/selectionStatus.cjs +3 -3
- package/dist/src/builders/server/selectionStatus.cjs.map +1 -1
- package/dist/src/builders/server/selectionStatus.mjs +3 -3
- package/dist/src/builders/server/selectionStatus.mjs.map +1 -1
- package/dist/src/builders/server/sessionArguments.cjs.map +1 -1
- package/dist/src/builders/server/sessionArguments.mjs.map +1 -1
- package/dist/src/builders/server/watcherService.cjs +65 -0
- package/dist/src/builders/server/watcherService.cjs.map +1 -0
- package/dist/src/builders/server/watcherService.mjs +61 -0
- package/dist/src/builders/server/watcherService.mjs.map +1 -0
- package/dist/src/builders/server/webTemplateDecision.cjs +1 -1
- package/dist/src/builders/server/webTemplateDecision.cjs.map +1 -1
- package/dist/src/builders/server/webTemplateDecision.mjs +2 -2
- package/dist/src/builders/server/webTemplateDecision.mjs.map +1 -1
- package/dist/src/builders/server/workspaceCheckout.cjs +1 -9
- package/dist/src/builders/server/workspaceCheckout.cjs.map +1 -1
- package/dist/src/builders/server/workspaceCheckout.mjs +2 -8
- package/dist/src/builders/server/workspaceCheckout.mjs.map +1 -1
- package/dist/src/builders/web/bundle.cjs.map +1 -1
- package/dist/src/builders/web/bundle.d.mts +3 -3
- package/dist/src/builders/web/bundle.mjs.map +1 -1
- package/dist/src/builders/web/index.cjs +1 -1
- package/dist/src/builders/web/index.cjs.map +1 -1
- package/dist/src/builders/web/index.mjs +1 -1
- package/dist/src/builders/web/index.mjs.map +1 -1
- package/dist/src/builders/web/webPluginGenerate.cjs +4 -15
- package/dist/src/builders/web/webPluginGenerate.cjs.map +1 -1
- package/dist/src/builders/web/webPluginGenerate.d.mts +5 -9
- package/dist/src/builders/web/webPluginGenerate.d.mts.map +1 -1
- package/dist/src/builders/web/webPluginGenerate.mjs +4 -15
- package/dist/src/builders/web/webPluginGenerate.mjs.map +1 -1
- package/dist/src/cli/cliApp.cjs +15 -9
- package/dist/src/cli/cliApp.cjs.map +1 -1
- package/dist/src/cli/cliApp.d.mts.map +1 -1
- package/dist/src/cli/cliApp.mjs +15 -9
- package/dist/src/cli/cliApp.mjs.map +1 -1
- package/dist/src/cli/commands/compat/context.cjs +4 -1
- package/dist/src/cli/commands/compat/context.cjs.map +1 -1
- package/dist/src/cli/commands/compat/context.d.mts.map +1 -1
- package/dist/src/cli/commands/compat/context.mjs +4 -1
- package/dist/src/cli/commands/compat/context.mjs.map +1 -1
- package/dist/src/cli/commands/compat/index.cjs +7 -4
- package/dist/src/cli/commands/compat/index.cjs.map +1 -1
- package/dist/src/cli/commands/compat/index.d.mts.map +1 -1
- package/dist/src/cli/commands/compat/index.mjs +7 -4
- package/dist/src/cli/commands/compat/index.mjs.map +1 -1
- package/dist/src/cli/commands/compat/providers/shared.cjs +8 -5
- package/dist/src/cli/commands/compat/providers/shared.cjs.map +1 -1
- package/dist/src/cli/commands/compat/providers/shared.d.mts +5 -5
- package/dist/src/cli/commands/compat/providers/shared.d.mts.map +1 -1
- package/dist/src/cli/commands/compat/providers/shared.mjs +6 -5
- package/dist/src/cli/commands/compat/providers/shared.mjs.map +1 -1
- package/dist/src/cli/commands/doctor/index.cjs +3 -3
- package/dist/src/cli/commands/doctor/index.cjs.map +1 -1
- package/dist/src/cli/commands/doctor/index.mjs +4 -4
- package/dist/src/cli/commands/doctor/index.mjs.map +1 -1
- package/dist/src/cli/commands/explain/index.cjs +3 -1
- package/dist/src/cli/commands/explain/index.cjs.map +1 -1
- package/dist/src/cli/commands/explain/index.d.mts.map +1 -1
- package/dist/src/cli/commands/explain/index.mjs +4 -2
- package/dist/src/cli/commands/explain/index.mjs.map +1 -1
- package/dist/src/cli/commands/init/index.cjs +2 -2
- package/dist/src/cli/commands/init/index.cjs.map +1 -1
- package/dist/src/cli/commands/init/index.mjs +3 -3
- package/dist/src/cli/commands/init/index.mjs.map +1 -1
- package/dist/src/cli/commands/init/presenter.cjs +1 -1
- package/dist/src/cli/commands/init/presenter.cjs.map +1 -1
- package/dist/src/cli/commands/init/presenter.mjs +2 -2
- package/dist/src/cli/commands/init/presenter.mjs.map +1 -1
- package/dist/src/cli/commands/sync/index.cjs +43 -7
- package/dist/src/cli/commands/sync/index.cjs.map +1 -1
- package/dist/src/cli/commands/sync/index.d.mts.map +1 -1
- package/dist/src/cli/commands/sync/index.mjs +46 -10
- package/dist/src/cli/commands/sync/index.mjs.map +1 -1
- package/dist/src/cli/commands/sync/presenter.cjs +1 -1
- package/dist/src/cli/commands/sync/presenter.cjs.map +1 -1
- package/dist/src/cli/commands/sync/presenter.d.mts +1 -1
- package/dist/src/cli/commands/sync/presenter.mjs +1 -1
- package/dist/src/cli/commands/sync/presenter.mjs.map +1 -1
- package/dist/src/cli/commands/web/index.cjs +3 -20
- package/dist/src/cli/commands/web/index.cjs.map +1 -1
- package/dist/src/cli/commands/web/index.mjs +3 -20
- package/dist/src/cli/commands/web/index.mjs.map +1 -1
- package/dist/src/cli/harnessOptions.cjs +4 -18
- package/dist/src/cli/harnessOptions.cjs.map +1 -1
- package/dist/src/cli/harnessOptions.d.mts.map +1 -1
- package/dist/src/cli/harnessOptions.mjs +5 -18
- package/dist/src/cli/harnessOptions.mjs.map +1 -1
- package/dist/src/cli/help.cjs +3 -1
- package/dist/src/cli/help.cjs.map +1 -1
- package/dist/src/cli/help.mjs +3 -1
- package/dist/src/cli/help.mjs.map +1 -1
- package/dist/src/cli/matrixOptions.cjs +1 -1
- package/dist/src/cli/matrixOptions.cjs.map +1 -1
- package/dist/src/cli/matrixOptions.d.mts +1 -1
- package/dist/src/cli/matrixOptions.mjs +1 -1
- package/dist/src/cli/matrixOptions.mjs.map +1 -1
- package/dist/src/cli/nativeAutomation.cjs +255 -0
- package/dist/src/cli/nativeAutomation.cjs.map +1 -0
- package/dist/src/cli/nativeAutomation.d.mts +17 -0
- package/dist/src/cli/nativeAutomation.d.mts.map +1 -0
- package/dist/src/cli/nativeAutomation.mjs +249 -0
- package/dist/src/cli/nativeAutomation.mjs.map +1 -0
- package/dist/src/cli/nativeAutomationCapability.cjs +7 -0
- package/dist/src/cli/nativeAutomationCapability.cjs.map +1 -0
- package/dist/src/cli/nativeAutomationCapability.d.mts +5 -0
- package/dist/src/cli/nativeAutomationCapability.d.mts.map +1 -0
- package/dist/src/cli/nativeAutomationCapability.mjs +7 -0
- package/dist/src/cli/nativeAutomationCapability.mjs.map +1 -0
- package/dist/src/cli/server/run.cjs +1 -1
- package/dist/src/cli/server/run.cjs.map +1 -1
- package/dist/src/cli/server/run.mjs +2 -2
- package/dist/src/cli/server/run.mjs.map +1 -1
- package/dist/src/composition/harnessState/index.cjs.map +1 -1
- package/dist/src/composition/harnessState/index.d.mts +3 -3
- package/dist/src/composition/harnessState/index.mjs +2 -2
- package/dist/src/composition/harnessState/index.mjs.map +1 -1
- package/dist/src/composition/layerPackageInstaller/index.cjs +7 -6
- package/dist/src/composition/layerPackageInstaller/index.cjs.map +1 -1
- package/dist/src/composition/layerPackageInstaller/index.mjs +7 -6
- package/dist/src/composition/layerPackageInstaller/index.mjs.map +1 -1
- package/dist/src/composition/poHomeMigration/index.cjs +1 -1
- package/dist/src/composition/poHomeMigration/index.cjs.map +1 -1
- package/dist/src/composition/poHomeMigration/index.mjs +1 -1
- package/dist/src/composition/poHomeMigration/index.mjs.map +1 -1
- package/dist/src/composition/projectTrust/index.cjs +6 -6
- package/dist/src/composition/projectTrust/index.cjs.map +1 -1
- package/dist/src/composition/projectTrust/index.d.mts +7 -7
- package/dist/src/composition/projectTrust/index.d.mts.map +1 -1
- package/dist/src/composition/projectTrust/index.mjs +6 -6
- package/dist/src/composition/projectTrust/index.mjs.map +1 -1
- package/dist/src/composition/repository/index.cjs +23 -8
- package/dist/src/composition/repository/index.cjs.map +1 -1
- package/dist/src/composition/repository/index.d.mts +12 -5
- package/dist/src/composition/repository/index.d.mts.map +1 -1
- package/dist/src/composition/repository/index.mjs +24 -10
- package/dist/src/composition/repository/index.mjs.map +1 -1
- package/dist/src/composition/syncService/index.cjs +12 -10
- package/dist/src/composition/syncService/index.cjs.map +1 -1
- package/dist/src/composition/syncService/index.d.mts.map +1 -1
- package/dist/src/composition/syncService/index.mjs +12 -10
- package/dist/src/composition/syncService/index.mjs.map +1 -1
- package/dist/src/composition/syncService/localBuilds.cjs +7 -2
- package/dist/src/composition/syncService/localBuilds.cjs.map +1 -1
- package/dist/src/composition/syncService/localBuilds.mjs +7 -2
- package/dist/src/composition/syncService/localBuilds.mjs.map +1 -1
- package/dist/src/extensions/setupDiagnostics.cjs +8 -8
- package/dist/src/extensions/setupDiagnostics.cjs.map +1 -1
- package/dist/src/extensions/setupDiagnostics.mjs +8 -8
- package/dist/src/extensions/setupDiagnostics.mjs.map +1 -1
- package/docs/server/api-export.md +2 -2
- package/docs/server/api.md +15 -14
- package/docs/server/getting-started.md +6 -6
- package/docs/server/index.md +4 -4
- package/docs/server/ipc.md +4 -7
- package/docs/server/lifecycle.md +17 -17
- package/docs/server/security.md +8 -8
- package/package.json +43 -37
- package/src/prompts/po-author-extension/SKILL.md +1 -1
- package/src/prompts/po-author-extension/references/extension-contract.md +4 -4
- package/dist/bin/doomRunner.cjs.map +0 -1
- package/dist/bin/doomRunner.d.mts.map +0 -1
- package/dist/bin/doomRunner.mjs.map +0 -1
package/LICENSE
CHANGED
|
@@ -1,21 +1,149 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
1
|
+
License text copyright © 2017 MariaDB Corporation Ab, All Rights Reserved.
|
|
2
|
+
"Business Source License" is a trademark of MariaDB Corporation Ab.
|
|
3
|
+
|
|
4
|
+
Parameters
|
|
5
|
+
|
|
6
|
+
Licensor: Agimon Pty Ltd
|
|
7
|
+
Licensed Work: Po, the software in the Po source repository and the
|
|
8
|
+
packages released from it, in each version released by
|
|
9
|
+
the Licensor.
|
|
10
|
+
The Licensed Work is (c) 2026 Agimon Pty Ltd.
|
|
11
|
+
Material identified as third-party in the "Third-party
|
|
12
|
+
components" section at the end of this file or in a
|
|
13
|
+
NOTICE file, and any package or directory whose own
|
|
14
|
+
license file grants a different license, is not part of
|
|
15
|
+
the Licensed Work and remains under its own license.
|
|
16
|
+
Additional Use Grant: You may make production use of the Licensed Work if
|
|
17
|
+
your use is Eligible Use. "Eligible Use" is production use that falls
|
|
18
|
+
within at least one of the following:
|
|
19
|
+
|
|
20
|
+
(a) Personal Use. Use by an individual for their own personal purposes,
|
|
21
|
+
and not on behalf of, or for the benefit of, an employer, client, or
|
|
22
|
+
other Organization. Use by an individual in the course of employment
|
|
23
|
+
or engagement by an Organization is use by that Organization.
|
|
24
|
+
|
|
25
|
+
(b) Small Organization Use. Use by or on behalf of an Organization whose
|
|
26
|
+
Annual Revenue is less than USD 1,000,000.
|
|
27
|
+
|
|
28
|
+
(c) Non-profit, Education and Research Use. Use, regardless of Annual
|
|
29
|
+
Revenue, by (i) an Organization registered or recognized as a
|
|
30
|
+
non-profit or charitable organization under the laws of its
|
|
31
|
+
jurisdiction, for its non-profit purposes; (ii) an accredited school,
|
|
32
|
+
college, or university, for teaching, learning, or academic research;
|
|
33
|
+
or (iii) a publicly funded research institution, for its research.
|
|
34
|
+
|
|
35
|
+
(d) Service Provider Use. Use by a consultant, contractor, agency, or other
|
|
36
|
+
service provider, regardless of its own Annual Revenue, solely to
|
|
37
|
+
build, deploy, host, operate, or support the Licensed Work for a client
|
|
38
|
+
whose own use would be Eligible Use under (a), (b), or (c). A service
|
|
39
|
+
provider's use for its own purposes is Eligible Use only if the service
|
|
40
|
+
provider itself qualifies under (b) or (c).
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
Hosted services. Offering the Licensed Work to third parties as a hosted
|
|
44
|
+
or managed service whose primary value is the Licensed Work is Eligible
|
|
45
|
+
Use only if each such third party's own use would be Eligible Use.
|
|
46
|
+
|
|
47
|
+
Definitions. "Organization" means any company, partnership, sole
|
|
48
|
+
proprietorship, trust, association, government body, or other entity, and
|
|
49
|
+
includes an individual acting in a business or professional capacity.
|
|
50
|
+
"Affiliate" means any entity that directly or indirectly controls, is
|
|
51
|
+
controlled by, or is under common control with an Organization, where
|
|
52
|
+
"control" means ownership of more than 50% of the voting interests of an
|
|
53
|
+
entity or the power to direct its management and policies by contract or
|
|
54
|
+
otherwise. "Annual Revenue" means the total gross revenue of an
|
|
55
|
+
Organization and all of its Affiliates combined, from all sources and
|
|
56
|
+
whether or not related to the Licensed Work, for its most recently
|
|
57
|
+
completed fiscal year, or, if it has not completed a fiscal year, for the
|
|
58
|
+
twelve months before the use (or since its formation, if shorter),
|
|
59
|
+
converted into US dollars at the average exchange rate for that period.
|
|
60
|
+
Proceeds of equity or debt financing are not revenue.
|
|
61
|
+
|
|
62
|
+
Threshold. If an Organization stops qualifying under (b), its existing
|
|
63
|
+
production use remains Eligible Use for 90 days after it stops
|
|
64
|
+
qualifying, after which it must obtain a commercial license or stop
|
|
65
|
+
production use. Use that was Eligible Use when it occurred never requires
|
|
66
|
+
a commercial license after the fact.
|
|
67
|
+
Change Date: Four years from the date a version of the Licensed Work
|
|
68
|
+
is first publicly released by the Licensor.
|
|
69
|
+
Change License: Apache License, Version 2.0
|
|
70
|
+
|
|
71
|
+
For information about alternative licensing arrangements for the Licensed
|
|
72
|
+
Work, please visit: https://agimon.ai/licensing
|
|
73
|
+
|
|
74
|
+
Notice
|
|
75
|
+
|
|
76
|
+
The Business Source License (this document, or the "License") is not an Open
|
|
77
|
+
Source license. However, the Licensed Work will eventually be made available
|
|
78
|
+
under an Open Source License, as stated in this License.
|
|
79
|
+
|
|
80
|
+
-----------------------------------------------------------------------------
|
|
81
|
+
|
|
82
|
+
Business Source License 1.1
|
|
83
|
+
|
|
84
|
+
Terms
|
|
85
|
+
|
|
86
|
+
The Licensor hereby grants you the right to copy, modify, create derivative
|
|
87
|
+
works, redistribute, and make non-production use of the Licensed Work. The
|
|
88
|
+
Licensor may make an Additional Use Grant, above, permitting limited
|
|
89
|
+
production use.
|
|
90
|
+
|
|
91
|
+
Effective on the Change Date, or the fourth anniversary of the first publicly
|
|
92
|
+
available distribution of a specific version of the Licensed Work under this
|
|
93
|
+
License, whichever comes first, the Licensor hereby grants you rights under
|
|
94
|
+
the terms of the Change License, and the rights granted in the paragraph
|
|
95
|
+
above terminate.
|
|
96
|
+
|
|
97
|
+
If your use of the Licensed Work does not comply with the requirements
|
|
98
|
+
currently in effect as described in this License, you must purchase a
|
|
99
|
+
commercial license from the Licensor, its affiliated entities, or authorized
|
|
100
|
+
resellers, or you must refrain from using the Licensed Work.
|
|
101
|
+
|
|
102
|
+
All copies of the original and modified Licensed Work, and derivative works
|
|
103
|
+
of the Licensed Work, are subject to this License. This License applies
|
|
104
|
+
separately for each version of the Licensed Work and the Change Date may vary
|
|
105
|
+
for each version of the Licensed Work released by Licensor.
|
|
106
|
+
|
|
107
|
+
You must conspicuously display this License on each original or modified copy
|
|
108
|
+
of the Licensed Work. If you receive the Licensed Work in original or
|
|
109
|
+
modified form from a third party, the terms and conditions set forth in this
|
|
110
|
+
License apply to your use of that work.
|
|
111
|
+
|
|
112
|
+
Any use of the Licensed Work in violation of this License will automatically
|
|
113
|
+
terminate your rights under this License for the current and all other
|
|
114
|
+
versions of the Licensed Work.
|
|
115
|
+
|
|
116
|
+
This License does not grant you any right in any trademark or logo of
|
|
117
|
+
Licensor or its affiliates (provided that you may use a trademark or logo of
|
|
118
|
+
Licensor as expressly required by this License).
|
|
119
|
+
|
|
120
|
+
TO THE EXTENT PERMITTED BY APPLICABLE LAW, THE LICENSED WORK IS PROVIDED ON
|
|
121
|
+
AN “AS IS” BASIS. LICENSOR HEREBY DISCLAIMS ALL WARRANTIES AND CONDITIONS,
|
|
122
|
+
EXPRESS OR IMPLIED, INCLUDING (WITHOUT LIMITATION) WARRANTIES OF
|
|
123
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, AND
|
|
124
|
+
TITLE.
|
|
125
|
+
|
|
126
|
+
MariaDB hereby grants you permission to use this License’s text to license
|
|
127
|
+
your works, and to refer to it using the trademark “Business Source License”,
|
|
128
|
+
as long as you comply with the Covenants of Licensor below.
|
|
129
|
+
|
|
130
|
+
Covenants of Licensor
|
|
131
|
+
|
|
132
|
+
In consideration of the right to use this License’s text and the “Business
|
|
133
|
+
Source License” name and trademark, Licensor covenants to MariaDB, and to all
|
|
134
|
+
other recipients of the licensed work to be provided by Licensor:
|
|
135
|
+
|
|
136
|
+
1. To specify as the Change License the GPL Version 2.0 or any later version,
|
|
137
|
+
or a license that is compatible with GPL Version 2.0 or a later version,
|
|
138
|
+
where “compatible” means that software provided under the Change License can
|
|
139
|
+
be included in a program with software provided under GPL Version 2.0 or a
|
|
140
|
+
later version. Licensor may specify additional Change Licenses without
|
|
141
|
+
limitation.
|
|
142
|
+
|
|
143
|
+
2. To either: (a) specify an additional grant of rights to use that does not
|
|
144
|
+
impose any additional restriction on the right granted in this License, as
|
|
145
|
+
the Additional Use Grant; or (b) insert the text “None”.
|
|
146
|
+
|
|
147
|
+
3. To specify a Change Date.
|
|
148
|
+
|
|
149
|
+
4. Not to modify this License in any other way.
|
package/README.md
CHANGED
|
@@ -19,7 +19,7 @@ denylist are repository-wide. Po draws that loading boundary around the session.
|
|
|
19
19
|
mode and some domains; add a profile if you want one. Four YAML files decide what loads;
|
|
20
20
|
`po --explain` tells you what got in, why, and what it costs before launch.
|
|
21
21
|
|
|
22
|
-
It borrows its shape from [
|
|
22
|
+
It borrows its shape from [Po Emacs Core](https://github.com/poemacs/core): quick to
|
|
23
23
|
start, close to Pi, opinionated where defaults help, and easy to pull apart when they do
|
|
24
24
|
not. Use it as-is, build your own config on top, or raid it for parts.
|
|
25
25
|
|
|
@@ -308,7 +308,7 @@ The fixed `@agimon-ai/po-artifact` package gives each session a durable artifact
|
|
|
308
308
|
names it in the system prompt, and shows recent artifacts in web and native Activity.
|
|
309
309
|
The Artifacts heading opens all files in that session's folder as a grid.
|
|
310
310
|
[`@agimon-ai/po-log`][pkg-po-log] collects session events, while
|
|
311
|
-
|
|
311
|
+
`@agimon-ai/po-core/telemetry` is the library-level telemetry adapter. Po Log's `logsink` code-mode namespace reads session evidence and explicitly selected cross-session history.
|
|
312
312
|
|
|
313
313
|
Runner selects matching RMUX and RTK native artifacts automatically. Do not install them directly.
|
|
314
314
|
The packages cover macOS and Linux on arm64 and x64 for both [RMUX][pkg-rmux-darwin-arm64] and
|
|
@@ -343,7 +343,7 @@ generated mode gets it. Short commands still return inline; commands that pass t
|
|
|
343
343
|
threshold of 60 seconds by default move into the background with durable logs. Use
|
|
344
344
|
`background: true` for an immediate detached run or `interactive: true` when the command needs
|
|
345
345
|
terminal input. Runner IDs and complete raw logs remain available to the current session through
|
|
346
|
-
the `
|
|
346
|
+
the `po-runner` CLI. Runner tries bundled RMUX, then `rmux` on PATH,
|
|
347
347
|
then `tmux` on PATH. If no pane backend accepts the run, non-interactive commands use a supervised
|
|
348
348
|
subprocess; interactive commands require RMUX or tmux. Conservatively recognized single commands
|
|
349
349
|
use the matching RTK stdin filter after completion. Compound commands, pipelines, incompatible
|
|
@@ -395,11 +395,18 @@ choices, and accepts the next spoken response as an ordinary user message.
|
|
|
395
395
|
|
|
396
396
|
Po logging records operational metadata such as counters, spans, session IDs, tool names, and
|
|
397
397
|
errors. Callers remain responsible for values they attach to telemetry. Native diagnostics expose
|
|
398
|
-
current-session metrics, and [`@agimon-ai/
|
|
398
|
+
current-session metrics, and [`@agimon-ai/po-logsink`][pkg-po-logsink] provides historical lookup
|
|
399
399
|
when a sink is configured.
|
|
400
400
|
|
|
401
401
|
### Modes and automation
|
|
402
402
|
|
|
403
|
+
`po --automation "prompt"` runs one bounded native headless session and writes JSON event lines
|
|
404
|
+
for automation consumers. It uses the same provider, configuration, hooks, workflow, and artifact
|
|
405
|
+
contracts as a native session, without starting Pi or the web console. Consumers that need to
|
|
406
|
+
invoke this entrypoint should first import `@agimon-ai/po/nativeAutomation` and require the exact
|
|
407
|
+
`NATIVE_AUTOMATION_CAPABILITY` marker, so older Po installations fail closed instead of routing
|
|
408
|
+
the flag to the web console.
|
|
409
|
+
|
|
403
410
|
#### Plan mode
|
|
404
411
|
|
|
405
412
|
A promise to "only plan" is not a permission boundary. [`@agimon-ai/po-plan`][pkg-po-plan]
|
|
@@ -663,7 +670,7 @@ its owning package's controls; values supplied by callers are not automatically
|
|
|
663
670
|
| `po sync` | Publishes the current repository, or the global composition outside repositories |
|
|
664
671
|
| `po sync --check` | Exits non-zero when the applicable registered generation is missing or stale |
|
|
665
672
|
| `po compat <codex\|claude\|antigravity>` | Resolves the selected matrix and launches the compatibility adapter |
|
|
666
|
-
| `
|
|
673
|
+
| `po-runner` | Inspects and controls supervised Runner processes and logs |
|
|
667
674
|
| `--explain` | Prints the resolved matrix and estimated prompt cost without launching Pi |
|
|
668
675
|
| `--emit-mcp <dir>`, `--no-mcp` | Writes the resolved MCP config or disables MCP for one run |
|
|
669
676
|
| `--` and remaining arguments | Forwards provider or Pi arguments unchanged where the selected command allows it |
|
|
@@ -674,13 +681,13 @@ its owning package's controls; values supplied by callers are not automatically
|
|
|
674
681
|
to install them and rebuild synchronized state.
|
|
675
682
|
- If neither RMUX nor tmux is available, non-interactive Runner calls report the supervised subprocess
|
|
676
683
|
fallback. Interactive calls require RMUX or tmux. Linux native artifacts require a compatible loader and libc.
|
|
677
|
-
- Po-owned packages expose native server, web, and MCP
|
|
678
|
-
`npm install` or select them in `modes.yaml`. Third-party Pi settings packages still load
|
|
679
|
-
the upstream SDK extension host, including provider registration before model selection.
|
|
684
|
+
- Po-owned packages expose native server, web, and MCP contributions, not Pi entry points. Install
|
|
685
|
+
them with `npm install` or select them in `modes.yaml`. Third-party Pi settings packages still load
|
|
686
|
+
through the upstream SDK extension host, including provider registration before model selection.
|
|
680
687
|
- Terminal leader menus, shortcuts, overlays, and widgets are no longer shipped. Native commands,
|
|
681
688
|
tools, and web panels remain where the owning package provides them. RMUX and RTK artifacts are
|
|
682
689
|
selected by Runner and should not be installed directly.
|
|
683
|
-
- The root `
|
|
690
|
+
- The root `po-runner` command delegates to Runner from the active repository and asks you to add
|
|
684
691
|
Runner to `modes.yaml` when it is absent. The distribution remains the supported way to get the
|
|
685
692
|
coordinated defaults.
|
|
686
693
|
- The Ollama preset and launcher `--mute` and `--auto-stop` flags are retired. They do not have
|
|
@@ -689,8 +696,8 @@ its owning package's controls; values supplied by callers are not automatically
|
|
|
689
696
|
## Architecture
|
|
690
697
|
|
|
691
698
|
See [Architecture](https://github.com/AgiFlow/po/blob/main/docs/architecture.md) for native
|
|
692
|
-
server/web/MCP
|
|
693
|
-
lifecycle ownership, and parent/child isolation. Po no longer composes its own Pi factories;
|
|
699
|
+
server/web/MCP contributions, canonical fingerprints, transition classification, shared-host
|
|
700
|
+
Cordis lifecycle ownership, and parent/child isolation. Po no longer composes its own Pi factories;
|
|
694
701
|
third-party Pi packages remain supported through the SDK host.
|
|
695
702
|
|
|
696
703
|
## Development
|
|
@@ -709,7 +716,7 @@ Po is maintained by [Agimon](https://agimon.ai/about).
|
|
|
709
716
|
|
|
710
717
|
## License
|
|
711
718
|
|
|
712
|
-
|
|
719
|
+
Business Source License 1.1: free for personal use, organisations under USD 1M revenue, non-profits and education. See [LICENSE](LICENSE) and https://agimon.ai/licensing.
|
|
713
720
|
|
|
714
721
|
## Maintainer release order
|
|
715
722
|
|
|
@@ -733,7 +740,6 @@ loaded extension graph inside the same release boundary as the packages that con
|
|
|
733
740
|
[pkg-po-edit]: https://www.npmjs.com/package/@agimon-ai/po-edit
|
|
734
741
|
[pkg-po-file-edit]: https://www.npmjs.com/package/@agimon-ai/po-file-edit
|
|
735
742
|
[pkg-po-log]: https://www.npmjs.com/package/@agimon-ai/po-log
|
|
736
|
-
[pkg-po-telemetry]: https://www.npmjs.com/package/@agimon-ai/po-telemetry
|
|
737
743
|
[pkg-rmux-darwin-arm64]: https://www.npmjs.com/package/@agimon-ai/po-runner-rmux-darwin-arm64
|
|
738
744
|
[pkg-rmux-darwin-x64]: https://www.npmjs.com/package/@agimon-ai/po-runner-rmux-darwin-x64
|
|
739
745
|
[pkg-rmux-linux-arm64]: https://www.npmjs.com/package/@agimon-ai/po-runner-rmux-linux-arm64
|
|
@@ -749,7 +755,7 @@ loaded extension graph inside the same release boundary as the packages that con
|
|
|
749
755
|
[pkg-po-help]: https://www.npmjs.com/package/@agimon-ai/po-help
|
|
750
756
|
[pkg-po-mcp]: https://www.npmjs.com/package/@agimon-ai/po-mcp
|
|
751
757
|
[pkg-po-user-feedback]: https://www.npmjs.com/package/@agimon-ai/po-user-feedback
|
|
752
|
-
[pkg-
|
|
758
|
+
[pkg-po-logsink]: ../../tooling/po-logsink/README.md
|
|
753
759
|
[pkg-po-plan]: https://www.npmjs.com/package/@agimon-ai/po-plan
|
|
754
760
|
[pkg-po-loop]: https://www.npmjs.com/package/@agimon-ai/po-loop
|
|
755
761
|
[pkg-po-goal]: https://www.npmjs.com/package/@agimon-ai/po-goal
|
package/dist/bin/cli.cjs
CHANGED
|
@@ -1,19 +1,42 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
const
|
|
3
|
-
const
|
|
4
|
-
require("
|
|
2
|
+
const require_runtime = require("../_virtual/_rolldown/runtime.cjs");
|
|
3
|
+
const require_agentDirectory = require("../src/bin/agentDirectory.cjs");
|
|
4
|
+
let node_fs = require("node:fs");
|
|
5
|
+
node_fs = require_runtime.__toESM(node_fs, 1);
|
|
6
|
+
let node_path = require("node:path");
|
|
7
|
+
node_path = require_runtime.__toESM(node_path, 1);
|
|
8
|
+
let node_url = require("node:url");
|
|
5
9
|
//#region src/bin/cli.ts
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
10
|
+
/**
|
|
11
|
+
* CLI Entry Point for po
|
|
12
|
+
*
|
|
13
|
+
* The executable installed as the `po` binary, and the file the repository
|
|
14
|
+
* launchers (pi.sh, claude.sh, codex.sh) invoke directly from source.
|
|
15
|
+
*/
|
|
16
|
+
async function main() {
|
|
17
|
+
if (require_agentDirectory.testRoot) {
|
|
18
|
+
const target = node_path.default.join(require_agentDirectory.testRoot, "packages/cli/po/dist/bin/cli.mjs");
|
|
19
|
+
if (!node_fs.default.existsSync(target)) throw new Error(`Local test CLI build is missing: ${target}. Build @agimon-ai/po first.`);
|
|
20
|
+
if (node_fs.default.realpathSync(target) !== node_fs.default.realpathSync((0, node_url.fileURLToPath)(require("url").pathToFileURL(__filename).href))) {
|
|
21
|
+
await import((0, node_url.pathToFileURL)(target).href);
|
|
22
|
+
return;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
const { HARNESS_VERSION, printHelp } = await Promise.resolve().then(() => require("../src/cli/help.cjs"));
|
|
26
|
+
const { informationalRequest, routeCommand } = await Promise.resolve().then(() => require("../src/cli/router.cjs"));
|
|
27
|
+
const args = process.argv.slice(2);
|
|
28
|
+
const informational = routeCommand(args) !== void 0 ? void 0 : informationalRequest(args);
|
|
29
|
+
const informationalExit = informational === "help" ? (() => {
|
|
30
|
+
printHelp();
|
|
31
|
+
return 0;
|
|
32
|
+
})() : informational === "version" ? (() => {
|
|
33
|
+
process.stdout.write(`${HARNESS_VERSION}\n`);
|
|
34
|
+
return 0;
|
|
35
|
+
})() : void 0;
|
|
36
|
+
return informationalExit === void 0 ? Promise.resolve().then(() => require("../src/cli/cliApp.cjs")).then(({ runCli }) => runCli(args)) : Promise.resolve(informationalExit);
|
|
37
|
+
}
|
|
38
|
+
main().then((exitCode) => {
|
|
39
|
+
if (exitCode !== void 0) process.exitCode = exitCode;
|
|
17
40
|
}, (error) => {
|
|
18
41
|
const message = error instanceof Error ? error.message : String(error);
|
|
19
42
|
process.stderr.write(`[po] ${message}\n`);
|
package/dist/bin/cli.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.cjs","names":["
|
|
1
|
+
{"version":3,"file":"cli.cjs","names":["testRoot","path","fs","fileURLToPath","pathToFileURL"],"sources":["../../src/bin/cli.ts"],"sourcesContent":["#!/usr/bin/env node\n\n/**\n * CLI Entry Point for po\n *\n * The executable installed as the `po` binary, and the file the repository\n * launchers (pi.sh, claude.sh, codex.sh) invoke directly from source.\n */\n\nimport fs from 'node:fs';\nimport path from 'node:path';\nimport { fileURLToPath, pathToFileURL } from 'node:url';\n\nimport { testRoot } from './agentDirectory';\n\nasync function main(): Promise<number | undefined> {\n if (testRoot) {\n const target = path.join(testRoot, 'packages/cli/po/dist/bin/cli.mjs');\n if (!fs.existsSync(target))\n throw new Error(`Local test CLI build is missing: ${target}. Build @agimon-ai/po first.`);\n if (fs.realpathSync(target) !== fs.realpathSync(fileURLToPath(import.meta.url))) {\n await import(pathToFileURL(target).href);\n return;\n }\n }\n const { HARNESS_VERSION, printHelp } = await import('../cli/help');\n const { informationalRequest, routeCommand } = await import('../cli/router');\n\n const args = process.argv.slice(2);\n // A named subcommand parses its own arguments, including its own --help, so the\n // fast path below must not answer for it.\n const ownsArguments = routeCommand(args) !== undefined;\n\n // Keep informational startup independent from telemetry, configuration, Pi,\n // and the extension compiler. Those graphs are useful for a real command but\n // used to account for almost all of `po --help` and `po --version`.\n const informational = ownsArguments ? undefined : informationalRequest(args);\n const informationalExit =\n informational === 'help'\n ? (() => {\n printHelp();\n return 0;\n })()\n : informational === 'version'\n ? (() => {\n process.stdout.write(`${HARNESS_VERSION}\\n`);\n return 0;\n })()\n : undefined;\n\n const run =\n informationalExit === undefined\n ? import('../cli/cliApp').then(({ runCli }) => runCli(args))\n : Promise.resolve(informationalExit);\n\n return run;\n}\n\nmain().then(\n (exitCode) => {\n if (exitCode !== undefined) process.exitCode = exitCode;\n },\n (error: unknown) => {\n const message = error instanceof Error ? error.message : String(error);\n process.stderr.write(`[po] ${message}\\n`);\n process.exitCode = 1;\n },\n);\n"],"mappings":";;;;;;;;;;;;;;;AAeA,eAAe,OAAoC;CACjD,IAAIA,uBAAAA,UAAU;EACZ,MAAM,SAASC,UAAAA,QAAK,KAAKD,uBAAAA,UAAU,kCAAkC;EACrE,IAAI,CAACE,QAAAA,QAAG,WAAW,MAAM,GACvB,MAAM,IAAI,MAAM,oCAAoC,OAAO,6BAA6B;EAC1F,IAAIA,QAAAA,QAAG,aAAa,MAAM,MAAMA,QAAAA,QAAG,cAAA,GAAaC,SAAAA,cAAAA,CAAAA,QAAAA,KAAAA,CAAAA,CAAAA,cAAAA,UAAAA,CAAAA,CAAAA,IAA6B,CAAC,GAAG;GAC/E,MAAM,QAAA,GAAOC,SAAAA,cAAAA,CAAc,MAAM,CAAC,CAAC;GACnC;EACF;CACF;CACA,MAAM,EAAE,iBAAiB,cAAc,MAAA,QAAA,QAAA,CAAA,CAAA,WAAA,QAAM,qBAAA,CAAA;CAC7C,MAAM,EAAE,sBAAsB,iBAAiB,MAAA,QAAA,QAAA,CAAA,CAAA,WAAA,QAAM,uBAAA,CAAA;CAErD,MAAM,OAAO,QAAQ,KAAK,MAAM,CAAC;CAQjC,MAAM,gBALgB,aAAa,IAAI,MAAM,KAAA,IAKP,KAAA,IAAY,qBAAqB,IAAI;CAC3E,MAAM,oBACJ,kBAAkB,gBACP;EACL,UAAU;EACV,OAAO;CACT,EAAA,CAAG,IACH,kBAAkB,mBACT;EACL,QAAQ,OAAO,MAAM,GAAG,gBAAgB,GAAG;EAC3C,OAAO;CACT,EAAA,CAAG,IACH,KAAA;CAOR,OAJE,sBAAsB,KAAA,IAAA,QAAA,QAAA,CAAA,CAAA,WAAA,QAClB,uBAAA,CAAA,CAAA,CAAwB,MAAM,EAAE,aAAa,OAAO,IAAI,CAAC,IACzD,QAAQ,QAAQ,iBAAiB;AAGzC;AAEA,KAAK,CAAC,CAAC,MACJ,aAAa;CACZ,IAAI,aAAa,KAAA,GAAW,QAAQ,WAAW;AACjD,IACC,UAAmB;CAClB,MAAM,UAAU,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;CACrE,QAAQ,OAAO,MAAM,QAAQ,QAAQ,GAAG;CACxC,QAAQ,WAAW;AACrB,CACF"}
|
package/dist/bin/cli.mjs
CHANGED
|
@@ -1,19 +1,39 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import "
|
|
2
|
+
import { testRoot } from "../src/bin/agentDirectory.mjs";
|
|
3
|
+
import fs from "node:fs";
|
|
4
|
+
import path from "node:path";
|
|
5
|
+
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
5
6
|
//#region src/bin/cli.ts
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
(
|
|
16
|
-
|
|
7
|
+
/**
|
|
8
|
+
* CLI Entry Point for po
|
|
9
|
+
*
|
|
10
|
+
* The executable installed as the `po` binary, and the file the repository
|
|
11
|
+
* launchers (pi.sh, claude.sh, codex.sh) invoke directly from source.
|
|
12
|
+
*/
|
|
13
|
+
async function main() {
|
|
14
|
+
if (testRoot) {
|
|
15
|
+
const target = path.join(testRoot, "packages/cli/po/dist/bin/cli.mjs");
|
|
16
|
+
if (!fs.existsSync(target)) throw new Error(`Local test CLI build is missing: ${target}. Build @agimon-ai/po first.`);
|
|
17
|
+
if (fs.realpathSync(target) !== fs.realpathSync(fileURLToPath(import.meta.url))) {
|
|
18
|
+
await import(pathToFileURL(target).href);
|
|
19
|
+
return;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
const { HARNESS_VERSION, printHelp } = await import("../src/cli/help.mjs");
|
|
23
|
+
const { informationalRequest, routeCommand } = await import("../src/cli/router.mjs");
|
|
24
|
+
const args = process.argv.slice(2);
|
|
25
|
+
const informational = routeCommand(args) !== void 0 ? void 0 : informationalRequest(args);
|
|
26
|
+
const informationalExit = informational === "help" ? (() => {
|
|
27
|
+
printHelp();
|
|
28
|
+
return 0;
|
|
29
|
+
})() : informational === "version" ? (() => {
|
|
30
|
+
process.stdout.write(`${HARNESS_VERSION}\n`);
|
|
31
|
+
return 0;
|
|
32
|
+
})() : void 0;
|
|
33
|
+
return informationalExit === void 0 ? import("../src/cli/cliApp.mjs").then(({ runCli }) => runCli(args)) : Promise.resolve(informationalExit);
|
|
34
|
+
}
|
|
35
|
+
main().then((exitCode) => {
|
|
36
|
+
if (exitCode !== void 0) process.exitCode = exitCode;
|
|
17
37
|
}, (error) => {
|
|
18
38
|
const message = error instanceof Error ? error.message : String(error);
|
|
19
39
|
process.stderr.write(`[po] ${message}\n`);
|
package/dist/bin/cli.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.mjs","names":[],"sources":["../../src/bin/cli.ts"],"sourcesContent":["#!/usr/bin/env node\n\n/**\n * CLI Entry Point for po\n *\n * The executable installed as the `po` binary, and the file the repository\n * launchers (pi.sh, claude.sh, codex.sh) invoke directly from source.\n */\n\nimport './agentDirectory';\
|
|
1
|
+
{"version":3,"file":"cli.mjs","names":[],"sources":["../../src/bin/cli.ts"],"sourcesContent":["#!/usr/bin/env node\n\n/**\n * CLI Entry Point for po\n *\n * The executable installed as the `po` binary, and the file the repository\n * launchers (pi.sh, claude.sh, codex.sh) invoke directly from source.\n */\n\nimport fs from 'node:fs';\nimport path from 'node:path';\nimport { fileURLToPath, pathToFileURL } from 'node:url';\n\nimport { testRoot } from './agentDirectory';\n\nasync function main(): Promise<number | undefined> {\n if (testRoot) {\n const target = path.join(testRoot, 'packages/cli/po/dist/bin/cli.mjs');\n if (!fs.existsSync(target))\n throw new Error(`Local test CLI build is missing: ${target}. Build @agimon-ai/po first.`);\n if (fs.realpathSync(target) !== fs.realpathSync(fileURLToPath(import.meta.url))) {\n await import(pathToFileURL(target).href);\n return;\n }\n }\n const { HARNESS_VERSION, printHelp } = await import('../cli/help');\n const { informationalRequest, routeCommand } = await import('../cli/router');\n\n const args = process.argv.slice(2);\n // A named subcommand parses its own arguments, including its own --help, so the\n // fast path below must not answer for it.\n const ownsArguments = routeCommand(args) !== undefined;\n\n // Keep informational startup independent from telemetry, configuration, Pi,\n // and the extension compiler. Those graphs are useful for a real command but\n // used to account for almost all of `po --help` and `po --version`.\n const informational = ownsArguments ? undefined : informationalRequest(args);\n const informationalExit =\n informational === 'help'\n ? (() => {\n printHelp();\n return 0;\n })()\n : informational === 'version'\n ? (() => {\n process.stdout.write(`${HARNESS_VERSION}\\n`);\n return 0;\n })()\n : undefined;\n\n const run =\n informationalExit === undefined\n ? import('../cli/cliApp').then(({ runCli }) => runCli(args))\n : Promise.resolve(informationalExit);\n\n return run;\n}\n\nmain().then(\n (exitCode) => {\n if (exitCode !== undefined) process.exitCode = exitCode;\n },\n (error: unknown) => {\n const message = error instanceof Error ? error.message : String(error);\n process.stderr.write(`[po] ${message}\\n`);\n process.exitCode = 1;\n },\n);\n"],"mappings":";;;;;;;;;;;;AAeA,eAAe,OAAoC;CACjD,IAAI,UAAU;EACZ,MAAM,SAAS,KAAK,KAAK,UAAU,kCAAkC;EACrE,IAAI,CAAC,GAAG,WAAW,MAAM,GACvB,MAAM,IAAI,MAAM,oCAAoC,OAAO,6BAA6B;EAC1F,IAAI,GAAG,aAAa,MAAM,MAAM,GAAG,aAAa,cAAc,YAAY,GAAG,CAAC,GAAG;GAC/E,MAAM,OAAO,cAAc,MAAM,CAAC,CAAC;GACnC;EACF;CACF;CACA,MAAM,EAAE,iBAAiB,cAAc,MAAM,OAAO;CACpD,MAAM,EAAE,sBAAsB,iBAAiB,MAAM,OAAO;CAE5D,MAAM,OAAO,QAAQ,KAAK,MAAM,CAAC;CAQjC,MAAM,gBALgB,aAAa,IAAI,MAAM,KAAA,IAKP,KAAA,IAAY,qBAAqB,IAAI;CAC3E,MAAM,oBACJ,kBAAkB,gBACP;EACL,UAAU;EACV,OAAO;CACT,EAAA,CAAG,IACH,kBAAkB,mBACT;EACL,QAAQ,OAAO,MAAM,GAAG,gBAAgB,GAAG;EAC3C,OAAO;CACT,EAAA,CAAG,IACH,KAAA;CAOR,OAJE,sBAAsB,KAAA,IAClB,OAAO,wBAAgB,CAAC,MAAM,EAAE,aAAa,OAAO,IAAI,CAAC,IACzD,QAAQ,QAAQ,iBAAiB;AAGzC;AAEA,KAAK,CAAC,CAAC,MACJ,aAAa;CACZ,IAAI,aAAa,KAAA,GAAW,QAAQ,WAAW;AACjD,IACC,UAAmB;CAClB,MAAM,UAAU,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;CACrE,QAAQ,OAAO,MAAM,QAAQ,QAAQ,GAAG;CACxC,QAAQ,WAAW;AACrB,CACF"}
|
|
@@ -5,17 +5,17 @@ require("../src/bin/agentDirectory.cjs");
|
|
|
5
5
|
let node_fs = require("node:fs");
|
|
6
6
|
let node_url = require("node:url");
|
|
7
7
|
let _agimon_ai_po_core_moduleResolution = require("@agimon-ai/po-core/moduleResolution");
|
|
8
|
-
//#region src/bin/
|
|
8
|
+
//#region src/bin/poRunner.ts
|
|
9
9
|
const RUNNER_CLI_EXPORT = "@agimon-ai/po-runner/bin/cli";
|
|
10
10
|
async function main(argv = process.argv.slice(2)) {
|
|
11
11
|
let repoRoot;
|
|
12
12
|
try {
|
|
13
13
|
repoRoot = require_index.findRepositoryRoot(process.cwd());
|
|
14
14
|
} catch (error) {
|
|
15
|
-
throw new Error("
|
|
15
|
+
throw new Error("po-runner must be invoked inside a configured repository.", { cause: error });
|
|
16
16
|
}
|
|
17
17
|
const entry = (0, _agimon_ai_po_core_moduleResolution.consumerPackageEntry)(RUNNER_CLI_EXPORT, repoRoot);
|
|
18
|
-
if (!entry) throw new Error("
|
|
18
|
+
if (!entry) throw new Error("Po Runner is not installed for this repository. Add @agimon-ai/po-runner to .po/modes.yaml and run po sync.");
|
|
19
19
|
const loaded = await import((0, node_url.pathToFileURL)(entry).href);
|
|
20
20
|
if (typeof loaded.main !== "function") throw new Error(`${RUNNER_CLI_EXPORT} does not export a callable main function.`);
|
|
21
21
|
return loaded.main(argv);
|
|
@@ -24,10 +24,10 @@ if (process.argv[1] && (0, node_fs.existsSync)(process.argv[1]) && (0, node_fs.r
|
|
|
24
24
|
process.exitCode = exitCode;
|
|
25
25
|
}, (error) => {
|
|
26
26
|
const message = error instanceof Error ? error.message : String(error);
|
|
27
|
-
process.stderr.write(`[
|
|
27
|
+
process.stderr.write(`[po-runner] ${message}\n`);
|
|
28
28
|
process.exitCode = 1;
|
|
29
29
|
});
|
|
30
30
|
//#endregion
|
|
31
31
|
exports.main = main;
|
|
32
32
|
|
|
33
|
-
//# sourceMappingURL=
|
|
33
|
+
//# sourceMappingURL=poRunner.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"poRunner.cjs","names":["findRepositoryRoot","consumerPackageEntry","pathToFileURL","existsSync","realpathSync","fileURLToPath"],"sources":["../../src/bin/poRunner.ts"],"sourcesContent":["#!/usr/bin/env node\n\n/**\n * CLI Entry Point for po-runner\n *\n * The Runner package is selectable, so this compatibility executable resolves\n * it from the active repository instead of retaining it in Po's dependency\n * closure. The Runner package's own entry only self-invokes when it is argv[1],\n * which it is not once this shim imports it by absolute path.\n */\n\nimport './agentDirectory';\nimport { existsSync, realpathSync } from 'node:fs';\nimport { fileURLToPath, pathToFileURL } from 'node:url';\n\nimport { consumerPackageEntry } from '@agimon-ai/po-core/moduleResolution';\n\nimport { findRepositoryRoot } from '../composition/repository';\n\nconst RUNNER_CLI_EXPORT = '@agimon-ai/po-runner/bin/cli';\n\ninterface RunnerCliModule {\n readonly main?: unknown;\n}\n\nexport async function main(argv: readonly string[] = process.argv.slice(2)): Promise<number> {\n let repoRoot: string;\n try {\n repoRoot = findRepositoryRoot(process.cwd());\n } catch (error) {\n throw new Error('po-runner must be invoked inside a configured repository.', { cause: error });\n }\n const entry = consumerPackageEntry(RUNNER_CLI_EXPORT, repoRoot);\n if (!entry) {\n throw new Error(\n 'Po Runner is not installed for this repository. Add @agimon-ai/po-runner to .po/modes.yaml and run po sync.',\n );\n }\n const loaded = (await import(pathToFileURL(entry).href)) as RunnerCliModule;\n if (typeof loaded.main !== 'function') {\n throw new Error(`${RUNNER_CLI_EXPORT} does not export a callable main function.`);\n }\n return (loaded.main as (args: readonly string[]) => Promise<number>)(argv);\n}\n\nif (\n process.argv[1] &&\n existsSync(process.argv[1]) &&\n realpathSync(fileURLToPath(import.meta.url)) === realpathSync(process.argv[1])\n) {\n main().then(\n (exitCode) => {\n process.exitCode = exitCode;\n },\n (error: unknown) => {\n const message = error instanceof Error ? error.message : String(error);\n process.stderr.write(`[po-runner] ${message}\\n`);\n process.exitCode = 1;\n },\n );\n}\n"],"mappings":";;;;;;;;AAmBA,MAAM,oBAAoB;AAM1B,eAAsB,KAAK,OAA0B,QAAQ,KAAK,MAAM,CAAC,GAAoB;CAC3F,IAAI;CACJ,IAAI;EACF,WAAWA,cAAAA,mBAAmB,QAAQ,IAAI,CAAC;CAC7C,SAAS,OAAO;EACd,MAAM,IAAI,MAAM,6DAA6D,EAAE,OAAO,MAAM,CAAC;CAC/F;CACA,MAAM,SAAA,GAAQC,oCAAAA,qBAAAA,CAAqB,mBAAmB,QAAQ;CAC9D,IAAI,CAAC,OACH,MAAM,IAAI,MACR,6GACF;CAEF,MAAM,SAAU,MAAM,QAAA,GAAOC,SAAAA,cAAAA,CAAc,KAAK,CAAC,CAAC;CAClD,IAAI,OAAO,OAAO,SAAS,YACzB,MAAM,IAAI,MAAM,GAAG,kBAAkB,2CAA2C;CAElF,OAAQ,OAAO,KAAsD,IAAI;AAC3E;AAEA,IACE,QAAQ,KAAK,OAAA,GACbC,QAAAA,WAAAA,CAAW,QAAQ,KAAK,EAAE,MAAA,GAC1BC,QAAAA,aAAAA,EAAAA,GAAaC,SAAAA,cAAAA,CAAAA,QAAAA,KAAAA,CAAAA,CAAAA,cAAAA,UAAAA,CAAAA,CAAAA,IAA6B,CAAC,OAAA,GAAMD,QAAAA,aAAAA,CAAa,QAAQ,KAAK,EAAE,GAE7E,KAAK,CAAC,CAAC,MACJ,aAAa;CACZ,QAAQ,WAAW;AACrB,IACC,UAAmB;CAClB,MAAM,UAAU,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;CACrE,QAAQ,OAAO,MAAM,eAAe,QAAQ,GAAG;CAC/C,QAAQ,WAAW;AACrB,CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"poRunner.d.mts","names":[],"sources":["../../src/bin/poRunner.ts"],"mappings":";wBAyBsB,KAAK,2BAAkD"}
|
|
@@ -4,17 +4,17 @@ import "../src/bin/agentDirectory.mjs";
|
|
|
4
4
|
import { existsSync, realpathSync } from "node:fs";
|
|
5
5
|
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
6
6
|
import { consumerPackageEntry } from "@agimon-ai/po-core/moduleResolution";
|
|
7
|
-
//#region src/bin/
|
|
7
|
+
//#region src/bin/poRunner.ts
|
|
8
8
|
const RUNNER_CLI_EXPORT = "@agimon-ai/po-runner/bin/cli";
|
|
9
9
|
async function main(argv = process.argv.slice(2)) {
|
|
10
10
|
let repoRoot;
|
|
11
11
|
try {
|
|
12
12
|
repoRoot = findRepositoryRoot(process.cwd());
|
|
13
13
|
} catch (error) {
|
|
14
|
-
throw new Error("
|
|
14
|
+
throw new Error("po-runner must be invoked inside a configured repository.", { cause: error });
|
|
15
15
|
}
|
|
16
16
|
const entry = consumerPackageEntry(RUNNER_CLI_EXPORT, repoRoot);
|
|
17
|
-
if (!entry) throw new Error("
|
|
17
|
+
if (!entry) throw new Error("Po Runner is not installed for this repository. Add @agimon-ai/po-runner to .po/modes.yaml and run po sync.");
|
|
18
18
|
const loaded = await import(pathToFileURL(entry).href);
|
|
19
19
|
if (typeof loaded.main !== "function") throw new Error(`${RUNNER_CLI_EXPORT} does not export a callable main function.`);
|
|
20
20
|
return loaded.main(argv);
|
|
@@ -23,10 +23,10 @@ if (process.argv[1] && existsSync(process.argv[1]) && realpathSync(fileURLToPath
|
|
|
23
23
|
process.exitCode = exitCode;
|
|
24
24
|
}, (error) => {
|
|
25
25
|
const message = error instanceof Error ? error.message : String(error);
|
|
26
|
-
process.stderr.write(`[
|
|
26
|
+
process.stderr.write(`[po-runner] ${message}\n`);
|
|
27
27
|
process.exitCode = 1;
|
|
28
28
|
});
|
|
29
29
|
//#endregion
|
|
30
30
|
export { main };
|
|
31
31
|
|
|
32
|
-
//# sourceMappingURL=
|
|
32
|
+
//# sourceMappingURL=poRunner.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"poRunner.mjs","names":[],"sources":["../../src/bin/poRunner.ts"],"sourcesContent":["#!/usr/bin/env node\n\n/**\n * CLI Entry Point for po-runner\n *\n * The Runner package is selectable, so this compatibility executable resolves\n * it from the active repository instead of retaining it in Po's dependency\n * closure. The Runner package's own entry only self-invokes when it is argv[1],\n * which it is not once this shim imports it by absolute path.\n */\n\nimport './agentDirectory';\nimport { existsSync, realpathSync } from 'node:fs';\nimport { fileURLToPath, pathToFileURL } from 'node:url';\n\nimport { consumerPackageEntry } from '@agimon-ai/po-core/moduleResolution';\n\nimport { findRepositoryRoot } from '../composition/repository';\n\nconst RUNNER_CLI_EXPORT = '@agimon-ai/po-runner/bin/cli';\n\ninterface RunnerCliModule {\n readonly main?: unknown;\n}\n\nexport async function main(argv: readonly string[] = process.argv.slice(2)): Promise<number> {\n let repoRoot: string;\n try {\n repoRoot = findRepositoryRoot(process.cwd());\n } catch (error) {\n throw new Error('po-runner must be invoked inside a configured repository.', { cause: error });\n }\n const entry = consumerPackageEntry(RUNNER_CLI_EXPORT, repoRoot);\n if (!entry) {\n throw new Error(\n 'Po Runner is not installed for this repository. Add @agimon-ai/po-runner to .po/modes.yaml and run po sync.',\n );\n }\n const loaded = (await import(pathToFileURL(entry).href)) as RunnerCliModule;\n if (typeof loaded.main !== 'function') {\n throw new Error(`${RUNNER_CLI_EXPORT} does not export a callable main function.`);\n }\n return (loaded.main as (args: readonly string[]) => Promise<number>)(argv);\n}\n\nif (\n process.argv[1] &&\n existsSync(process.argv[1]) &&\n realpathSync(fileURLToPath(import.meta.url)) === realpathSync(process.argv[1])\n) {\n main().then(\n (exitCode) => {\n process.exitCode = exitCode;\n },\n (error: unknown) => {\n const message = error instanceof Error ? error.message : String(error);\n process.stderr.write(`[po-runner] ${message}\\n`);\n process.exitCode = 1;\n },\n );\n}\n"],"mappings":";;;;;;;AAmBA,MAAM,oBAAoB;AAM1B,eAAsB,KAAK,OAA0B,QAAQ,KAAK,MAAM,CAAC,GAAoB;CAC3F,IAAI;CACJ,IAAI;EACF,WAAW,mBAAmB,QAAQ,IAAI,CAAC;CAC7C,SAAS,OAAO;EACd,MAAM,IAAI,MAAM,6DAA6D,EAAE,OAAO,MAAM,CAAC;CAC/F;CACA,MAAM,QAAQ,qBAAqB,mBAAmB,QAAQ;CAC9D,IAAI,CAAC,OACH,MAAM,IAAI,MACR,6GACF;CAEF,MAAM,SAAU,MAAM,OAAO,cAAc,KAAK,CAAC,CAAC;CAClD,IAAI,OAAO,OAAO,SAAS,YACzB,MAAM,IAAI,MAAM,GAAG,kBAAkB,2CAA2C;CAElF,OAAQ,OAAO,KAAsD,IAAI;AAC3E;AAEA,IACE,QAAQ,KAAK,MACb,WAAW,QAAQ,KAAK,EAAE,KAC1B,aAAa,cAAc,YAAY,GAAG,CAAC,MAAM,aAAa,QAAQ,KAAK,EAAE,GAE7E,KAAK,CAAC,CAAC,MACJ,aAAa;CACZ,QAAQ,WAAW;AACrB,IACC,UAAmB;CAClB,MAAM,UAAU,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;CACrE,QAAQ,OAAO,MAAM,eAAe,QAAQ,GAAG;CAC/C,QAAQ,WAAW;AACrB,CACF"}
|
|
@@ -9,7 +9,7 @@ let _agimon_ai_po_config_majorModes = require("@agimon-ai/po-config/majorModes")
|
|
|
9
9
|
let node_url = require("node:url");
|
|
10
10
|
let _agimon_ai_po_core_moduleResolution = require("@agimon-ai/po-core/moduleResolution");
|
|
11
11
|
let _agimon_ai_po_core_runtimeIdentity = require("@agimon-ai/po-core/runtimeIdentity");
|
|
12
|
-
let
|
|
12
|
+
let _agimon_ai_po_core_serverPlugin = require("@agimon-ai/po-core/serverPlugin");
|
|
13
13
|
//#region src/builders/cli/extensionAssembler/index.ts
|
|
14
14
|
const DEFAULT_SELECTION_LAYER = "default";
|
|
15
15
|
const DEFAULT_SELECTION_LAYER_INDEX = -1;
|
|
@@ -42,23 +42,23 @@ const CORE_PACKAGE_ENTRIES = [
|
|
|
42
42
|
];
|
|
43
43
|
const CACHE_PACKAGE_ENTRY = "@agimon-ai/po-cache/extensions/server";
|
|
44
44
|
const SESSION_PACKAGE_ENTRY = "@agimon-ai/po-session/extensions/server";
|
|
45
|
-
/** Po's own server
|
|
45
|
+
/** Po's own server package, resolved through the distribution like any own entry. */
|
|
46
46
|
const PO_SERVER_ENTRY = "server";
|
|
47
47
|
/** Manifest fields through which a selected package contributes to a Po host. */
|
|
48
|
-
const
|
|
48
|
+
const PO_CONTRIBUTION_FIELDS = [
|
|
49
49
|
"poServer",
|
|
50
50
|
"poWeb",
|
|
51
51
|
"poMcp"
|
|
52
52
|
];
|
|
53
53
|
/**
|
|
54
|
-
* Resolves a selected package to its built server
|
|
55
|
-
*
|
|
54
|
+
* Resolves a selected package to its built server entry, or to its manifest as the discovery
|
|
55
|
+
* anchor of a web or MCP only package. A package with no Po contribution resolves empty.
|
|
56
56
|
*/
|
|
57
57
|
function nativePackageEntries(manifestPath, resolveExport) {
|
|
58
58
|
const manifest = JSON.parse(node_fs.default.readFileSync(manifestPath, "utf8"));
|
|
59
59
|
const root = node_path.default.dirname(node_fs.default.realpathSync(manifestPath));
|
|
60
|
-
const declaration = (0,
|
|
61
|
-
if (!declaration) return
|
|
60
|
+
const declaration = (0, _agimon_ai_po_core_serverPlugin.declaredServerPackagesOf)(root, manifest)[0];
|
|
61
|
+
if (!declaration) return PO_CONTRIBUTION_FIELDS.some((field) => manifest[field] !== void 0) ? [node_path.default.join(root, "package.json")] : [];
|
|
62
62
|
const exported = resolveExport();
|
|
63
63
|
const dist = node_path.default.resolve(root, declaration.dist);
|
|
64
64
|
if (!exported || !node_fs.default.existsSync(dist) || node_fs.default.realpathSync(exported) !== node_fs.default.realpathSync(dist)) throw new Error(`Native package ${declaration.packageName} must export its built poServer dist as ./extensions/server.`);
|
|
@@ -104,8 +104,9 @@ function missingConsumerPackage(name, consumerRoot) {
|
|
|
104
104
|
function createLayerResolvers(consumerRoot, environment = process.env) {
|
|
105
105
|
if (!consumerRoot) return LAYER_RESOLVERS;
|
|
106
106
|
const fallbackEntry = (name) => FIXED_CORE_PACKAGES.has(packageName(name)) ? (0, _agimon_ai_po_core_moduleResolution.optionalPackageEntry)(name, require("url").pathToFileURL(__filename).href) : void 0;
|
|
107
|
+
const entryOf = (name) => fallbackEntry(name) ?? (0, _agimon_ai_po_core_moduleResolution.consumerPackageEntry)(name, consumerRoot, environment) ?? (FIXED_CORE_PACKAGES.has(packageName(name)) ? (0, _agimon_ai_po_core_moduleResolution.checkoutPackageEntry)(name, require("url").pathToFileURL(__filename).href) : void 0);
|
|
107
108
|
const requiredEntry = (name) => {
|
|
108
|
-
const entry =
|
|
109
|
+
const entry = entryOf(name);
|
|
109
110
|
if (!entry) throw missingConsumerPackage(name, consumerRoot);
|
|
110
111
|
return entry;
|
|
111
112
|
};
|
|
@@ -117,7 +118,7 @@ function createLayerResolvers(consumerRoot, environment = process.env) {
|
|
|
117
118
|
return {
|
|
118
119
|
ownEntry: require_entryResolution.ownEntry,
|
|
119
120
|
packageEntry: requiredEntry,
|
|
120
|
-
optionalPackageEntry:
|
|
121
|
+
optionalPackageEntry: entryOf,
|
|
121
122
|
packageEntries: requiredEntries,
|
|
122
123
|
optionalPackageEntries: (name) => installedPackageEntries(name, consumerRoot, environment),
|
|
123
124
|
localEntry: _agimon_ai_po_core_moduleResolution.localEntry,
|
|
@@ -238,16 +239,16 @@ function resolveDefinitionSelections(definition, layer, layerIndex, resolvers, t
|
|
|
238
239
|
throw error;
|
|
239
240
|
}
|
|
240
241
|
if (!resolved?.length && tolerateUnsynced && !optional) {
|
|
241
|
-
resolvedSelections.push(missingOptionalSelection(identity, `Package "${selector}" is not synced yet: it resolves to no Po server, web or MCP
|
|
242
|
+
resolvedSelections.push(missingOptionalSelection(identity, `Package "${selector}" is not synced yet: it resolves to no Po server, web or MCP contribution.`));
|
|
242
243
|
continue;
|
|
243
244
|
}
|
|
244
245
|
if (!resolved?.length) {
|
|
245
246
|
if (optional) {
|
|
246
|
-
resolvedSelections.push(missingOptionalSelection(identity, `Optional package "${selector}" is unavailable or declares no Po server, web or MCP
|
|
247
|
+
resolvedSelections.push(missingOptionalSelection(identity, `Optional package "${selector}" is unavailable or declares no Po server, web or MCP contribution.`));
|
|
247
248
|
continue;
|
|
248
249
|
}
|
|
249
|
-
if ((0, _agimon_ai_po_config_majorModes.isLocalPackageSpecifier)(selector)) throw new Error(`Layer "${layer}" package "${selector}" does not resolve under ${definition.baseDirectory}. Point it at an extension file, or a package directory whose package.json declares a Po
|
|
250
|
-
throw new Error(`Layer "${layer}" package "${selector}" declares no Po server, web or MCP
|
|
250
|
+
if ((0, _agimon_ai_po_config_majorModes.isLocalPackageSpecifier)(selector)) throw new Error(`Layer "${layer}" package "${selector}" does not resolve under ${definition.baseDirectory}. Point it at an extension file, or a package directory whose package.json declares a Po contribution.`);
|
|
251
|
+
throw new Error(`Layer "${layer}" package "${selector}" declares no Po server, web or MCP contribution.`);
|
|
251
252
|
}
|
|
252
253
|
resolved.forEach((resolvedPath, manifestIndex) => {
|
|
253
254
|
resolvedSelections.push(resolvedSelection(identity, manifestIndex, resolvedPath));
|