@noopolis/daimon 0.1.2 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +269 -51
- package/dist/contracts/attentionContract.d.ts +117 -0
- package/dist/contracts/attentionContract.d.ts.map +1 -0
- package/dist/contracts/attentionContract.js +14 -0
- package/dist/contracts/canonicalJson.d.ts +3 -0
- package/dist/contracts/canonicalJson.d.ts.map +1 -0
- package/dist/contracts/canonicalJson.js +54 -0
- package/dist/contracts/grokWorkerContract.d.ts +74 -0
- package/dist/contracts/grokWorkerContract.d.ts.map +1 -0
- package/dist/contracts/grokWorkerContract.js +88 -0
- package/dist/contracts/organizationRuntimeContract.d.ts +765 -0
- package/dist/contracts/organizationRuntimeContract.d.ts.map +1 -0
- package/dist/contracts/organizationRuntimeContract.js +121 -0
- package/dist/contracts/runtimeContractManifest.d.ts +1615 -0
- package/dist/contracts/runtimeContractManifest.d.ts.map +1 -0
- package/dist/contracts/runtimeContractManifest.js +181 -0
- package/dist/core/credentialRedaction.d.ts +4 -0
- package/dist/core/credentialRedaction.d.ts.map +1 -0
- package/dist/core/credentialRedaction.js +28 -0
- package/dist/mcp/toolServer.d.ts +19 -2
- package/dist/mcp/toolServer.d.ts.map +1 -1
- package/dist/mcp/toolServer.js +57 -17
- package/dist/observability/causalEvents.d.ts +3 -3
- package/dist/observability/causalEvents.d.ts.map +1 -1
- package/dist/observability/causalEvents.js +103 -15
- package/dist/observability/orgObserver.d.ts.map +1 -1
- package/dist/observability/orgObserver.js +3 -3
- package/dist/pi/agyHeadlessResult.d.ts +60 -0
- package/dist/pi/agyHeadlessResult.d.ts.map +1 -0
- package/dist/pi/agyHeadlessResult.js +95 -0
- package/dist/pi/cliChildOutput.d.ts +67 -0
- package/dist/pi/cliChildOutput.d.ts.map +1 -0
- package/dist/pi/cliChildOutput.js +269 -0
- package/dist/pi/cliEngineRun.d.ts +16 -0
- package/dist/pi/cliEngineRun.d.ts.map +1 -0
- package/dist/pi/cliEngineRun.js +27 -0
- package/dist/pi/cliEngineSpawn.d.ts +55 -0
- package/dist/pi/cliEngineSpawn.d.ts.map +1 -0
- package/dist/pi/cliEngineSpawn.js +164 -0
- package/dist/pi/cliEnvironment.d.ts +12 -0
- package/dist/pi/cliEnvironment.d.ts.map +1 -0
- package/dist/pi/cliEnvironment.js +32 -0
- package/dist/pi/cliMcpRegistration.d.ts +61 -0
- package/dist/pi/cliMcpRegistration.d.ts.map +1 -0
- package/dist/pi/cliMcpRegistration.js +75 -0
- package/dist/pi/cliProcess.d.ts +7 -0
- package/dist/pi/cliProcess.d.ts.map +1 -0
- package/dist/pi/cliProcess.js +132 -0
- package/dist/pi/cliSession.d.ts +84 -24
- package/dist/pi/cliSession.d.ts.map +1 -1
- package/dist/pi/cliSession.js +313 -158
- package/dist/pi/cliTurnMetering.d.ts +60 -0
- package/dist/pi/cliTurnMetering.d.ts.map +1 -0
- package/dist/pi/cliTurnMetering.js +60 -0
- package/dist/pi/codexFilesystemRules.d.ts +3 -0
- package/dist/pi/codexFilesystemRules.d.ts.map +1 -0
- package/dist/pi/codexFilesystemRules.js +28 -0
- package/dist/pi/codexHeadlessResult.d.ts +68 -0
- package/dist/pi/codexHeadlessResult.d.ts.map +1 -0
- package/dist/pi/codexHeadlessResult.js +122 -0
- package/dist/pi/codexRolloutUsage.d.ts +95 -0
- package/dist/pi/codexRolloutUsage.d.ts.map +1 -0
- package/dist/pi/codexRolloutUsage.js +221 -0
- package/dist/pi/engineWakeLimits.d.ts +39 -0
- package/dist/pi/engineWakeLimits.d.ts.map +1 -0
- package/dist/pi/engineWakeLimits.js +55 -0
- package/dist/pi/grokHeadlessResult.d.ts +36 -0
- package/dist/pi/grokHeadlessResult.d.ts.map +1 -0
- package/dist/pi/grokHeadlessResult.js +118 -0
- package/dist/pi/grokHomeMcpRegistration.d.ts +21 -0
- package/dist/pi/grokHomeMcpRegistration.d.ts.map +1 -0
- package/dist/pi/grokHomeMcpRegistration.js +57 -0
- package/dist/pi/grokSandbox.d.ts +11 -0
- package/dist/pi/grokSandbox.d.ts.map +1 -0
- package/dist/pi/grokSandbox.js +216 -0
- package/dist/pi/grokStreamUsage.d.ts +31 -0
- package/dist/pi/grokStreamUsage.d.ts.map +1 -0
- package/dist/pi/grokStreamUsage.js +51 -0
- package/dist/pi/piAgentHandle.d.ts +4 -3
- package/dist/pi/piAgentHandle.d.ts.map +1 -1
- package/dist/pi/piAgentHandle.js +37 -10
- package/dist/pi/piAgentWakeSupport.d.ts +35 -0
- package/dist/pi/piAgentWakeSupport.d.ts.map +1 -1
- package/dist/pi/piAgentWakeSupport.js +4 -0
- package/dist/pi/piHarness.d.ts +10 -1
- package/dist/pi/piHarness.d.ts.map +1 -1
- package/dist/pi/piHarness.js +61 -8
- package/dist/pi/prompts.d.ts +1 -0
- package/dist/pi/prompts.d.ts.map +1 -1
- package/dist/pi/prompts.js +24 -0
- package/dist/pi/turnTrace.d.ts.map +1 -1
- package/dist/pi/turnTrace.js +5 -8
- package/dist/pi/worldTrajectory.d.ts +1 -1
- package/dist/pi/worldTrajectory.d.ts.map +1 -1
- package/dist/pi/worldTrajectory.js +3 -3
- package/dist/runtime/agySubscriptionBootstrap.d.ts +16 -0
- package/dist/runtime/agySubscriptionBootstrap.d.ts.map +1 -0
- package/dist/runtime/agySubscriptionBootstrap.js +80 -0
- package/dist/runtime/agySubscriptionRealm.d.ts +38 -0
- package/dist/runtime/agySubscriptionRealm.d.ts.map +1 -0
- package/dist/runtime/agySubscriptionRealm.js +242 -0
- package/dist/runtime/attention.d.ts +21 -0
- package/dist/runtime/attention.d.ts.map +1 -0
- package/dist/runtime/attention.js +36 -0
- package/dist/runtime/attentionDispatcher.d.ts +66 -0
- package/dist/runtime/attentionDispatcher.d.ts.map +1 -0
- package/dist/runtime/attentionDispatcher.js +271 -0
- package/dist/runtime/cli.d.ts +7 -0
- package/dist/runtime/cli.d.ts.map +1 -0
- package/dist/runtime/cli.js +251 -0
- package/dist/runtime/codexSandboxProjection.d.ts +17 -0
- package/dist/runtime/codexSandboxProjection.d.ts.map +1 -0
- package/dist/runtime/codexSandboxProjection.js +40 -0
- package/dist/runtime/contract-manifest.json +1 -0
- package/dist/runtime/contract-manifest.sha256 +1 -0
- package/dist/runtime/contractManifest.d.ts +8 -0
- package/dist/runtime/contractManifest.d.ts.map +1 -0
- package/dist/runtime/contractManifest.js +4 -0
- package/dist/runtime/engineBrokerCapabilities.d.ts +30 -0
- package/dist/runtime/engineBrokerCapabilities.d.ts.map +1 -0
- package/dist/runtime/engineBrokerCapabilities.js +59 -0
- package/dist/runtime/engineBrokerControlClient.d.ts +44 -0
- package/dist/runtime/engineBrokerControlClient.d.ts.map +1 -0
- package/dist/runtime/engineBrokerControlClient.js +132 -0
- package/dist/runtime/engineBrokerCredentialJournal.d.ts +10 -0
- package/dist/runtime/engineBrokerCredentialJournal.d.ts.map +1 -0
- package/dist/runtime/engineBrokerCredentialJournal.js +17 -0
- package/dist/runtime/engineBrokerInferenceProtocol.d.ts +52 -0
- package/dist/runtime/engineBrokerInferenceProtocol.d.ts.map +1 -0
- package/dist/runtime/engineBrokerInferenceProtocol.js +65 -0
- package/dist/runtime/engineBrokerMcpCallLog.d.ts +160 -0
- package/dist/runtime/engineBrokerMcpCallLog.d.ts.map +1 -0
- package/dist/runtime/engineBrokerMcpCallLog.js +219 -0
- package/dist/runtime/engineBrokerMcpFacade.d.ts +56 -0
- package/dist/runtime/engineBrokerMcpFacade.d.ts.map +1 -0
- package/dist/runtime/engineBrokerMcpFacade.js +343 -0
- package/dist/runtime/engineBrokerNativeClient.d.ts +52 -0
- package/dist/runtime/engineBrokerNativeClient.d.ts.map +1 -0
- package/dist/runtime/engineBrokerNativeClient.js +151 -0
- package/dist/runtime/engineBrokerProtocol.d.ts +135 -0
- package/dist/runtime/engineBrokerProtocol.d.ts.map +1 -0
- package/dist/runtime/engineBrokerProtocol.js +274 -0
- package/dist/runtime/engineBrokerSealLedger.d.ts +70 -0
- package/dist/runtime/engineBrokerSealLedger.d.ts.map +1 -0
- package/dist/runtime/engineBrokerSealLedger.js +123 -0
- package/dist/runtime/engineBrokerService.d.ts +37 -0
- package/dist/runtime/engineBrokerService.d.ts.map +1 -0
- package/dist/runtime/engineBrokerService.js +138 -0
- package/dist/runtime/engineBrokerServiceCli.d.ts +5 -0
- package/dist/runtime/engineBrokerServiceCli.d.ts.map +1 -0
- package/dist/runtime/engineBrokerServiceCli.js +32 -0
- package/dist/runtime/engineBrokerServiceConfig.d.ts +50 -0
- package/dist/runtime/engineBrokerServiceConfig.d.ts.map +1 -0
- package/dist/runtime/engineBrokerServiceConfig.js +92 -0
- package/dist/runtime/engineBrokerSingleflight.d.ts +13 -0
- package/dist/runtime/engineBrokerSingleflight.d.ts.map +1 -0
- package/dist/runtime/engineBrokerSingleflight.js +24 -0
- package/dist/runtime/engineBrokerTurnAccounting.d.ts +76 -0
- package/dist/runtime/engineBrokerTurnAccounting.d.ts.map +1 -0
- package/dist/runtime/engineBrokerTurnAccounting.js +108 -0
- package/dist/runtime/engineBrokerTurnRegistry.d.ts +57 -0
- package/dist/runtime/engineBrokerTurnRegistry.d.ts.map +1 -0
- package/dist/runtime/engineBrokerTurnRegistry.js +158 -0
- package/dist/runtime/engineDispatcher.d.ts +36 -0
- package/dist/runtime/engineDispatcher.d.ts.map +1 -0
- package/dist/runtime/engineDispatcher.js +216 -0
- package/dist/runtime/engineReadiness.d.ts +23 -0
- package/dist/runtime/engineReadiness.d.ts.map +1 -0
- package/dist/runtime/engineReadiness.js +222 -0
- package/dist/runtime/grokAuthenticationError.d.ts +8 -0
- package/dist/runtime/grokAuthenticationError.d.ts.map +1 -0
- package/dist/runtime/grokAuthenticationError.js +20 -0
- package/dist/runtime/grokBrokerCredentialAuthority.d.ts +22 -0
- package/dist/runtime/grokBrokerCredentialAuthority.d.ts.map +1 -0
- package/dist/runtime/grokBrokerCredentialAuthority.js +124 -0
- package/dist/runtime/grokBrokerCredentialReader.d.ts +5 -0
- package/dist/runtime/grokBrokerCredentialReader.d.ts.map +1 -0
- package/dist/runtime/grokBrokerCredentialReader.js +37 -0
- package/dist/runtime/grokBrokerModelPolicy.d.ts +23 -0
- package/dist/runtime/grokBrokerModelPolicy.d.ts.map +1 -0
- package/dist/runtime/grokBrokerModelPolicy.js +28 -0
- package/dist/runtime/grokBrokerProjection.d.ts +106 -0
- package/dist/runtime/grokBrokerProjection.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProjection.js +94 -0
- package/dist/runtime/grokBrokerProxy.d.ts +55 -0
- package/dist/runtime/grokBrokerProxy.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProxy.js +262 -0
- package/dist/runtime/grokBrokerProxyRequest.d.ts +30 -0
- package/dist/runtime/grokBrokerProxyRequest.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProxyRequest.js +74 -0
- package/dist/runtime/grokBrokerRealmLease.d.ts +4 -0
- package/dist/runtime/grokBrokerRealmLease.d.ts.map +1 -0
- package/dist/runtime/grokBrokerRealmLease.js +33 -0
- package/dist/runtime/grokBrokerRefresh.d.ts +2 -0
- package/dist/runtime/grokBrokerRefresh.d.ts.map +1 -0
- package/dist/runtime/grokBrokerRefresh.js +15 -0
- package/dist/runtime/grokBrokerTurnMeter.d.ts +128 -0
- package/dist/runtime/grokBrokerTurnMeter.d.ts.map +1 -0
- package/dist/runtime/grokBrokerTurnMeter.js +251 -0
- package/dist/runtime/grokBrokerWorkerConfig.d.ts +86 -0
- package/dist/runtime/grokBrokerWorkerConfig.d.ts.map +1 -0
- package/dist/runtime/grokBrokerWorkerConfig.js +135 -0
- package/dist/runtime/grokEngineBroker.d.ts +48 -0
- package/dist/runtime/grokEngineBroker.d.ts.map +1 -0
- package/dist/runtime/grokEngineBroker.js +114 -0
- package/dist/runtime/grokEngineBrokerLedger.d.ts +52 -0
- package/dist/runtime/grokEngineBrokerLedger.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerLedger.js +114 -0
- package/dist/runtime/grokEngineBrokerMetering.d.ts +51 -0
- package/dist/runtime/grokEngineBrokerMetering.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerMetering.js +34 -0
- package/dist/runtime/grokEngineBrokerTurn.d.ts +58 -0
- package/dist/runtime/grokEngineBrokerTurn.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerTurn.js +165 -0
- package/dist/runtime/grokInferenceClientConfig.d.ts +41 -0
- package/dist/runtime/grokInferenceClientConfig.d.ts.map +1 -0
- package/dist/runtime/grokInferenceClientConfig.js +62 -0
- package/dist/runtime/grokInferenceGrants.d.ts +77 -0
- package/dist/runtime/grokInferenceGrants.d.ts.map +1 -0
- package/dist/runtime/grokInferenceGrants.js +116 -0
- package/dist/runtime/grokInferenceProxy.d.ts +29 -0
- package/dist/runtime/grokInferenceProxy.d.ts.map +1 -0
- package/dist/runtime/grokInferenceProxy.js +82 -0
- package/dist/runtime/grokInferenceProxyRequest.d.ts +23 -0
- package/dist/runtime/grokInferenceProxyRequest.d.ts.map +1 -0
- package/dist/runtime/grokInferenceProxyRequest.js +63 -0
- package/dist/runtime/grokSlotPreflightReceipt.d.ts +70 -0
- package/dist/runtime/grokSlotPreflightReceipt.d.ts.map +1 -0
- package/dist/runtime/grokSlotPreflightReceipt.js +101 -0
- package/dist/runtime/grokSubscriptionRealm.d.ts +4 -0
- package/dist/runtime/grokSubscriptionRealm.d.ts.map +1 -0
- package/dist/runtime/grokSubscriptionRealm.js +435 -0
- package/dist/runtime/grokSubscriptionRealmTypes.d.ts +26 -0
- package/dist/runtime/grokSubscriptionRealmTypes.d.ts.map +1 -0
- package/dist/runtime/grokSubscriptionRealmTypes.js +1 -0
- package/dist/runtime/grokWorkerAttestation.d.ts +170 -0
- package/dist/runtime/grokWorkerAttestation.d.ts.map +1 -0
- package/dist/runtime/grokWorkerAttestation.js +266 -0
- package/dist/runtime/grokWorkerDenyPlacement.d.ts +80 -0
- package/dist/runtime/grokWorkerDenyPlacement.d.ts.map +1 -0
- package/dist/runtime/grokWorkerDenyPlacement.js +128 -0
- package/dist/runtime/grokWorkerHomeAttestation.d.ts +30 -0
- package/dist/runtime/grokWorkerHomeAttestation.d.ts.map +1 -0
- package/dist/runtime/grokWorkerHomeAttestation.js +69 -0
- package/dist/runtime/grokWorkerSandboxProfile.d.ts +27 -0
- package/dist/runtime/grokWorkerSandboxProfile.d.ts.map +1 -0
- package/dist/runtime/grokWorkerSandboxProfile.js +44 -0
- package/dist/runtime/grokWorkerTmpAttestation.d.ts +55 -0
- package/dist/runtime/grokWorkerTmpAttestation.d.ts.map +1 -0
- package/dist/runtime/grokWorkerTmpAttestation.js +63 -0
- package/dist/runtime/index.d.ts +26 -0
- package/dist/runtime/index.d.ts.map +1 -0
- package/dist/runtime/index.js +23 -0
- package/dist/runtime/inferenceUsageLedger.d.ts +38 -0
- package/dist/runtime/inferenceUsageLedger.d.ts.map +1 -0
- package/dist/runtime/inferenceUsageLedger.js +53 -0
- package/dist/runtime/mcpToolResult.d.ts +127 -0
- package/dist/runtime/mcpToolResult.d.ts.map +1 -0
- package/dist/runtime/mcpToolResult.js +214 -0
- package/dist/runtime/moltnetMachineRead.d.ts +97 -0
- package/dist/runtime/moltnetMachineRead.d.ts.map +1 -0
- package/dist/runtime/moltnetMachineRead.js +183 -0
- package/dist/runtime/native/daimon-engine-broker +0 -0
- package/dist/runtime/organizationRuntime.d.ts +165 -0
- package/dist/runtime/organizationRuntime.d.ts.map +1 -0
- package/dist/runtime/organizationRuntime.js +3 -0
- package/dist/runtime/organizationRuntimeControl.d.ts +42 -0
- package/dist/runtime/organizationRuntimeControl.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeControl.js +235 -0
- package/dist/runtime/organizationRuntimeHost.d.ts +19 -0
- package/dist/runtime/organizationRuntimeHost.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeHost.js +359 -0
- package/dist/runtime/organizationRuntimeParsing.d.ts +6 -0
- package/dist/runtime/organizationRuntimeParsing.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeParsing.js +370 -0
- package/dist/runtime/organizationRuntimeReadiness.d.ts +12 -0
- package/dist/runtime/organizationRuntimeReadiness.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeReadiness.js +59 -0
- package/dist/runtime/physicalReadiness.d.ts +47 -0
- package/dist/runtime/physicalReadiness.d.ts.map +1 -0
- package/dist/runtime/physicalReadiness.js +142 -0
- package/dist/runtime/portableCredentialAuth.d.ts +6 -0
- package/dist/runtime/portableCredentialAuth.d.ts.map +1 -0
- package/dist/runtime/portableCredentialAuth.js +70 -0
- package/dist/runtime/portableCredentialMaterial.d.ts +8 -0
- package/dist/runtime/portableCredentialMaterial.d.ts.map +1 -0
- package/dist/runtime/portableCredentialMaterial.js +169 -0
- package/dist/runtime/productionAgentTools.d.ts +5 -0
- package/dist/runtime/productionAgentTools.d.ts.map +1 -0
- package/dist/runtime/productionAgentTools.js +328 -0
- package/dist/runtime/runtimeHomeLayout.d.ts +48 -0
- package/dist/runtime/runtimeHomeLayout.d.ts.map +1 -0
- package/dist/runtime/runtimeHomeLayout.js +84 -0
- package/dist/runtime/schedule.d.ts +40 -0
- package/dist/runtime/schedule.d.ts.map +1 -0
- package/dist/runtime/schedule.js +371 -0
- package/dist/runtime/storeCoordination.d.ts +23 -0
- package/dist/runtime/storeCoordination.d.ts.map +1 -0
- package/dist/runtime/storeCoordination.js +94 -0
- package/dist/runtime/toolResultSpill.d.ts +152 -0
- package/dist/runtime/toolResultSpill.d.ts.map +1 -0
- package/dist/runtime/toolResultSpill.js +351 -0
- package/dist/runtime/turnRequestLedger.d.ts +160 -0
- package/dist/runtime/turnRequestLedger.d.ts.map +1 -0
- package/dist/runtime/turnRequestLedger.js +249 -0
- package/dist/runtime/turnUsageLedger.d.ts +143 -0
- package/dist/runtime/turnUsageLedger.d.ts.map +1 -0
- package/dist/runtime/turnUsageLedger.js +203 -0
- package/dist/runtime/wakeAcceptanceProcessIdentity.d.ts +17 -0
- package/dist/runtime/wakeAcceptanceProcessIdentity.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceProcessIdentity.js +50 -0
- package/dist/runtime/wakeAcceptanceReconciliation.d.ts +211 -0
- package/dist/runtime/wakeAcceptanceReconciliation.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceReconciliation.js +289 -0
- package/dist/runtime/wakeAcceptanceRecord.d.ts +23 -0
- package/dist/runtime/wakeAcceptanceRecord.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceRecord.js +56 -0
- package/dist/runtime/wakeAcceptanceRetention.d.ts +12 -0
- package/dist/runtime/wakeAcceptanceRetention.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceRetention.js +12 -0
- package/dist/runtime/wakeAcceptanceStore.d.ts +113 -0
- package/dist/runtime/wakeAcceptanceStore.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceStore.js +558 -0
- package/dist/runtime/wakeAcceptanceTypes.d.ts +179 -0
- package/dist/runtime/wakeAcceptanceTypes.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceTypes.js +95 -0
- package/dist/runtime/wakeFuse.d.ts +69 -0
- package/dist/runtime/wakeFuse.d.ts.map +1 -0
- package/dist/runtime/wakeFuse.js +367 -0
- package/package.json +20 -9
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"piAgentHandle.d.ts","sourceRoot":"","sources":["../../src/pi/piAgentHandle.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"piAgentHandle.d.ts","sourceRoot":"","sources":["../../src/pi/piAgentHandle.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACxF,OAAO,EAAoC,KAAK,sBAAsB,EAAE,MAAM,kBAAkB,CAAC;AAEjG,OAAO,EACL,uBAAuB,EACvB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AAmB,EAClC,gBAAgB,CAAC,EAAE,qBAAqB,EACxC,qBAAqB,CAAC,EAAE,KAAK,EAC7B,yBAAyB,CAAC,EAAE,KAAK,EACjC,uBAAuB,CAAC,EAAE,yBAAyB,EACnD,yBAAyB,CAAC,EAAE,KAAK,EACjC,sBAAsB,CAAC,EAAE,2BAA2B;IA0BhD,IAAI,CAAC,KAAK,EAAE,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC;YAOnC,OAAO;IA+RrB,MAAM,IAAI,WAAW;IAQf,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;CAM5B"}
|
package/dist/pi/piAgentHandle.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createTrustedPiMemoryToolContext } from "./memoryTools.js";
|
|
2
|
-
import { formatWakePrompt } from "./prompts.js";
|
|
2
|
+
import { formatWakePrompt, preserveModelFacingWakeIdentity } from "./prompts.js";
|
|
3
3
|
import { stampTurnInputSubmitted, stampTurnOutputCompleted } from "./turnCausal.js";
|
|
4
4
|
import { WakeAcceptanceStore } from "./wakeAcceptance.js";
|
|
5
5
|
import { persistPiTurnTrace } from "./turnTrace.js";
|
|
@@ -7,7 +7,7 @@ import { formatDreamPrompt } from "./wakeModes.js";
|
|
|
7
7
|
import { createPiRawTrainingCapture } from "./rawTrainingCapture.js";
|
|
8
8
|
import { formatWorldWakePrompt, worldWakeContext } from "./worldNudge.js";
|
|
9
9
|
import { createPiWorldTrajectoryCapture } from "./worldTrajectory.js";
|
|
10
|
-
import { cloneWakeEvent, persistPiTurnArtifacts, PiWakeDeliveryQueue, selectPiSessionForWake, subscribeToPiTurnEvents } from "./piAgentWakeSupport.js";
|
|
10
|
+
import { cloneWakeEvent, disposePiSession, persistPiTurnArtifacts, PiWakeDeliveryQueue, selectPiSessionForWake, subscribeToPiTurnEvents } from "./piAgentWakeSupport.js";
|
|
11
11
|
import { readMemoryContext } from "@noopolis/mneme";
|
|
12
12
|
export class PiAgentHandle {
|
|
13
13
|
id;
|
|
@@ -22,6 +22,7 @@ export class PiAgentHandle {
|
|
|
22
22
|
rawTrainingCaptureOptions;
|
|
23
23
|
worldTrajectoryIdentity;
|
|
24
24
|
piSessionForRawCapture;
|
|
25
|
+
wakeEnvironmentContext;
|
|
25
26
|
state = "idle";
|
|
26
27
|
lastWakeAt;
|
|
27
28
|
lastError;
|
|
@@ -29,7 +30,7 @@ export class PiAgentHandle {
|
|
|
29
30
|
stampTurnInputSubmitted;
|
|
30
31
|
stampTurnOutputCompleted;
|
|
31
32
|
persistTrace;
|
|
32
|
-
constructor(id, session, createSession, runtimeHomePath, traceModel, memory, memoryToolContext, dependencies = {}, worldToolContext, rawTrainingCaptureRef, rawTrainingCaptureOptions, worldTrajectoryIdentity, piSessionForRawCapture) {
|
|
33
|
+
constructor(id, session, createSession, runtimeHomePath, traceModel, memory, memoryToolContext, dependencies = {}, worldToolContext, rawTrainingCaptureRef, rawTrainingCaptureOptions, worldTrajectoryIdentity, piSessionForRawCapture, wakeEnvironmentContext) {
|
|
33
34
|
this.id = id;
|
|
34
35
|
this.session = session;
|
|
35
36
|
this.createSession = createSession;
|
|
@@ -42,6 +43,7 @@ export class PiAgentHandle {
|
|
|
42
43
|
this.rawTrainingCaptureOptions = rawTrainingCaptureOptions;
|
|
43
44
|
this.worldTrajectoryIdentity = worldTrajectoryIdentity;
|
|
44
45
|
this.piSessionForRawCapture = piSessionForRawCapture;
|
|
46
|
+
this.wakeEnvironmentContext = wakeEnvironmentContext;
|
|
45
47
|
this.stampTurnInputSubmitted = dependencies.runWake ?? stampTurnInputSubmitted;
|
|
46
48
|
this.stampTurnOutputCompleted = dependencies.completeTurn ?? stampTurnOutputCompleted;
|
|
47
49
|
this.persistTrace = dependencies.traceTurn ?? persistPiTurnTrace;
|
|
@@ -88,7 +90,7 @@ export class PiAgentHandle {
|
|
|
88
90
|
? undefined
|
|
89
91
|
: createPiWorldTrajectoryCapture();
|
|
90
92
|
const request = {
|
|
91
|
-
eventId: event.id
|
|
93
|
+
eventId: /^(simfile|moltnet|mneme|daimon):.+$/u.test(event.id) ? event.id : `daimon:${event.id}`,
|
|
92
94
|
kind: event.kind,
|
|
93
95
|
text: safeWakeText,
|
|
94
96
|
from: event.from,
|
|
@@ -98,6 +100,10 @@ export class PiAgentHandle {
|
|
|
98
100
|
? formatWakePrompt(event)
|
|
99
101
|
: safeWakeText;
|
|
100
102
|
try {
|
|
103
|
+
if (this.wakeEnvironmentContext !== undefined) {
|
|
104
|
+
this.wakeEnvironmentContext.current = event.id;
|
|
105
|
+
this.wakeEnvironmentContext.spokeFor = undefined;
|
|
106
|
+
}
|
|
101
107
|
if (this.worldToolContext !== undefined) {
|
|
102
108
|
this.worldToolContext.current = worldContext;
|
|
103
109
|
}
|
|
@@ -139,7 +145,7 @@ export class PiAgentHandle {
|
|
|
139
145
|
prepared,
|
|
140
146
|
status: "completed"
|
|
141
147
|
};
|
|
142
|
-
promptText = prepared.promptText;
|
|
148
|
+
promptText = preserveModelFacingWakeIdentity(prepared.promptText, event, request.eventId);
|
|
143
149
|
if (this.memoryToolContext !== undefined) {
|
|
144
150
|
this.memoryToolContext.observeTool = (toolEvent) => tools.push(toolEvent);
|
|
145
151
|
this.memoryToolContext.current = createTrustedPiMemoryToolContext({
|
|
@@ -169,6 +175,7 @@ export class PiAgentHandle {
|
|
|
169
175
|
}
|
|
170
176
|
stage = "engine_prompt";
|
|
171
177
|
const engineStartedAt = Date.now();
|
|
178
|
+
selectedSession.session.bindWake?.(event);
|
|
172
179
|
await selectedSession.session.prompt(promptText, { expandPromptTemplates: false });
|
|
173
180
|
enginePromptMs = Date.now() - engineStartedAt;
|
|
174
181
|
this.state = "idle";
|
|
@@ -181,6 +188,10 @@ export class PiAgentHandle {
|
|
|
181
188
|
runtimeHomePath: this.runtimeHomePath,
|
|
182
189
|
turnId: event.id
|
|
183
190
|
});
|
|
191
|
+
if (this.memory !== undefined && prepared !== undefined) {
|
|
192
|
+
await this.memory.recordTurn({ principal: prepared.principal, prompt: prepared.packet, request, recall: prepared.recall, result: "completed", outputText, toolEvents: tools })
|
|
193
|
+
.catch((recordError) => { this.lastError = `memory record failed: ${recordError instanceof Error ? recordError.message : String(recordError)}`; });
|
|
194
|
+
}
|
|
184
195
|
await this.persistTrace({
|
|
185
196
|
agentId: this.id,
|
|
186
197
|
enginePromptMs,
|
|
@@ -203,9 +214,6 @@ export class PiAgentHandle {
|
|
|
203
214
|
if (rawTrainingCapture !== undefined
|
|
204
215
|
&& this.rawTrainingCaptureOptions !== undefined
|
|
205
216
|
&& this.piSessionForRawCapture !== undefined) {
|
|
206
|
-
// Do not retry a partially failed private capture in the catch path.
|
|
207
|
-
// The first failure is authoritative and retrying the same immutable
|
|
208
|
-
// turn path would only mask it with an EEXIST/partial-write error.
|
|
209
217
|
rawTrainingCapturePersistAttempted = true;
|
|
210
218
|
}
|
|
211
219
|
await persistPiTurnArtifacts({
|
|
@@ -225,9 +233,18 @@ export class PiAgentHandle {
|
|
|
225
233
|
worldTrajectory,
|
|
226
234
|
worldTrajectoryIdentity: this.worldTrajectoryIdentity
|
|
227
235
|
});
|
|
236
|
+
// An agent with a mounted `moltnet_send` tool has exactly one
|
|
237
|
+
// legitimate publication channel; its terminal text is always a
|
|
238
|
+
// private note to the runtime — whether it spoke, stayed silent, or
|
|
239
|
+
// narrated a failure back as its reply — never the bridge's
|
|
240
|
+
// terminal-text fallback (moltnet/internal/bridge/daimon/
|
|
241
|
+
// receipt_tracker.go), which is reserved for agents with no send tool
|
|
242
|
+
// at all. `outputText` itself stays intact for the turn trace and
|
|
243
|
+
// memory record above.
|
|
244
|
+
const hasSendCapability = this.wakeEnvironmentContext?.hasSendCapability === true;
|
|
228
245
|
return {
|
|
229
246
|
agentId: this.id,
|
|
230
|
-
text: outputText,
|
|
247
|
+
text: hasSendCapability ? "" : outputText,
|
|
231
248
|
durationMs: Date.now() - startedAtMs
|
|
232
249
|
};
|
|
233
250
|
}
|
|
@@ -264,6 +281,9 @@ export class PiAgentHandle {
|
|
|
264
281
|
? {}
|
|
265
282
|
: { worldContextBound: worldContext !== undefined })
|
|
266
283
|
}).catch(() => undefined);
|
|
284
|
+
if (this.memory !== undefined && prepared !== undefined) {
|
|
285
|
+
await this.memory.recordTurn({ principal: prepared.principal, prompt: prepared.packet, request, recall: prepared.recall, result: "failed", error: message, outputText: chunks.join("\n").trim(), toolEvents: tools }).catch(() => undefined);
|
|
286
|
+
}
|
|
267
287
|
const persistRawCapture = !rawTrainingCapturePersistAttempted
|
|
268
288
|
&& selectedSession !== undefined;
|
|
269
289
|
if (persistRawCapture && rawTrainingCapture !== undefined) {
|
|
@@ -293,6 +313,11 @@ export class PiAgentHandle {
|
|
|
293
313
|
throw error;
|
|
294
314
|
}
|
|
295
315
|
finally {
|
|
316
|
+
selectedSession?.session.bindWake?.();
|
|
317
|
+
if (this.wakeEnvironmentContext !== undefined) {
|
|
318
|
+
this.wakeEnvironmentContext.current = undefined;
|
|
319
|
+
this.wakeEnvironmentContext.spokeFor = undefined;
|
|
320
|
+
}
|
|
296
321
|
if (this.memoryToolContext !== undefined) {
|
|
297
322
|
this.memoryToolContext.current = undefined;
|
|
298
323
|
this.memoryToolContext.observeTool = undefined;
|
|
@@ -318,7 +343,9 @@ export class PiAgentHandle {
|
|
|
318
343
|
};
|
|
319
344
|
}
|
|
320
345
|
async stop() {
|
|
321
|
-
|
|
346
|
+
// CLI-backed sessions may own a process group, while native Pi remains
|
|
347
|
+
// source-compatible through the synchronous dispose() hook.
|
|
348
|
+
await disposePiSession(this.session);
|
|
322
349
|
this.state = "stopped";
|
|
323
350
|
}
|
|
324
351
|
}
|
|
@@ -10,8 +10,43 @@ export type PiSession = Awaited<ReturnType<typeof createAgentSession>>["session"
|
|
|
10
10
|
export interface PiSessionLike {
|
|
11
11
|
subscribe(listener: Parameters<PiSession["subscribe"]>[0]): () => void;
|
|
12
12
|
prompt(text: string, options?: Parameters<PiSession["prompt"]>[1]): Promise<void>;
|
|
13
|
+
/** Optional per-turn context for isolated CLI child environments. */
|
|
14
|
+
bindWake?(event?: WakeEvent): void;
|
|
15
|
+
/** Kept synchronous for existing Pi session implementations. */
|
|
13
16
|
dispose(): void;
|
|
17
|
+
/** Optional additive hook for sessions that must asynchronously quiesce children. */
|
|
18
|
+
disposeAsync?(): Promise<void>;
|
|
14
19
|
}
|
|
20
|
+
export type PiWakeEnvironmentContextRef = {
|
|
21
|
+
current?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Set to the delivery id of the current wake once `moltnet_send` has been
|
|
24
|
+
* accepted during it. Bookkeeping only: it no longer gates whether the wake
|
|
25
|
+
* completion path publishes terminal text (see `hasSendCapability`), but it
|
|
26
|
+
* still records, per wake, whether this agent actually spoke. Never a
|
|
27
|
+
* boolean: a boolean could survive a stale reset and silently misattribute
|
|
28
|
+
* a later wake.
|
|
29
|
+
*/
|
|
30
|
+
spokeFor?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Set once per agent, at harness construction, to whether a `moltnet_send`
|
|
33
|
+
* tool is mounted for it (`piHarness.ts`, from `productionTools`) — never
|
|
34
|
+
* reset per wake, unlike `current`/`spokeFor`.
|
|
35
|
+
*
|
|
36
|
+
* A turn that fails partway (a tool error the model narrates back as
|
|
37
|
+
* terminal text, e.g. "Blocked: Moltnet auth is not mounted...") still
|
|
38
|
+
* completes structurally and used to publish that narration through the
|
|
39
|
+
* terminal-text fallback even though `moltnet_send` was never actually
|
|
40
|
+
* called — a second, unintended echo into the room. An agent with a
|
|
41
|
+
* mounted send tool has exactly one legitimate publication channel
|
|
42
|
+
* (`moltnet_send`); its terminal text is always a private note to the
|
|
43
|
+
* runtime, whether it spoke, stayed silent, or failed. Only an agent with
|
|
44
|
+
* no send tool at all keeps the documented terminal-text fallback
|
|
45
|
+
* (`moltnet/internal/bridge/daimon/AGENTS.md`).
|
|
46
|
+
*/
|
|
47
|
+
hasSendCapability?: boolean;
|
|
48
|
+
};
|
|
49
|
+
export declare function disposePiSession(session: PiSessionLike): Promise<void>;
|
|
15
50
|
export type PiSessionCreator = (mode: MemoryWakeMode, sessionDirectory: string) => Promise<PiSessionLike>;
|
|
16
51
|
export type PiNativeSessionCreator = (mode: MemoryWakeMode, sessionDirectory: string) => Promise<PiSession>;
|
|
17
52
|
export interface WakeSessionSelection {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"piAgentWakeSupport.d.ts","sourceRoot":"","sources":["../../src/pi/piAgentWakeSupport.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAC1E,OAAO,KAAK,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAEzE,OAAO,KAAK,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9D,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,2BAA2B,EACjC,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAEL,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EAC1B,MAAM,gBAAgB,CAAC;AAOxB,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAC1D,OAAO,EAEL,KAAK,wBAAwB,EAC7B,KAAK,uBAAuB,EAC7B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAGL,KAAK,wBAAwB,EAC7B,KAAK,yBAAyB,EAC/B,MAAM,sBAAsB,CAAC;AAE9B,MAAM,MAAM,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,OAAO,kBAAkB,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;AAClF,MAAM,WAAW,aAAa;IAC5B,SAAS,CAAC,QAAQ,EAAE,UAAU,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,MAAM,IAAI,CAAC;IACvE,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,UAAU,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,G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C,EAAE,yBAAyB,CAAC;CACrD,KAAG,OAAO,CAAC,IAAI,CAqCf,CAAC"}
|
|
@@ -3,6 +3,10 @@ import { summarizeSessionEvent, } from "./turnTrace.js";
|
|
|
3
3
|
import { createAwakeThreadId, createDreamSessionDirectory, createDreamSessionKey, createDreamThreadId, } from "./wakeModes.js";
|
|
4
4
|
import { WakeAcceptanceError, } from "./wakeAcceptance.js";
|
|
5
5
|
import { capturePiWorldTrajectoryEvent, persistPiWorldTrajectory, } from "./worldTrajectory.js";
|
|
6
|
+
export async function disposePiSession(session) {
|
|
7
|
+
await Promise.resolve(session.dispose());
|
|
8
|
+
await session.disposeAsync?.();
|
|
9
|
+
}
|
|
6
10
|
export class PiWakeDeliveryQueue {
|
|
7
11
|
agentId;
|
|
8
12
|
acceptance;
|
package/dist/pi/piHarness.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { createAgentSession } from "@earendil-works/pi-coding-agent";
|
|
1
|
+
import { createAgentSession, type ToolDefinition } from "@earendil-works/pi-coding-agent";
|
|
2
2
|
import { type MemoryAuthorityConfig } from "@noopolis/mneme";
|
|
3
3
|
import type { AgentHandle, AgentHarnessAdapter, AgentStartInput, HarnessModelSpec } from "../core/types.js";
|
|
4
4
|
import { type PiSessionLike } from "./piAgentHandle.js";
|
|
5
|
+
import { type PiWakeEnvironmentContextRef } from "./piAgentWakeSupport.js";
|
|
5
6
|
import { type PiWorldBinding } from "./worldTools.js";
|
|
6
7
|
import { type PiRawTrainingCaptureOptions } from "./rawTrainingCapture.js";
|
|
7
8
|
type HarnessMemoryEmbeddingProvider = {
|
|
@@ -18,6 +19,8 @@ type PiHarnessBaseOptions = {
|
|
|
18
19
|
name: string;
|
|
19
20
|
};
|
|
20
21
|
modelsPath?: string;
|
|
22
|
+
/** Host-only names removed from every engine and Pi bash child environment. */
|
|
23
|
+
protectedEnvironmentNames?: readonly string[];
|
|
21
24
|
memory?: {
|
|
22
25
|
authority?: MemoryAuthorityConfig;
|
|
23
26
|
embeddingProvider?: HarnessMemoryEmbeddingProvider;
|
|
@@ -27,6 +30,10 @@ type PiHarnessBaseOptions = {
|
|
|
27
30
|
};
|
|
28
31
|
thinkingLevel?: PiThinkingLevel;
|
|
29
32
|
world?: PiWorldBinding;
|
|
33
|
+
productionTools?: readonly ToolDefinition[];
|
|
34
|
+
/** Engine-owned default; an empty list disables Pi builtins for confined CLI engines. */
|
|
35
|
+
toolNames?: readonly string[];
|
|
36
|
+
wakeEnvironmentContext?: PiWakeEnvironmentContextRef;
|
|
30
37
|
};
|
|
31
38
|
export type PiHarnessOptions = PiHarnessBaseOptions & ({
|
|
32
39
|
rawTrainingCapture?: PiRawTrainingCaptureOptions;
|
|
@@ -37,6 +44,8 @@ export type PiHarnessOptions = PiHarnessBaseOptions & ({
|
|
|
37
44
|
});
|
|
38
45
|
export type PiSessionFactoryInput = Exclude<Parameters<typeof createAgentSession>[0], undefined> & {
|
|
39
46
|
daimonSecretEnvironmentNames?: readonly string[];
|
|
47
|
+
/** The isolated runtime home assigned by Daimon to this one agent. */
|
|
48
|
+
runtimeHomePath?: string;
|
|
40
49
|
};
|
|
41
50
|
export type PiSessionFactory = (input: PiSessionFactoryInput) => Promise<{
|
|
42
51
|
session: PiSessionLike;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"piHarness.d.ts","sourceRoot":"","sources":["../../src/pi/piHarness.ts"],"names":[],"mappings":"AAGA,OAAO,
|
|
1
|
+
{"version":3,"file":"piHarness.d.ts","sourceRoot":"","sources":["../../src/pi/piHarness.ts"],"names":[],"mappings":"AAGA,OAAO,EAGL,kBAAkB,EAIlB,KAAK,cAAc,EACpB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAuB,KAAK,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AAElF,OAAO,KAAK,EAAE,WAAW,EAAE,mBAAmB,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAM5G,OAAO,EAAqE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5C,yFAAyF;IACzF,SAAS,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9B,sBAAsB,CAAC,EAAE,2BAA2B,CAAC;CACtD,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG,oBAAoB,GAAG,CAClD;IACA,kBAAkB,CAAC,EAAE,2BAA2B,CAAC;IACjD,cAAc,CAAC,EAAE,KAAK,CAAC;CACxB,GACC;IACA,kBAAkB,CAAC,EAAE,KAAK,CAAC;IAC3B,cAAc,EAAE,gBAAgB,CAAC;CAClC,CACF,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,OAAO,CAAC,UAAU,CAAC,OAAO,kBAAkB,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,GAAG;IACjG,4BAA4B,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACjD,sEAAsE;IACtE,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAEF,MAAM,MAAM,gBAAgB,GAAG,CAAC,KAAK,EAAE,qBAAqB,KAAK,OAAO,CAAC;IAAE,OAAO,EAAE,aAAa,CAAA;CAAE,CAAC,CAAC;AAErG,qBAAa,gBAAiB,YAAW,mBAAmB;IAK9C,OAAO,CAAC,QAAQ,CAAC,OAAO;IAJpC,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAc;IAC1C,OAAO,CAAC,QAAQ,CAAC,aAAa,CAAgB;IAC9C,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAmB;gBAErB,OAAO,EAAE,gBAAgB;IAMhD,UAAU,CAAC,KAAK,EAAE,eAAe,GAAG,OAAO,CAAC,WAAW,CAAC;CAmK/D"}
|
package/dist/pi/piHarness.js
CHANGED
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import { mkdir } from "node:fs/promises";
|
|
2
2
|
import path from "node:path";
|
|
3
|
-
import { AuthStorage, createAgentSession, SessionManager, SettingsManager } from "@earendil-works/pi-coding-agent";
|
|
3
|
+
import { AuthStorage, createBashTool, createAgentSession, SessionManager, SettingsManager } from "@earendil-works/pi-coding-agent";
|
|
4
4
|
import { createMemoryRuntime } from "@noopolis/mneme";
|
|
5
5
|
import { resolvePiHarnessModel } from "./modelConfig.js";
|
|
6
6
|
import { createPiModelRegistry } from "./modelRegistry.js";
|
|
7
7
|
import { createPiMemoryTools, piMemoryToolNames } from "./memoryTools.js";
|
|
8
8
|
import { createResourceLoader } from "./prompts.js";
|
|
9
9
|
import { PiAgentHandle } from "./piAgentHandle.js";
|
|
10
|
+
import { DAIMON_WAKE_ID_ENV } from "./cliEnvironment.js";
|
|
10
11
|
import { createPiWorldTools, piWorldToolNames } from "./worldTools.js";
|
|
12
|
+
import { ensureRuntimeHome, ensureRuntimeHomeDirectory } from "../runtime/runtimeHomeLayout.js";
|
|
11
13
|
import { bindPiRawTrainingCapture, validatePiRawTrainingCaptureOptions } from "./rawTrainingCapture.js";
|
|
12
14
|
export class PiHarnessAdapter {
|
|
13
15
|
options;
|
|
@@ -22,10 +24,12 @@ export class PiHarnessAdapter {
|
|
|
22
24
|
}
|
|
23
25
|
async startAgent(input) {
|
|
24
26
|
validatePiRawTrainingCaptureOptions(this.options.rawTrainingCapture);
|
|
25
|
-
await
|
|
27
|
+
await ensureRuntimeHome(input.runtimeHomePath);
|
|
28
|
+
await Promise.all([".config", ".local/share", ".local/state", ".cache", ".tmp", "tool-state"]
|
|
29
|
+
.map((relative) => ensureRuntimeHomeDirectory(input.runtimeHomePath, relative)));
|
|
26
30
|
await mkdir(input.workspacePath, { recursive: true });
|
|
27
31
|
const memoryRuntimeHomePath = this.options.memory?.runtimeHomePath ?? input.runtimeHomePath;
|
|
28
|
-
await
|
|
32
|
+
await ensureRuntimeHome(memoryRuntimeHomePath);
|
|
29
33
|
const modelSpec = this.options.model ?? {
|
|
30
34
|
auth: { method: "codex" },
|
|
31
35
|
provider: "openai",
|
|
@@ -49,6 +53,11 @@ export class PiHarnessAdapter {
|
|
|
49
53
|
const memoryToolContext = memory === undefined ? undefined : {};
|
|
50
54
|
const worldToolContext = this.options.world === undefined ? undefined : {};
|
|
51
55
|
const rawTrainingCaptureRef = this.options.rawTrainingCapture === undefined ? undefined : {};
|
|
56
|
+
const wakeEnvironmentContext = this.options.wakeEnvironmentContext ?? {};
|
|
57
|
+
// Fixed for the life of this agent, not per wake: whether it can publish
|
|
58
|
+
// through `moltnet_send` at all. Gates the terminal-text fallback in
|
|
59
|
+
// `PiAgentHandle.runWake` (see `PiWakeEnvironmentContextRef.hasSendCapability`).
|
|
60
|
+
wakeEnvironmentContext.hasSendCapability = (this.options.productionTools ?? []).some((tool) => tool.name === "moltnet_send");
|
|
52
61
|
const sessionInput = (mode, sessionDirectory) => {
|
|
53
62
|
const memoryTools = memory === undefined || memoryToolContext === undefined
|
|
54
63
|
? []
|
|
@@ -64,14 +73,26 @@ export class PiHarnessAdapter {
|
|
|
64
73
|
world: this.options.world,
|
|
65
74
|
contextRef: worldToolContext
|
|
66
75
|
});
|
|
76
|
+
// Every child tool inherits the same denylist: host control values,
|
|
77
|
+
// Daimon-held world/model secrets, and caller-protected names.
|
|
78
|
+
const protectedNames = [...new Set([
|
|
79
|
+
...(this.options.protectedEnvironmentNames ?? []),
|
|
80
|
+
...(this.options.world === undefined ? [] : [this.options.world.tokenEnv])
|
|
81
|
+
])];
|
|
82
|
+
const requestedTools = this.options.toolNames ?? input.tools;
|
|
83
|
+
const protectedBash = protectedNames.length === 0 || requestedTools?.includes("bash") === false
|
|
84
|
+
? []
|
|
85
|
+
: [createProtectedBashTool(input.workspacePath, input.runtimeHomePath, protectedNames, wakeEnvironmentContext)];
|
|
67
86
|
const toolNames = [
|
|
68
|
-
...(
|
|
87
|
+
...(requestedTools ?? ["read", "write", "edit", "bash", "grep", "find", "ls"]),
|
|
69
88
|
...piMemoryToolNames(memoryTools),
|
|
70
|
-
...(worldTools === undefined ? [] : piWorldToolNames(worldTools))
|
|
89
|
+
...(worldTools === undefined ? [] : piWorldToolNames(worldTools)),
|
|
90
|
+
...(this.options.productionTools ?? []).map((tool) => tool.name)
|
|
71
91
|
];
|
|
72
92
|
return {
|
|
73
93
|
cwd: input.workspacePath,
|
|
74
94
|
agentDir: input.runtimeHomePath,
|
|
95
|
+
runtimeHomePath: input.runtimeHomePath,
|
|
75
96
|
daimonSecretEnvironmentNames: this.options.world === undefined ? [] : [this.options.world.tokenEnv],
|
|
76
97
|
authStorage: this.authStorage,
|
|
77
98
|
modelRegistry: this.modelRegistry,
|
|
@@ -82,7 +103,9 @@ export class PiHarnessAdapter {
|
|
|
82
103
|
world: worldTools !== undefined
|
|
83
104
|
}),
|
|
84
105
|
tools: [...new Set(toolNames)],
|
|
85
|
-
customTools: worldTools === undefined
|
|
106
|
+
customTools: worldTools === undefined
|
|
107
|
+
? [...protectedBash, ...memoryTools, ...(this.options.productionTools ?? [])]
|
|
108
|
+
: [...protectedBash, ...memoryTools, ...worldTools, ...(this.options.productionTools ?? [])],
|
|
86
109
|
sessionManager: SessionManager.create(input.workspacePath, sessionDirectory),
|
|
87
110
|
settingsManager: SettingsManager.inMemory({
|
|
88
111
|
compaction: { enabled: false },
|
|
@@ -105,7 +128,7 @@ export class PiHarnessAdapter {
|
|
|
105
128
|
provider: resolvedModel.provider
|
|
106
129
|
}, memory, memoryToolContext, {}, worldToolContext, rawTrainingCaptureRef, this.options.rawTrainingCapture, worldToolContext === undefined
|
|
107
130
|
? undefined
|
|
108
|
-
: { instructions: input.instructions, thinkingLevel: this.options.thinkingLevel ?? "off" }, session);
|
|
131
|
+
: { instructions: input.instructions, thinkingLevel: this.options.thinkingLevel ?? "off" }, session, wakeEnvironmentContext);
|
|
109
132
|
}
|
|
110
133
|
const createSession = async (mode, sessionDirectory) => {
|
|
111
134
|
const { session } = await (this.options.sessionFactory ?? createAgentSession)(sessionInput(mode, sessionDirectory));
|
|
@@ -121,6 +144,36 @@ export class PiHarnessAdapter {
|
|
|
121
144
|
: {
|
|
122
145
|
instructions: input.instructions,
|
|
123
146
|
thinkingLevel: this.options.thinkingLevel ?? "off"
|
|
124
|
-
}, undefined);
|
|
147
|
+
}, undefined, wakeEnvironmentContext);
|
|
125
148
|
}
|
|
126
149
|
}
|
|
150
|
+
function createProtectedBashTool(workspacePath, runtimeHomePath, protectedNames, wakeEnvironmentContext) {
|
|
151
|
+
const bash = createBashTool(workspacePath, {
|
|
152
|
+
spawnHook: (context) => ({
|
|
153
|
+
...context,
|
|
154
|
+
env: {
|
|
155
|
+
...Object.fromEntries(Object.entries(context.env).filter(([name]) => !protectedNames.includes(name))),
|
|
156
|
+
HOME: runtimeHomePath,
|
|
157
|
+
XDG_CONFIG_HOME: `${runtimeHomePath}/.config`,
|
|
158
|
+
XDG_DATA_HOME: `${runtimeHomePath}/.local/share`,
|
|
159
|
+
XDG_STATE_HOME: `${runtimeHomePath}/.local/state`,
|
|
160
|
+
XDG_CACHE_HOME: `${runtimeHomePath}/.cache`,
|
|
161
|
+
TMPDIR: `${runtimeHomePath}/.tmp`,
|
|
162
|
+
...(wakeEnvironmentContext.current === undefined
|
|
163
|
+
? {}
|
|
164
|
+
: { [DAIMON_WAKE_ID_ENV]: wakeEnvironmentContext.current })
|
|
165
|
+
}
|
|
166
|
+
})
|
|
167
|
+
});
|
|
168
|
+
return {
|
|
169
|
+
name: bash.name,
|
|
170
|
+
label: bash.label,
|
|
171
|
+
description: bash.description,
|
|
172
|
+
parameters: bash.parameters,
|
|
173
|
+
...(bash.prepareArguments === undefined ? {} : { prepareArguments: bash.prepareArguments }),
|
|
174
|
+
...(bash.executionMode === undefined ? {} : { executionMode: bash.executionMode }),
|
|
175
|
+
async execute(toolCallId, params, signal, onUpdate) {
|
|
176
|
+
return bash.execute(toolCallId, params, signal, onUpdate);
|
|
177
|
+
}
|
|
178
|
+
};
|
|
179
|
+
}
|
package/dist/pi/prompts.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import { type ResourceLoader } from "@earendil-works/pi-coding-agent";
|
|
|
2
2
|
import { type MemoryWakeMode } from "@noopolis/mneme";
|
|
3
3
|
import type { AgentStartInput, WakeEvent } from "../core/types.js";
|
|
4
4
|
export declare const formatWakePrompt: (event: WakeEvent) => string;
|
|
5
|
+
export declare const preserveModelFacingWakeIdentity: (promptText: string, event: WakeEvent, memoryEventId: string) => string;
|
|
5
6
|
export declare const createResourceLoader: (input: AgentStartInput, mode: MemoryWakeMode, capabilities: Readonly<{
|
|
6
7
|
memory: boolean;
|
|
7
8
|
world: boolean;
|
package/dist/pi/prompts.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../../src/pi/prompts.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,cAAc,EACpB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAEL,KAAK,cAAc,EACpB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,KAAK,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAEnE,eAAO,MAAM,gBAAgB,GAAI,OAAO,SAAS,KAAG,MAKtC,CAAC;
|
|
1
|
+
{"version":3,"file":"prompts.d.ts","sourceRoot":"","sources":["../../src/pi/prompts.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,cAAc,EACpB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAEL,KAAK,cAAc,EACpB,MAAM,iBAAiB,CAAC;AAEzB,OAAO,KAAK,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAEnE,eAAO,MAAM,gBAAgB,GAAI,OAAO,SAAS,KAAG,MAKtC,CAAC;AAYf,eAAO,MAAM,+BAA+B,GAC1C,YAAY,MAAM,EAClB,OAAO,SAAS,EAChB,eAAe,MAAM,KACpB,MAiBF,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAC/B,OAAO,eAAe,EACtB,MAAM,cAAc,EACpB,cAAc,QAAQ,CAAC;IAAE,MAAM,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAAC,KAC1D,cA+BF,CAAC"}
|
package/dist/pi/prompts.js
CHANGED
|
@@ -6,6 +6,30 @@ export const formatWakePrompt = (event) => `Wake event:
|
|
|
6
6
|
- from: ${event.from === undefined ? "[no attribution supplied] (absence)" : JSON.stringify(event.from)}
|
|
7
7
|
|
|
8
8
|
${event.text}`;
|
|
9
|
+
const WAKE_HEADER_PATTERN = /(^|\r?\n)## Wake\r?\nid: ([^\r\n]*)(?=\r?\n|$)/u;
|
|
10
|
+
const formatAuthoritativeWakeIdentity = (event) => [
|
|
11
|
+
"Wake identity:",
|
|
12
|
+
"Use this exact wake id as the delivery id/event key when a tool asks for event_key.",
|
|
13
|
+
`- id: ${event.id}`,
|
|
14
|
+
`- kind: ${event.kind}`,
|
|
15
|
+
`- from: ${event.from === undefined ? "[no attribution supplied] (absence)" : JSON.stringify(event.from)}`
|
|
16
|
+
].join("\n");
|
|
17
|
+
export const preserveModelFacingWakeIdentity = (promptText, event, memoryEventId) => {
|
|
18
|
+
if (event.id === memoryEventId)
|
|
19
|
+
return promptText;
|
|
20
|
+
const match = WAKE_HEADER_PATTERN.exec(promptText);
|
|
21
|
+
if (match === null) {
|
|
22
|
+
return `${formatAuthoritativeWakeIdentity(event)}\n\n${promptText}`;
|
|
23
|
+
}
|
|
24
|
+
const currentId = match[2];
|
|
25
|
+
if (currentId === event.id)
|
|
26
|
+
return promptText;
|
|
27
|
+
if (currentId !== memoryEventId) {
|
|
28
|
+
throw new Error("memory-prepared wake prompt carried an unexpected wake id");
|
|
29
|
+
}
|
|
30
|
+
const idStart = match.index + match[0].length - currentId.length;
|
|
31
|
+
return `${promptText.slice(0, idStart)}${event.id}${promptText.slice(idStart + currentId.length)}`;
|
|
32
|
+
};
|
|
9
33
|
export const createResourceLoader = (input, mode, capabilities) => {
|
|
10
34
|
const systemPrompt = [
|
|
11
35
|
`You are ${input.name} (${input.id}).`,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"turnTrace.d.ts","sourceRoot":"","sources":["../../src/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AC,EAAE,OAAO,CAAC;CAC7B;AAED,MAAM,WAAW,uBAAwB,SAAQ,IAAI,CAAC,2BAA2B,EAAE,aAAa,GAAG,SAAS,CAAC;IAC3G,eAAe,EAAE,MAAM,CAAC;IACxB,OAAO,CAAC,EAAE,2BAA2B,CAAC,SAAS,CAAC,CAAC;CAClD;AAED,eAAO,MAAM,eAAe,GAAI,OAAO,OAAO,KAAG,MAIhD,CAAC;AAIF,eAAO,MAAM,eAAe,GAAI,QAAQ,MAAM,KAAG,iBAAiB,CAAC,QAAQ,CAOzE,CAAC;AA+BH,eAAO,MAAM,qBAAqB,GAAI,OAAO,OAAO,KAAG,oBAAoB,GAAG,SAsB7E,CAAC;AAEF,eAAO,MAAM,mBAAmB,GAAI,OAAO,MAAM,KAAG,MAGnD,CAAC;AAEF,eAAO,MAAM,sBAAsB,GAAI,OAAO,2BAA2B,KAAG,iBAuD1E,CAAC;AAEH,eAAO,MAAM,oBAAoB,GAC/B,iBAAiB,MAAM,EACvB,QAAQ,iBAAiB,KACxB,OAAO,CAAC,IAAI,CAMd,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAU,OAAO,uBAAuB,KAAG,OAAO,CAAC,IAAI,CAWrF,CAAC"}
|
package/dist/pi/turnTrace.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import { createHash } from "node:crypto";
|
|
2
|
-
import { appendFile,
|
|
2
|
+
import { appendFile, writeFile } from "node:fs/promises";
|
|
3
3
|
import path from "node:path";
|
|
4
|
+
import { redactCredentialText } from "../core/credentialRedaction.js";
|
|
5
|
+
import { ensureRuntimeHomeDirectory } from "../runtime/runtimeHomeLayout.js";
|
|
4
6
|
export const redactTraceText = (value) => {
|
|
5
|
-
let redacted =
|
|
6
|
-
redacted = redacted.replace(/\bBearer\s+[A-Za-z0-9._~+/=-]{12,}/giu, "Bearer [REDACTED]");
|
|
7
|
-
redacted = redacted.replace(/\bmagt_v1_[A-Za-z0-9_-]{16,}\b/gu, "[REDACTED]");
|
|
8
|
-
redacted = redacted.replace(/\b(?:sk|sk-proj)-[A-Za-z0-9_-]{20,}\b/gu, "[REDACTED]");
|
|
9
|
-
redacted = redacted.replace(/("([^"]*(?:api[_-]?key|token|secret|password)[^"]*)"\s*:\s*")([^"]+)(")/giu, "$1[REDACTED]$4");
|
|
7
|
+
let redacted = redactCredentialText(value, [], 4_096);
|
|
10
8
|
redacted = redacted.replace(/\/(?:Users|home|private|tmp|var|opt|run)\/[^\s"']+/gu, "[path]");
|
|
11
9
|
return redacted.length > 1000 ? `${redacted.slice(0, 1000)}...` : redacted;
|
|
12
10
|
};
|
|
@@ -121,8 +119,7 @@ export const buildPiTurnTraceRecord = (input) => ({
|
|
|
121
119
|
});
|
|
122
120
|
export const writeTurnTraceRecord = async (runtimeHomePath, record) => {
|
|
123
121
|
const telemetryPath = path.join(runtimeHomePath, "telemetry");
|
|
124
|
-
const turnsPath =
|
|
125
|
-
await mkdir(turnsPath, { recursive: true });
|
|
122
|
+
const turnsPath = await ensureRuntimeHomeDirectory(runtimeHomePath, "telemetry/turns");
|
|
126
123
|
const body = `${JSON.stringify(record, null, 2)}\n`;
|
|
127
124
|
await writeFile(path.join(turnsPath, `${sanitizeTraceFileId(record.turn_id)}.json`), body, "utf8");
|
|
128
125
|
await appendFile(path.join(telemetryPath, "turns.ndjson"), `${JSON.stringify(record)}\n`, "utf8");
|
|
@@ -5,7 +5,7 @@ export declare const WORLD_TRAJECTORY_SCHEMA: "daimon.world_trajectory.v1";
|
|
|
5
5
|
* Pi's SessionManager remains the private raw session recorder. This module
|
|
6
6
|
* derives a minimized public/evaluation projection from the same subscribed
|
|
7
7
|
* session events. Raw training capture is deliberately separate; see
|
|
8
|
-
* docs/
|
|
8
|
+
* docs/observability.md.
|
|
9
9
|
*/
|
|
10
10
|
export interface PiWorldTrajectoryToolCall {
|
|
11
11
|
arguments?: unknown;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worldTrajectory.d.ts","sourceRoot":"","sources":["../../src/pi/worldTrajectory.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"worldTrajectory.d.ts","sourceRoot":"","sources":["../../src/pi/worldTrajectory.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAEvD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAG1D,eAAO,MAAM,uBAAuB,EAAG,4BAAqC,CAAC;AAE7E;;;;;GAKG;AAEH,MAAM,WAAW,yBAAyB;IACxC,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,MAAM,EAAE,SAAS,GAAG,WAAW,GAAG,QAAQ,CAAC;IAC3C,YAAY,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,KAAK,EAAE,yBAAyB,EAAE,CAAC;IAC5C,QAAQ,CAAC,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CACtC;AAED,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;CAChC;AAED,MAAM,WAAW,6BAA6B;IAC5C,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,wBAAwB,CAAC;IAClC,WAAW,EAAE,IAAI,CAAC;IAClB,OAAO,EAAE,kBAAkB,CAAC;IAC5B,YAAY,EAAE,MAAM,CAAC;IACrB,KAAK,EAAE,gBAAgB,CAAC;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,MAAM,CAAC;IACxB,SAAS,EAAE,IAAI,CAAC;IAChB,MAAM,EAAE,WAAW,GAAG,QAAQ,CAAC;IAC/B,aAAa,EAAE,MAAM,CAAC;IACtB,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;CAChB;AAaD;;;GAGG;AACH,eAAO,MAAM,0BAA0B,GACrC,OAAO,OAAO,EACd,cAAS,KACR,OAsBF,CAAC;AAKF,eAAO,MAAM,8BAA8B,QAAO,wBAGhD,CAAC;AAEH,eAAO,MAAM,6BAA6B,GACxC,SAAS,wBAAwB,EACjC,OAAO,OAAO,EACd,UAAgB,KACf,IAqCF,CAAC;AAKF,eAAO,MAAM,wBAAwB,GACnC,OAAO,6BAA6B,KACnC,OAAO,CAAC,IAAI,CAiDd,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { createHash } from "node:crypto";
|
|
2
|
-
import { appendFile,
|
|
2
|
+
import { appendFile, writeFile } from "node:fs/promises";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import { redactTraceText, sanitizeTraceFileId } from "./turnTrace.js";
|
|
5
|
+
import { ensureRuntimeHomeDirectory } from "../runtime/runtimeHomeLayout.js";
|
|
5
6
|
export const WORLD_TRAJECTORY_SCHEMA = "daimon.world_trajectory.v1";
|
|
6
7
|
const asObject = (value) => typeof value === "object" && value !== null && !Array.isArray(value)
|
|
7
8
|
? value
|
|
@@ -123,8 +124,7 @@ export const persistPiWorldTrajectory = async (input) => {
|
|
|
123
124
|
}
|
|
124
125
|
};
|
|
125
126
|
const telemetryPath = path.join(input.runtimeHomePath, "telemetry");
|
|
126
|
-
const trajectoriesPath =
|
|
127
|
-
await mkdir(trajectoriesPath, { recursive: true });
|
|
127
|
+
const trajectoriesPath = await ensureRuntimeHomeDirectory(input.runtimeHomePath, "telemetry/world-trajectories");
|
|
128
128
|
const bytes = `${JSON.stringify(record, null, 2)}\n`;
|
|
129
129
|
await writeFile(path.join(trajectoriesPath, `${sanitizeTraceFileId(input.turnId)}.json`), bytes, { encoding: "utf8", mode: 0o600 });
|
|
130
130
|
await appendFile(path.join(telemetryPath, "world-trajectories.ndjson"), `${JSON.stringify(record)}\n`, { encoding: "utf8", mode: 0o600 });
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type AgySubscriptionRealm } from "./agySubscriptionRealm.js";
|
|
2
|
+
import type { OrganizationRuntimeConfig } from "./organizationRuntime.js";
|
|
3
|
+
export type AgyBootstrapInvocation = Readonly<{
|
|
4
|
+
args: readonly string[];
|
|
5
|
+
command: string;
|
|
6
|
+
cwd: string;
|
|
7
|
+
env: NodeJS.ProcessEnv;
|
|
8
|
+
}>;
|
|
9
|
+
export declare const createAgyBootstrapInvocation: (input: {
|
|
10
|
+
busAddress: string;
|
|
11
|
+
executablePath: string;
|
|
12
|
+
runtimeHomePath: string;
|
|
13
|
+
workspacePath: string;
|
|
14
|
+
}) => AgyBootstrapInvocation;
|
|
15
|
+
export declare function runAgySubscriptionBootstrap(config: OrganizationRuntimeConfig, startRealm?: () => Promise<AgySubscriptionRealm>): Promise<void>;
|
|
16
|
+
//# sourceMappingURL=agySubscriptionBootstrap.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agySubscriptionBootstrap.d.ts","sourceRoot":"","sources":["../../src/runtime/agySubscriptionBootstrap.ts"],"names":[],"mappings":"AAGA,OAAO,EAA6B,KAAK,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAEjG,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,0BAA0B,CAAC;AAG1E,MAAM,MAAM,sBAAsB,GAAG,QAAQ,CAAC;IAC5C,IAAI,EAAE,SAAS,MAAM,EAAE,CAAC;IACxB,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC,UAAU,CAAC;CACxB,CAAC,CAAC;AAEH,eAAO,MAAM,4BAA4B,GAAI,OAAO;IAClD,UAAU,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,eAAe,EAAE,MAAM,CAAC;IACxB,aAAa,EAAE,MAAM,CAAC;CACvB,KAAG,sBAaF,CAAC;AAEH,wBAAsB,2BAA2B,CAC/C,MAAM,EAAE,yBAAyB,EACjC,UAAU,GAAE,MAAM,OAAO,CAAC,oBAAoB,CAA6B,GAC1E,OAAO,CAAC,IAAI,CAAC,CA2Cf"}
|