@systemfsoftware/agent 0.0.0-bootstrap.0 → 0.1.0-beta.192
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 +21 -0
- package/dist/ActivityStore-CEy3oY41.mjs +90 -0
- package/dist/ActivityStore-CEy3oY41.mjs.map +1 -0
- package/dist/ActivityStore-CPXWRHGz.d.mts +91 -0
- package/dist/Admin-BcQDrWKY.mjs +329 -0
- package/dist/Admin-BcQDrWKY.mjs.map +1 -0
- package/dist/Admin-BfolLkHj.d.mts +5678 -0
- package/dist/Agent-Bn3zMhDH.mjs +60 -0
- package/dist/Agent-Bn3zMhDH.mjs.map +1 -0
- package/dist/Agent-DSVEpq4e.d.mts +219 -0
- package/dist/AgentError-RkUaetX8.d.mts +128 -0
- package/dist/AgentError-yFdnS9bl.mjs +141 -0
- package/dist/AgentError-yFdnS9bl.mjs.map +1 -0
- package/dist/AgentPolicy-CI7LRBQa.mjs +116 -0
- package/dist/AgentPolicy-CI7LRBQa.mjs.map +1 -0
- package/dist/AgentPolicy-D-GmZQex.d.mts +128 -0
- package/dist/AgentRegistration-Dg53p6du.mjs +14 -0
- package/dist/AgentRegistration-Dg53p6du.mjs.map +1 -0
- package/dist/AgentRuntime-CoGy_5dm.d.mts +751 -0
- package/dist/AgentRuntime-CzP4I4RB.mjs +5249 -0
- package/dist/AgentRuntime-CzP4I4RB.mjs.map +1 -0
- package/dist/AgentUpdates-7xT0It_R.d.mts +54 -0
- package/dist/AgentUpdates-BS_6gR5K.mjs +66 -0
- package/dist/AgentUpdates-BS_6gR5K.mjs.map +1 -0
- package/dist/BrowserUse-C9vict2M.d.mts +196 -0
- package/dist/BrowserUse-DjEyFDLZ.mjs +156 -0
- package/dist/BrowserUse-DjEyFDLZ.mjs.map +1 -0
- package/dist/Budget-CXh_ChFJ.d.mts +112 -0
- package/dist/Budget-j1UkthgY.mjs +351 -0
- package/dist/Budget-j1UkthgY.mjs.map +1 -0
- package/dist/CodeExecutor-B_Vt1Ghy.mjs +281 -0
- package/dist/CodeExecutor-B_Vt1Ghy.mjs.map +1 -0
- package/dist/CodeExecutor-D5-Rda75.d.mts +198 -0
- package/dist/CodeMode-B7JvfKAD.d.mts +159 -0
- package/dist/CodeMode-BI7WhUkr.mjs +555 -0
- package/dist/CodeMode-BI7WhUkr.mjs.map +1 -0
- package/dist/CommittedActivity-DXyCKCtX.mjs +146 -0
- package/dist/CommittedActivity-DXyCKCtX.mjs.map +1 -0
- package/dist/CommittedActivity-LWOKXqdi.d.mts +62 -0
- package/dist/Compaction-C0hWAmOG.mjs +15 -0
- package/dist/Compaction-C0hWAmOG.mjs.map +1 -0
- package/dist/Compaction-e5cNeFmY.d.mts +5 -0
- package/dist/ContextCompactor-Chm9BLrD.d.mts +165 -0
- package/dist/ContextCompactor-DV4NOQvg.mjs +134 -0
- package/dist/ContextCompactor-DV4NOQvg.mjs.map +1 -0
- package/dist/ContextHistory-C80rW5M7.mjs +76 -0
- package/dist/ContextHistory-C80rW5M7.mjs.map +1 -0
- package/dist/ContextHistory-akQ1Td7a.d.mts +65 -0
- package/dist/ContextTools-917r7gpv.d.mts +186 -0
- package/dist/ContextTools-p8JDPo-W.mjs +88 -0
- package/dist/ContextTools-p8JDPo-W.mjs.map +1 -0
- package/dist/ContextWindow-BJZI4MMt.d.mts +61 -0
- package/dist/ContextWindow-kbFcs1IF.mjs +63 -0
- package/dist/ContextWindow-kbFcs1IF.mjs.map +1 -0
- package/dist/Digest-BDToAbaX.d.mts +25 -0
- package/dist/Digest-CU6IWj-2.mjs +106 -0
- package/dist/Digest-CU6IWj-2.mjs.map +1 -0
- package/dist/DurableAgentRuntime-BHXo8GPJ.mjs +8432 -0
- package/dist/DurableAgentRuntime-BHXo8GPJ.mjs.map +1 -0
- package/dist/DurableFailpoint-BD5nowNl.mjs +98 -0
- package/dist/DurableFailpoint-BD5nowNl.mjs.map +1 -0
- package/dist/DurableFailpoint-Cqi5tyof.d.mts +42 -0
- package/dist/DurableStep-CzVIho7y.mjs +54 -0
- package/dist/DurableStep-CzVIho7y.mjs.map +1 -0
- package/dist/DurableStep-cI_Ho_rU.d.mts +109 -0
- package/dist/EventSource-BwZVkEQi.mjs +66 -0
- package/dist/EventSource-BwZVkEQi.mjs.map +1 -0
- package/dist/EventSource-C0TCBeIf.d.mts +52 -0
- package/dist/FailureDiagnostic-DdHV2eFs.mjs +304 -0
- package/dist/FailureDiagnostic-DdHV2eFs.mjs.map +1 -0
- package/dist/FailureDiagnostic-DpzYNI8f.d.mts +232 -0
- package/dist/IdGenerator-BCzwV0ZI.mjs +29 -0
- package/dist/IdGenerator-BCzwV0ZI.mjs.map +1 -0
- package/dist/IdGenerator-BY8NH74o.d.mts +26 -0
- package/dist/Identifiers-LWd4837I.mjs +41 -0
- package/dist/Identifiers-LWd4837I.mjs.map +1 -0
- package/dist/Identifiers-qafW4EP0.d.mts +38 -0
- package/dist/InMemory-BrTm6XEO.mjs +57 -0
- package/dist/InMemory-BrTm6XEO.mjs.map +1 -0
- package/dist/InMemory-C3qXFT5k.d.mts +46 -0
- package/dist/InMemory.d.mts +2 -0
- package/dist/InMemory.mjs +1 -0
- package/dist/InteractiveBrowser-B-hlNJy5.mjs +237 -0
- package/dist/InteractiveBrowser-B-hlNJy5.mjs.map +1 -0
- package/dist/InteractiveBrowser-nnML0r7w.d.mts +258 -0
- package/dist/LifecyclePublication-BDc_ug5v.mjs +204 -0
- package/dist/LifecyclePublication-BDc_ug5v.mjs.map +1 -0
- package/dist/Memory-CT5bDZqi.d.mts +57 -0
- package/dist/Memory-Dl9ecPpm.mjs +204 -0
- package/dist/Memory-Dl9ecPpm.mjs.map +1 -0
- package/dist/MemoryNamespace-BtnlH_E6.d.mts +35 -0
- package/dist/MemoryNamespace-DZSpjLj9.mjs +116 -0
- package/dist/MemoryNamespace-DZSpjLj9.mjs.map +1 -0
- package/dist/MemoryNotes-4CRzkPBD.d.mts +425 -0
- package/dist/MemoryNotes-i41TsH11.mjs +132 -0
- package/dist/MemoryNotes-i41TsH11.mjs.map +1 -0
- package/dist/MemoryReference-Dd3KSMa7.d.mts +77 -0
- package/dist/MemoryReference-RFU0HQJG.mjs +108 -0
- package/dist/MemoryReference-RFU0HQJG.mjs.map +1 -0
- package/dist/MemoryRevalidation--aAh_Pfq.mjs +136 -0
- package/dist/MemoryRevalidation--aAh_Pfq.mjs.map +1 -0
- package/dist/MemoryRevalidation-FsJ8E61W.d.mts +64 -0
- package/dist/MemoryStore-Bg5RunTk.d.mts +187 -0
- package/dist/MemoryStore-E0J99hb2.mjs +245 -0
- package/dist/MemoryStore-E0J99hb2.mjs.map +1 -0
- package/dist/MessageDelivery-BE2Yf3FC.mjs +615 -0
- package/dist/MessageDelivery-BE2Yf3FC.mjs.map +1 -0
- package/dist/MessageDelivery-Dh6GZBt_.d.mts +1129 -0
- package/dist/Messaging-BqWHYf93.d.mts +216 -0
- package/dist/Messaging-DgSiv4f4.mjs +154 -0
- package/dist/Messaging-DgSiv4f4.mjs.map +1 -0
- package/dist/Messaging-DhM-APnP.d.mts +1074 -0
- package/dist/MessagingHost-Bm5e-kAX.mjs +117 -0
- package/dist/MessagingHost-Bm5e-kAX.mjs.map +1 -0
- package/dist/MessagingHost-CubWeYKN.d.mts +80 -0
- package/dist/OperationAuthorizer-VSiHCC2S.mjs +72 -0
- package/dist/OperationAuthorizer-VSiHCC2S.mjs.map +1 -0
- package/dist/OperationAuthorizer-y-F-Ox_Q.d.mts +62 -0
- package/dist/Output-DQ8mWcgf.mjs +7 -0
- package/dist/Output-DQ8mWcgf.mjs.map +1 -0
- package/dist/Output-SbOdlBFL.d.mts +22 -0
- package/dist/PageCapture-BfRURUOA.mjs +275 -0
- package/dist/PageCapture-BfRURUOA.mjs.map +1 -0
- package/dist/PageCapture-C_mE72Sd.d.mts +216 -0
- package/dist/PageScreenshot-BJTASs4o.mjs +53 -0
- package/dist/PageScreenshot-BJTASs4o.mjs.map +1 -0
- package/dist/PageScreenshot-CaoaH7mc.d.mts +48 -0
- package/dist/PersistentHistory-BrtZ0g2j.d.mts +14 -0
- package/dist/PersistentHistory-CTAVhHKH.mjs +147 -0
- package/dist/PersistentHistory-CTAVhHKH.mjs.map +1 -0
- package/dist/PreparedInputAdmission-Ci18uY4s.d.mts +973 -0
- package/dist/PreparedInputAdmission-adqVJJa6.mjs +95 -0
- package/dist/PreparedInputAdmission-adqVJJa6.mjs.map +1 -0
- package/dist/ProvisionalText-BcKpPYKQ.d.mts +70 -0
- package/dist/ProvisionalText-DXddTK4c.mjs +47 -0
- package/dist/ProvisionalText-DXddTK4c.mjs.map +1 -0
- package/dist/Receipt-B-FlCaNH.mjs +35 -0
- package/dist/Receipt-B-FlCaNH.mjs.map +1 -0
- package/dist/Receipt-B4feBxMY.d.mts +31 -0
- package/dist/RecordFormat-DoNh-AFe.mjs +79 -0
- package/dist/RecordFormat-DoNh-AFe.mjs.map +1 -0
- package/dist/RecordFormat-ZMus8Dx8.d.mts +52 -0
- package/dist/Records-C645aQks.mjs +1145 -0
- package/dist/Records-C645aQks.mjs.map +1 -0
- package/dist/Records-C9I1nCL9.d.mts +1423 -0
- package/dist/Recovery-zWy_kmZq.mjs +736 -0
- package/dist/Recovery-zWy_kmZq.mjs.map +1 -0
- package/dist/Redaction-C0zLBAn6.d.mts +28 -0
- package/dist/Redaction-CtyCBMEj.mjs +116 -0
- package/dist/Redaction-CtyCBMEj.mjs.map +1 -0
- package/dist/RememberingStore-BO-OnCgP.mjs +23 -0
- package/dist/RememberingStore-BO-OnCgP.mjs.map +1 -0
- package/dist/RememberingStore-DgqXmILx.d.mts +14 -0
- package/dist/RunContinuation-BVAHoYlN.d.mts +127 -0
- package/dist/RunContinuation-Bpfp087i.mjs +1060 -0
- package/dist/RunContinuation-Bpfp087i.mjs.map +1 -0
- package/dist/RunEvent-CwgDzXcH.d.mts +465 -0
- package/dist/RunEvent-DJxENnJi.mjs +345 -0
- package/dist/RunEvent-DJxENnJi.mjs.map +1 -0
- package/dist/RunEventSink-B8uM8bw2.mjs +22 -0
- package/dist/RunEventSink-B8uM8bw2.mjs.map +1 -0
- package/dist/RunEventSink-f-T4jbNB.d.mts +105 -0
- package/dist/RunHooks-Bob22Bcj.d.mts +40 -0
- package/dist/RunHooks-DWuLBVdU.mjs +60 -0
- package/dist/RunHooks-DWuLBVdU.mjs.map +1 -0
- package/dist/RunJournal-C_1eqQdr.mjs +1107 -0
- package/dist/RunJournal-C_1eqQdr.mjs.map +1 -0
- package/dist/RunOptions-BVSa3BO2.d.mts +560 -0
- package/dist/RunOptions-COEUCrx4.mjs +61 -0
- package/dist/RunOptions-COEUCrx4.mjs.map +1 -0
- package/dist/RunPolicyUsage-B-JXRZYO.mjs +25 -0
- package/dist/RunPolicyUsage-B-JXRZYO.mjs.map +1 -0
- package/dist/RunPolicyUsage-jvJo0vJp.d.mts +21 -0
- package/dist/RunStorage-CsQQ0Y5u.mjs +304 -0
- package/dist/RunStorage-CsQQ0Y5u.mjs.map +1 -0
- package/dist/Sandbox-37vXP0BV.d.mts +24 -0
- package/dist/Sandbox-Bze6pHYc.mjs +30 -0
- package/dist/Sandbox-Bze6pHYc.mjs.map +1 -0
- package/dist/Schedule-BY0lzbij.mjs +336 -0
- package/dist/Schedule-BY0lzbij.mjs.map +1 -0
- package/dist/ScheduleTransition-CjVP48I8.d.mts +22 -0
- package/dist/ScheduleTransition-DtNzlN9k.mjs +180 -0
- package/dist/ScheduleTransition-DtNzlN9k.mjs.map +1 -0
- package/dist/Scheduling-BpJN9E1j.mjs +699 -0
- package/dist/Scheduling-BpJN9E1j.mjs.map +1 -0
- package/dist/Scheduling-DYTM29s9.d.mts +57 -0
- package/dist/SemanticMemory-BRV0cuWg.mjs +300 -0
- package/dist/SemanticMemory-BRV0cuWg.mjs.map +1 -0
- package/dist/SemanticMemory-rgWlhW87.d.mts +431 -0
- package/dist/SemanticMemoryIndex-D7yNEWpt.d.mts +826 -0
- package/dist/SemanticMemoryIndex-godQDjNx.mjs +186 -0
- package/dist/SemanticMemoryIndex-godQDjNx.mjs.map +1 -0
- package/dist/SemanticMemoryRevalidation-Bm3_pfsI.d.mts +44 -0
- package/dist/SemanticMemoryRevalidation-D8VV-eU6.mjs +179 -0
- package/dist/SemanticMemoryRevalidation-D8VV-eU6.mjs.map +1 -0
- package/dist/Subagent-CSIRUgUo.mjs +1315 -0
- package/dist/Subagent-CSIRUgUo.mjs.map +1 -0
- package/dist/Subagent-CXEI5YZ8.d.mts +2368 -0
- package/dist/SubagentContract-B7vQPueI.d.mts +176 -0
- package/dist/SubagentContract-C-7AxTm_.mjs +187 -0
- package/dist/SubagentContract-C-7AxTm_.mjs.map +1 -0
- package/dist/SubagentHost-BEnICu7g.mjs +70 -0
- package/dist/SubagentHost-BEnICu7g.mjs.map +1 -0
- package/dist/SubagentHost-CKhz1vbH.d.mts +167 -0
- package/dist/SubagentReservations-BYNAHPpm.mjs +465 -0
- package/dist/SubagentReservations-BYNAHPpm.mjs.map +1 -0
- package/dist/SubagentReservations-WrmIVzO5.d.mts +185 -0
- package/dist/SubmissionLedger-WG0beEyt.mjs +921 -0
- package/dist/SubmissionLedger-WG0beEyt.mjs.map +1 -0
- package/dist/SubmissionStatus-CPZsOM5a.mjs +17 -0
- package/dist/SubmissionStatus-CPZsOM5a.mjs.map +1 -0
- package/dist/Subscription-BhQbmUD-.mjs +340 -0
- package/dist/Subscription-BhQbmUD-.mjs.map +1 -0
- package/dist/Subscription-CC--_OnU.d.mts +815 -0
- package/dist/SubscriptionInput-BEeB0Cj8.d.mts +42 -0
- package/dist/SubscriptionInput-Xcd4JjEs.mjs +53 -0
- package/dist/SubscriptionInput-Xcd4JjEs.mjs.map +1 -0
- package/dist/SubscriptionTransition-CWt9UVH0.d.mts +23 -0
- package/dist/SubscriptionTransition-lrf733c8.mjs +154 -0
- package/dist/SubscriptionTransition-lrf733c8.mjs.map +1 -0
- package/dist/Subscriptions-4K_qu_2f.mjs +638 -0
- package/dist/Subscriptions-4K_qu_2f.mjs.map +1 -0
- package/dist/Subscriptions-BF3aSf8X.d.mts +75 -0
- package/dist/Thread-B8JApGHa.mjs +283 -0
- package/dist/Thread-B8JApGHa.mjs.map +1 -0
- package/dist/Thread-BnAtkJl4.d.mts +116 -0
- package/dist/ThreadArchiveRange-1PMdjpdJ.mjs +64 -0
- package/dist/ThreadArchiveRange-1PMdjpdJ.mjs.map +1 -0
- package/dist/ThreadContextHistory-BSStMOLX.mjs +211 -0
- package/dist/ThreadContextHistory-BSStMOLX.mjs.map +1 -0
- package/dist/ThreadContextHistory-lTZ8Ftq1.d.mts +33 -0
- package/dist/ThreadContextHistoryProjection-Cp7_RR6V.d.mts +59 -0
- package/dist/ThreadContextHistoryProjection-_8uNz-h1.mjs +149 -0
- package/dist/ThreadContextHistoryProjection-_8uNz-h1.mjs.map +1 -0
- package/dist/ThreadHistory-BkyGfv5E.d.mts +76 -0
- package/dist/ThreadHistory-Blt_W31N.mjs +69 -0
- package/dist/ThreadHistory-Blt_W31N.mjs.map +1 -0
- package/dist/ThreadImport-C8Tqiezd.mjs +491 -0
- package/dist/ThreadImport-C8Tqiezd.mjs.map +1 -0
- package/dist/ThreadImport-DaSmrlRi.d.mts +843 -0
- package/dist/ThreadInvariants-DyPhMeo-.d.mts +23 -0
- package/dist/ThreadInvariants-fniroLRY.mjs +154 -0
- package/dist/ThreadInvariants-fniroLRY.mjs.map +1 -0
- package/dist/ThreadProjectionMaintenance-D6fBjr1q.mjs +37 -0
- package/dist/ThreadProjectionMaintenance-D6fBjr1q.mjs.map +1 -0
- package/dist/ThreadProjectionMaintenance-DjUy7kCa.d.mts +51 -0
- package/dist/ThreadStore-BMUAp5Ta.mjs +937 -0
- package/dist/ThreadStore-BMUAp5Ta.mjs.map +1 -0
- package/dist/ThreadTransfer-B3NkyO_y.mjs +154 -0
- package/dist/ThreadTransfer-B3NkyO_y.mjs.map +1 -0
- package/dist/ThreadTransfer-BM02cbOo.d.mts +63 -0
- package/dist/ThreadWork-C-xa2Boi.mjs +484 -0
- package/dist/ThreadWork-C-xa2Boi.mjs.map +1 -0
- package/dist/ToolBroker-DkoVyx6T.mjs +42 -0
- package/dist/ToolBroker-DkoVyx6T.mjs.map +1 -0
- package/dist/ToolBroker-Dy2xM6ht.d.mts +134 -0
- package/dist/ToolDiscovery-DHySvLQd.mjs +211 -0
- package/dist/ToolDiscovery-DHySvLQd.mjs.map +1 -0
- package/dist/ToolDiscovery-VjamzX3q.d.mts +119 -0
- package/dist/ToolExposure-Cn7xETn5.d.mts +6 -0
- package/dist/ToolExposure-D7id9Gt5.d.mts +37 -0
- package/dist/ToolExposure-DCvQWFIa.mjs +9 -0
- package/dist/ToolExposure-DCvQWFIa.mjs.map +1 -0
- package/dist/ToolExposure-DNME8BkG.d.mts +44 -0
- package/dist/ToolExposure-DPnq8Won.mjs +30 -0
- package/dist/ToolExposure-DPnq8Won.mjs.map +1 -0
- package/dist/ToolExposure-DaGaF5tj.mjs +20 -0
- package/dist/ToolExposure-DaGaF5tj.mjs.map +1 -0
- package/dist/ToolExposure.d.mts +4 -0
- package/dist/ToolExposure.mjs +4 -0
- package/dist/ToolReconciler-6bb7xlip.d.mts +81 -0
- package/dist/ToolReconciler-DJQd3SZA.mjs +87 -0
- package/dist/ToolReconciler-DJQd3SZA.mjs.map +1 -0
- package/dist/ToolResult-By5KAje4.d.mts +79 -0
- package/dist/ToolResult-DwZxjlHw.mjs +160 -0
- package/dist/ToolResult-DwZxjlHw.mjs.map +1 -0
- package/dist/ToolResultStorage-BmoRewhh.mjs +46 -0
- package/dist/ToolResultStorage-BmoRewhh.mjs.map +1 -0
- package/dist/ToolResultStorage-Bp5fm0do.d.mts +49 -0
- package/dist/ToolResults-C4-HsMCp.d.mts +33 -0
- package/dist/ToolResults-nCgBlTp2.mjs +45 -0
- package/dist/ToolResults-nCgBlTp2.mjs.map +1 -0
- package/dist/Usage-B0xgME5f.mjs +340 -0
- package/dist/Usage-B0xgME5f.mjs.map +1 -0
- package/dist/Usage-Bc-jXe_9.d.mts +128 -0
- package/dist/WakeScheduler-DVYj66C-.mjs +74 -0
- package/dist/WakeScheduler-DVYj66C-.mjs.map +1 -0
- package/dist/WakeScheduler-SFqj67Sk.d.mts +74 -0
- package/dist/WebCapture-CA4ZarW2.mjs +64 -0
- package/dist/WebCapture-CA4ZarW2.mjs.map +1 -0
- package/dist/WebCapture-pzIeUJ5W.d.mts +49 -0
- package/dist/WebSearch-CD0V--qh.d.mts +18 -0
- package/dist/WebSearch-DnbOzRL_.mjs +30 -0
- package/dist/WebSearch-DnbOzRL_.mjs.map +1 -0
- package/dist/Worker-CQu8Qp1j.mjs +267 -0
- package/dist/Worker-CQu8Qp1j.mjs.map +1 -0
- package/dist/Worker-xxucY_0b.d.mts +468 -0
- package/dist/WorkerAdmission-BhFjx86s.mjs +162 -0
- package/dist/WorkerAdmission-BhFjx86s.mjs.map +1 -0
- package/dist/WorkerAdmission-BnRuXLWF.d.mts +171 -0
- package/dist/WorkerHost-DtYzi54D.d.mts +150 -0
- package/dist/WorkerHost-DuQug9Bq.mjs +73 -0
- package/dist/WorkerHost-DuQug9Bq.mjs.map +1 -0
- package/dist/agent-registration-CNs2twrr.mjs +262 -0
- package/dist/agent-registration-CNs2twrr.mjs.map +1 -0
- package/dist/capabilities/BrowserUse.d.mts +2 -0
- package/dist/capabilities/BrowserUse.mjs +1 -0
- package/dist/capabilities/Budget.d.mts +2 -0
- package/dist/capabilities/Budget.mjs +1 -0
- package/dist/capabilities/CodeMode.d.mts +2 -0
- package/dist/capabilities/CodeMode.mjs +1 -0
- package/dist/capabilities/ContextTools.d.mts +2 -0
- package/dist/capabilities/ContextTools.mjs +1 -0
- package/dist/capabilities/MemoryNotes.d.mts +2 -0
- package/dist/capabilities/MemoryNotes.mjs +1 -0
- package/dist/capabilities/Messaging.d.mts +3 -0
- package/dist/capabilities/Messaging.mjs +4 -0
- package/dist/capabilities/Redaction.d.mts +2 -0
- package/dist/capabilities/Redaction.mjs +1 -0
- package/dist/capabilities/RunHooks.d.mts +2 -0
- package/dist/capabilities/RunHooks.mjs +1 -0
- package/dist/capabilities/SemanticMemory.d.mts +2 -0
- package/dist/capabilities/SemanticMemory.mjs +1 -0
- package/dist/capabilities/Subagent.d.mts +4 -0
- package/dist/capabilities/Subagent.mjs +6 -0
- package/dist/capabilities/SubagentReservations.d.mts +2 -0
- package/dist/capabilities/SubagentReservations.mjs +1 -0
- package/dist/capabilities/ToolDiscovery.d.mts +2 -0
- package/dist/capabilities/ToolDiscovery.mjs +1 -0
- package/dist/capabilities/ToolResults.d.mts +2 -0
- package/dist/capabilities/ToolResults.mjs +1 -0
- package/dist/capabilities/WebCapture.d.mts +2 -0
- package/dist/capabilities/WebCapture.mjs +1 -0
- package/dist/capabilities/WebSearch.d.mts +2 -0
- package/dist/capabilities/WebSearch.mjs +1 -0
- package/dist/compaction-C3hXuO4Z.mjs +539 -0
- package/dist/compaction-C3hXuO4Z.mjs.map +1 -0
- package/dist/completion-B_WDnSg-.d.mts +11 -0
- package/dist/core/Agent.d.mts +2 -0
- package/dist/core/Agent.mjs +1 -0
- package/dist/core/AgentError.d.mts +2 -0
- package/dist/core/AgentError.mjs +1 -0
- package/dist/core/AgentPolicy.d.mts +2 -0
- package/dist/core/AgentPolicy.mjs +1 -0
- package/dist/core/AgentUpdates.d.mts +2 -0
- package/dist/core/AgentUpdates.mjs +1 -0
- package/dist/core/FailureDiagnostic.d.mts +2 -0
- package/dist/core/FailureDiagnostic.mjs +1 -0
- package/dist/core/IdGenerator.d.mts +2 -0
- package/dist/core/IdGenerator.mjs +1 -0
- package/dist/core/Identifiers.d.mts +2 -0
- package/dist/core/Identifiers.mjs +1 -0
- package/dist/core/Memory.d.mts +2 -0
- package/dist/core/Memory.mjs +1 -0
- package/dist/core/MemoryNamespace.d.mts +2 -0
- package/dist/core/MemoryNamespace.mjs +1 -0
- package/dist/core/MemoryReference.d.mts +2 -0
- package/dist/core/MemoryReference.mjs +1 -0
- package/dist/core/MemoryRevalidation.d.mts +2 -0
- package/dist/core/MemoryRevalidation.mjs +1 -0
- package/dist/core/MemoryStore.d.mts +2 -0
- package/dist/core/MemoryStore.mjs +1 -0
- package/dist/core/ProvisionalText.d.mts +2 -0
- package/dist/core/ProvisionalText.mjs +1 -0
- package/dist/core/Receipt.d.mts +2 -0
- package/dist/core/Receipt.mjs +1 -0
- package/dist/core/RememberingStore.d.mts +2 -0
- package/dist/core/RememberingStore.mjs +1 -0
- package/dist/core/RunEvent.d.mts +3 -0
- package/dist/core/RunEvent.mjs +1 -0
- package/dist/core/RunPolicyUsage.d.mts +2 -0
- package/dist/core/RunPolicyUsage.mjs +1 -0
- package/dist/core/SemanticMemoryIndex.d.mts +2 -0
- package/dist/core/SemanticMemoryIndex.mjs +1 -0
- package/dist/core/SemanticMemoryRevalidation.d.mts +2 -0
- package/dist/core/SemanticMemoryRevalidation.mjs +1 -0
- package/dist/core/SubagentContract.d.mts +2 -0
- package/dist/core/SubagentContract.mjs +1 -0
- package/dist/core/Thread.d.mts +2 -0
- package/dist/core/Thread.mjs +1 -0
- package/dist/core/ToolResult.d.mts +2 -0
- package/dist/core/ToolResult.mjs +1 -0
- package/dist/core/ToolResultStorage.d.mts +2 -0
- package/dist/core/ToolResultStorage.mjs +1 -0
- package/dist/core/Usage.d.mts +2 -0
- package/dist/core/Usage.mjs +1 -0
- package/dist/core/Worker.d.mts +3 -0
- package/dist/core/Worker.mjs +3 -0
- package/dist/durable/ActivityStore.d.mts +2 -0
- package/dist/durable/ActivityStore.mjs +1 -0
- package/dist/durable/Admin.d.mts +2 -0
- package/dist/durable/Admin.mjs +1 -0
- package/dist/durable/AgentRegistration.d.mts +3 -0
- package/dist/durable/AgentRegistration.mjs +2 -0
- package/dist/durable/CommittedActivity.d.mts +2 -0
- package/dist/durable/CommittedActivity.mjs +1 -0
- package/dist/durable/Digest.d.mts +2 -0
- package/dist/durable/Digest.mjs +3 -0
- package/dist/durable/DurableAgentRuntime.d.mts +3 -0
- package/dist/durable/DurableAgentRuntime.mjs +4 -0
- package/dist/durable/DurableFailpoint.d.mts +2 -0
- package/dist/durable/DurableFailpoint.mjs +1 -0
- package/dist/durable/DurableFailpointTestControl.d.mts +14 -0
- package/dist/durable/DurableFailpointTestControl.mjs +21 -0
- package/dist/durable/DurableFailpointTestControl.mjs.map +1 -0
- package/dist/durable/EventSource.d.mts +2 -0
- package/dist/durable/EventSource.mjs +1 -0
- package/dist/durable/LifecyclePublication.d.mts +2 -0
- package/dist/durable/LifecyclePublication.mjs +1 -0
- package/dist/durable/MessageDelivery.d.mts +2 -0
- package/dist/durable/MessageDelivery.mjs +1 -0
- package/dist/durable/MessageDeliveryStoreConformance.d.mts +401 -0
- package/dist/durable/MessageDeliveryStoreConformance.mjs +273 -0
- package/dist/durable/MessageDeliveryStoreConformance.mjs.map +1 -0
- package/dist/durable/OperationAuthorizer.d.mts +2 -0
- package/dist/durable/OperationAuthorizer.mjs +1 -0
- package/dist/durable/PersistentHistory.d.mts +2 -0
- package/dist/durable/PersistentHistory.mjs +1 -0
- package/dist/durable/PreparedInputAdmission.d.mts +2 -0
- package/dist/durable/PreparedInputAdmission.mjs +1 -0
- package/dist/durable/RecordFormat.d.mts +2 -0
- package/dist/durable/RecordFormat.mjs +1 -0
- package/dist/durable/Records.d.mts +2 -0
- package/dist/durable/Records.mjs +1 -0
- package/dist/durable/Recovery.d.mts +2 -0
- package/dist/durable/Recovery.mjs +1 -0
- package/dist/durable/RunContinuation.d.mts +4 -0
- package/dist/durable/RunContinuation.mjs +4 -0
- package/dist/durable/RunJournal.d.mts +2 -0
- package/dist/durable/RunJournal.mjs +1 -0
- package/dist/durable/RunStorage.d.mts +2 -0
- package/dist/durable/RunStorage.mjs +1 -0
- package/dist/durable/Schedule.d.mts +2 -0
- package/dist/durable/Schedule.mjs +1 -0
- package/dist/durable/ScheduleStoreConformance.d.mts +16 -0
- package/dist/durable/ScheduleStoreConformance.mjs +421 -0
- package/dist/durable/ScheduleStoreConformance.mjs.map +1 -0
- package/dist/durable/ScheduleTransition.d.mts +2 -0
- package/dist/durable/ScheduleTransition.mjs +1 -0
- package/dist/durable/Scheduling.d.mts +2 -0
- package/dist/durable/Scheduling.mjs +1 -0
- package/dist/durable/SettlementPublisher.d.mts +2 -0
- package/dist/durable/SettlementPublisher.mjs +99 -0
- package/dist/durable/SettlementPublisher.mjs.map +1 -0
- package/dist/durable/SqlMemoryStore.d.mts +729 -0
- package/dist/durable/SqlMemoryStore.mjs +626 -0
- package/dist/durable/SqlMemoryStore.mjs.map +1 -0
- package/dist/durable/SqlStorageOwner.d.mts +18 -0
- package/dist/durable/SqlStorageOwner.mjs +6 -0
- package/dist/durable/SqlStorageOwner.mjs.map +1 -0
- package/dist/durable/SubmissionLedger.d.mts +3 -0
- package/dist/durable/SubmissionLedger.mjs +3 -0
- package/dist/durable/SubmissionLedgerConformance.d.mts +31 -0
- package/dist/durable/SubmissionLedgerConformance.mjs +2090 -0
- package/dist/durable/SubmissionLedgerConformance.mjs.map +1 -0
- package/dist/durable/SubmissionStatus.d.mts +2 -0
- package/dist/durable/SubmissionStatus.mjs +1 -0
- package/dist/durable/Subscription.d.mts +2 -0
- package/dist/durable/Subscription.mjs +1 -0
- package/dist/durable/SubscriptionInput.d.mts +2 -0
- package/dist/durable/SubscriptionInput.mjs +1 -0
- package/dist/durable/SubscriptionStoreConformance.d.mts +15 -0
- package/dist/durable/SubscriptionStoreConformance.mjs +816 -0
- package/dist/durable/SubscriptionStoreConformance.mjs.map +1 -0
- package/dist/durable/SubscriptionTransition.d.mts +2 -0
- package/dist/durable/SubscriptionTransition.mjs +1 -0
- package/dist/durable/Subscriptions.d.mts +2 -0
- package/dist/durable/Subscriptions.mjs +1 -0
- package/dist/durable/ThreadArchiveRange.d.mts +2 -0
- package/dist/durable/ThreadArchiveRange.mjs +1 -0
- package/dist/durable/ThreadContextHistory.d.mts +2 -0
- package/dist/durable/ThreadContextHistory.mjs +1 -0
- package/dist/durable/ThreadContextHistoryProjection.d.mts +2 -0
- package/dist/durable/ThreadContextHistoryProjection.mjs +1 -0
- package/dist/durable/ThreadImport.d.mts +2 -0
- package/dist/durable/ThreadImport.mjs +1 -0
- package/dist/durable/ThreadInvariants.d.mts +2 -0
- package/dist/durable/ThreadInvariants.mjs +1 -0
- package/dist/durable/ThreadProjectionMaintenance.d.mts +2 -0
- package/dist/durable/ThreadProjectionMaintenance.mjs +1 -0
- package/dist/durable/ThreadReader.d.mts +2 -0
- package/dist/durable/ThreadReader.mjs +1 -0
- package/dist/durable/ThreadStore.d.mts +3 -0
- package/dist/durable/ThreadStore.mjs +3 -0
- package/dist/durable/ThreadStoreConformance.d.mts +53 -0
- package/dist/durable/ThreadStoreConformance.mjs +402 -0
- package/dist/durable/ThreadStoreConformance.mjs.map +1 -0
- package/dist/durable/ThreadTransfer.d.mts +2 -0
- package/dist/durable/ThreadTransfer.mjs +1 -0
- package/dist/durable/ThreadWork.d.mts +2 -0
- package/dist/durable/ThreadWork.mjs +1 -0
- package/dist/durable/ToolReconciler.d.mts +2 -0
- package/dist/durable/ToolReconciler.mjs +1 -0
- package/dist/durable/WakeScheduler.d.mts +2 -0
- package/dist/durable/WakeScheduler.mjs +1 -0
- package/dist/durable/WorkerAdmission.d.mts +2 -0
- package/dist/durable/WorkerAdmission.mjs +1 -0
- package/dist/durable/WorkerHost.d.mts +2 -0
- package/dist/durable/WorkerHost.mjs +1 -0
- package/dist/engine/AgentRuntime.d.mts +2 -0
- package/dist/engine/AgentRuntime.mjs +1 -0
- package/dist/engine/Compaction.d.mts +4 -0
- package/dist/engine/Compaction.mjs +2 -0
- package/dist/engine/ContextCompactor.d.mts +2 -0
- package/dist/engine/ContextCompactor.mjs +1 -0
- package/dist/engine/ContextHistory.d.mts +2 -0
- package/dist/engine/ContextHistory.mjs +1 -0
- package/dist/engine/ContextWindow.d.mts +2 -0
- package/dist/engine/ContextWindow.mjs +1 -0
- package/dist/engine/DurableStep.d.mts +2 -0
- package/dist/engine/DurableStep.mjs +3 -0
- package/dist/engine/MessagingHost.d.mts +2 -0
- package/dist/engine/MessagingHost.mjs +1 -0
- package/dist/engine/Output.d.mts +3 -0
- package/dist/engine/Output.mjs +2 -0
- package/dist/engine/RunEventSink.d.mts +2 -0
- package/dist/engine/RunEventSink.mjs +1 -0
- package/dist/engine/RunOptions.d.mts +2 -0
- package/dist/engine/RunOptions.mjs +1 -0
- package/dist/engine/SubagentHost.d.mts +2 -0
- package/dist/engine/SubagentHost.mjs +1 -0
- package/dist/engine/ThreadHistory.d.mts +2 -0
- package/dist/engine/ThreadHistory.mjs +1 -0
- package/dist/engine/ToolBroker.d.mts +2 -0
- package/dist/engine/ToolBroker.mjs +1 -0
- package/dist/index.d.mts +90 -0
- package/dist/index.mjs +101 -0
- package/dist/output-contract-CYA4oBhe.mjs +128 -0
- package/dist/output-contract-CYA4oBhe.mjs.map +1 -0
- package/dist/rolldown-runtime-D3KUYPsf.mjs +12 -0
- package/dist/run-context-reader-CHox63hg.d.mts +17 -0
- package/dist/sandbox/CodeExecutor.d.mts +2 -0
- package/dist/sandbox/CodeExecutor.mjs +1 -0
- package/dist/sandbox/InteractiveBrowser.d.mts +2 -0
- package/dist/sandbox/InteractiveBrowser.mjs +1 -0
- package/dist/sandbox/PageCapture.d.mts +2 -0
- package/dist/sandbox/PageCapture.mjs +1 -0
- package/dist/sandbox/PageScreenshot.d.mts +2 -0
- package/dist/sandbox/PageScreenshot.mjs +1 -0
- package/dist/sandbox/Sandbox.d.mts +2 -0
- package/dist/sandbox/Sandbox.mjs +1 -0
- package/dist/subagent-policy-xRJhrc0a.mjs +133 -0
- package/dist/subagent-policy-xRJhrc0a.mjs.map +1 -0
- package/dist/tool-execution-Cl7v8fXU.mjs +16 -0
- package/dist/tool-execution-Cl7v8fXU.mjs.map +1 -0
- package/dist/tool-operations-CauPonM8.mjs +84 -0
- package/dist/tool-operations-CauPonM8.mjs.map +1 -0
- package/dist/utf8-Bl0ZhhGe.mjs +27 -0
- package/dist/utf8-Bl0ZhhGe.mjs.map +1 -0
- package/package.json +489 -5
- package/src/InMemory.ts +79 -0
- package/src/ToolExposure.ts +2 -0
- package/src/capabilities/BrowserUse.ts +212 -0
- package/src/capabilities/Budget.ts +544 -0
- package/src/capabilities/CodeMode.ts +1129 -0
- package/src/capabilities/ContextTools.ts +131 -0
- package/src/capabilities/MemoryNotes.ts +177 -0
- package/src/capabilities/Messaging.ts +260 -0
- package/src/capabilities/Redaction.ts +163 -0
- package/src/capabilities/RunHooks.ts +116 -0
- package/src/capabilities/SemanticMemory.ts +402 -0
- package/src/capabilities/Subagent.ts +2343 -0
- package/src/capabilities/SubagentReservations.ts +807 -0
- package/src/capabilities/ToolDiscovery.ts +291 -0
- package/src/capabilities/ToolResults.ts +50 -0
- package/src/capabilities/WebCapture.ts +64 -0
- package/src/capabilities/WebSearch.ts +45 -0
- package/src/capabilities/internal/subagent-background.ts +1137 -0
- package/src/capabilities/internal/subagent-contract.ts +92 -0
- package/src/capabilities/internal/subagent-policy.ts +205 -0
- package/src/capabilities/internal/subagent-reporting.ts +152 -0
- package/src/core/Agent.ts +528 -0
- package/src/core/AgentError.ts +189 -0
- package/src/core/AgentPolicy.ts +194 -0
- package/src/core/AgentUpdates.ts +104 -0
- package/src/core/FailureDiagnostic.ts +392 -0
- package/src/core/IdGenerator.ts +42 -0
- package/src/core/Identifiers.ts +64 -0
- package/src/core/Memory.ts +283 -0
- package/src/core/MemoryNamespace.ts +202 -0
- package/src/core/MemoryReference.ts +120 -0
- package/src/core/MemoryRevalidation.ts +151 -0
- package/src/core/MemoryStore.ts +371 -0
- package/src/core/Messaging.ts +72 -0
- package/src/core/ProvisionalText.ts +53 -0
- package/src/core/Receipt.ts +42 -0
- package/src/core/RememberingStore.ts +22 -0
- package/src/core/RunEvent.ts +345 -0
- package/src/core/RunPolicyUsage.ts +19 -0
- package/src/core/SemanticMemoryIndex.ts +259 -0
- package/src/core/SemanticMemoryRevalidation.ts +220 -0
- package/src/core/SubagentContract.ts +263 -0
- package/src/core/Thread.ts +447 -0
- package/src/core/ToolExposure.ts +75 -0
- package/src/core/ToolResult.ts +204 -0
- package/src/core/ToolResultStorage.ts +56 -0
- package/src/core/Usage.ts +562 -0
- package/src/core/Worker.ts +236 -0
- package/src/core/internal/agent-updates.ts +42 -0
- package/src/core/internal/completion.ts +33 -0
- package/src/core/internal/json.ts +17 -0
- package/src/core/internal/memory-document.ts +39 -0
- package/src/core/internal/message-status.ts +60 -0
- package/src/core/internal/strict-schema.ts +14 -0
- package/src/core/internal/tool-execution.ts +33 -0
- package/src/core/internal/utf8.ts +32 -0
- package/src/durable/ActivityStore.ts +131 -0
- package/src/durable/Admin.ts +504 -0
- package/src/durable/AgentRegistration.ts +16 -0
- package/src/durable/CommittedActivity.ts +262 -0
- package/src/durable/Digest.ts +57 -0
- package/src/durable/DurableAgentRuntime.ts +12758 -0
- package/src/durable/DurableFailpoint.ts +108 -0
- package/src/durable/DurableFailpointTestControl.ts +39 -0
- package/src/durable/EventSource.ts +179 -0
- package/src/durable/LifecyclePublication.ts +343 -0
- package/src/durable/MessageDelivery.ts +949 -0
- package/src/durable/MessageDeliveryStoreConformance.ts +407 -0
- package/src/durable/OperationAuthorizer.ts +89 -0
- package/src/durable/PersistentHistory.ts +322 -0
- package/src/durable/PreparedInputAdmission.ts +128 -0
- package/src/durable/RecordFormat.ts +113 -0
- package/src/durable/Records.ts +1396 -0
- package/src/durable/Recovery.ts +1022 -0
- package/src/durable/RunContinuation.ts +1946 -0
- package/src/durable/RunJournal.ts +1926 -0
- package/src/durable/RunStorage.ts +533 -0
- package/src/durable/Schedule.ts +445 -0
- package/src/durable/ScheduleStoreConformance.ts +642 -0
- package/src/durable/ScheduleTransition.ts +267 -0
- package/src/durable/Scheduling.ts +1031 -0
- package/src/durable/SettlementPublisher.ts +172 -0
- package/src/durable/SqlMemoryStore.ts +1042 -0
- package/src/durable/SqlStorageOwner.ts +25 -0
- package/src/durable/SubmissionLedger.ts +1247 -0
- package/src/durable/SubmissionLedgerConformance.ts +4695 -0
- package/src/durable/SubmissionStatus.ts +14 -0
- package/src/durable/Subscription.ts +527 -0
- package/src/durable/SubscriptionInput.ts +145 -0
- package/src/durable/SubscriptionStoreConformance.ts +1275 -0
- package/src/durable/SubscriptionTransition.ts +330 -0
- package/src/durable/Subscriptions.ts +1245 -0
- package/src/durable/ThreadArchiveRange.ts +91 -0
- package/src/durable/ThreadContextHistory.ts +338 -0
- package/src/durable/ThreadContextHistoryProjection.ts +219 -0
- package/src/durable/ThreadImport.ts +1199 -0
- package/src/durable/ThreadInvariants.ts +312 -0
- package/src/durable/ThreadProjectionMaintenance.ts +72 -0
- package/src/durable/ThreadReader.ts +21 -0
- package/src/durable/ThreadStore.ts +1258 -0
- package/src/durable/ThreadStoreConformance.ts +877 -0
- package/src/durable/ThreadTransfer.ts +263 -0
- package/src/durable/ThreadWork.ts +713 -0
- package/src/durable/ToolReconciler.ts +112 -0
- package/src/durable/WakeScheduler.ts +125 -0
- package/src/durable/WorkerAdmission.ts +98 -0
- package/src/durable/WorkerHost.ts +204 -0
- package/src/durable/internal/StorageOwner.ts +181 -0
- package/src/durable/internal/agent-registration.ts +713 -0
- package/src/durable/internal/agent-updates.ts +338 -0
- package/src/durable/internal/canonical-json.ts +110 -0
- package/src/durable/internal/evidence.ts +29 -0
- package/src/durable/internal/foreign-diagnostic.ts +48 -0
- package/src/durable/internal/history-prompt.ts +87 -0
- package/src/durable/internal/initial-context.ts +215 -0
- package/src/durable/internal/journal-metadata.ts +188 -0
- package/src/durable/internal/message-status.ts +18 -0
- package/src/durable/internal/messaging-host.ts +615 -0
- package/src/durable/internal/prompt-footprint.ts +47 -0
- package/src/durable/internal/prompt-history-cache.ts +604 -0
- package/src/durable/internal/record-encoding.ts +258 -0
- package/src/durable/internal/record-ownership.ts +68 -0
- package/src/durable/internal/run-context-reader.ts +51 -0
- package/src/durable/internal/run-context.ts +211 -0
- package/src/durable/internal/schedule-time.ts +304 -0
- package/src/durable/internal/thread-import-reader.ts +85 -0
- package/src/durable/internal/thread-initialization.ts +181 -0
- package/src/durable/internal/thread-transfer-source.ts +7 -0
- package/src/durable/internal/tool-operations.ts +138 -0
- package/src/durable/internal/transfer-dependencies.ts +40 -0
- package/src/durable/internal/usage-totals.ts +36 -0
- package/src/durable/internal/worker-host.ts +4041 -0
- package/src/durable/internal/worker-runtime.ts +10 -0
- package/src/engine/AgentRuntime.ts +100 -0
- package/src/engine/Compaction.ts +11 -0
- package/src/engine/ContextCompactor.ts +302 -0
- package/src/engine/ContextHistory.ts +75 -0
- package/src/engine/ContextWindow.ts +81 -0
- package/src/engine/DurableStep.ts +115 -0
- package/src/engine/MessagingHost.ts +118 -0
- package/src/engine/Output.ts +2 -0
- package/src/engine/RunEventSink.ts +124 -0
- package/src/engine/RunOptions.ts +664 -0
- package/src/engine/SubagentHost.ts +231 -0
- package/src/engine/ThreadHistory.ts +125 -0
- package/src/engine/ToolBroker.ts +159 -0
- package/src/engine/ToolExposure.ts +49 -0
- package/src/engine/internal/agent-runtime.ts +11137 -0
- package/src/engine/internal/bounded-value.ts +312 -0
- package/src/engine/internal/compaction.ts +673 -0
- package/src/engine/internal/error-diagnostic.ts +39 -0
- package/src/engine/internal/image-tokens.ts +61 -0
- package/src/engine/internal/interpreter-options.ts +569 -0
- package/src/engine/internal/output-contract.ts +226 -0
- package/src/engine/internal/primitive-delta.ts +103 -0
- package/src/engine/internal/provider-result-staging.ts +211 -0
- package/src/engine/internal/provisional-text.ts +107 -0
- package/src/engine/internal/tool-derivative.ts +47 -0
- package/src/engine/internal/tool-exposure.ts +228 -0
- package/src/engine/internal/tool-telemetry.ts +488 -0
- package/src/index.ts +100 -0
- package/src/sandbox/CodeExecutor.ts +352 -0
- package/src/sandbox/InteractiveBrowser.ts +343 -0
- package/src/sandbox/PageCapture.ts +391 -0
- package/src/sandbox/PageScreenshot.ts +83 -0
- package/src/sandbox/Sandbox.ts +29 -0
- package/README.md +0 -3
|
@@ -0,0 +1,560 @@
|
|
|
1
|
+
import * as LanguageModel from "effect/ai/LanguageModel";
|
|
2
|
+
import * as Model from "effect/ai/Model";
|
|
3
|
+
import * as Prompt from "effect/ai/Prompt";
|
|
4
|
+
import * as Response from "effect/ai/Response";
|
|
5
|
+
import * as Cause from "effect/Cause";
|
|
6
|
+
import * as Context from "effect/Context";
|
|
7
|
+
import * as DateTime from "effect/DateTime";
|
|
8
|
+
import * as Effect from "effect/Effect";
|
|
9
|
+
import * as Layer from "effect/Layer";
|
|
10
|
+
import * as Schema from "effect/Schema";
|
|
11
|
+
import { f as AgentToolAuthorizationCheckError, o as AgentInputError } from "./AgentError-RkUaetX8.mjs";
|
|
12
|
+
import { d as ToolCallId, f as TurnId, s as RunId, t as AgentId, u as ThreadId } from "./Identifiers-qafW4EP0.mjs";
|
|
13
|
+
import { o as MemoryRecallError } from "./MemoryReference-Dd3KSMa7.mjs";
|
|
14
|
+
import { m as ToolExecutionKind } from "./SubagentContract-B7vQPueI.mjs";
|
|
15
|
+
import { c as Selection } from "./ToolExposure-DNME8BkG.mjs";
|
|
16
|
+
import { r as ModelCallUsage } from "./Usage-Bc-jXe_9.mjs";
|
|
17
|
+
import { r as FrameworkMessage } from "./Worker-xxucY_0b.mjs";
|
|
18
|
+
import { c as ContextMessageTokenEstimator, n as CompactionError } from "./ContextCompactor-Chm9BLrD.mjs";
|
|
19
|
+
import { c as ModelCallContext, r as ContextRolloverSelection } from "./ContextWindow-BJZI4MMt.mjs";
|
|
20
|
+
import { l as ToolExecutionClassValue } from "./DurableStep-cI_Ho_rU.mjs";
|
|
21
|
+
declare namespace RunOptions_d_exports {
|
|
22
|
+
export { CommandDrainPolicy, CurrentToolFailureObserver, ModelToolFailure, PreparedRunContext, ProgrammaticPreflightFailure, ProgrammaticToolFailure, ResolvedModelCall, RunApprovalDecision, RunApprovalHook, RunApprovalRequest, RunBudgetHook, RunBufferLimits, RunContextHook, RunContextPreparation, RunContextPreparationError, RunContextPreparationPassthrough, RunContextRequest, RunCostEstimate, RunCostEstimateRequest, RunCostEstimator, RunInputCommand, RunInputHook, RunOptions, RunOptionsError, RunOptionsRequirements, RunSchedulingHook, RunSchedulingOverride, RunToolAuthorization, RunToolAuthorizationDecision, RunToolAuthorizationHook, RunToolAuthorizationRequest, RunToolCallDescriptor, RunToolFailureObserver, RunToolScheduling, RunTransientContextHook, RunUsageDelta, ToolFailureObservation, toolFailureObserverLayer };
|
|
23
|
+
}
|
|
24
|
+
/** Live, trusted application diagnostics. Never persisted, transported, or automatically logged. */
|
|
25
|
+
interface ToolFailureIdentity {
|
|
26
|
+
readonly agentId: AgentId;
|
|
27
|
+
readonly threadId: ThreadId;
|
|
28
|
+
readonly runId: RunId;
|
|
29
|
+
readonly turnId: TurnId;
|
|
30
|
+
readonly toolName: string;
|
|
31
|
+
/** Best-effort error tag, with the existing `UnknownError` fallback. */
|
|
32
|
+
readonly tag: string;
|
|
33
|
+
}
|
|
34
|
+
/** A model-declared call failed validation or returned a declared failure without failing the Run. */
|
|
35
|
+
interface ModelToolFailure extends ToolFailureIdentity {
|
|
36
|
+
readonly _tag: 'ModelToolFailure';
|
|
37
|
+
readonly kind: 'declared-failure' | 'parameter-rejection';
|
|
38
|
+
/** Raw provider identity, without the telemetry ID filter. */
|
|
39
|
+
readonly toolCallId: ToolCallId;
|
|
40
|
+
readonly executionClass: ToolExecutionClassValue;
|
|
41
|
+
readonly message?: never;
|
|
42
|
+
/** Original private failure; never automatically logged or included in RunEvents. */
|
|
43
|
+
readonly cause: Cause.Cause<unknown>;
|
|
44
|
+
}
|
|
45
|
+
interface ProgrammaticToolFailureIdentity extends ToolFailureIdentity {
|
|
46
|
+
readonly _tag: 'ProgrammaticToolFailure';
|
|
47
|
+
/** `${parentToolCallId}#${sequenceIndex}`, raw and unique only within this in-memory pass. */
|
|
48
|
+
readonly toolCallId: string;
|
|
49
|
+
readonly parentToolCallId: ToolCallId;
|
|
50
|
+
/** Presence means the Handler started and consumed budget; side effects may exist. */
|
|
51
|
+
readonly sequenceIndex: number;
|
|
52
|
+
readonly executionClass: ToolExecutionClassValue;
|
|
53
|
+
}
|
|
54
|
+
interface ProgrammaticDeclaredFailure extends ProgrammaticToolFailureIdentity {
|
|
55
|
+
readonly kind: 'declared-failure';
|
|
56
|
+
readonly message?: never;
|
|
57
|
+
/** Original private failure; never automatically logged or included in RunEvents. */
|
|
58
|
+
readonly cause: Cause.Cause<unknown>;
|
|
59
|
+
}
|
|
60
|
+
interface ProgrammaticHandlerFailure extends ProgrammaticToolFailureIdentity {
|
|
61
|
+
readonly kind: 'handler-error';
|
|
62
|
+
readonly message?: never;
|
|
63
|
+
/** The original, uncollapsed Cause captured before the broker's diagnostic projection. */
|
|
64
|
+
readonly cause: Cause.Cause<unknown>;
|
|
65
|
+
}
|
|
66
|
+
interface ProgrammaticDiagnosticFailure extends ProgrammaticToolFailureIdentity {
|
|
67
|
+
readonly kind: 'infrastructure' | 'protocol';
|
|
68
|
+
/** At most 4096 UTF-8 bytes. Never a declared payload. */
|
|
69
|
+
readonly message: string;
|
|
70
|
+
/** Original Cause when one exists; never fabricated from a source-less rejection. */
|
|
71
|
+
readonly cause?: Cause.Cause<unknown> | undefined;
|
|
72
|
+
}
|
|
73
|
+
/** A programmatic Handler started and its failure became a broker outcome. */
|
|
74
|
+
type ProgrammaticToolFailure = ProgrammaticDeclaredFailure | ProgrammaticHandlerFailure | ProgrammaticDiagnosticFailure;
|
|
75
|
+
/** A programmatic invocation was rejected before its Handler started. No inner identity exists. */
|
|
76
|
+
interface ProgrammaticPreflightFailure extends ToolFailureIdentity {
|
|
77
|
+
readonly _tag: 'ProgrammaticPreflightFailure';
|
|
78
|
+
readonly kind: 'infrastructure' | 'protocol';
|
|
79
|
+
readonly parentToolCallId: ToolCallId;
|
|
80
|
+
/** Absent if the Tool could not be resolved. */
|
|
81
|
+
readonly executionClass?: ToolExecutionClassValue | undefined;
|
|
82
|
+
/** At most 4096 UTF-8 bytes. */
|
|
83
|
+
readonly message: string;
|
|
84
|
+
/** Original Cause only for Cause-backed rejection, never fabricated from an outcome. */
|
|
85
|
+
readonly cause?: Cause.Cause<unknown> | undefined;
|
|
86
|
+
}
|
|
87
|
+
/** Plain readonly interfaces, intentionally not persisted or transported Schemas (RUN-036). */
|
|
88
|
+
type ToolFailureObservation = ModelToolFailure | ProgrammaticToolFailure | ProgrammaticPreflightFailure;
|
|
89
|
+
/**
|
|
90
|
+
* Trusted in-process observation of non-propagating application Tool failures (RUN-036).
|
|
91
|
+
* Capture reporting dependencies before installation. Delivery is inline under the existing
|
|
92
|
+
* Tool permit for started calls; preflight reporting is serialized per broker. Delivery is at
|
|
93
|
+
* most once per in-memory attempt, with isolated observer/reporter defects.
|
|
94
|
+
* External interruption may end delivery. Replacement Attempts may repeat IDs and observations.
|
|
95
|
+
* Never reenter ToolBroker, RunEventSink, or Agent execution, or intentionally self-interrupt.
|
|
96
|
+
*/
|
|
97
|
+
interface RunToolFailureObserver {
|
|
98
|
+
readonly observe: (observation: ToolFailureObservation) => Effect.Effect<void>;
|
|
99
|
+
}
|
|
100
|
+
/** Resolved once per Run; durable coordinators capture it at Layer acquisition. Default absent. */
|
|
101
|
+
declare const CurrentToolFailureObserver: Context.Reference<RunToolFailureObserver | undefined>;
|
|
102
|
+
/** The sole installation seam, shared by ephemeral Runs and durable platform options. */
|
|
103
|
+
declare const toolFailureObserverLayer: (observer: RunToolFailureObserver) => Layer.Layer<never>;
|
|
104
|
+
/** Number of queued inputs consumed at one documented Turn seam. */
|
|
105
|
+
declare const CommandDrainPolicy: Schema.Literals<readonly ["one", "all"]>;
|
|
106
|
+
type CommandDrainPolicy = typeof CommandDrainPolicy.Type;
|
|
107
|
+
/** Engine-normalized input command. Capability packages may adapt richer audit records to it. */
|
|
108
|
+
interface RunInputCommand {
|
|
109
|
+
readonly kind: 'steering' | 'follow-up';
|
|
110
|
+
readonly input: Prompt.RawInput;
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Dependency-neutral input seam used by the interpreter.
|
|
114
|
+
*
|
|
115
|
+
* A capability adapter owns queue bounds and Scope finalization. The engine calls
|
|
116
|
+
* `start` before the first drain, `drain` only at safe Turn seams (including after
|
|
117
|
+
* cancellation of a disposable model call), and `end`
|
|
118
|
+
* exactly once when the Run leaves its Scope.
|
|
119
|
+
*/
|
|
120
|
+
interface RunInputHook<Error = never, Requirements = never> {
|
|
121
|
+
/**
|
|
122
|
+
* Wait for an eligible join without appending it to history. Must register before checking
|
|
123
|
+
* authority and retain any claimed input for `drain`, even when this wait is interrupted.
|
|
124
|
+
* Used only with `restartOnJoinedInput`; each wait belongs to the model stream's Scope.
|
|
125
|
+
*/
|
|
126
|
+
readonly awaitJoin?: Effect.Effect<void, Error, Requirements> | undefined;
|
|
127
|
+
/**
|
|
128
|
+
* Claim an eligible join without appending it to history, and report whether one exists. At a
|
|
129
|
+
* model stop the engine calls this first and calls `drain` only after `true`, so the stopped
|
|
130
|
+
* Turn's response precedes the joined input in history. A later join gets its own Run.
|
|
131
|
+
*/
|
|
132
|
+
readonly hasJoin?: ((policy: CommandDrainPolicy) => Effect.Effect<boolean, Error, Requirements>) | undefined;
|
|
133
|
+
readonly start?: (() => Effect.Effect<void, Error, Requirements>) | undefined;
|
|
134
|
+
readonly drain: (policy: CommandDrainPolicy) => Effect.Effect<ReadonlyArray<RunInputCommand>, Error, Requirements>;
|
|
135
|
+
readonly end?: (() => Effect.Effect<void, never, Requirements>) | undefined;
|
|
136
|
+
}
|
|
137
|
+
/** Decision returned by an ephemeral approval adapter. */
|
|
138
|
+
type RunApprovalDecision = {
|
|
139
|
+
readonly _tag: 'approved';
|
|
140
|
+
readonly reason?: string | undefined;
|
|
141
|
+
} | {
|
|
142
|
+
readonly _tag: 'denied';
|
|
143
|
+
readonly reason?: string | undefined;
|
|
144
|
+
} | {
|
|
145
|
+
readonly _tag: 'unresolved';
|
|
146
|
+
readonly reason?: string | undefined;
|
|
147
|
+
};
|
|
148
|
+
/** Native Effect AI approval request enriched with stable Run identities. */
|
|
149
|
+
interface RunApprovalRequest {
|
|
150
|
+
readonly request: Response.ToolApprovalRequestPart;
|
|
151
|
+
readonly threadId: ThreadId;
|
|
152
|
+
readonly runId: RunId;
|
|
153
|
+
readonly turnId: TurnId;
|
|
154
|
+
readonly toolCallId: ToolCallId;
|
|
155
|
+
readonly toolName: string;
|
|
156
|
+
readonly parameters: unknown;
|
|
157
|
+
}
|
|
158
|
+
/** Approval policy preparation is deadline-bounded; canonical acceptance stays host-owned. */
|
|
159
|
+
interface RunApprovalHook<Error = never, Requirements = never> {
|
|
160
|
+
/** Retain a nonempty batch's required requests before any decision can release dispatch proof. */
|
|
161
|
+
readonly prepareBatch?: ((requests: ReadonlyArray<RunApprovalRequest>) => Effect.Effect<void, Error, Requirements>) | undefined;
|
|
162
|
+
/** Prepare a decision without publishing canonical facts; this shares the Run duration deadline. */
|
|
163
|
+
readonly request: (request: RunApprovalRequest) => Effect.Effect<RunApprovalDecision, Error, Requirements>;
|
|
164
|
+
/** Accept the prepared decision canonically before the engine honors it, outside preparation timers. */
|
|
165
|
+
readonly commit?: ((request: RunApprovalRequest, decision: RunApprovalDecision) => Effect.Effect<void, Error, Requirements>) | undefined;
|
|
166
|
+
}
|
|
167
|
+
/** Input passed to ordered context transformation and compaction adapters. */
|
|
168
|
+
interface RunContextRequest {
|
|
169
|
+
readonly threadId: ThreadId;
|
|
170
|
+
readonly runId: RunId;
|
|
171
|
+
readonly turnId: TurnId;
|
|
172
|
+
readonly turn: number;
|
|
173
|
+
/**
|
|
174
|
+
* Official engine history for this Attempt before context preparation. The
|
|
175
|
+
* engine never replaces or mutates this value. Durable prompt
|
|
176
|
+
* reconstruction can produce a different model-visible basis afterward, so
|
|
177
|
+
* adapters that need canonical retrieval should key it by the supplied Run
|
|
178
|
+
* identities rather than infer durable state from this Prompt alone.
|
|
179
|
+
*/
|
|
180
|
+
readonly source: Prompt.Prompt;
|
|
181
|
+
/**
|
|
182
|
+
* Durable coordinator's exact prior-Run prefix length in `source`. A preparation hook
|
|
183
|
+
* can replace `source.content.slice(0, priorRunPrefixLength)` with application context
|
|
184
|
+
* while preserving this Run's instructions, input, updates and recovered Tool exchanges.
|
|
185
|
+
* This is a model-only transformation: canonical records and retry receipts are retained.
|
|
186
|
+
* Absent for non-durable Runs; never infer this boundary from message roles or text.
|
|
187
|
+
*/
|
|
188
|
+
readonly priorRunPrefixLength?: number | undefined;
|
|
189
|
+
/**
|
|
190
|
+
* The exact model-visible final-output contract the engine appends to the
|
|
191
|
+
* prepared prompt after this hook returns (RUN-028), or
|
|
192
|
+
* undefined when the definition's output Schema cannot render to JSON
|
|
193
|
+
* Schema. Exposed so a limit-targeting adapter can reserve the contract's
|
|
194
|
+
* overhead in its own window calculation; the hook can size for the
|
|
195
|
+
* contract but cannot remove or alter it.
|
|
196
|
+
*/
|
|
197
|
+
readonly outputContract?: string | undefined;
|
|
198
|
+
}
|
|
199
|
+
/**
|
|
200
|
+
* One captured provider configuration and its context bounds. Build the native Model Layer
|
|
201
|
+
* from the same resolved values as context; do not defer route selection inside its requests.
|
|
202
|
+
* Capture provider requirements in the preparation Layer. The engine acquires this closed
|
|
203
|
+
* Layer once per Turn and keeps it through compaction, dispatch, accounting, and overflow retry.
|
|
204
|
+
*/
|
|
205
|
+
interface ResolvedModelCall {
|
|
206
|
+
readonly model: Layer.Layer<LanguageModel.LanguageModel | Model.ProviderName | Model.ModelName>;
|
|
207
|
+
readonly context: ModelCallContext;
|
|
208
|
+
/**
|
|
209
|
+
* The selected provider's native Tool schema transformer, such as toCodecOpenAI or
|
|
210
|
+
* toCodecAnthropic. Omission uses generic JSON Schema and is suitable only when the provider
|
|
211
|
+
* does not rewrite schemas. Select it from the same captured configuration as the Model Layer.
|
|
212
|
+
* Provider-defined Tools count their native name/configuration arguments instead; their
|
|
213
|
+
* provider-generated call parameter schemas are never transformed into function declarations.
|
|
214
|
+
*/
|
|
215
|
+
readonly toolSchemaTransformer?: LanguageModel.CodecTransformer | undefined;
|
|
216
|
+
/**
|
|
217
|
+
* Replace the entire estimate of a message, including its framing, with a non-negative finite
|
|
218
|
+
* integer. Undefined uses the native structural estimate for that message. Capture any model
|
|
219
|
+
* or content-specific reservation before returning this callback; it must be deterministic for
|
|
220
|
+
* copied message content and same-Turn retries, without consulting mutable provider state.
|
|
221
|
+
* The engine shares it across admission, built-in compaction sizing, and default summaries.
|
|
222
|
+
* Do not also charge a replaced message through uncountedOverheadTokens.
|
|
223
|
+
*/
|
|
224
|
+
readonly estimateMessageTokens?: ContextMessageTokenEstimator | undefined;
|
|
225
|
+
}
|
|
226
|
+
/** Prepared model-only context returned by a context adapter. */
|
|
227
|
+
interface PreparedRunContext {
|
|
228
|
+
/** Replace non-pinned registered native Tools at this Turn boundary. */
|
|
229
|
+
readonly toolSelection?: Selection | undefined;
|
|
230
|
+
readonly prompt: Prompt.Prompt;
|
|
231
|
+
/** Resolves actual model selection and admission together, once at this Turn boundary. */
|
|
232
|
+
readonly modelCall?: ResolvedModelCall | undefined;
|
|
233
|
+
/**
|
|
234
|
+
* Start a fresh native context window even below capacity. Coverage must map to a complete
|
|
235
|
+
* canonical prefix for durable Runs and cannot discard protected input or split Tool pairs.
|
|
236
|
+
* Omit through to select prior history before this Run's protected instructions/input; this
|
|
237
|
+
* is a no-op when no prior prefix remains, including after a committed reset is recovered.
|
|
238
|
+
* Leave the source prefix intact; the engine commits and applies the selected rollover.
|
|
239
|
+
*/
|
|
240
|
+
readonly rollover?: ContextRolloverSelection | undefined;
|
|
241
|
+
}
|
|
242
|
+
/**
|
|
243
|
+
* Model-only prompt transformation. Compaction requires a safely mapped original
|
|
244
|
+
* instruction/input block and content-equivalent covered prefixes across Turns.
|
|
245
|
+
* Incompatible changes fail with CompactionError before compaction or model I/O.
|
|
246
|
+
*/
|
|
247
|
+
interface RunContextHook<Error = never, Requirements = never> {
|
|
248
|
+
/**
|
|
249
|
+
* Resources acquired by `prepare` belong to the current Turn and close before
|
|
250
|
+
* the next Turn starts. Acquire resources shared across Turns in a surrounding
|
|
251
|
+
* Run Layer or Scope instead.
|
|
252
|
+
*/
|
|
253
|
+
readonly prepare: (request: RunContextRequest) => Effect.Effect<PreparedRunContext, Error, Requirements>;
|
|
254
|
+
}
|
|
255
|
+
/**
|
|
256
|
+
* Supplies model-visible reference context for one Turn without changing the
|
|
257
|
+
* prompt that compaction covers or the history that the engine commits.
|
|
258
|
+
*
|
|
259
|
+
* The engine treats the returned input as untrusted, validates it before
|
|
260
|
+
* provider I/O, and includes it in the Turn's context and completion-reserve
|
|
261
|
+
* admission. It never passes this input to the compaction summary Model. A
|
|
262
|
+
* same-Turn provider-overflow retry reuses the loaded snapshot. Return an
|
|
263
|
+
* empty Prompt when the Turn needs no references.
|
|
264
|
+
*/
|
|
265
|
+
interface RunTransientContextHook<Error = never, Requirements = never> {
|
|
266
|
+
readonly load: (request: RunContextRequest) => Effect.Effect<Prompt.RawInput, Error, Requirements>;
|
|
267
|
+
}
|
|
268
|
+
/** Context service failures retain their concrete tags and structured fields. */
|
|
269
|
+
type RunContextPreparationError = AgentInputError | MemoryRecallError | CompactionError;
|
|
270
|
+
/**
|
|
271
|
+
* One usage delta. Turn-boundary consumption charges `modelCalls: 1` after a
|
|
272
|
+
* complete response and before any Tool starts; the programmatic Tool broker
|
|
273
|
+
* charges `modelCalls: 0, toolCalls: 1` before each inner handler starts
|
|
274
|
+
* (RUN-017).
|
|
275
|
+
*/
|
|
276
|
+
interface RunUsageDelta {
|
|
277
|
+
readonly modelCalls: 0 | 1;
|
|
278
|
+
readonly inputTokens: number;
|
|
279
|
+
readonly outputTokens: number;
|
|
280
|
+
readonly totalTokens: number;
|
|
281
|
+
readonly toolCalls: number;
|
|
282
|
+
readonly costMicrousd: number;
|
|
283
|
+
readonly usage: Response.Usage;
|
|
284
|
+
/** Present for model-call deltas; absent for programmatic Tool-only charges. */
|
|
285
|
+
readonly modelUsage?: ModelCallUsage | undefined;
|
|
286
|
+
}
|
|
287
|
+
/** Stable pricing identity returned alongside a host's microdollar estimate. */
|
|
288
|
+
interface RunCostEstimate {
|
|
289
|
+
readonly costMicrousd: number;
|
|
290
|
+
readonly serviceTier?: string | undefined;
|
|
291
|
+
readonly pricingVersion?: string | undefined;
|
|
292
|
+
/** Unknown estimates do not prove a free call and fail an explicit cost budget after usage is retained. */
|
|
293
|
+
readonly pricingStatus?: 'estimated' | 'unknown' | undefined;
|
|
294
|
+
}
|
|
295
|
+
/** Provider usage and identity supplied for one model-call estimate. */
|
|
296
|
+
interface RunCostEstimateRequest {
|
|
297
|
+
/** Observed hosted web search calls, separately billed from tokens. */
|
|
298
|
+
readonly webSearchCalls?: number | undefined;
|
|
299
|
+
readonly provider: string;
|
|
300
|
+
/** Configured binding identity; only response.model identifies the returned model. */
|
|
301
|
+
readonly model: string;
|
|
302
|
+
readonly usage: Response.Usage;
|
|
303
|
+
/** Actual provider response fields, never the configured binding name. */
|
|
304
|
+
readonly response?: {
|
|
305
|
+
readonly id?: string | undefined;
|
|
306
|
+
readonly model?: string | undefined;
|
|
307
|
+
} | undefined;
|
|
308
|
+
/** Native Effect AI provider metadata, runtime-only; HTTP details are excluded. */
|
|
309
|
+
readonly finishMetadata?: Response.FinishPart['metadata'] | undefined;
|
|
310
|
+
readonly purpose?: 'turn' | 'summary' | undefined;
|
|
311
|
+
}
|
|
312
|
+
/**
|
|
313
|
+
* Host-owned price lookup; durable hosts close every dependency before installing it.
|
|
314
|
+
*/
|
|
315
|
+
type RunCostEstimator<Error = never, Requirements = never> = (request: RunCostEstimateRequest) => Effect.Effect<RunCostEstimate, Error, Requirements>;
|
|
316
|
+
/**
|
|
317
|
+
* Dependency-neutral hierarchical budget hook. A typed failure at a Turn-seam
|
|
318
|
+
* consumption or a stream-guard pull stops the Run. A mid-pass programmatic
|
|
319
|
+
* consumption failure instead becomes that call's outcome (RUN-017 —
|
|
320
|
+
* exhaustion prevents the call): the Run still stops at the next Turn seam,
|
|
321
|
+
* because the following model call's `consume` and the guarded stream pulls
|
|
322
|
+
* re-enforce the same budget.
|
|
323
|
+
*/
|
|
324
|
+
interface RunBudgetHook<Error = never, Requirements = never> {
|
|
325
|
+
/**
|
|
326
|
+
* Guard one active model or Tool stream pull. Hierarchical budget adapters
|
|
327
|
+
* use an absolute deadline so repeated pulls share one duration allowance.
|
|
328
|
+
*/
|
|
329
|
+
readonly guard: <A, E, R>(effect: Effect.Effect<A, E, R>) => Effect.Effect<A, E | Error, R | Requirements>;
|
|
330
|
+
readonly consume: (delta: RunUsageDelta) => Effect.Effect<void, Error, Requirements>;
|
|
331
|
+
}
|
|
332
|
+
/**
|
|
333
|
+
* One application Tool Call of a completed Turn as the durable runtime sees
|
|
334
|
+
* it: stable identity, the encoded (wire-form) parameters exactly as official
|
|
335
|
+
* history carries them, and the Tool's declared execution class (fail-closed
|
|
336
|
+
* `"uncertain"` for unannotated Tools).
|
|
337
|
+
*/
|
|
338
|
+
interface RunToolCallDescriptor {
|
|
339
|
+
readonly toolCallId: ToolCallId;
|
|
340
|
+
readonly toolName: string;
|
|
341
|
+
/** Encoded JSON parameters — the same value official history and canonical records carry. */
|
|
342
|
+
readonly parameters: unknown;
|
|
343
|
+
readonly executionClass: ToolExecutionClassValue;
|
|
344
|
+
/** Definition-owned classification; never inferred from the Tool name. */
|
|
345
|
+
readonly executionKind: ToolExecutionKind;
|
|
346
|
+
}
|
|
347
|
+
/** Decision returned by a host's action-time Tool authorization policy. */
|
|
348
|
+
type RunToolAuthorizationDecision = {
|
|
349
|
+
readonly _tag: 'allowed';
|
|
350
|
+
} | {
|
|
351
|
+
readonly _tag: 'denied';
|
|
352
|
+
/** Safe model-facing explanation. */
|
|
353
|
+
readonly reason: string;
|
|
354
|
+
/** Original local policy evidence; retained privately at native Run settlement. */
|
|
355
|
+
readonly cause?: Cause.Cause<unknown>;
|
|
356
|
+
};
|
|
357
|
+
/**
|
|
358
|
+
* Exact authority presented before one application Tool Handler may start.
|
|
359
|
+
*
|
|
360
|
+
* `input` is the Agent Schema's encoded Run input. Durable coordinators replace it with the exact
|
|
361
|
+
* canonical Submission input admitted for the logical Run on every Attempt.
|
|
362
|
+
* `call` is the exact still-executable call being authorized. Recorded settled calls are never
|
|
363
|
+
* reauthorized because no Handler can start for them.
|
|
364
|
+
*/
|
|
365
|
+
interface RunToolAuthorizationRequest {
|
|
366
|
+
readonly frameworkMessage?: FrameworkMessage;
|
|
367
|
+
readonly threadId: ThreadId;
|
|
368
|
+
readonly runId: RunId;
|
|
369
|
+
readonly turnId: TurnId;
|
|
370
|
+
readonly turn: number;
|
|
371
|
+
readonly input: unknown;
|
|
372
|
+
readonly call: RunToolCallDescriptor;
|
|
373
|
+
/** Present for an ephemeral inner invocation; the outer Tool's approval grants no inner authority. */
|
|
374
|
+
readonly programmatic?: {
|
|
375
|
+
readonly parentToolCallId: ToolCallId;
|
|
376
|
+
readonly sequenceIndex: number;
|
|
377
|
+
} | undefined;
|
|
378
|
+
}
|
|
379
|
+
/** Host policy invoked before each executable native or programmatic application call. */
|
|
380
|
+
interface RunToolAuthorizationHook<Error = never, Requirements = never> {
|
|
381
|
+
readonly authorize: (request: RunToolAuthorizationRequest) => Effect.Effect<RunToolAuthorizationDecision, Error, Requirements>;
|
|
382
|
+
}
|
|
383
|
+
declare const RunContextPreparation_base: Context.ServiceClass<RunContextPreparation, "@effect-agent/engine/RunContextPreparation", {
|
|
384
|
+
/** Optional transformation of the model-visible prompt. */
|
|
385
|
+
readonly hook?: RunContextHook<RunContextPreparationError, never> | undefined;
|
|
386
|
+
/** Optional per-Turn reference context, excluded from history and compaction coverage. */
|
|
387
|
+
readonly transientContext?: RunTransientContextHook<RunContextPreparationError, never> | undefined;
|
|
388
|
+
}>;
|
|
389
|
+
/**
|
|
390
|
+
* Host-owned model-context preparation, independent of action-time Tool authorization.
|
|
391
|
+
*
|
|
392
|
+
* Runs use this service when provided; durable coordinators capture it while their runtime
|
|
393
|
+
* Layer is acquired. Implementations acquire dependencies in their Layer and preserve the
|
|
394
|
+
* declared error tags. Layer acquisition failures belong to the providing Effect, not this union.
|
|
395
|
+
* Without this service, Runs apply no host context loading. Provide `ContextCompactor`
|
|
396
|
+
* separately to select native compaction; neither service replaces `RunToolAuthorization`.
|
|
397
|
+
*/
|
|
398
|
+
declare class RunContextPreparation extends RunContextPreparation_base {}
|
|
399
|
+
/** Explicit no-preparer Layer used by compatible runtime assemblies. */
|
|
400
|
+
declare const RunContextPreparationPassthrough: Layer.Layer<RunContextPreparation>;
|
|
401
|
+
declare const RunToolAuthorization_base: Context.ServiceClass<RunToolAuthorization, "@effect-agent/engine/RunToolAuthorization", RunToolAuthorizationHook<AgentToolAuthorizationCheckError, never>>;
|
|
402
|
+
/**
|
|
403
|
+
* Host action-time authority for native and programmatic application Tools. Implementations close over
|
|
404
|
+
* their dependencies at Layer construction and return a denial when execution is not authorized.
|
|
405
|
+
* A dependency or validation failure instead fails with AgentToolAuthorizationCheckError and
|
|
406
|
+
* retains its original Cause. Defects and interruption remain in the Effect Cause channel.
|
|
407
|
+
* Durable coordinators capture this service once and retain it across replacement Attempts.
|
|
408
|
+
* Ephemeral Runs also resolve this service at their Run boundary. A typed per-run
|
|
409
|
+
* `RunOptions.toolAuthorization` overrides it while retaining its own error and requirement channel.
|
|
410
|
+
*/
|
|
411
|
+
declare class RunToolAuthorization extends RunToolAuthorization_base {
|
|
412
|
+
/** Immutable built-in policy; its identity lets the interpreter omit absent host checks. */
|
|
413
|
+
static readonly allowAllPolicy: RunToolAuthorizationHook;
|
|
414
|
+
/** Explicit compatibility policy: Tool execution requires no additional host authorization. */
|
|
415
|
+
static readonly allowAll: Layer.Layer<RunToolAuthorization>;
|
|
416
|
+
}
|
|
417
|
+
/** Positive concurrency ceiling for one Run. One is sequential; the Agent's bound can only tighten. */
|
|
418
|
+
declare const RunSchedulingOverride: Schema.Int;
|
|
419
|
+
type RunSchedulingOverride = typeof RunSchedulingOverride.Type;
|
|
420
|
+
/** Dependency-neutral scheduling policy surrounding native Effect AI Tool handlers. */
|
|
421
|
+
interface RunSchedulingHook {
|
|
422
|
+
readonly runOverride?: RunSchedulingOverride | undefined;
|
|
423
|
+
readonly toolRequiresSequential?: ((toolName: string) => boolean) | undefined;
|
|
424
|
+
}
|
|
425
|
+
/**
|
|
426
|
+
* Host Tool scheduling, captured by durable runtimes across replacement Attempts.
|
|
427
|
+
* The Agent's admitted concurrency remains the upper bound. A sequential Tool
|
|
428
|
+
* forms a barrier around neighboring parallel batches, including on recovery.
|
|
429
|
+
* Ephemeral Runs may override this reference with `RunOptions.scheduling`.
|
|
430
|
+
*/
|
|
431
|
+
declare const RunToolScheduling: Context.Reference<RunSchedulingHook>;
|
|
432
|
+
/**
|
|
433
|
+
* Tightening-only memory limits for one Run. The engine supplies finite ceilings for every field;
|
|
434
|
+
* callers may lower them for a deployment or test but cannot widen the engine defaults.
|
|
435
|
+
*/
|
|
436
|
+
interface RunBufferLimits {
|
|
437
|
+
/** Maximum decoded response parts retained from one model call, including compaction calls. */
|
|
438
|
+
readonly maxModelResponseParts?: number | undefined;
|
|
439
|
+
/** Maximum conservative retained-byte estimate for one model response. */
|
|
440
|
+
readonly maxModelResponseBytes?: number | undefined;
|
|
441
|
+
/** Maximum observed Run events, including the terminal event; headless execution has no event cap. */
|
|
442
|
+
readonly maxRunEvents?: number | undefined;
|
|
443
|
+
/**
|
|
444
|
+
* Maximum cumulative UTF-8 JSON bytes in Tool progress, including unobserved and provider
|
|
445
|
+
* progress. Defaults to 8 MiB. Invalid or oversized application progress
|
|
446
|
+
* fails with ModelProtocolError; terminal Tool results use the Agent's toolResultBounds.
|
|
447
|
+
*/
|
|
448
|
+
readonly maxToolProgressBytes?: number | undefined;
|
|
449
|
+
/** Maximum events buffered by the public stream before its execution producer waits. */
|
|
450
|
+
readonly maxBufferedEvents?: number | undefined;
|
|
451
|
+
}
|
|
452
|
+
/**
|
|
453
|
+
* Application-owned values and hooks for one Run. ThreadHistory.layer retains history
|
|
454
|
+
* incrementally in memory, including completed updates before a failure or interruption.
|
|
455
|
+
* PersistentHistory.layer commits only successful Runs to a ThreadStore. Hook failures and
|
|
456
|
+
* requirements stay visible in the returned Stream / Effect through the generic parameters.
|
|
457
|
+
*/
|
|
458
|
+
interface RunOptions<HookError = never, HookRequirements = never> {
|
|
459
|
+
/** Finite per-Run limits: accepted update count and cumulative UTF-8 JSON value bytes. Defaults: 32 and 16384. */
|
|
460
|
+
readonly updates?: {
|
|
461
|
+
readonly maxCount?: number;
|
|
462
|
+
readonly maxBytes?: number;
|
|
463
|
+
};
|
|
464
|
+
/** Initial or canonically restored run-scoped native selection. */
|
|
465
|
+
readonly toolSelection?: Selection | undefined;
|
|
466
|
+
/**
|
|
467
|
+
* Host preparation boundary before each new or replacement model call, including context preparation
|
|
468
|
+
* and compaction calls. The preceding Tool batch and history advance have finished. A resumed
|
|
469
|
+
* canonical Tool batch bypasses this hook until it continues to a new Turn. This hook does not
|
|
470
|
+
* reset the Run deadline or change prompt protection, and is not automatically inherited by spawned children.
|
|
471
|
+
* Resources acquired here close with the current Turn, before the next Turn starts.
|
|
472
|
+
*/
|
|
473
|
+
readonly beforeTurn?: (() => Effect.Effect<void, HookError, HookRequirements>) | undefined;
|
|
474
|
+
/** Reuse a Thread identity, including retained history, instead of allocating one. */
|
|
475
|
+
readonly threadId?: ThreadId | undefined;
|
|
476
|
+
/**
|
|
477
|
+
* Preallocated Run identity used instead of `IdGenerator` when supplied.
|
|
478
|
+
* The S1 Subagent seam preallocates child Run identity through this option
|
|
479
|
+
* so `SubagentRequested` can carry the intended child identity.
|
|
480
|
+
*/
|
|
481
|
+
readonly runId?: RunId | undefined;
|
|
482
|
+
/**
|
|
483
|
+
* Seed or append-only extension for an in-memory Thread. ThreadHistory.layer retains this
|
|
484
|
+
* prefix before execution and rejects replacement of existing messages. The engine appends
|
|
485
|
+
* this Run's evaluated instructions and rendered input. PersistentHistory rejects this option;
|
|
486
|
+
* durable hosts supply the history reconstructed from their journal.
|
|
487
|
+
*/
|
|
488
|
+
readonly history?: Prompt.Prompt | undefined;
|
|
489
|
+
readonly commandDrainPolicy?: CommandDrainPolicy | undefined;
|
|
490
|
+
readonly input?: RunInputHook<HookError, HookRequirements> | undefined;
|
|
491
|
+
readonly approval?: RunApprovalHook<HookError, HookRequirements> | undefined;
|
|
492
|
+
/** Per-Run override of RunContextPreparation.hook, preserving application-specific E/R. */
|
|
493
|
+
readonly context?: RunContextHook<HookError, HookRequirements> | undefined;
|
|
494
|
+
/**
|
|
495
|
+
* Per-Run override of RunContextPreparation.transientContext. Use the service
|
|
496
|
+
* for host configuration; this generic hook preserves application-specific E/R.
|
|
497
|
+
* Model-visible reference context is loaded for each Turn, including a grace
|
|
498
|
+
* finalization Turn and a Turn reconstructed by durable recovery. The engine
|
|
499
|
+
* validates and budgets the result but never adds it to official history or
|
|
500
|
+
* compaction coverage. A same-Turn provider-overflow retry reuses the Turn's
|
|
501
|
+
* loaded snapshot.
|
|
502
|
+
*/
|
|
503
|
+
readonly transientContext?: RunTransientContextHook<HookError, HookRequirements> | undefined;
|
|
504
|
+
readonly budget?: RunBudgetHook<HookError, HookRequirements> | undefined;
|
|
505
|
+
/**
|
|
506
|
+
* Host-owned action-time authorization for model-declared application Tool batches. The engine
|
|
507
|
+
* uses this per-Run override when present, otherwise the provided RunToolAuthorization service.
|
|
508
|
+
* It invokes the policy for every still-executable call after complete-batch validation and approval, but
|
|
509
|
+
* before the durable dispatch fence or any Handler permit. A resumed durable batch invokes it again
|
|
510
|
+
* with the same canonical Run/Turn/input authority and Tool Call identity. Programmatic
|
|
511
|
+
* `ToolBroker` calls invoke it after schema/visibility checks and before budget reservation or
|
|
512
|
+
* execution, with their parent identity in `programmatic`. Inner denials become catchable
|
|
513
|
+
* outcomes; other independent calls may already have completed.
|
|
514
|
+
*/
|
|
515
|
+
readonly toolAuthorization?: RunToolAuthorizationHook<HookError, HookRequirements> | undefined;
|
|
516
|
+
/**
|
|
517
|
+
* Optional absolute deadline for the Run's `maxDuration` rail. The engine
|
|
518
|
+
* uses the earlier of this value and the fresh policy deadline, so callers
|
|
519
|
+
* may preserve or tighten an existing Run allowance but can never widen it.
|
|
520
|
+
* Durable coordinators reuse the canonical per-Attempt duration allowance;
|
|
521
|
+
* deployment downtime does not consume it. An immutable worker grant can
|
|
522
|
+
* impose an earlier absolute expiry. Turn, Tool and cost budgets remain Run-wide.
|
|
523
|
+
*/
|
|
524
|
+
readonly durationDeadline?: DateTime.Utc | undefined;
|
|
525
|
+
/**
|
|
526
|
+
* Per-Run Tool Call allowance (RUN-021): a TIGHTENING-ONLY bound below the
|
|
527
|
+
* Agent Policy's `maxToolCalls` — the effective limit is
|
|
528
|
+
* `min(policy.maxToolCalls, max(1, floor(toolCallAllowance)))`, so an
|
|
529
|
+
* allowance can never widen the Definition's ceiling. The `onExhaustion`
|
|
530
|
+
* resolution (RUN-018) keys off the effective limit, which is how an
|
|
531
|
+
* orchestrator grants a delegated child a budget extension by re-invoking
|
|
532
|
+
* with a larger allowance up to the child Definition's policy.
|
|
533
|
+
*/
|
|
534
|
+
readonly toolCallAllowance?: number | undefined;
|
|
535
|
+
/**
|
|
536
|
+
* Per-Run Turn allowance (RUN-021): tightening-only below the Agent
|
|
537
|
+
* Policy's `maxTurns`, with the same normalization and the same
|
|
538
|
+
* `onExhaustion` resolution (RUN-019 grace) at the effective limit.
|
|
539
|
+
*/
|
|
540
|
+
readonly turnAllowance?: number | undefined;
|
|
541
|
+
/** Required when the core policy declares `costBudgetMicrousd`. */
|
|
542
|
+
readonly estimateCostMicrousd?: RunCostEstimator<HookError, HookRequirements> | undefined;
|
|
543
|
+
readonly scheduling?: RunSchedulingHook | undefined;
|
|
544
|
+
/** Optional tightening-only overrides for the engine's finite in-memory buffer ceilings. */
|
|
545
|
+
readonly bufferLimits?: RunBufferLimits | undefined;
|
|
546
|
+
/**
|
|
547
|
+
* Incremental history observer. ThreadHistory.layer retains each complete update first.
|
|
548
|
+
* Invoked inline with the source Prompt and its retained compacted model context whenever
|
|
549
|
+
* official history advances, including initial
|
|
550
|
+
* instructions/input before the first model call. It can write before the Run succeeds or its
|
|
551
|
+
* resources close. Failure stops execution through HookError; defects and interruption propagate.
|
|
552
|
+
* Earlier callback writes are caller-owned and are not rolled back if this or a later step fails.
|
|
553
|
+
* PersistentHistory's on-success adapter rejects this hook;
|
|
554
|
+
* the durable coordinator uses it for live Prompt state while its journal owns durable commits.
|
|
555
|
+
*/
|
|
556
|
+
readonly onHistory?: ((history: Prompt.Prompt, modelContext: Prompt.Prompt) => Effect.Effect<void, HookError, HookRequirements>) | undefined;
|
|
557
|
+
}
|
|
558
|
+
type RunOptionsError<Options> = Options extends RunOptions<infer Error, infer _Requirements> ? Error : never;
|
|
559
|
+
type RunOptionsRequirements<Options> = Options extends RunOptions<infer _Error, infer Requirements> ? Requirements : never;
|
|
560
|
+
export { RunToolAuthorizationDecision as A, RunOptions as C, RunSchedulingHook as D, RunOptions_d_exports as E, RunToolScheduling as F, RunTransientContextHook as I, RunUsageDelta as L, RunToolAuthorizationRequest as M, RunToolCallDescriptor as N, RunSchedulingOverride as O, RunToolFailureObserver as P, ToolFailureObservation as R, RunInputHook as S, RunOptionsRequirements as T, RunContextRequest as _, ProgrammaticPreflightFailure as a, RunCostEstimator as b, RunApprovalDecision as c, RunBudgetHook as d, RunBufferLimits as f, RunContextPreparationPassthrough as g, RunContextPreparationError as h, PreparedRunContext as i, RunToolAuthorizationHook as j, RunToolAuthorization as k, RunApprovalHook as l, RunContextPreparation as m, CurrentToolFailureObserver as n, ProgrammaticToolFailure as o, RunContextHook as p, ModelToolFailure as r, ResolvedModelCall as s, CommandDrainPolicy as t, RunApprovalRequest as u, RunCostEstimate as v, RunOptionsError as w, RunInputCommand as x, RunCostEstimateRequest as y, toolFailureObserverLayer as z };
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { t as __exportAll } from "./rolldown-runtime-D3KUYPsf.mjs";
|
|
2
|
+
import * as Context from "effect/Context";
|
|
3
|
+
import * as Effect from "effect/Effect";
|
|
4
|
+
import * as Layer from "effect/Layer";
|
|
5
|
+
import * as Schema from "effect/Schema";
|
|
6
|
+
// src/engine/RunOptions.ts
|
|
7
|
+
var RunOptions_exports = /* @__PURE__ */ __exportAll({
|
|
8
|
+
CommandDrainPolicy: () => CommandDrainPolicy,
|
|
9
|
+
CurrentToolFailureObserver: () => CurrentToolFailureObserver,
|
|
10
|
+
RunContextPreparation: () => RunContextPreparation,
|
|
11
|
+
RunContextPreparationPassthrough: () => RunContextPreparationPassthrough,
|
|
12
|
+
RunSchedulingOverride: () => RunSchedulingOverride,
|
|
13
|
+
RunToolAuthorization: () => RunToolAuthorization,
|
|
14
|
+
RunToolScheduling: () => RunToolScheduling,
|
|
15
|
+
toolFailureObserverLayer: () => toolFailureObserverLayer
|
|
16
|
+
});
|
|
17
|
+
/** Resolved once per Run; durable coordinators capture it at Layer acquisition. Default absent. */
|
|
18
|
+
const CurrentToolFailureObserver = Context.Reference("@effect-agent/engine/CurrentToolFailureObserver", { defaultValue: () => void 0 });
|
|
19
|
+
/** The sole installation seam, shared by ephemeral Runs and durable platform options. */
|
|
20
|
+
const toolFailureObserverLayer = (observer) => Layer.succeed(CurrentToolFailureObserver)(observer);
|
|
21
|
+
/** Number of queued inputs consumed at one documented Turn seam. */
|
|
22
|
+
const CommandDrainPolicy = Schema.Literals(["one", "all"]);
|
|
23
|
+
/**
|
|
24
|
+
* Host-owned model-context preparation, independent of action-time Tool authorization.
|
|
25
|
+
*
|
|
26
|
+
* Runs use this service when provided; durable coordinators capture it while their runtime
|
|
27
|
+
* Layer is acquired. Implementations acquire dependencies in their Layer and preserve the
|
|
28
|
+
* declared error tags. Layer acquisition failures belong to the providing Effect, not this union.
|
|
29
|
+
* Without this service, Runs apply no host context loading. Provide `ContextCompactor`
|
|
30
|
+
* separately to select native compaction; neither service replaces `RunToolAuthorization`.
|
|
31
|
+
*/
|
|
32
|
+
var RunContextPreparation = class extends Context.Service()("@effect-agent/engine/RunContextPreparation") {};
|
|
33
|
+
/** Explicit no-preparer Layer used by compatible runtime assemblies. */
|
|
34
|
+
const RunContextPreparationPassthrough = Layer.succeed(RunContextPreparation)({});
|
|
35
|
+
/**
|
|
36
|
+
* Host action-time authority for native and programmatic application Tools. Implementations close over
|
|
37
|
+
* their dependencies at Layer construction and return a denial when execution is not authorized.
|
|
38
|
+
* A dependency or validation failure instead fails with AgentToolAuthorizationCheckError and
|
|
39
|
+
* retains its original Cause. Defects and interruption remain in the Effect Cause channel.
|
|
40
|
+
* Durable coordinators capture this service once and retain it across replacement Attempts.
|
|
41
|
+
* Ephemeral Runs also resolve this service at their Run boundary. A typed per-run
|
|
42
|
+
* `RunOptions.toolAuthorization` overrides it while retaining its own error and requirement channel.
|
|
43
|
+
*/
|
|
44
|
+
var RunToolAuthorization = class RunToolAuthorization extends Context.Service()("@effect-agent/engine/RunToolAuthorization") {
|
|
45
|
+
/** Immutable built-in policy; its identity lets the interpreter omit absent host checks. */
|
|
46
|
+
static allowAllPolicy = Object.freeze({ authorize: () => Effect.succeed({ _tag: "allowed" }) });
|
|
47
|
+
/** Explicit compatibility policy: Tool execution requires no additional host authorization. */
|
|
48
|
+
static allowAll = Layer.succeed(RunToolAuthorization, RunToolAuthorization.allowAllPolicy);
|
|
49
|
+
};
|
|
50
|
+
/** Positive concurrency ceiling for one Run. One is sequential; the Agent's bound can only tighten. */
|
|
51
|
+
const RunSchedulingOverride = Schema.Int.check(Schema.isGreaterThan(0));
|
|
52
|
+
/**
|
|
53
|
+
* Host Tool scheduling, captured by durable runtimes across replacement Attempts.
|
|
54
|
+
* The Agent's admitted concurrency remains the upper bound. A sequential Tool
|
|
55
|
+
* forms a barrier around neighboring parallel batches, including on recovery.
|
|
56
|
+
* Ephemeral Runs may override this reference with `RunOptions.scheduling`.
|
|
57
|
+
*/
|
|
58
|
+
const RunToolScheduling = Context.Reference("@effect-agent/engine/RunToolScheduling", { defaultValue: () => ({}) });
|
|
59
|
+
export { RunOptions_exports as a, RunToolScheduling as c, RunContextPreparationPassthrough as i, toolFailureObserverLayer as l, CurrentToolFailureObserver as n, RunSchedulingOverride as o, RunContextPreparation as r, RunToolAuthorization as s, CommandDrainPolicy as t };
|
|
60
|
+
|
|
61
|
+
//# sourceMappingURL=RunOptions-COEUCrx4.mjs.map
|