@e4779/pi-fabric 0.117.2-fork.30 → 0.131.0-fork.32

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.
Files changed (796) hide show
  1. package/README.md +12 -5
  2. package/THIRD_PARTY_NOTICES.md +6 -14
  3. package/dist/activity/store.d.ts +2 -1
  4. package/dist/activity/store.d.ts.map +1 -1
  5. package/dist/actors/binding-store.d.ts +13 -0
  6. package/dist/actors/binding-store.d.ts.map +1 -1
  7. package/dist/actors/directory.d.ts.map +1 -1
  8. package/dist/actors/global-registry.d.ts +8 -0
  9. package/dist/actors/global-registry.d.ts.map +1 -1
  10. package/dist/actors/host-event-payload.d.ts +14 -0
  11. package/dist/actors/host-event-payload.d.ts.map +1 -1
  12. package/dist/actors/manager.d.ts +4 -3
  13. package/dist/actors/manager.d.ts.map +1 -1
  14. package/dist/actors/mesh-monitor.d.ts +2 -0
  15. package/dist/actors/mesh-monitor.d.ts.map +1 -1
  16. package/dist/actors/name-policy.d.ts +3 -0
  17. package/dist/actors/name-policy.d.ts.map +1 -0
  18. package/dist/actors/registry-store.d.ts +14 -5
  19. package/dist/actors/registry-store.d.ts.map +1 -1
  20. package/dist/actors/store-read.d.ts +16 -0
  21. package/dist/actors/store-read.d.ts.map +1 -0
  22. package/dist/agents/agent-files.d.ts +80 -0
  23. package/dist/agents/agent-files.d.ts.map +1 -0
  24. package/dist/agents/agent-files.js +327 -0
  25. package/dist/agents/agent-files.js.map +7 -0
  26. package/dist/agents/child-skills.d.ts +60 -0
  27. package/dist/agents/child-skills.d.ts.map +1 -0
  28. package/dist/agents/child-skills.js +94 -0
  29. package/dist/agents/child-skills.js.map +7 -0
  30. package/dist/agents/clone-first-worktree.d.ts +6 -0
  31. package/dist/agents/clone-first-worktree.d.ts.map +1 -1
  32. package/dist/agents/cow-clone.d.ts.map +1 -1
  33. package/dist/agents/handoff.d.ts +12 -2
  34. package/dist/agents/handoff.d.ts.map +1 -1
  35. package/dist/agents/herdr-status.d.ts +26 -0
  36. package/dist/agents/herdr-status.d.ts.map +1 -0
  37. package/dist/agents/herdr-status.js +161 -0
  38. package/dist/agents/herdr-status.js.map +7 -0
  39. package/dist/agents/hosted-run.d.ts +20 -4
  40. package/dist/agents/hosted-run.d.ts.map +1 -1
  41. package/dist/agents/manager.d.ts +18 -2
  42. package/dist/agents/manager.d.ts.map +1 -1
  43. package/dist/agents/model-pin-guard.d.ts +27 -0
  44. package/dist/agents/model-pin-guard.d.ts.map +1 -0
  45. package/dist/agents/model-pin-guard.js +86 -0
  46. package/dist/agents/model-pin-guard.js.map +7 -0
  47. package/dist/agents/model-pin.d.ts +25 -0
  48. package/dist/agents/model-pin.d.ts.map +1 -0
  49. package/dist/agents/provider-bridge.d.ts +7 -6
  50. package/dist/agents/provider-bridge.d.ts.map +1 -1
  51. package/dist/agents/provider-bridge.js +33 -5
  52. package/dist/agents/provider-bridge.js.map +3 -3
  53. package/dist/agents/request.d.ts.map +1 -1
  54. package/dist/agents/result.d.ts.map +1 -1
  55. package/dist/agents/result.js +1 -1
  56. package/dist/agents/runner-notice.d.ts.map +1 -1
  57. package/dist/agents/runner-protocol.d.ts +8 -0
  58. package/dist/agents/runner-protocol.d.ts.map +1 -1
  59. package/dist/agents/service-schema.d.ts.map +1 -1
  60. package/dist/agents/transports/herdr-socket.d.ts +12 -0
  61. package/dist/agents/transports/herdr-socket.d.ts.map +1 -0
  62. package/dist/agents/transports/herdr-transport.d.ts.map +1 -1
  63. package/dist/agents/types.d.ts +51 -0
  64. package/dist/agents/types.d.ts.map +1 -1
  65. package/dist/agents/worker-recovery.d.ts +75 -0
  66. package/dist/agents/worker-recovery.d.ts.map +1 -0
  67. package/dist/agents/worktree-manager.d.ts.map +1 -1
  68. package/dist/agents.js +12 -11
  69. package/dist/agents.js.map +2 -2
  70. package/dist/audit/details.d.ts +36 -1
  71. package/dist/audit/details.d.ts.map +1 -1
  72. package/dist/audit/projection.d.ts.map +1 -1
  73. package/dist/audit/trace-schema.d.ts +50 -0
  74. package/dist/audit/trace-schema.d.ts.map +1 -0
  75. package/dist/audit/trace.d.ts +2 -48
  76. package/dist/audit/trace.d.ts.map +1 -1
  77. package/dist/chunks/chunk-2RWNVCFD.js +483 -0
  78. package/dist/chunks/chunk-2RWNVCFD.js.map +7 -0
  79. package/dist/chunks/chunk-2SCMGO2Z.js +16 -0
  80. package/dist/chunks/chunk-2SCMGO2Z.js.map +7 -0
  81. package/dist/chunks/chunk-35EEGOH3.js +324 -0
  82. package/dist/chunks/chunk-35EEGOH3.js.map +7 -0
  83. package/dist/chunks/{chunk-3FJUP3GV.js → chunk-36XQFTEN.js} +2 -2
  84. package/dist/chunks/{chunk-UTOBAZ5T.js → chunk-37NIOSVU.js} +1 -1
  85. package/dist/chunks/chunk-37NIOSVU.js.map +7 -0
  86. package/dist/chunks/chunk-3IJEQBFS.js +25 -0
  87. package/dist/chunks/chunk-3IJEQBFS.js.map +7 -0
  88. package/dist/chunks/{chunk-EHQQ4KCX.js → chunk-3MOY6WIB.js} +84 -19
  89. package/dist/chunks/chunk-3MOY6WIB.js.map +7 -0
  90. package/dist/chunks/chunk-3PKZSIRA.js +1312 -0
  91. package/dist/chunks/chunk-3PKZSIRA.js.map +7 -0
  92. package/dist/chunks/chunk-3VK6UGAN.js +64 -0
  93. package/dist/chunks/chunk-3VK6UGAN.js.map +7 -0
  94. package/dist/chunks/{chunk-ROTCDDOV.js → chunk-3XT5WHSG.js} +59 -119
  95. package/dist/chunks/chunk-3XT5WHSG.js.map +7 -0
  96. package/dist/chunks/{chunk-FIDUHKMM.js → chunk-4BYS4ZLY.js} +16 -16
  97. package/dist/chunks/chunk-4BYS4ZLY.js.map +7 -0
  98. package/dist/chunks/{chunk-K7J2ABAZ.js → chunk-4KX6BIPL.js} +91 -31
  99. package/dist/chunks/chunk-4KX6BIPL.js.map +7 -0
  100. package/dist/chunks/{chunk-UOM37PE4.js → chunk-4PBW54I2.js} +162 -92
  101. package/dist/chunks/chunk-4PBW54I2.js.map +7 -0
  102. package/dist/chunks/{chunk-ZEXCKK4K.js → chunk-4WKD3YM3.js} +3 -3
  103. package/dist/chunks/{chunk-PK4NIJEV.js → chunk-4XMXFHAR.js} +62 -3
  104. package/dist/chunks/chunk-4XMXFHAR.js.map +7 -0
  105. package/dist/chunks/{chunk-4EW7GVUR.js → chunk-56NMRVTV.js} +589 -377
  106. package/dist/chunks/chunk-56NMRVTV.js.map +7 -0
  107. package/dist/chunks/{chunk-GIK2WNAK.js → chunk-5BOTHX47.js} +109 -20
  108. package/dist/chunks/chunk-5BOTHX47.js.map +7 -0
  109. package/dist/chunks/chunk-5QJFDKPN.js +179 -0
  110. package/dist/chunks/chunk-5QJFDKPN.js.map +7 -0
  111. package/dist/chunks/{chunk-P7CBPPHY.js → chunk-6GWDGTHC.js} +5 -5
  112. package/dist/chunks/{chunk-P7CBPPHY.js.map → chunk-6GWDGTHC.js.map} +1 -1
  113. package/dist/chunks/chunk-6HO2IUQ5.js +104 -0
  114. package/dist/chunks/chunk-6HO2IUQ5.js.map +7 -0
  115. package/dist/chunks/chunk-6OGYPHNQ.js +62 -0
  116. package/dist/chunks/chunk-6OGYPHNQ.js.map +7 -0
  117. package/dist/chunks/{chunk-GO32KSEZ.js → chunk-7CIES6X2.js} +84 -9
  118. package/dist/chunks/chunk-7CIES6X2.js.map +7 -0
  119. package/dist/chunks/{chunk-G4TLWHRS.js → chunk-7N7IC3Z2.js} +4 -3
  120. package/dist/chunks/{chunk-G4TLWHRS.js.map → chunk-7N7IC3Z2.js.map} +2 -2
  121. package/dist/chunks/{chunk-5XBYFSI5.js → chunk-7YNE4NB2.js} +2 -2
  122. package/dist/chunks/{chunk-NTC2MCB6.js → chunk-B5L3X3ID.js} +1 -1
  123. package/dist/chunks/{chunk-NTC2MCB6.js.map → chunk-B5L3X3ID.js.map} +1 -1
  124. package/dist/chunks/chunk-BIBRWZWQ.js +325 -0
  125. package/dist/chunks/chunk-BIBRWZWQ.js.map +7 -0
  126. package/dist/chunks/{chunk-K6QXUGS5.js → chunk-BMAEZNZ5.js} +2 -1
  127. package/dist/chunks/{chunk-FSB2VIRZ.js → chunk-CBIV747V.js} +14 -3
  128. package/dist/chunks/chunk-CBIV747V.js.map +7 -0
  129. package/dist/chunks/{chunk-CCHZXF6K.js → chunk-CXYJJ3HZ.js} +3 -3
  130. package/dist/chunks/{chunk-R2XQ6AHT.js → chunk-DGERP4VL.js} +22 -10
  131. package/dist/chunks/chunk-DGERP4VL.js.map +7 -0
  132. package/dist/chunks/chunk-F2LGSRIN.js +38 -0
  133. package/dist/chunks/chunk-F2LGSRIN.js.map +7 -0
  134. package/dist/chunks/chunk-F6A6MQ6G.js +609 -0
  135. package/dist/chunks/chunk-F6A6MQ6G.js.map +7 -0
  136. package/dist/chunks/{chunk-IR3PIHJM.js → chunk-FK73YJKV.js} +67 -2
  137. package/dist/chunks/chunk-FK73YJKV.js.map +7 -0
  138. package/dist/chunks/{chunk-VYQV5JRT.js → chunk-GJVKEHDL.js} +2 -2
  139. package/dist/chunks/chunk-GJVKEHDL.js.map +7 -0
  140. package/dist/chunks/{chunk-TIIIHPHF.js → chunk-GS67KDMV.js} +2 -2
  141. package/dist/chunks/{chunk-D5NYNIST.js → chunk-H57KPL3V.js} +5 -5
  142. package/dist/chunks/{chunk-KVYNGDGC.js → chunk-HFDJWLMS.js} +6 -6
  143. package/dist/chunks/{chunk-KVYNGDGC.js.map → chunk-HFDJWLMS.js.map} +1 -1
  144. package/dist/chunks/{chunk-INRXG4J5.js → chunk-HGD75NZY.js} +2 -2
  145. package/dist/chunks/{chunk-CRRUW26I.js → chunk-HRDMBGMY.js} +12 -12
  146. package/dist/chunks/{chunk-CRRUW26I.js.map → chunk-HRDMBGMY.js.map} +2 -2
  147. package/dist/chunks/{chunk-MLLYR3Y6.js → chunk-HSEZPCL5.js} +19 -78
  148. package/dist/chunks/chunk-HSEZPCL5.js.map +7 -0
  149. package/dist/chunks/{chunk-LNASO4VT.js → chunk-IOGDTIGN.js} +44 -19
  150. package/dist/chunks/chunk-IOGDTIGN.js.map +7 -0
  151. package/dist/chunks/chunk-JMUUNW2H.js +65 -0
  152. package/dist/chunks/chunk-JMUUNW2H.js.map +7 -0
  153. package/dist/chunks/{chunk-UXIBKMUM.js → chunk-KIFOEBYJ.js} +4 -4
  154. package/dist/chunks/{chunk-SPCJXN4K.js → chunk-LKYLD5SN.js} +298 -65
  155. package/dist/chunks/chunk-LKYLD5SN.js.map +7 -0
  156. package/dist/chunks/{chunk-FUY6XVRX.js → chunk-MPMEK3IQ.js} +2 -2
  157. package/dist/chunks/{chunk-HP5P7NBO.js → chunk-MSDL7U6Q.js} +4 -4
  158. package/dist/chunks/chunk-N7ZAK2PB.js +132 -0
  159. package/dist/chunks/chunk-N7ZAK2PB.js.map +7 -0
  160. package/dist/chunks/{chunk-VSDUSNIA.js → chunk-NBIYYMKS.js} +8 -2
  161. package/dist/chunks/chunk-NBIYYMKS.js.map +7 -0
  162. package/dist/chunks/chunk-NENQZCGW.js +45 -0
  163. package/dist/chunks/chunk-NENQZCGW.js.map +7 -0
  164. package/dist/chunks/chunk-NJHJKINP.js +47 -0
  165. package/dist/chunks/chunk-NJHJKINP.js.map +7 -0
  166. package/dist/chunks/{chunk-U366I5K2.js → chunk-NQ7IWEIF.js} +18 -6
  167. package/dist/chunks/chunk-NQ7IWEIF.js.map +7 -0
  168. package/dist/chunks/{chunk-ZQMBS5SH.js → chunk-OJ4HAALD.js} +15 -12
  169. package/dist/chunks/chunk-OJ4HAALD.js.map +7 -0
  170. package/dist/chunks/chunk-OZCJU3PZ.js +33 -0
  171. package/dist/chunks/chunk-OZCJU3PZ.js.map +7 -0
  172. package/dist/chunks/chunk-P3DCXKL3.js +40 -0
  173. package/dist/chunks/chunk-P3DCXKL3.js.map +7 -0
  174. package/dist/chunks/chunk-P7YSPKTM.js +294 -0
  175. package/dist/chunks/chunk-P7YSPKTM.js.map +7 -0
  176. package/dist/chunks/chunk-PQVUMJ5J.js +223 -0
  177. package/dist/chunks/chunk-PQVUMJ5J.js.map +7 -0
  178. package/dist/chunks/chunk-PUBHBEYO.js +84 -0
  179. package/dist/chunks/chunk-PUBHBEYO.js.map +7 -0
  180. package/dist/chunks/{chunk-P4KH4S4S.js → chunk-QGTD3LAZ.js} +5 -20
  181. package/dist/chunks/chunk-QGTD3LAZ.js.map +7 -0
  182. package/dist/chunks/{chunk-TIJ3YQXX.js → chunk-QOEOKW2X.js} +2 -2
  183. package/dist/chunks/{chunk-TIJ3YQXX.js.map → chunk-QOEOKW2X.js.map} +1 -1
  184. package/dist/chunks/{chunk-QT4W5YVB.js → chunk-RAA3FAYZ.js} +2 -2
  185. package/dist/chunks/{chunk-WJJXODAB.js → chunk-RLKRZXSX.js} +8 -1
  186. package/dist/chunks/{chunk-WJJXODAB.js.map → chunk-RLKRZXSX.js.map} +2 -2
  187. package/dist/chunks/chunk-RWKQ5SRW.js +129 -0
  188. package/dist/chunks/chunk-RWKQ5SRW.js.map +7 -0
  189. package/dist/chunks/chunk-SW25R47N.js +71 -0
  190. package/dist/chunks/chunk-SW25R47N.js.map +7 -0
  191. package/dist/chunks/{chunk-EFETPXU2.js → chunk-TJZYM2SP.js} +118 -237
  192. package/dist/chunks/chunk-TJZYM2SP.js.map +7 -0
  193. package/dist/chunks/{chunk-53N2I4QA.js → chunk-TXCNZCZP.js} +2 -2
  194. package/dist/chunks/chunk-UD7LFV43.js +28 -0
  195. package/dist/chunks/chunk-UD7LFV43.js.map +7 -0
  196. package/dist/chunks/{chunk-ASSLHWZS.js → chunk-UFMYN5TA.js} +2 -2
  197. package/dist/chunks/{chunk-7QKKLBHJ.js → chunk-UPMWLOKL.js} +10 -1
  198. package/dist/chunks/{chunk-7QKKLBHJ.js.map → chunk-UPMWLOKL.js.map} +2 -2
  199. package/dist/chunks/chunk-V4OW2ULC.js +422 -0
  200. package/dist/chunks/chunk-V4OW2ULC.js.map +7 -0
  201. package/dist/chunks/{chunk-FE6NOAO7.js → chunk-VNWQIGQL.js} +1820 -649
  202. package/dist/chunks/chunk-VNWQIGQL.js.map +7 -0
  203. package/dist/chunks/{chunk-PYFJW3HC.js → chunk-W5FEHVZA.js} +2 -16
  204. package/dist/chunks/{chunk-PYFJW3HC.js.map → chunk-W5FEHVZA.js.map} +3 -3
  205. package/dist/chunks/{chunk-XCEEQ5AB.js → chunk-WGMCNCP6.js} +1567 -1564
  206. package/dist/chunks/chunk-WGMCNCP6.js.map +7 -0
  207. package/dist/chunks/chunk-WKFRGICG.js +101 -0
  208. package/dist/chunks/chunk-WKFRGICG.js.map +7 -0
  209. package/dist/chunks/{chunk-3UGN25XS.js → chunk-WWTGWGH7.js} +80 -1662
  210. package/dist/chunks/chunk-WWTGWGH7.js.map +7 -0
  211. package/dist/chunks/{chunk-5UBRGTVN.js → chunk-X7QETPBC.js} +31 -15
  212. package/dist/chunks/chunk-X7QETPBC.js.map +7 -0
  213. package/dist/chunks/{chunk-LEU5CDSL.js → chunk-XFOSUGLU.js} +5 -5
  214. package/dist/chunks/{chunk-MZUC6LLH.js → chunk-XMYG2TKR.js} +4 -4
  215. package/dist/chunks/{chunk-MZUC6LLH.js.map → chunk-XMYG2TKR.js.map} +1 -1
  216. package/dist/chunks/chunk-YC65P7ZO.js +57 -0
  217. package/dist/chunks/chunk-YC65P7ZO.js.map +7 -0
  218. package/dist/chunks/{chunk-EKODKR6Y.js → chunk-YHFWMAQ5.js} +1 -24
  219. package/dist/chunks/chunk-YHFWMAQ5.js.map +7 -0
  220. package/dist/chunks/{chunk-C7Z6F3SO.js → chunk-ZFWICFNJ.js} +27 -20
  221. package/dist/chunks/{chunk-C7Z6F3SO.js.map → chunk-ZFWICFNJ.js.map} +2 -2
  222. package/dist/cli/decisions.d.ts.map +1 -1
  223. package/dist/cli/decisions.js +15 -3
  224. package/dist/cli/decisions.js.map +2 -2
  225. package/dist/cli/mesh.js +4 -3
  226. package/dist/cli/mesh.js.map +1 -1
  227. package/dist/commands/fabric-handler.d.ts +7 -0
  228. package/dist/commands/fabric-handler.d.ts.map +1 -0
  229. package/dist/commands/fabric-handler.js +916 -0
  230. package/dist/commands/fabric-handler.js.map +7 -0
  231. package/dist/commands/fabric.d.ts +11 -1
  232. package/dist/commands/fabric.d.ts.map +1 -1
  233. package/dist/compaction/claim-events.d.ts +61 -0
  234. package/dist/compaction/claim-events.d.ts.map +1 -0
  235. package/dist/compaction/claim-events.js +210 -0
  236. package/dist/compaction/claim-events.js.map +7 -0
  237. package/dist/compaction/claim.d.ts +51 -0
  238. package/dist/compaction/claim.d.ts.map +1 -0
  239. package/dist/compaction/hook.d.ts +28 -2
  240. package/dist/compaction/hook.d.ts.map +1 -1
  241. package/dist/compaction/hook.js +12 -7
  242. package/dist/compaction/owner.js +9 -8
  243. package/dist/compaction/trace-events.d.ts +1 -1
  244. package/dist/compaction/trace-events.d.ts.map +1 -1
  245. package/dist/components/configuration.js +6 -6
  246. package/dist/components/effect-scope.d.ts.map +1 -1
  247. package/dist/config.d.ts +39 -2
  248. package/dist/config.d.ts.map +1 -1
  249. package/dist/core/action-arguments.d.ts.map +1 -1
  250. package/dist/core/action-policy-hooks.d.ts +69 -0
  251. package/dist/core/action-policy-hooks.d.ts.map +1 -0
  252. package/dist/core/action-registry.d.ts +31 -10
  253. package/dist/core/action-registry.d.ts.map +1 -1
  254. package/dist/core/action-registry.js +12 -9
  255. package/dist/core/approval-controller.d.ts +23 -3
  256. package/dist/core/approval-controller.d.ts.map +1 -1
  257. package/dist/core/atomic-write.d.ts +164 -0
  258. package/dist/core/atomic-write.d.ts.map +1 -1
  259. package/dist/core/child-tool-allowlist.d.ts +17 -1
  260. package/dist/core/child-tool-allowlist.d.ts.map +1 -1
  261. package/dist/core/compact-controller.d.ts +34 -0
  262. package/dist/core/compact-controller.d.ts.map +1 -1
  263. package/dist/core/core-override-guidance.d.ts +3 -1
  264. package/dist/core/core-override-guidance.d.ts.map +1 -1
  265. package/dist/core/file-lock.d.ts.map +1 -1
  266. package/dist/core/foreground-tools.d.ts +4 -1
  267. package/dist/core/foreground-tools.d.ts.map +1 -1
  268. package/dist/core/host-policy.d.ts +43 -0
  269. package/dist/core/host-policy.d.ts.map +1 -0
  270. package/dist/core/host-sdk-runtime.d.ts.map +1 -1
  271. package/dist/core/host-sdk.d.ts.map +1 -1
  272. package/dist/core/host-sdk.js +1 -1
  273. package/dist/core/managed-host-guidance.d.ts +5 -0
  274. package/dist/core/managed-host-guidance.d.ts.map +1 -0
  275. package/dist/core/model-aliases.d.ts +22 -0
  276. package/dist/core/model-aliases.d.ts.map +1 -0
  277. package/dist/core/model-resolution.d.ts +41 -20
  278. package/dist/core/model-resolution.d.ts.map +1 -1
  279. package/dist/core/native-tool-result.d.ts +1 -0
  280. package/dist/core/native-tool-result.d.ts.map +1 -1
  281. package/dist/core/program-tasks.d.ts +52 -0
  282. package/dist/core/program-tasks.d.ts.map +1 -0
  283. package/dist/core/prompt-guidance.d.ts +5 -0
  284. package/dist/core/prompt-guidance.d.ts.map +1 -0
  285. package/dist/core/prompt-guidance.js +159 -0
  286. package/dist/core/prompt-guidance.js.map +7 -0
  287. package/dist/core/provider-operations.d.ts.map +1 -1
  288. package/dist/core/provider-operations.js +60 -108
  289. package/dist/core/provider-operations.js.map +3 -3
  290. package/dist/core/shell-inbox.d.ts.map +1 -1
  291. package/dist/core/shell-jobs.d.ts +7 -5
  292. package/dist/core/shell-jobs.d.ts.map +1 -1
  293. package/dist/core/shell-timing.d.ts.map +1 -1
  294. package/dist/core/skill-prompt.d.ts +1 -1
  295. package/dist/core/skill-prompt.d.ts.map +1 -1
  296. package/dist/core/skill-references.d.ts +1 -1
  297. package/dist/core/skill-references.d.ts.map +1 -1
  298. package/dist/core/system-guidance.d.ts.map +1 -1
  299. package/dist/core/tool-result-proxy.d.ts.map +1 -1
  300. package/dist/decisions/command.d.ts +2 -1
  301. package/dist/decisions/command.d.ts.map +1 -1
  302. package/dist/decisions/command.js +40 -12
  303. package/dist/decisions/command.js.map +2 -2
  304. package/dist/decisions/events.d.ts +12 -0
  305. package/dist/decisions/events.d.ts.map +1 -0
  306. package/dist/decisions/events.js +130 -0
  307. package/dist/decisions/events.js.map +7 -0
  308. package/dist/decisions/host.d.ts +31 -3
  309. package/dist/decisions/host.d.ts.map +1 -1
  310. package/dist/decisions/render.d.ts +44 -0
  311. package/dist/decisions/render.d.ts.map +1 -0
  312. package/dist/decisions/store.d.ts +8 -0
  313. package/dist/decisions/store.d.ts.map +1 -1
  314. package/dist/durable/agent.d.ts +8 -0
  315. package/dist/durable/agent.d.ts.map +1 -1
  316. package/dist/durable/extension-load-error.d.ts +8 -0
  317. package/dist/durable/extension-load-error.d.ts.map +1 -0
  318. package/dist/durable/session.d.ts +1 -0
  319. package/dist/durable/session.d.ts.map +1 -1
  320. package/dist/durable/worker-host.d.ts +10 -1
  321. package/dist/durable/worker-host.d.ts.map +1 -1
  322. package/dist/durable/worker-host.js +10 -1181
  323. package/dist/durable/worker-host.js.map +4 -4
  324. package/dist/durable/worker-options.d.ts +3 -0
  325. package/dist/durable/worker-options.d.ts.map +1 -1
  326. package/dist/durable/worker-role-seed.d.ts +82 -0
  327. package/dist/durable/worker-role-seed.d.ts.map +1 -0
  328. package/dist/durable/worker.js +43 -4
  329. package/dist/durable/worker.js.map +2 -2
  330. package/dist/durable-controls.d.ts.map +1 -1
  331. package/dist/durable-extension-wasm.d.ts +8 -0
  332. package/dist/durable-extension-wasm.d.ts.map +1 -0
  333. package/dist/durable-extension-wasm.js +32 -0
  334. package/dist/durable-extension-wasm.js.map +7 -0
  335. package/dist/durable-extension.d.ts +94 -0
  336. package/dist/durable-extension.d.ts.map +1 -0
  337. package/dist/durable-extension.js +649 -0
  338. package/dist/durable-extension.js.map +7 -0
  339. package/dist/durable-host.d.ts +8 -0
  340. package/dist/durable-host.d.ts.map +1 -0
  341. package/dist/durable-host.js +20 -0
  342. package/dist/durable-host.js.map +7 -0
  343. package/dist/durable-journal.d.ts +94 -0
  344. package/dist/durable-journal.d.ts.map +1 -0
  345. package/dist/durable.d.ts.map +1 -1
  346. package/dist/durable.js +10 -8
  347. package/dist/durable.js.map +2 -2
  348. package/dist/entropy/index.js +12 -10
  349. package/dist/entropy/pool-store.d.ts.map +1 -1
  350. package/dist/execution-service.d.ts +14 -0
  351. package/dist/execution-service.d.ts.map +1 -1
  352. package/dist/extension-bootstrap.d.ts.map +1 -1
  353. package/dist/extension-bootstrap.js +28 -27
  354. package/dist/extension-bootstrap.js.map +2 -2
  355. package/dist/extension-copy.d.ts +21 -0
  356. package/dist/extension-copy.d.ts.map +1 -0
  357. package/dist/extension-copy.js +90 -0
  358. package/dist/extension-copy.js.map +7 -0
  359. package/dist/extension.d.ts +1 -1
  360. package/dist/extension.d.ts.map +1 -1
  361. package/dist/fabric-exec-arguments.d.ts.map +1 -1
  362. package/dist/fabric-exec-tool.d.ts +2 -1
  363. package/dist/fabric-exec-tool.d.ts.map +1 -1
  364. package/dist/fabric-runtime-state.d.ts +19 -0
  365. package/dist/fabric-runtime-state.d.ts.map +1 -1
  366. package/dist/fabric-runtime-state.js +2125 -786
  367. package/dist/fabric-runtime-state.js.map +4 -4
  368. package/dist/fabric-state.d.ts +44 -1
  369. package/dist/fabric-state.d.ts.map +1 -1
  370. package/dist/index.d.ts +5 -3
  371. package/dist/index.d.ts.map +1 -1
  372. package/dist/index.js +88 -53
  373. package/dist/index.js.map +2 -2
  374. package/dist/jev/client.js +2 -2
  375. package/dist/jev/manager.d.ts +3 -0
  376. package/dist/jev/manager.d.ts.map +1 -1
  377. package/dist/jev/observation.d.ts +1 -1
  378. package/dist/jev/observation.js +6 -6
  379. package/dist/jev-fabric/bridge.d.ts.map +1 -1
  380. package/dist/jev.js +11 -12
  381. package/dist/managed-host.d.ts +13 -0
  382. package/dist/managed-host.d.ts.map +1 -1
  383. package/dist/memory/digest.js +2 -2
  384. package/dist/memory/discovery.js +6 -7
  385. package/dist/memory/file-worker.js +10 -11
  386. package/dist/memory/file-worker.js.map +1 -1
  387. package/dist/memory/normalize.js +5 -6
  388. package/dist/memory/search.js +7 -8
  389. package/dist/memory/worker-provider.js +11 -12
  390. package/dist/memory.js +11 -12
  391. package/dist/memory.js.map +1 -1
  392. package/dist/mesh/grants.d.ts +3 -3
  393. package/dist/mesh/grants.d.ts.map +1 -1
  394. package/dist/mesh/store.d.ts +8 -0
  395. package/dist/mesh/store.d.ts.map +1 -1
  396. package/dist/native-codemode.d.ts.map +1 -1
  397. package/dist/native-tool-catalog.d.ts.map +1 -1
  398. package/dist/native-tool-catalog.js +12 -3
  399. package/dist/native-tool-catalog.js.map +2 -2
  400. package/dist/programs/host.d.ts +18 -6
  401. package/dist/programs/host.d.ts.map +1 -1
  402. package/dist/programs/host.js +71 -47
  403. package/dist/programs/host.js.map +2 -2
  404. package/dist/programs/source.d.ts +11 -0
  405. package/dist/programs/source.d.ts.map +1 -1
  406. package/dist/programs/store.d.ts.map +1 -1
  407. package/dist/protocol.d.ts +504 -8
  408. package/dist/protocol.d.ts.map +1 -1
  409. package/dist/protocol.js +41 -11
  410. package/dist/provider-globals.d.ts +13 -0
  411. package/dist/provider-globals.d.ts.map +1 -0
  412. package/dist/providers/agents-actions.d.ts.map +1 -1
  413. package/dist/providers/agents-provider.d.ts +3 -0
  414. package/dist/providers/agents-provider.d.ts.map +1 -1
  415. package/dist/providers/captured-tools-provider.d.ts +5 -0
  416. package/dist/providers/captured-tools-provider.d.ts.map +1 -1
  417. package/dist/providers/compact-provider.d.ts +4 -1
  418. package/dist/providers/compact-provider.d.ts.map +1 -1
  419. package/dist/providers/components-provider.d.ts.map +1 -1
  420. package/dist/providers/decisions-provider.d.ts +9 -1
  421. package/dist/providers/decisions-provider.d.ts.map +1 -1
  422. package/dist/providers/jev-provider.d.ts +1 -1
  423. package/dist/providers/jev-provider.js +11 -12
  424. package/dist/providers/memory-provider.js +10 -11
  425. package/dist/providers/pi-tools-provider.d.ts +14 -0
  426. package/dist/providers/pi-tools-provider.d.ts.map +1 -1
  427. package/dist/providers/programs-provider.d.ts.map +1 -1
  428. package/dist/providers/sessions-provider.d.ts +7 -0
  429. package/dist/providers/sessions-provider.d.ts.map +1 -1
  430. package/dist/repeat-guard.d.ts +7 -6
  431. package/dist/repeat-guard.d.ts.map +1 -1
  432. package/dist/residency/actor-client.js +3 -3
  433. package/dist/residency/client.d.ts +15 -0
  434. package/dist/residency/client.d.ts.map +1 -1
  435. package/dist/residency/host.d.ts.map +1 -1
  436. package/dist/residency/host.js +34 -23
  437. package/dist/residency/launcher.js +1 -1
  438. package/dist/residency/pi-entry.js +34 -23
  439. package/dist/residency/pi-entry.js.map +1 -1
  440. package/dist/residency/protocol.d.ts +2 -0
  441. package/dist/residency/protocol.d.ts.map +1 -1
  442. package/dist/runners.js +11 -1
  443. package/dist/runners.js.map +2 -2
  444. package/dist/runtime/core-override-guest-types.js +2 -2
  445. package/dist/runtime/cpython-child-source.d.ts.map +1 -1
  446. package/dist/runtime/cpython-runtime.d.ts.map +1 -1
  447. package/dist/runtime/cpython-runtime.js +51 -21
  448. package/dist/runtime/cpython-runtime.js.map +2 -2
  449. package/dist/runtime/deadline-pause.d.ts +2 -0
  450. package/dist/runtime/deadline-pause.d.ts.map +1 -1
  451. package/dist/runtime/dynamic-guest-types.d.ts.map +1 -1
  452. package/dist/runtime/dynamic-guest-types.js +2 -1
  453. package/dist/runtime/exec-journal.d.ts +73 -0
  454. package/dist/runtime/exec-journal.d.ts.map +1 -0
  455. package/dist/runtime/exec-journal.js +335 -0
  456. package/dist/runtime/exec-journal.js.map +7 -0
  457. package/dist/runtime/guest-types.d.ts +3 -2
  458. package/dist/runtime/guest-types.d.ts.map +1 -1
  459. package/dist/runtime/guest-types.js +1 -1
  460. package/dist/runtime/journal-shim.d.ts +3 -0
  461. package/dist/runtime/journal-shim.d.ts.map +1 -0
  462. package/dist/runtime/kernel.d.ts +95 -1
  463. package/dist/runtime/kernel.d.ts.map +1 -1
  464. package/dist/runtime/monty-bridge.d.ts +6 -2
  465. package/dist/runtime/monty-bridge.d.ts.map +1 -1
  466. package/dist/runtime/monty-runtime.d.ts.map +1 -1
  467. package/dist/runtime/monty-runtime.js +27 -15
  468. package/dist/runtime/monty-runtime.js.map +2 -2
  469. package/dist/runtime/native-codemode-guest.d.ts.map +1 -1
  470. package/dist/runtime/node-process-runtime.d.ts.map +1 -1
  471. package/dist/runtime/node-process-runtime.js +7 -5
  472. package/dist/runtime/quickjs-runtime.d.ts +7 -1
  473. package/dist/runtime/quickjs-runtime.d.ts.map +1 -1
  474. package/dist/runtime/quickjs-runtime.js +5 -4
  475. package/dist/runtime/sha256.d.ts +4 -0
  476. package/dist/runtime/sha256.d.ts.map +1 -0
  477. package/dist/runtime/transpile.d.ts +8 -0
  478. package/dist/runtime/transpile.d.ts.map +1 -0
  479. package/dist/runtime/type-checker.d.ts +1 -7
  480. package/dist/runtime/type-checker.d.ts.map +1 -1
  481. package/dist/runtime/type-checker.js +4 -2
  482. package/dist/runtime/typescript-kernel.js +13 -10
  483. package/dist/runtime/typescript-kernel.js.map +1 -1
  484. package/dist/runtime-state-builtins.d.ts.map +1 -1
  485. package/dist/speculation/scanner.js +1 -1
  486. package/dist/speculation/store.d.ts +7 -16
  487. package/dist/speculation/store.d.ts.map +1 -1
  488. package/dist/speculation/types.d.ts +1 -0
  489. package/dist/speculation/types.d.ts.map +1 -1
  490. package/dist/storage/retention.d.ts.map +1 -1
  491. package/dist/topology/participant-directory.d.ts +26 -1
  492. package/dist/topology/participant-directory.d.ts.map +1 -1
  493. package/dist/topology/peer-presence.d.ts.map +1 -1
  494. package/dist/topology/peer-settle.js +11 -0
  495. package/dist/topology/peer-settle.js.map +7 -0
  496. package/dist/topology/session-label-settings.d.ts +13 -0
  497. package/dist/topology/session-label-settings.d.ts.map +1 -0
  498. package/dist/topology/session-label.d.ts +60 -0
  499. package/dist/topology/session-label.d.ts.map +1 -0
  500. package/dist/topology/types.d.ts +27 -0
  501. package/dist/topology/types.d.ts.map +1 -1
  502. package/dist/type-error-guidance.js +1 -1
  503. package/dist/ui/controller.d.ts +1 -0
  504. package/dist/ui/controller.d.ts.map +1 -1
  505. package/dist/ui/conversation-chrome.d.ts.map +1 -1
  506. package/dist/ui/conversation-chrome.js +3 -2
  507. package/dist/ui/conversation-commands.d.ts +1 -1
  508. package/dist/ui/conversation-commands.d.ts.map +1 -1
  509. package/dist/ui/conversation-native-reader.js +2 -2
  510. package/dist/ui/conversation-selection.d.ts +4 -1
  511. package/dist/ui/conversation-selection.d.ts.map +1 -1
  512. package/dist/ui/conversation-targets.d.ts.map +1 -1
  513. package/dist/ui/conversation-targets.js +2 -2
  514. package/dist/ui/conversation.d.ts +25 -24
  515. package/dist/ui/conversation.d.ts.map +1 -1
  516. package/dist/ui/conversation.js +170 -339
  517. package/dist/ui/conversation.js.map +2 -2
  518. package/dist/ui/core-tool-render.d.ts +1 -0
  519. package/dist/ui/core-tool-render.d.ts.map +1 -1
  520. package/dist/ui/dashboard.d.ts.map +1 -1
  521. package/dist/ui/dashboard.js +17 -13
  522. package/dist/ui/dashboard.js.map +2 -2
  523. package/dist/ui/fabric-render.d.ts +6 -0
  524. package/dist/ui/fabric-render.d.ts.map +1 -1
  525. package/dist/ui/footer-dock.d.ts +48 -0
  526. package/dist/ui/footer-dock.d.ts.map +1 -0
  527. package/dist/ui/format.d.ts +7 -0
  528. package/dist/ui/format.d.ts.map +1 -1
  529. package/dist/ui/settings-sections-lifecycle.d.ts.map +1 -1
  530. package/dist/ui/settings-sections-presentation.d.ts.map +1 -1
  531. package/dist/ui/settings-values.d.ts +1 -0
  532. package/dist/ui/settings-values.d.ts.map +1 -1
  533. package/dist/ui/settings.js +59 -18
  534. package/dist/ui/settings.js.map +2 -2
  535. package/dist/ui/shell-hang-keys.d.ts +8 -1
  536. package/dist/ui/shell-hang-keys.d.ts.map +1 -1
  537. package/dist/ui/shell-tasks.d.ts +2 -2
  538. package/dist/ui/shell-tasks.d.ts.map +1 -1
  539. package/dist/ui/shell-tasks.js +27 -94
  540. package/dist/ui/shell-tasks.js.map +2 -2
  541. package/dist/ui/snapshot.d.ts.map +1 -1
  542. package/dist/ui/terminal-title.d.ts +41 -0
  543. package/dist/ui/terminal-title.d.ts.map +1 -0
  544. package/dist/ui/types.d.ts +4 -0
  545. package/dist/ui/types.d.ts.map +1 -1
  546. package/dist/ui/widget-keys.d.ts +5 -0
  547. package/dist/ui/widget-keys.d.ts.map +1 -0
  548. package/dist/ui/widget.d.ts +34 -16
  549. package/dist/ui/widget.d.ts.map +1 -1
  550. package/dist/ui/word-diff/line-emphasis.js +1603 -0
  551. package/dist/ui/word-diff/line-emphasis.js.map +7 -0
  552. package/dist/util.d.ts +2 -0
  553. package/dist/util.d.ts.map +1 -1
  554. package/dist/verified/authority.d.ts +2 -2
  555. package/dist/verified/authority.d.ts.map +1 -1
  556. package/dist/verified/budget.d.ts +4 -0
  557. package/dist/verified/budget.d.ts.map +1 -0
  558. package/dist/verified/generated/actor-name.d.ts +4 -0
  559. package/dist/verified/generated/actor-name.js +17 -0
  560. package/dist/verified/generated/authority.d.ts +4 -0
  561. package/dist/verified/generated/authority.js +28 -0
  562. package/dist/verified/generated/budget.d.ts +4 -0
  563. package/dist/verified/generated/budget.js +17 -0
  564. package/dist/verified/generated/compaction.d.ts +4 -0
  565. package/dist/verified/generated/compaction.js +19 -0
  566. package/dist/verified/generated/grants.d.ts +4 -0
  567. package/dist/verified/generated/grants.js +17 -0
  568. package/dist/verified/generated/lifecycle.d.ts +4 -0
  569. package/dist/verified/generated/lifecycle.js +50 -0
  570. package/dist/verified/generated/manifest.json +137 -48
  571. package/dist/verified/generated/policy.d.ts +17 -0
  572. package/dist/verified/generated/policy.js +211 -0
  573. package/dist/verified/generated/provider.d.ts +4 -0
  574. package/dist/verified/generated/provider.js +18 -0
  575. package/dist/verified/generated/resources.d.ts +6 -0
  576. package/dist/verified/generated/resources.js +73 -0
  577. package/dist/verified/generated/speculation.d.ts +6 -0
  578. package/dist/verified/generated/speculation.js +48 -0
  579. package/dist/verified/generated/storage.d.ts +4 -0
  580. package/dist/verified/generated/storage.js +18 -0
  581. package/dist/verified/grants.d.ts +22 -0
  582. package/dist/verified/grants.d.ts.map +1 -0
  583. package/dist/verified/lifecycle.d.ts +31 -0
  584. package/dist/verified/lifecycle.d.ts.map +1 -0
  585. package/dist/verified/machine.d.ts +18 -0
  586. package/dist/verified/machine.d.ts.map +1 -0
  587. package/dist/verified/memory.d.ts +1 -1
  588. package/dist/verified/memory.d.ts.map +1 -1
  589. package/dist/verified/nat.d.ts +1 -1
  590. package/dist/verified/nat.d.ts.map +1 -1
  591. package/dist/verified/policy.d.ts +17 -5
  592. package/dist/verified/policy.d.ts.map +1 -1
  593. package/dist/verified/provider.d.ts +22 -0
  594. package/dist/verified/provider.d.ts.map +1 -0
  595. package/dist/verified/resources.d.ts +21 -7
  596. package/dist/verified/resources.d.ts.map +1 -1
  597. package/dist/verified/speculation.d.ts +36 -0
  598. package/dist/verified/speculation.d.ts.map +1 -0
  599. package/dist/verified/storage.d.ts.map +1 -1
  600. package/dist/worker/missing-install.d.ts +8 -0
  601. package/dist/worker/missing-install.d.ts.map +1 -0
  602. package/dist/worker/options.d.ts.map +1 -1
  603. package/dist/worker/options.js +25 -0
  604. package/dist/worker/options.js.map +2 -2
  605. package/dist/worker/prompt-lifecycle.d.ts +16 -0
  606. package/dist/worker/prompt-lifecycle.d.ts.map +1 -0
  607. package/dist/worker/prompt-lifecycle.js +90 -0
  608. package/dist/worker/prompt-lifecycle.js.map +7 -0
  609. package/dist/worker/questions.d.ts +15 -3
  610. package/dist/worker/questions.d.ts.map +1 -1
  611. package/dist/worker/questions.js +53 -8
  612. package/dist/worker/questions.js.map +2 -2
  613. package/dist/worker/recovery-watchdog.d.ts +22 -0
  614. package/dist/worker/recovery-watchdog.d.ts.map +1 -1
  615. package/dist/worker/recovery-watchdog.js +116 -1
  616. package/dist/worker/recovery-watchdog.js.map +2 -2
  617. package/dist/worker/result.js +1 -1
  618. package/dist/worker/result.js.map +2 -2
  619. package/dist/worker.js +131 -21
  620. package/dist/worker.js.map +2 -2
  621. package/docs/actor-name-policy-handoff.md +5 -0
  622. package/docs/agents.md +164 -17
  623. package/docs/architecture.md +5 -1
  624. package/docs/audit-trace.md +2 -1
  625. package/docs/background-tasks.md +102 -16
  626. package/docs/codemode-parity.md +2 -2
  627. package/docs/compaction.md +21 -5
  628. package/docs/components.md +1 -1
  629. package/docs/configuration.md +111 -66
  630. package/docs/decisions.md +92 -10
  631. package/docs/durable-extension.md +121 -0
  632. package/docs/durable-pi.md +306 -6
  633. package/docs/extractive-history.md +3 -1
  634. package/docs/interface.md +20 -17
  635. package/docs/jev.md +1 -1
  636. package/docs/kernels.md +1 -1
  637. package/{node_modules/pi-coralbricks-provider/LICENSE → docs/licenses/gdp-wired-mit.txt} +1 -1
  638. package/docs/managed-host-migration.md +50 -0
  639. package/docs/programmatic-compaction.md +216 -6
  640. package/docs/programs.md +23 -1
  641. package/docs/prompt-cache.md +4 -2
  642. package/docs/provider-capabilities.md +15 -14
  643. package/docs/providers.md +99 -3
  644. package/docs/shell-composition.md +15 -0
  645. package/docs/short-lock-protocol.md +90 -0
  646. package/docs/skills.md +5 -1
  647. package/docs/speculation.md +6 -0
  648. package/docs/verified-kernels.md +309 -220
  649. package/package.json +45 -24
  650. package/proofs/actor-name.ts +27 -0
  651. package/proofs/authority.ts +62 -0
  652. package/proofs/budget.ts +24 -0
  653. package/proofs/compaction.ts +51 -0
  654. package/proofs/grants.ts +39 -0
  655. package/proofs/index.ts +40 -0
  656. package/proofs/kernel.ts +44 -0
  657. package/proofs/lifecycle.ts +128 -0
  658. package/proofs/policy.ts +195 -0
  659. package/proofs/provider.ts +52 -0
  660. package/proofs/resources.ts +160 -0
  661. package/proofs/speculation.ts +69 -0
  662. package/proofs/storage.ts +66 -0
  663. package/scripts/verified-kernels.ts +141 -0
  664. package/skillsets/python/fabric-council/SKILL.md +92 -20
  665. package/skillsets/python/fabric-exec/SKILL.md +2 -2
  666. package/skillsets/python/fabric-exec/references/agents.md +10 -4
  667. package/skillsets/python/fabric-fusion/SKILL.md +1 -1
  668. package/skillsets/python/fabric-guide/SKILL.md +1 -1
  669. package/skillsets/typescript/fabric-council/SKILL.md +109 -22
  670. package/skillsets/typescript/fabric-exec/SKILL.md +7 -7
  671. package/skillsets/typescript/fabric-exec/references/agents.md +12 -3
  672. package/skillsets/typescript/fabric-fusion/SKILL.md +1 -1
  673. package/skillsets/typescript/fabric-guide/SKILL.md +1 -1
  674. package/LAWS.bend +0 -502
  675. package/PROOF.bend +0 -452
  676. package/dist/chunks/chunk-3UGN25XS.js.map +0 -7
  677. package/dist/chunks/chunk-4EW7GVUR.js.map +0 -7
  678. package/dist/chunks/chunk-5UBRGTVN.js.map +0 -7
  679. package/dist/chunks/chunk-BN7F52EG.js +0 -525
  680. package/dist/chunks/chunk-BN7F52EG.js.map +0 -7
  681. package/dist/chunks/chunk-DK35W6U7.js +0 -259
  682. package/dist/chunks/chunk-DK35W6U7.js.map +0 -7
  683. package/dist/chunks/chunk-EFETPXU2.js.map +0 -7
  684. package/dist/chunks/chunk-EHQQ4KCX.js.map +0 -7
  685. package/dist/chunks/chunk-EKODKR6Y.js.map +0 -7
  686. package/dist/chunks/chunk-FE6NOAO7.js.map +0 -7
  687. package/dist/chunks/chunk-FIDUHKMM.js.map +0 -7
  688. package/dist/chunks/chunk-FSB2VIRZ.js.map +0 -7
  689. package/dist/chunks/chunk-GIK2WNAK.js.map +0 -7
  690. package/dist/chunks/chunk-GO32KSEZ.js.map +0 -7
  691. package/dist/chunks/chunk-IR3PIHJM.js.map +0 -7
  692. package/dist/chunks/chunk-ITVLKXCI.js +0 -266
  693. package/dist/chunks/chunk-ITVLKXCI.js.map +0 -7
  694. package/dist/chunks/chunk-K7J2ABAZ.js.map +0 -7
  695. package/dist/chunks/chunk-KJZAOENY.js +0 -212
  696. package/dist/chunks/chunk-KJZAOENY.js.map +0 -7
  697. package/dist/chunks/chunk-LNASO4VT.js.map +0 -7
  698. package/dist/chunks/chunk-MLLYR3Y6.js.map +0 -7
  699. package/dist/chunks/chunk-P4KH4S4S.js.map +0 -7
  700. package/dist/chunks/chunk-PK4NIJEV.js.map +0 -7
  701. package/dist/chunks/chunk-Q2JQ3RYZ.js +0 -99
  702. package/dist/chunks/chunk-Q2JQ3RYZ.js.map +0 -7
  703. package/dist/chunks/chunk-R2XQ6AHT.js.map +0 -7
  704. package/dist/chunks/chunk-ROTCDDOV.js.map +0 -7
  705. package/dist/chunks/chunk-SPCJXN4K.js.map +0 -7
  706. package/dist/chunks/chunk-U366I5K2.js.map +0 -7
  707. package/dist/chunks/chunk-UKMQK5VP.js +0 -231
  708. package/dist/chunks/chunk-UKMQK5VP.js.map +0 -7
  709. package/dist/chunks/chunk-UOM37PE4.js.map +0 -7
  710. package/dist/chunks/chunk-UTOBAZ5T.js.map +0 -7
  711. package/dist/chunks/chunk-VSDUSNIA.js.map +0 -7
  712. package/dist/chunks/chunk-VTK2FEH7.js +0 -229
  713. package/dist/chunks/chunk-VTK2FEH7.js.map +0 -7
  714. package/dist/chunks/chunk-VYQV5JRT.js.map +0 -7
  715. package/dist/chunks/chunk-XCEEQ5AB.js.map +0 -7
  716. package/dist/chunks/chunk-ZLNJDTCN.js +0 -226
  717. package/dist/chunks/chunk-ZLNJDTCN.js.map +0 -7
  718. package/dist/chunks/chunk-ZQMBS5SH.js.map +0 -7
  719. package/dist/ui/conversation-shortcut.d.ts +0 -3
  720. package/dist/ui/conversation-shortcut.d.ts.map +0 -1
  721. package/dist/ui/widget-activity.d.ts +0 -21
  722. package/dist/ui/widget-activity.d.ts.map +0 -1
  723. package/dist/verified/generated/authority-kernel.d.ts +0 -10
  724. package/dist/verified/generated/authority-kernel.js +0 -127
  725. package/dist/verified/generated/kernel.d.ts +0 -31
  726. package/dist/verified/generated/kernel.js +0 -389
  727. package/dist/verified/generated/lifecycle-kernel.d.ts +0 -7
  728. package/dist/verified/generated/lifecycle-kernel.js +0 -164
  729. package/dist/verified/generated/provider-kernel.d.ts +0 -9
  730. package/dist/verified/generated/provider-kernel.js +0 -87
  731. package/dist/verified/generated/storage-kernel.d.ts +0 -11
  732. package/dist/verified/generated/storage-kernel.js +0 -107
  733. package/docs/licenses/bend-apache-2.0.txt +0 -202
  734. package/node_modules/pi-coralbricks-provider/README.md +0 -306
  735. package/node_modules/pi-coralbricks-provider/auth.ts +0 -30
  736. package/node_modules/pi-coralbricks-provider/custom-models.json +0 -1
  737. package/node_modules/pi-coralbricks-provider/deprecated-models.json +0 -1
  738. package/node_modules/pi-coralbricks-provider/guard.ts +0 -155
  739. package/node_modules/pi-coralbricks-provider/index.ts +0 -662
  740. package/node_modules/pi-coralbricks-provider/models.json +0 -88
  741. package/node_modules/pi-coralbricks-provider/package.json +0 -74
  742. package/node_modules/pi-coralbricks-provider/park.ts +0 -122
  743. package/node_modules/pi-coralbricks-provider/patch.json +0 -34
  744. package/node_modules/pi-coralbricks-provider/scripts/update-models.js +0 -658
  745. package/node_modules/pi-coralbricks-provider/settings.ts +0 -143
  746. package/node_modules/pi-coralbricks-provider/sync-policy.ts +0 -309
  747. package/proofs/abi.json +0 -308
  748. package/proofs/authority-abi.json +0 -7
  749. package/proofs/authority-kernel.bend +0 -23
  750. package/proofs/authority-proof.bend +0 -74
  751. package/proofs/authority-spec.bend +0 -30
  752. package/proofs/authority-state.bend +0 -43
  753. package/proofs/authority-types.d.ts +0 -3
  754. package/proofs/kernel.bend +0 -139
  755. package/proofs/lifecycle-abi.json +0 -3
  756. package/proofs/lifecycle-kernel.bend +0 -11
  757. package/proofs/lifecycle-proof.bend +0 -249
  758. package/proofs/lifecycle-spec.bend +0 -261
  759. package/proofs/lifecycle-types.d.ts +0 -4
  760. package/proofs/lifecycle.bend +0 -119
  761. package/proofs/provider-abi.json +0 -4
  762. package/proofs/provider-kernel.bend +0 -14
  763. package/proofs/provider-plans.bend +0 -28
  764. package/proofs/provider-spec.bend +0 -14
  765. package/proofs/provider-types.d.ts +0 -5
  766. package/proofs/resource-proof.bend +0 -633
  767. package/proofs/resource-spec.bend +0 -133
  768. package/proofs/resources.bend +0 -160
  769. package/proofs/state-kernel.bend +0 -17
  770. package/proofs/state-plans.bend +0 -40
  771. package/proofs/state-proof.bend +0 -42
  772. package/proofs/state-spec.bend +0 -26
  773. package/proofs/storage-abi.json +0 -3
  774. package/proofs/storage-kernel.bend +0 -11
  775. package/proofs/storage-plans.bend +0 -100
  776. package/proofs/storage-proof.bend +0 -176
  777. package/proofs/storage-spec.bend +0 -70
  778. package/proofs/storage-types.d.ts +0 -8
  779. package/proofs/types.d.ts +0 -7
  780. package/scripts/test-verified-kernels.mjs +0 -107
  781. package/scripts/verified-kernels.mjs +0 -176
  782. /package/dist/chunks/{chunk-3FJUP3GV.js.map → chunk-36XQFTEN.js.map} +0 -0
  783. /package/dist/chunks/{chunk-ZEXCKK4K.js.map → chunk-4WKD3YM3.js.map} +0 -0
  784. /package/dist/chunks/{chunk-5XBYFSI5.js.map → chunk-7YNE4NB2.js.map} +0 -0
  785. /package/dist/chunks/{chunk-K6QXUGS5.js.map → chunk-BMAEZNZ5.js.map} +0 -0
  786. /package/dist/chunks/{chunk-CCHZXF6K.js.map → chunk-CXYJJ3HZ.js.map} +0 -0
  787. /package/dist/chunks/{chunk-TIIIHPHF.js.map → chunk-GS67KDMV.js.map} +0 -0
  788. /package/dist/chunks/{chunk-D5NYNIST.js.map → chunk-H57KPL3V.js.map} +0 -0
  789. /package/dist/chunks/{chunk-INRXG4J5.js.map → chunk-HGD75NZY.js.map} +0 -0
  790. /package/dist/chunks/{chunk-UXIBKMUM.js.map → chunk-KIFOEBYJ.js.map} +0 -0
  791. /package/dist/chunks/{chunk-FUY6XVRX.js.map → chunk-MPMEK3IQ.js.map} +0 -0
  792. /package/dist/chunks/{chunk-HP5P7NBO.js.map → chunk-MSDL7U6Q.js.map} +0 -0
  793. /package/dist/chunks/{chunk-QT4W5YVB.js.map → chunk-RAA3FAYZ.js.map} +0 -0
  794. /package/dist/chunks/{chunk-53N2I4QA.js.map → chunk-TXCNZCZP.js.map} +0 -0
  795. /package/dist/chunks/{chunk-ASSLHWZS.js.map → chunk-UFMYN5TA.js.map} +0 -0
  796. /package/dist/chunks/{chunk-LEU5CDSL.js.map → chunk-XFOSUGLU.js.map} +0 -0
package/docs/agents.md CHANGED
@@ -32,13 +32,38 @@ You can give `fabric_exec` optional `agentBudget` and `tokenBudget` limits. Conf
32
32
 
33
33
  `agents.wait`/`join`, terminal `agents.status`, and cleanup acknowledge the result and retract any pending notification, including completion that arrived before the wait. Running status and UI/list polling do not acknowledge results. Acknowledgment means the Fabric program received the result: return the relevant outcome to Main when it needs to reason about it. Prefer `wait` over a polling loop.
34
34
 
35
+ ### Queued spawns
36
+
37
+ By default `agents.spawn` waits inside the call for a free `agents.maxConcurrent` slot. A program that spawns more children than the limit blocks there, and if its deadline passes first, the waiting spawns never launch and the program cannot return the ids of the runs that did.
38
+
39
+ `agents.spawn({ ..., queue: true })` returns at once with `status: "queued"` and the run's `id`. The run starts when a slot frees, first come first served, even after the program that spawned it has ended. Its `timeoutMs` counts from its start, not from the spawn call. Meanwhile `agents.wait`, `agents.status`, and `agents.list` accept the id and report `queued`; `wait` resolves with the final result once the run starts and finishes. `agents.stop` on a queued run cancels it without launching and returns a `stopped` result. `agents.cleanup` removes a cancelled queued run; a queued run must be stopped first. `agents.steer`, `agents.followUp`, and `agents.log` need a started run and throw until then. If the launch fails after admission (an unavailable model, a worktree error), the run ends `failed` with that error and a detached run reports it like any other completion. Request validation errors still reject the `spawn` call itself. `queue` is not available with `residency: "durable"`. A [background program](background-tasks.md) (`fabric_exec` with `background: true`) is the other way to keep a long spawn loop from blocking Main, but each spawn in it still waits for a slot.
40
+
41
+ ```ts
42
+ const handles = await Promise.all(tasks.map((task) => agents.spawn({ task, queue: true })));
43
+ return handles.map((handle) => handle.id);
44
+ ```
45
+
35
46
  Durable spawns use the same inbox. Undelivered envelopes survive disconnects; receipts survive reconnects. Escape or an errored Main turn parks pending results until new input; Main does not restart immediately. Explicit lifecycle subscriptions, actor messages, and trajectory handoffs retain their separate delivery policies. A terminal run can still report incomplete work; Main must inspect its result.
36
47
 
37
48
  ### Stalled Pi error recovery
38
49
 
39
50
  After a failed or aborted assistant response (including `Error: Terminated`), Fabric allows Pi's own retries to recover. If no recovery output arrives for 60 seconds, the worker fails the run with the original error and terminates the child, escalating from SIGTERM to SIGKILL after another 5 seconds. Repeated retry announcements, errors, or lifecycle events do not extend this deadline. Nonempty text/thinking/tool-call deltas refresh it; a successful assistant response clears it. Healthy inference and tool execution are not subject to this recovery timer, and the overall run deadline still applies.
40
51
 
41
- Fabric handles exhausted retries explicitly without waiting forever on an earlier `willRetry` flag. Child shutdown after RPC stdin closes is also bounded: 5 seconds for graceful exit, then SIGTERM and a further 5 seconds before SIGKILL. These failures settle `agents.wait`/`join` and notify detached callers normally; they do not automatically replay potentially side-effecting work. Already-running workers must be stopped and respawned to use the fix.
52
+ Fabric handles exhausted retries explicitly without waiting forever on an earlier `willRetry` flag. Child shutdown after RPC stdin closes is also bounded: 5 seconds for graceful exit, then SIGTERM and a further 5 seconds before SIGKILL. When the child already gave its final answer, a slow exit does not fail the run: it stays `completed` with that answer, and the run log records a `fabric_exit_warning` event. Without a final answer (an error, or a last message that stopped on a tool call), the run fails. These failures settle `agents.wait`/`join` and notify detached callers normally; they do not automatically replay potentially side-effecting work. Already-running workers must be stopped and respawned to use the fix.
53
+
54
+ ### Stalled Pi stream
55
+
56
+ A Pi turn that goes silent fails; it does not stay `running`. If no model, tool or turn event arrives for 30 minutes while the turn is waiting on the model, the worker fails the run with `Pi stream stalled` and terminates the child as above. That frees the run's concurrency slot. Extension widget and status requests and queue updates do not count as events, because a stalled child can still send several of them a second. The timer does not run while a tool call runs, while the session compacts, while a child question waits for the parent, or between turns. A slow tool or a long human answer therefore never triggers it. 30 minutes is longer than any single model response we have measured.
57
+
58
+ The worker also enforces each `fabric_exec` call's program deadline from outside the child. The child's progress updates for the call carry the current deadline in `details.deadlineAt`. The update clears the field while a human wait pauses the deadline. If the call is still running 5 minutes after the last reported deadline, the worker fails the run with a message that names the tool call and terminates the child. A host call that never settles cannot hold the run past its deadline this way.
59
+
60
+ ### Pi task consumed without a turn
61
+
62
+ A Pi extension can take the first task prompt without starting a turn, for example an `input` hook that returns `handled`. Pi then answers the prompt with `disposition: "handled"` and sends no `agent_start`. The worker sends the task with the id `fabric-task` and follows only that reply. If the reply says `handled` and no turn starts within 60 seconds, or the child exits first, the run fails with `Pi handled the task without starting a turn; terminating child`. The wait covers an extension command that handled the prompt and then starts its own turn. The failure also carries the last warning or error notice the child sent before the reply, flattened and limited to 500 characters, so the parent sees why the task was refused. If the reply carries an absent disposition (an older Pi host) and the child starts no turn within 300 seconds, the run also fails with a message that starts `Pi acknowledged the task`. Later steer, follow-up and operator commands are not tracked. The task is not replayed.
63
+
64
+ ### Pi run that ends on a tool call
65
+
66
+ A tool can end a Pi run by returning `terminate: true`, as a compaction tool may do. Pi then stops after that tool batch, and the run's last assistant message is the tool call, with no final answer after it. The `pi` and `pi-durable` runners settle such a run `failed` with `Pi ended the run after a tool call without a final answer (tool: <name>)`. Any text the model wrote before the tool call stays in `text`. Work the tool planned to run afterwards, such as a follow-up prompt after compaction, does not happen in a child, because the worker closes the child once it settles. Leave tools that end the run out of a child's `tools` allowlist.
42
67
 
43
68
  ### Image-heavy lifecycle events
44
69
 
@@ -50,7 +75,36 @@ The 4,194,304-character guard still applies to other event data, including a sin
50
75
 
51
76
  Use `agents.models({ runner: "pi" })` and copy the returned `key` verbatim, or use an explicitly configured `models.aliases` name. Reuse the `model` returned by a successful spawn. Do not reconstruct it from an agent's display name. For example, an agent named “Sol” need not share the version number of one named “Astra”. Prior success with one key does not validate a different key.
52
77
 
53
- `provider/model` selectors prefer an exact visible match. A near-miss ID resolves to the closest available model on the **same provider**, using Fabric's existing similarity ranking; ties prefer recent usage, then canonical key order. For example, `openai-codex/gpt-6-sol` resolves to `openai-codex/gpt-5.6-sol` when that is the closest visible model. The returned handle's `model` and the worker's `requestedModel` contain the canonical selection. Unknown providers and names without sufficient resemblance still fail before launch. Model IDs containing `/` stay provider-scoped. Configured aliases keep their ordered, exact-target fallback chains.
78
+ To check one known key without reading the whole list, pass it as `model`: `agents.models({ runner: "pi", model: "provider/id" })` returns only the entries whose `key` equals that string exactly and case-sensitively, so a missing model gives `[]`. This lookup does not resolve aliases or near matches, and it filters the Claude, Veda, and registered-runner lists the same way.
79
+
80
+ `provider/model` selectors prefer an exact visible match. A near-miss ID resolves to the closest available model on the **same provider**, using Fabric's existing similarity ranking; ties prefer recent usage, then canonical key order. For example, `openai-codex/gpt-6-sol` resolves to `openai-codex/gpt-5.6-sol` when that is the closest visible model. The returned handle's `model` and the worker's `requestedModel` contain the canonical selection. Unknown providers and names without sufficient resemblance still fail before launch. Model IDs containing `/` stay provider-scoped. Configured aliases keep their ordered, exact-target fallback chains. To turn the alias and near-miss steps off, see [exact model match](#exact-model-match).
81
+
82
+ ### Exact model match
83
+
84
+ Set `modelMatch: "exact"` on `agents.run` or `agents.spawn` to select a named model without fallback. **This is not a security guarantee or final-dispatch enforcement.** Later hooks, unknown API payloads, providers, and extension-made calls can route data elsewhere; attribution may detect drift only after a call. Do not rely on this mode to prevent data disclosure. `model` is then required and must be a `provider/id` that `agents.models({ runner: "pi" })` lists. Fabric skips the `models.aliases` step (an alias named like the model is ignored), the closest-match step, and the fuzzy step, and it applies no alias `thinking` level. Matching ignores case, as it does for other exact lookups, and the handle reports the registry's own spelling. When two registry entries differ only by case, the identical spelling wins, and Fabric authenticates that same entry. Without `modelMatch`, resolution is unchanged.
85
+
86
+ Fabric refuses these requests before any child starts:
87
+
88
+ - `model` is missing or not in `provider/id` form: `modelMatch "exact" requires model in provider/id form, as listed by agents.models({ runner: "pi" }).`
89
+ - The model is not in the visible registry: the usual `Model "<selector>" is not available to this Pi session.` error, which names `agents.models({ runner: "pi" })`.
90
+ - The runner is not `pi` or `pi-durable`: `modelMatch "exact" is supported only by the pi and pi-durable runners.` Claude, Veda, and registered runners forward `model` to a backend that can apply its own aliases, so Fabric cannot promise that model and refuses the request.
91
+ - The value is not `"exact"`: the input schema rejects it, and a direct request fails with `Invalid Fabric agent modelMatch`.
92
+
93
+ The mode holds on every launch path, including a retry or resume of the same run and `residency: "durable"`, where the resident host resolves the model again with the same mode. It is not accepted by `agents.handoff`, `agents.create`, actor activations, or the hosted `AgentService`; their schemas reject it.
94
+
95
+ What `modelMatch: "exact"` does (subject to the limitations above):
96
+
97
+ 1. **Fabric picks the listed `provider/id` and nothing else.** There is no alias, closest-match or fuzzy step, and no `thinking` level comes from an alias. A model that `agents.models({ runner: "pi" })` does not list is refused before any child starts.
98
+ 2. **Admission is strict.** An exact request always uses strict model admission, whatever `agents.modelAdmission` says. This covers the first launch, a startup retry, a resume, and the resident host. Permissive admission accepts a child that reports a different model after selection, and an exact run never does.
99
+ 3. **The guard checks observable model changes and requests.** When it detects a different session model or a known payload model mismatch, it stops the child at that check and the run fails with `Fabric exact model pin violated: only <pin> may run, but <actual> was about to run. The provider call was stopped before any request was sent.` The worker loads the `model-pin-guard` Pi extension into the child with `-e`, the same way it loads the write guard, and it loads even with `extensions: false`. The guard knows the pinned `provider/id` and checks three things:
100
+ - **Model switches.** On the `model_select` event, any model other than the pin ends the run. This detects emitted switches and stops the child, including when Pi's own compaction or branch summaries use the changed session model; independent calls and provider routing remain outside the guard. Pi emits `model_select` only when the model changes. The launch with `--model <pin>`, Fabric's startup `set_model` to the same pin, and a different default model in settings never reach the guard as a switch.
101
+ - **The current model before each request.** The `context`, `context_with_system` and `before_provider_request` events must show the pin as Pi's current model.
102
+ - **The outgoing payload.** In `before_provider_request`, the guard compares the model id inside the payload with the registry `id` of the pin, which is the value Pi sends. It does this only for APIs whose payload shape carries the model id in a known field: `model` for `openai-completions`, `openai-responses`, `openai-codex-responses`, `anthropic-messages`, `mistral-conversations`, `google-generative-ai`, `google-vertex` and `pi-messages`, and `modelId` for `bedrock-converse-stream`. It skips Azure OpenAI Responses, whose payload names a deployment, virtual models, APIs that extensions register, and any payload without a string in that field. A rewrite made by a handler that is loaded before the guard is caught. A rewrite made by a handler that runs after the guard is not.
103
+
104
+ On a detected violation the guard writes one `[pi-fabric] model-pin-violation` line to stderr and ends the child process with status 71 at that check. The error's pre-send wording refers to the intercepted request, not to prior calls or undetected rerouting. Pi ignores an exception thrown by an extension handler. `ctx.abort()` also stopped the call in Pi 1.0.4 probes, because credential lookup ahead of the provider honours the aborted signal, but the run would then fail as a plain abort with no fixed reason. Ending the process depends on neither behaviour. A pin failure is final: Fabric neither retries nor resumes it, whatever words the model ids contain.
105
+ 4. **The guard is not final-dispatch enforcement.** A guard inside the child process cannot stop extension code in that process from calling another model. This covers nested model calls from tools, custom compaction that summarizes with another model, a provider that an extension re-registers under the pinned name so that it forwards to another model, and a payload rewrite by a handler that runs after the guard. The strict attribution check on assistant messages stays as a second line of defence: it fails the run afterwards where a reply names another model, after the call has been made.
106
+
107
+ A project extension that emits a detected model switch at `before_agent_start`, between turns, inside a tool, or inside a `context` handler causes the guard to end the run; this does not rule out other calls or later rerouting. This also holds at `session_start`: an extension that switches the model there and relied on Fabric to switch it back now fails an exact run, because the guard cannot tell that switch from one that is followed by a summary on the other model. Run such an extension with a default request, or set `extensions: false` for the exact run.
54
108
 
55
109
  For independent launches, await `Promise.allSettled` and inspect every result. An uncaught `Promise.all` rejection ends the Fabric program and can abort sibling calls still in flight; it does not prove every requested model was unavailable. Already completed calls are not rolled back, so retain successful handles and retry only failed launches.
56
110
 
@@ -61,6 +115,83 @@ return results.map(result => result.status === "fulfilled"
61
115
  : { ok: false, error: String(result.reason) });
62
116
  ```
63
117
 
118
+ ### Child system prompt
119
+
120
+ `systemPrompt` on `agents.run` or `agents.spawn` adds text to the child's system prompt. Fabric joins it ahead of any [component model guidance](components.md), and Pi and Claude children append the result to their system prompt with `--append-system-prompt`. A Veda child receives it as a `<system_instructions>` block in its prompt. A blank value is ignored, and durable `agents.spawn` refuses it.
121
+
122
+ ### Child skills
123
+
124
+ `skills` on `agents.run` or `agents.spawn` chooses the child's Pi skills by name. Fabric looks up each name among the skills this session has loaded, as Pi lists them in its `skill:` commands. A child never gets a skill this session does not have, and a path in place of a name is refused.
125
+
126
+ | Value | The child gets |
127
+ | --- | --- |
128
+ | omitted | Pi's own skill discovery, as before. |
129
+ | `false` | No skills. |
130
+ | `["writing", "review"]` | Those skills preloaded in full, plus this session's other skills in its skill list. |
131
+ | `{ preload: ["writing"], inherit: false }` | Only the preloaded skills. |
132
+
133
+ A preloaded skill is placed in the child's system prompt in full, in the `<skill>` block Pi uses for `/skill:name`, after any `systemPrompt` and ahead of component model guidance. Fabric starts the child with `--no-skills` and one `--skill` for each skill it may still list, so it does not run its own discovery. Fabric's bundled skills come from the parent's list too; a child with `skills: false` has none of them.
134
+
135
+ An unknown name fails before any child starts. The error lists this session's skill names and suggests the closest one. A listed skill whose file cannot be read also fails. Only the `pi` and `pi-durable` runners accept `skills`; Claude and Veda children refuse it before launch, including `skills: false`. `extensions: false` children accept it, because Pi loads skills without extensions. Durable `agents.spawn` refuses it, like `systemPrompt`.
136
+
137
+ ### Named agent files
138
+
139
+ A named agent file saves the settings of a child agent in a Markdown file with YAML frontmatter. Pass its name as `agent` to `agents.run` or `agents.spawn` and Fabric fills the request from the file. Files written for Claude Code subagents and for Pi agent profiles load unchanged.
140
+
141
+ ```ts
142
+ const reviewer = await agents.run({ agent: "reviewer", task: "Review the diff on this branch" });
143
+ // A field you pass on the call wins over the file.
144
+ const quick = await agents.run({ agent: "reviewer", task: "Skim the diff", thinking: "low" });
145
+ ```
146
+
147
+ An agent file looks like this:
148
+
149
+ ```md
150
+ ---
151
+ name: reviewer
152
+ description: Reviews a diff for defects
153
+ tools: Read, Grep, Glob
154
+ model: cheap
155
+ effort: high
156
+ runtimes:
157
+ fabric:
158
+ timeoutMs: 1800000
159
+ ---
160
+
161
+ You review diffs. Report defects only.
162
+ ```
163
+
164
+ **Where Fabric looks.** Fabric reads the visible `*.md` files directly inside two folders, with no recursion. It skips names that start with a dot. From lowest to highest precedence:
165
+
166
+ 1. `agents/` inside the Pi agent directory (`~/.pi/agent/agents` unless `PI_CODING_AGENT_DIR` says otherwise).
167
+ 2. `.pi/agents` at the project root Fabric uses for the mesh.
168
+
169
+ A project file shadows a user file with the same `name`. Fabric reads the project folder only when the host trusts the project, and says so when it skips a folder that exists. The folder list is the `AGENT_FILE_FOLDERS` constant in `src/agents/agent-files.ts`.
170
+
171
+ **Fields.**
172
+
173
+ | Frontmatter | Becomes | Notes |
174
+ | --- | --- | --- |
175
+ | `name` | the run name | Required. 1 to 64 characters from letters, digits, `.`, `_` and `-`, starting with a letter or digit. The call's `name` wins. |
176
+ | `description` | nothing | Shown by `agents.definitions()`. |
177
+ | body | `systemPrompt` | The text after the frontmatter. It is handled exactly like a `systemPrompt` passed on the call (see [Child system prompt](#child-system-prompt)): Fabric joins it ahead of any component model guidance. |
178
+ | `model` | `model` | Resolved like a call's `model`, so `models.aliases` names and their thinking levels apply. `inherit` or no value sets nothing. |
179
+ | `tools` | `tools` | A YAML list or a comma-separated string. Claude Code names map to Pi names without regard to case: `Read` to `read`, `Grep` to `grep`, `Glob` to `find`, `LS` to `ls`, `Bash` to `bash`, `Edit`, `MultiEdit` to `edit`, `Write` to `write`. Other names stay as written. No value means the default allowlist. |
180
+ | `thinking` or `effort` | `thinking` | One of `off`, `minimal`, `low`, `medium`, `high`, `xhigh`, `max`. Writing both is an error. |
181
+ | `skills` | `skills` | Skill names to preload (see [Child skills](#child-skills)), as a YAML list or a comma-separated string. An entry can also be `{ name, required }`; a missing skill with `required: false` is skipped with a warning. `source` and `version` load with a warning and are not used. A path is an error. An empty list preloads nothing. |
182
+ | `context.skills` | `skills.inherit` | `true` (the default) keeps this session's other skills in the child's skill list; `false` leaves only the preloaded ones. Other `context` keys are ignored with a warning. |
183
+ | `runtimes.fabric` | request fields | Fabric-only settings under their request field names: `runner`, `kernel`, `model`, `thinking`, `tools`, `timeoutMs`, `readOnly`. They win over the shared fields above. An unknown key is an error. |
184
+
185
+ Any other top-level field, such as `color`, `delegate` or `permissionMode`, is ignored. Fabric reports each one as a warning in `agents.definitions()` and in the run's progress notice. It never fails the run, so a file written for another tool keeps loading. Pi agent profiles accept only seven keys, so a file in `.pi/agents` that you share with that tool must keep to them. Put Fabric-only settings under `runtimes.fabric` only in a folder that tool does not read.
186
+
187
+ **Override rule.** Fabric fills a request field from the file only when the call leaves it out. A field passed on the call, including an empty list, always wins. `agents.spawn` with `residency: "durable"` refuses a file that has a body, because a durable spawn does not accept `systemPrompt`.
188
+
189
+ **Errors.** An unknown name fails before any child starts. The message lists the available names and suggests the closest one. A file Fabric cannot read fails with the file path and the line, for example a missing closing `---`, a duplicate key, an unknown thinking level, or an unknown `runtimes.fabric` key. A broken project file never falls back to a user file of the same name.
190
+
191
+ **Listing.** `agents.definitions()` returns `{ name, description, path, scope, shadows?, warnings, error? }[]` with `scope` set to `"user"` or `"project"`. `shadows` is the path of the user file a project file replaces. A file that cannot be read appears with an `error`. The call reads the folders each time and starts no child.
192
+
193
+ Fabric does not read actor templates from files (they stay in `global-actors.json`), and does not look in `.claude/agents`. Fabric loads the file reader and its YAML parser on first use, so a session that never names an agent does not pay for them.
194
+
64
195
  ### Requested models are authoritative
65
196
 
66
197
  For Pi workers, Fabric reapplies the resolved `provider/model` over RPC **after startup extensions finish**, reapplies the requested thinking level, and independently reads `get_state` before sending the task. A successful `set_model` response alone is insufficient: it can echo the requested model even when an extension switches away during `model_select`. Thinking is reported at Pi's effective, capability-clamped level.
@@ -71,7 +202,7 @@ Startup waits for a correlated RPC readiness response. Startup, model admission,
71
202
 
72
203
  Selectors with no available match, rejected/malformed RPC responses, or a remaining model mismatch fail the run without sending its task. A startup or admission stall exhausts the overall deadline with `timed_out`, also without sending the task. Queued controls wait for admission too. After parent-side selector resolution, the worker must use that canonical model: it does not substitute an MRU model or fall back during admission. Standalone `AgentManager` callers can also supply a unique exact bare model ID; ambiguous IDs must be provider-qualified.
73
204
 
74
- `requestedModel` preserves launch intent in run records; `model` follows verified child state and actual assistant attribution. The manager and participant UI preserve that observed value; the launch label cannot overwrite it. If assistant attribution drifts after admission, Fabric terminates the child and reports both requested and observed models in the failure. This verifies Pi's local provider/model identity, not a remote provider's internal routing.
205
+ `requestedModel` in run records is the model Fabric selected at launch, after alias and near-miss resolution, not the caller's selector (with `modelMatch: "exact"` the two name the same model); `model` follows verified child state and actual assistant attribution. The manager and participant UI preserve that observed value; the launch label cannot overwrite it. If assistant attribution drifts after admission, Fabric terminates the child and reports both requested and observed models in the failure. This verifies Pi's local provider/model identity, not a remote provider's internal routing.
75
206
 
76
207
  Existing workers are not retroactively changed by rebuilding or reloading the parent. Stop and respawn affected workers to apply model admission.
77
208
 
@@ -134,7 +265,9 @@ Set `cwd` on `agents.run()` or `agents.spawn()` to choose a leaf or recursive Pi
134
265
 
135
266
  For Pi children, selecting `cwd` neither grants nor requires project trust. Fabric adds no trust gate and passes neither `--approve` nor `--no-approve`; Pi loads `AGENTS.override.md`, `AGENTS.md`, and `CLAUDE.md` under its normal context rules, while protected project resources remain governed by Pi's saved decisions and `defaultProjectTrust`. Each runner keeps its native startup behavior. A generated worktree is evaluated at its own canonical path.
136
267
 
137
- Extension-enabled Pi children inherit the parent’s full-code mode, including ordinary non-recursive leaves. They retain `fabric_exec` as the outer tool, and their optional `tools` allowlist also constrains nested Pi and captured-tool calls. `extensions: false` explicitly opts out; Claude/Veda and parents outside full-code mode keep their existing tool surfaces. Recursive children additionally receive only the delegated `agent` risk. An inherited optional-tool allowlist is intersected with requested/default descendant tools before launch (including durable transfer); malformed inherited allowlists fail closed. Selecting another cwd cannot restore filtered tools. This is not filesystem isolation: enabled tools, trusted extensions, and native execution retain their normal host privileges. A launch-policy change requires `/reload` and newly launched children; it does not hot-swap an already running worker’s tools.
268
+ Extension-enabled Pi children inherit the parent’s full-code mode, including ordinary non-recursive leaves. They retain `fabric_exec` as the outer tool, and their optional `tools` allowlist also constrains nested Pi and captured-tool calls. `extensions: false` explicitly opts out; Claude/Veda and parents outside full-code mode keep their existing tool surfaces. Recursive children additionally receive only the delegated `agent` risk. An inherited optional-tool allowlist is intersected with requested/default descendant tools before launch (including durable transfer); malformed inherited allowlists fail closed. Selecting another cwd cannot restore filtered tools. Recursive `fabric_exec` authority requires an exact inherited entry: `*` and signed selectors cannot grant it. Resident transfers carry `AgentRunRequest.recursiveToolAuthority?: "deny"`, a host-only attenuation field omitted from public provider arguments (a caller cannot use it to grant permission), and both Pi runners exclude `fabric_exec` at native wildcard expansion when it was not explicitly granted by launch policy. Relative `+name`/`-name` selectors under an inherited restriction retain only explicitly added, permitted names; they cannot restore unknown target defaults. This is not filesystem isolation: enabled tools, trusted extensions, and native execution retain their normal host privileges. A launch-policy change requires `/reload` and newly launched children; it does not hot-swap an already running worker’s tools.
269
+
270
+ An extension-enabled Pi child loads the parent's Fabric build with `-e`, and it also loads the packages in its Pi settings. Those can name a different Fabric build, for example after a Fabric upgrade while the parent session keeps running. The Fabric copy named on the command line then takes precedence: any other copy of the `pi-fabric` package writes one `is inactive` warning and registers nothing, so the child still starts with exactly one `fabric_exec`. When several copies are named on the command line, the first one wins. A top-level `pi` without `-e` keeps the build from its settings.
138
271
 
139
272
  ### Durable participant residency
140
273
 
@@ -163,7 +296,7 @@ return { audit, supervisor };
163
296
 
164
297
  The first durable request starts one hidden resident host for the current root when needed. Fabric transfers actor ownership to this host or starts the one-shot run there. It publishes the owner in the standard participant directory. Fabric routes `steer`, `followUp`, `tell`, blocking `ask`, and `stop` through the acknowledged mesh control plane. The process uses the captured agent, mesh, timeout, recursion, and cost-ceiling configuration. It also uses the runner, model, and tool capabilities that the originating call explicitly authorized. Users do not configure a daemon profile or workflow policy.
165
298
 
166
- The original TUI can shut down after the transfer. Durable agents continue until they reach a terminal status. A resumed copy of the same root can call `agents.status`, `agents.wait`, `agents.log`, and `agents.cleanup`. The mesh stores terminal notifications and active actor deliveries until Main resumes. Durable actors keep their registry definition, mailbox history, runner session, mesh subscriptions, and replay cursor. Main relays session-bound host events while it is available. The cross-process relay can omit oversized raw image blocks. The relay keeps their redacted media descriptors.
299
+ The original TUI can shut down after the transfer. Durable agents continue until they reach a terminal status. A resumed copy of the same root can call `agents.status`, `agents.wait`, `agents.log`, and `agents.cleanup`. A new root session in the same project can call `agents.status`, `agents.wait`, and `agents.log` for that durable agent too. The project boundary is the mesh root (`<project>/.pi/fabric/mesh` unless `mesh.root` says otherwise), and a run in another mesh root stays unknown. The read needs no opt-in from the run, and `agents.status` returns the full record, including `text`. It only reads: the completion receipt, `agents.cleanup`, and notifications stay with the root that spawned the agent. A scoped session reads only a run whose scope its own scope covers (same principal, every grant), and it never reads a run launched without a scope. If the run is unfinished and its resident host is not running, a wait from the owning root restarts the host for a hosted run (see hosted runs). `agents.wait` from another root fails instead, because it never starts that root's host. Resume the spawning session to re-attach a hosted run. The mesh stores terminal notifications and active actor deliveries until Main resumes. Durable actors keep their registry definition, mailbox history, runner session, mesh subscriptions, and replay cursor. Main relays session-bound host events while it is available. The cross-process relay can omit oversized raw image blocks. The relay keeps their redacted media descriptors.
167
300
 
168
301
  A durable actor has one resident execution owner. Other trusted sessions in the project can call `ask`, `tell`, `steer`, `followUp`, and `stop`; Fabric routes each call to that owner. Direct messages carry the caller's model and thinking binding. Actor status, mailbox history, logs, and definition export are shared project views. Only the owner can clear the mailbox or change tools, events, instructions, delivery policy, and project defaults. Fabric sends durable actor removal to the resident owner. The hidden host exits after a short idle grace when it owns no live durable actor or running durable agent. Durable residency requires a trusted project and `mesh.enabled`. Schema enforce mode does not support it.
169
302
 
@@ -317,7 +450,7 @@ Veda children do not have recursive Fabric capabilities. Fabric rejects `recursi
317
450
 
318
451
  ### Custom runners
319
452
 
320
- The default `pi-durable` runner uses the full isolated Pi/Fabric worker host; explicit `pi` selects the legacy CLI. See [Durable Pi runner](durable-pi.md) for recovery boundaries and the separate `pi-durable-leaf` hosted factory. Neither restores arbitrary `fabric_exec` continuations.
453
+ The default `pi-durable` runner uses the full isolated Pi/Fabric worker host; explicit `pi` selects the legacy CLI. See [Durable Pi runner](durable-pi.md) for recovery boundaries and the separate `pi-durable-leaf` hosted factory. The default runner reruns an interrupted `fabric_exec` once when its program made no effect. Neither restores arbitrary `fabric_exec` continuations.
321
454
 
322
455
  A Pi extension can add a runner through the `pi-fabric/runners` subpath. The subpath is never loaded by the Fabric extension at startup.
323
456
 
@@ -334,11 +467,11 @@ Two kinds exist:
334
467
  - `kind: "worker"`: `launch(context)` returns `{ workerPath, workerArguments }`. Fabric runs that script under the selected transport and reads the [worker protocol](#worker-protocol) files. The context carries the run files, the task and launch facts, and `fabricWorker`, the launch Fabric would use for its own worker, so an adapter can wrap it. The optional `stop()` runs before the transport kills the process. A worker that dies before any progress is relaunched with the same launch (startup retry); Fabric never re-prompts a custom worker mid-run.
335
468
  - `kind: "hosted"`: no Fabric process. The adapter owns execution, for example in a daemon. `prepare(context)` must be pure and returns a JSON locator of at most 8 KiB. Fabric writes it to the run record (`hosted.locator`) and `hosted.json` before it calls `start(locator, context, reporter)`. `context.idempotencyKey` is the Fabric run id, so a second submission with the same key must not start a second run. `liveness(locator)` answers `running`, `sleeping`, `settled`, `cancelled`, `interrupted`, or `unknown`. `stop(locator, reason)` is required and returns `{ confirmed }`. `abort`, `sleep`/`wake` (with the `sleep` capability), `steer`, and `followUp` are optional. The adapter delivers steer and follow-up messages itself; a delivery failure lands in the run transcript.
336
469
 
337
- The hosted `reporter` has `progress({ turns, toolCalls, currentTool, text })`, `usage(total)` with the cumulative run usage (Fabric records the increase, which feeds budgets and `tokens.usage` lifecycle events), `transcript(event)`, `question(q)`, `finish({ status, output, structured? })`, and `fail({ error, retryable })`. `question` routes like a Pi child dialog: direct UI when the parent has one, otherwise a [decision](decisions.md#routed-child-questions), and only with `agents.childQuestions: "route"`. The run record shows `blockedOn` while it waits.
470
+ The hosted `reporter` has `progress({ turns, toolCalls, currentTool, text })`, `usage(total)` with the cumulative run usage (Fabric records the increase, which feeds budgets and `tokens.usage` lifecycle events), `transcript(event)`, `question(q)`, `finish({ status, output, structured? })`, and `fail({ error, retryable })`. When the run has a `schema`, Fabric validates a `completed` finish against it as it does for its own worker: `structured` (`null` included), or `output` parsed as JSON when `structured` is absent, must match. A mismatch, or a value over 1 MiB from either source, settles the run `failed` with `Structured agent output was invalid: ...`. `question` routes like a Pi child dialog: direct UI when the parent has one, otherwise a [decision](decisions.md#routed-child-questions), and only with `agents.childQuestions: "route"`. The run record shows `blockedOn` while it waits, with the decision's `decisionId` once one is raised. After the resident host detaches a durable run, that reporter's `question` never settles, including for a question already open: ask again through the reporter that the next `attach` receives.
338
471
 
339
- Fabric never relaunches or re-prompts a hosted run. A `sleeping` run stays `running` with `sleeping: true`. When liveness reports `interrupted` or `unknown` (or `settled` without a result), the run settles `failed` with `outcome: "indeterminate"`. The same outcome marks a stop the adapter did not confirm, and a durable spawn request the resident host was processing when it restarted. Hosted runs work with `agents.run`, `spawn`, `wait`, `status`, `stop`, `steer`, `followUp`, the dashboard, budgets, and `residency: "durable"`. Persistent actors need a worker runner.
472
+ Fabric never relaunches or re-prompts a hosted run. A program parks an idle hosted run with `agents.sleep({ id })` and resumes it with `agents.wake({ id })`. Both call the adapter's `sleep`/`wake` hook and return `{ id, requested }` after the hook resolves. They fail for an unknown id, a run that is not hosted in this session, a runner without the `sleep` capability, and a finished run. A `sleeping` run stays `running` with `sleeping: true` once liveness reports `sleeping`. When liveness reports `interrupted` or `unknown` (or `settled` without a result), the run settles `failed` with `outcome: "indeterminate"`. The same outcome marks a stop the adapter did not confirm, and a durable spawn request the resident host was processing when it restarted. Hosted runs work with `agents.run`, `spawn`, `wait`, `status`, `stop`, `sleep`, `wake`, `steer`, `followUp`, the dashboard, budgets, and `residency: "durable"`. Persistent actors need a worker runner.
340
473
 
341
- Registration is process-local. The resident host runs Pi with `--no-extensions`, so a durable run of a custom runner requires `residentModule`: an absolute path to an ES module that registers the adapter when imported. Fabric refuses a durable spawn without it. The resident host imports the module before launch. On restart it imports it again and calls `attach(locator, context, reporter)` for every unfinished hosted run; a run whose runner cannot be loaded settles indeterminate. When the resident host shuts down, durable hosted runs are detached; they keep running and are re-attached on the next start. Session hosted runs are stopped with the session.
474
+ Registration is process-local. The resident host runs Pi with `--no-extensions`, so a durable run of a custom runner requires `residentModule`: an absolute path to an ES module that registers the adapter when imported. Fabric refuses a durable spawn without it. The resident host imports the module before launch. On restart it imports it again and calls `attach(locator, context, reporter)` for every unfinished hosted run; a run whose runner cannot be loaded settles indeterminate. When the resident host shuts down, durable hosted runs are detached; they keep running and are re-attached on the next start. If the resident host is gone while a durable hosted run is unfinished, `agents.wait` starts a new host, which re-attaches the run. The wait fails with the start error when the host cannot start. It also fails after the host stops three times during one wait. A new host re-attaches only hosted runs, so a wait on any other unfinished durable run fails at once when its host is gone. That wait also settles the run `failed` with `outcome: "indeterminate"`, so `agents.status` and `agents.list` stop reporting it as running. `agents.status` itself only reads the persisted record. Session hosted runs are stopped with the session.
342
475
 
343
476
  An illustrative daemon-backed adapter:
344
477
 
@@ -381,14 +514,14 @@ registerAgentRunner(runner);
381
514
 
382
515
  ### Worker protocol
383
516
 
384
- A worker runner process talks to Fabric through four files named in `context.files`. `pi-fabric/runners` exports a JSON Schema for each (`AgentRunRecordSchema`, `LifecycleLineSchema`, `TranscriptEventSchema`, `SteerCommandSchema`, protocol version `FABRIC_WORKER_PROTOCOL_VERSION = 1`). Readers ignore unknown fields.
517
+ A worker runner process talks to Fabric through four files named in `context.files`. `pi-fabric/runners` exports a JSON Schema for each (`AgentRunRecordSchema`, `LifecycleLineSchema`, `TranscriptEventSchema`, `SteerCommandSchema`, protocol version `FABRIC_WORKER_PROTOCOL_VERSION = 1`). Readers ignore unknown fields. Fabric can add a steer command type without changing the protocol version, as it did for `ui_decision`, which it sends only to a runner that declares `questions`. A worker must ignore a steer line whose `type` it does not know, as Fabric's own worker does.
385
518
 
386
519
  | File | Direction | Content |
387
520
  | --- | --- | --- |
388
521
  | `statusFile` | worker writes | The run record, replaced atomically (write a temporary file, then rename). `status` moves from `running` to `completed`, `failed`, `stopped`, or `timed_out`; `text`, `value`, `error`, `turns`, `toolCalls`, `usage` (cumulative), `currentTool`, and `blockedOn` are the public fields. |
389
522
  | `lifecycleFile` | worker appends | One `{ version: 1, event, occurredAt, data }` line per event: `tokens.usage` (a per-event increase), `question` (a dialog to route), and the `pi.*` lifecycle events. |
390
523
  | `logFile` | worker appends | Transcript events for logs and the dashboard: `message_end` with a `user` or `assistant` message, `tool_execution_start`, `tool_execution_end`, and `extension_error`. |
391
- | `steerFile` | Fabric appends | Commands with `id` and `ts`: `steer`, `follow_up`, `set_steering_mode`, `set_follow_up_mode`, `compact`, and `ui_response` (`requestId` plus `value`, `confirmed`, or `cancelled`) answering a routed `question`. |
524
+ | `steerFile` | Fabric appends | Commands with `id` and `ts`: `steer`, `follow_up`, `set_steering_mode`, `set_follow_up_mode`, `compact`, `ui_decision` (`requestId` and `decisionId`) naming the decision behind a routed `question`, which the worker records in `blockedOn.decisionId`, and `ui_response` (`requestId` plus `value`, `confirmed`, or `cancelled`) answering it. |
392
525
 
393
526
  A worker that exits without a terminal record is treated as a dead transport: it is relaunched only when it made no progress, and otherwise settles failed.
394
527
 
@@ -420,6 +553,8 @@ This is the host-level equivalent of the `pi-model-switch` extension's `switch_m
420
553
 
421
554
  Herdr uses its local socket API to create an argv-backed background tab as one atomic operation. It does not change focus or require shell quoting. Automatic selection works only when the parent Pi process already runs in Herdr. This requires `HERDR_ENV=1` with an injected workspace and socket. Select `transport: "herdr"` under the same conditions. Use the attach command in the handle to open a child directly.
422
555
 
556
+ Inside Herdr, a root session also shows its running agents on its own pane, whatever transport they use, and marks the pane blocked while a child question waits on the user. See `ui.herdrStatus` in the [configuration reference](configuration.md#ui).
557
+
423
558
  LocalTerm provides the required primitives that match tmux: detached creation, pinning, listing, capture, exec, attach, and kill. Pi Fabric requires no LocalTerm patch. Start the daemon before you select this transport:
424
559
 
425
560
  ```bash
@@ -500,6 +635,8 @@ Fabric uses one participant directory for each project. Every live entity has a
500
635
 
501
636
  `agents.self()` returns the participant record for the caller. `agents.sessions()` lists every live root Pi session, including the caller's root and peers, as symmetric participant records for session-to-session coordination. Call `agents.members({ scope?, kinds?, includeStale? })` to list all kinds. `agents.list({ scope? })` lists agents and uses `scope: "local"` by default. Set the scope to `"lineage"` for descendants of the same root across recursive runtimes. Use `"project"` for all live project agents. `agents.main()` and `agents.peers()` remain convenient compatibility projections. Standard discovery hides participants with expired execution-host leases. Shared summaries include operational metadata. They exclude agent prompts, results, and errors.
502
637
 
638
+ Live discovery never returns a session that has left. To see recent departures, call `agents.departed({ limit? })`. It lists other root Pi sessions that are no longer live, newest first, each with `status`, `sessionId`, `cwd`, `label`, `startedAt`, and `lastSeenAt`. `status: "stopped"` means the session closed cleanly and left a tombstone. `status: "lost"` means its host lease expired without a clean close, so `lastSeenAt` is its last heartbeat. A session that is live again drops out of the list. Tombstones live under their own mesh prefix, so `agents.sessions()`, `agents.peers()`, and `agents.members()` never read them. Only roots get tombstones; child agents and actors simply leave. `mesh.departedLimit` and `mesh.departedRetentionMs` bound how many tombstones are kept and for how long.
639
+
503
640
  ```ts
504
641
  const main = await agents.main();
505
642
  const sessions = await agents.sessions();
@@ -513,9 +650,11 @@ const lineage = await agents.list({ scope: "lineage" });
513
650
  return { self: await agents.self(), lineage };
514
651
  ```
515
652
 
516
- Child dialogs (`select`, `confirm`, `input`, `editor`) are cancelled by default. With `agents.childQuestions: "route"` they reach the parent's UI, or a root-held [durable decision](decisions.md#routed-child-questions) when the parent is headless; the run record shows `blockedOn` while one waits.
653
+ Child dialogs (`select`, `confirm`, `input`, `editor`) are cancelled by default. With `agents.childQuestions: "route"` they reach the parent's UI, or a root-held [durable decision](decisions.md#routed-child-questions) when the parent is headless or the run is durable; the run record shows `blockedOn`, with the decision's `decisionId`, while one waits. A run spawned with `holdQuestions: true` raises each question as a root-held decision with a 30-day deadline instead, even when the parent has a UI; see [Holding a question for a person](decisions.md#holding-a-question-for-a-person).
517
654
 
518
- For Main and one-shot agents, `steer` arrives after the tool calls in the current turn and before the next model call. `followUp` waits until the current run settles. For actors, both operations add a message to the serial mailbox. `agents.status({ id })` accepts any participant ID. It returns complete details for a local run or actor and a bounded directory summary for a remote participant. `agents.setSteeringMode` and `setFollowUpMode` continue to control local one-shot runs.
655
+ Routing also gives a Pi child with extensions the tools in `agents.childQuestionTools` (default `["ask"]`), so the caller does not have to name them in `tools`. A child's system prompt lists only the extension tools its `tools` allowlist permits.
656
+
657
+ For Main and one-shot agents, `steer` arrives after the tool calls in the current turn and before the next model call. A workflow that runs inside one `fabric_exec` is one tool call, so Main's steer waits for all of it; move the program to the background (Ctrl+B twice, or `background: true`) to steer Main while it runs, see [Background programs](background-tasks.md#background-programs). `followUp` waits until the current run settles. For actors, both operations add a message to the serial mailbox. `agents.status({ id })` accepts any participant ID. It returns complete details for a local run or actor and a bounded directory summary for a remote participant. `agents.setSteeringMode` and `setFollowUpMode` continue to control local one-shot runs.
519
658
 
520
659
  Local routing returns `"main"` or `"local"`. For cross-process `steer`, `followUp`, and `stop`, Fabric resolves the exact owner of the target. It sends a control command addressed to that owner and waits for an acknowledgement that matches the version, target, and owner identity. Success returns `routed: "mesh", acknowledged: true` after this verified acknowledgement. Unknown IDs, stale owners, rejection, and timeout throw an error. The dashboard actions `s`, `u`, and `x` use the same route. Set `mesh.enabled` to use cross-process control. See [`references/agents.md`](../skillsets/typescript/fabric-exec/references/agents.md).
521
660
 
@@ -525,7 +664,7 @@ An owner keeps its host ID across restarts (a Pi session's Main ID, or a residen
525
664
 
526
665
  ### Peer labels and queue gates
527
666
 
528
- Every root participant mints a project-scoped label such as `FAB-1` when it first publishes: the prefix derives from the project directory basename (initials for multi-word names, up to three letters for single-word names) and the number comes from a mesh-wide monotonic counter, so retired labels are never reused. Labels appear on participant records, peer projections, and the dashboard, giving other sessions' tooling a stable handle to show users in place of raw session ids.
667
+ Every root participant mints a project-scoped label such as `FAB-1` at its first Fabric use (a `fabric_exec` run, an agent, or an actor), so opening Pi and leaving it idle takes no number: the prefix derives from the project directory basename (initials for multi-word names, up to three letters for single-word names) and the number comes from a mesh-wide monotonic counter, so a number is never minted twice. The counter belongs to a generation (`FABRIC_PEER_LABEL_SEQUENCE`, currently 3); this generation restarted numbering at 1, retired the labels earlier generations recorded, and skips any number a still-running older session holds. Concurrent sessions claim numbers by compare-and-swap under the mesh lock, so each gets its own. A resumed session keeps its label: it reads the `pi-fabric-peer` entry it recorded for its own participant id and reuses that label, without taking a number, at once, even before its first Fabric use, unless the label belongs to another project, comes from an older counter generation, or another live participant holds it. Forks and clones have new participant ids, so they take new numbers. Labels appear on participant records, peer projections, and the dashboard, giving other sessions' tooling a stable handle to show users in place of raw session ids. A root session also shows its own label at the head of the Fabric widget (or in the Pi footer when the widget is hidden) and, when configured, in its Herdr tab or pane name, so you can tell which terminal is `FAB-3`. Headless hosts read the label and participant id from the `pi-fabric-peer` session entry through Pi's RPC `get_entries`; see `ui.sessionLabel` in [UI configuration](configuration.md#ui).
529
668
 
530
669
  Two host-local, versioned events on `pi.events` let queue extensions coordinate with peers:
531
670
 
@@ -552,7 +691,7 @@ File or git changes you did not make may be theirs: do not revert or overwrite t
552
691
  - **Cache safety.** The notice is a persistent transcript message appended at a turn boundary. The system prompt, tool declarations, and every earlier message stay byte-identical, so the provider's cached prefix remains valid and only the notice itself is new input. The mid-run notice is a native `turn_end` boundary entry: it rides the request the run was about to make and never triggers an extra one. The text is deterministic for a given change. It carries labels, participant ids, and a working directory when that differs from the caller's, and no clock, run status, or model.
553
692
  - **Once per change.** Fabric rebuilds what the model was told from the notices on the active branch, so resuming or navigating a session does not repeat one. A compaction may drop earlier notices from the context, so the current peers are stated again at the next boundary.
554
693
  - **Departures are debounced.** A peer is reported gone only after it has been absent for 20 seconds, longer than the 15-second host lease, so a missed heartbeat or a wake from sleep is not reported as a departure and a rejoin. Arrivals are reported at once.
555
- - **Scope.** Only root sessions receive notices. Child agents and actors are coordinated by their parent. A notice shares what the participant directory already shares: prompts, results, and errors stay local.
694
+ - **Scope.** Only root sessions with a UI receive notices. A run without a UI, such as `pi -p`, gets none: nobody reads the notice there, and the model's reply to it would replace the answer in the output. Child agents and actors are coordinated by their parent. A notice shares what the participant directory already shares: prompts, results, and errors stay local.
556
695
 
557
696
  **Limitation:** a session joins the participant directory when its Fabric runtime activates, which is normally its first `fabric_exec` call. Before that it neither sees peers nor is seen by them, so the first notice of a fresh session arrives after that first call, before the next model request. A session that never runs `fabric_exec` stays invisible.
558
697
 
@@ -631,6 +770,8 @@ A project-scoped actor stores one definition for the project. Select storage per
631
770
  - **Session binding.** A mode-`0600` file stores only `model` and `thinking` for one Pi session ID. It survives a resume of that session and does not rewrite `actors.json`.
632
771
  - **Runtime.** One owner keeps the stable actor identity, serial mailbox, and runner session. Other sessions send direct work to that owner.
633
772
 
773
+ Creation rejects names already present in the visible project or session scope, including stopped actors. Creating a stopped actor's namesake is refused; automatic replacement is disabled. To reuse the name, explicitly remove the stopped actor first with `agents.remove({ id })`; removal deletes its retained actor session and history. This is a compatibility change from automatic replacement. The refusal does not provide distributed ownership or execution fencing between independent hosts.
774
+
634
775
  Fabric resolves each activation in this order:
635
776
 
636
777
  ```text
@@ -676,6 +817,12 @@ Fabric sanitizes host-event JSON before placing it in the mailbox. The JSON incl
676
817
 
677
818
  Actors handle one message at a time. By default, they coalesce repeated host events, which is useful for `message_update` and `tool_execution_update`. They restore from the trusted project actor registry.
678
819
 
820
+ ### Unreadable actor files
821
+
822
+ Fabric keeps actor state in three kinds of file: the shared registry `actors.json` under the mesh `actors/` directory, a binding file per session under its `bindings/` directory, and the template library `~/.pi/agent/fabric/actors/global-actors.json`. A missing file reads as empty. If a file exists but cannot be read or parsed, every action that would save it fails with `Cannot read Fabric actor store <path>: <detail>`. A template library that cannot be read also produces a warning at startup. Fabric does not overwrite the file, so the other hosts' actors, the other bindings, and the saved templates stay on disk. Shutdown still runs to completion and then reports the same error, without saving the suspended state of this session's actors.
823
+
824
+ To recover, fix the problem the message names. Restore read permission for your user, or repair the JSON by hand. To start with an empty file instead, move the file aside, for example to `actors.json.bak`, and copy back any entries you want to keep. Fabric reads the file again on the next access, so you do not need to restart.
825
+
679
826
  ### Native asynchronous vision handoff
680
827
 
681
828
  A vision handoff does not require a separate extension that watches events. Create one persistent actor, select a multimodal model, and subscribe to `input`. Fabric automatically detects and attaches images from the prompt. Passive `steer` sends the description to Main without starting an unrelated idle turn. Set `coalesce: false` to preserve separate image prompts while the vision actor is busy:
@@ -768,7 +915,7 @@ The `offset` values on log lines and all page cursors are byte offsets in the JS
768
915
 
769
916
  ## Global actor templates
770
917
 
771
- Persistent actors belong to a project mesh. If you want to reuse a persona in several projects, store it in the project-independent **template library**. This library is in your agent directory at `~/.pi/agent/fabric/actors/`. A template contains only an actor definition, including its name, instructions, subscriptions, and run settings. It contains no mailbox, session transcript, run logs, or other history. Templates are inactive. Import one into a project to run it.
918
+ Persistent actors belong to a project mesh. If you want to reuse a persona in several projects, store it in the project-independent **template library**. This library is in your agent directory at `~/.pi/agent/fabric/actors/`. A template contains only an actor definition, including its name, instructions, subscriptions, and run settings. It contains no mailbox, session transcript, run logs, or other history. Templates are inactive. Import one into a project to run it. If the library file exists but cannot be read or parsed, Fabric warns at startup, and every global template action fails with that error until the file reads again. Fabric never replaces an unreadable library with an empty one.
772
919
 
773
920
  ```ts
774
921
  // Store a reusable persona in the global registry. This does not create a live actor.
@@ -781,7 +928,7 @@ return agents.create({
781
928
  });
782
929
 
783
930
  // List the templates. Then create a new actor from one in the current project.
784
- const [template] = agents.actors({ scope: "global" });
931
+ const [template] = await agents.actors({ scope: "global" });
785
932
  return agents.import({ name: template.name }); // create it without inherited history
786
933
  return agents.import({ name: "security-reviewer", as: "security-reviewer-2" }); // rename it if the name exists
787
934
 
@@ -105,6 +105,10 @@ preflight, and callers requiring all final errors to throw should omit `settle`.
105
105
 
106
106
  Fabric caps final `fabric_exec` output at 50,000 characters by default, which matches Pi's built-in 50KB tool ceiling. Failed executions get a tighter 20,000-character visible ceiling, and the complete output stays in the same private artifact. An oversized structured return shares that budget across every multiline section and preserves both ends with explicit omission markers. Unstructured output keeps its global beginning and end. Fabric writes the complete output to a mode-`0600` temporary artifact and includes the artifact path inside the visible ceiling. The model can then retrieve a targeted range without carrying the entire result. Type-check diagnostics use the same ceiling. Models should still filter noisy commands and return only useful evidence, because source-side projection preserves more relevant information than post-format truncation. When a later nested call fails after earlier calls completed, the error adds a bounded list of completed refs and paths. The model can inspect that list before repeating side effects. Nested outputs the guest did not return are never exposed. Raw media never enters those text channels: image payloads in `fabric_exec` logs, results, and error text, in worker event lines, and in actor host events are replaced by a `{type: "image", mediaIndex, mimeType, redacted: true}` descriptor and hoisted out of band, so a nested `pi.read` image stays available to a multimodal model without pushing hundreds of KB of base64 into one serialized line. A child event line that only exceeds the 4 MB cap because it embeds raw base64 is sanitized to avoid failing the run.
107
107
 
108
+ ### Ending the turn from a program
109
+
110
+ A Pi tool can return `terminate: true` to end the agent loop after its tool batch, as a compaction tool does after it compacts the session. Called from a program, such a tool still asks for the same thing. The program runs to completion, and the `fabric_exec` result then carries `terminate: true`. The flag counts only when the nested call succeeded and the program succeeded. A failed program keeps the turn going so the model can see the error. Pi ends the loop only when every tool result in the batch asks for it.
111
+
108
112
  ### Foreground tools
109
113
 
110
114
  Full code mode keeps `fabric_exec` as the single model tool so that every effect passes one typed, budgeted, audited path. A few extension tools only make sense as a direct model turn, such as a question to the human. The `foreground` policy declares a capped, explicit list of such registered tools beside `fabric_exec`. It changes declaration only. It grants no new authority: a direct call takes the same `tool_call` hooks, the same `extensions.<name>` approval ref and risk class as the program path, and the tool stays callable from programs. Pi core tools, Pi built-ins, and Schema enforce mode are excluded. See [foreground tools](configuration.md#foreground-tools).
@@ -146,4 +150,4 @@ Control topics and topology and legacy state prefixes are reserved from guest me
146
150
  - Actor responses enter the main context only through the delivery policy fixed at creation. Directive output passes schema validation. It is still untrusted model output, and the main agent should weigh it.
147
151
  - A project-scoped actor has one execution owner. Passive sessions do not consume host events, drain a second mailbox, or persist shutdown state. They can read the shared definition, mailbox, and logs; change their own model and thinking binding; and send direct calls to the authenticated owner. The owner can also execute a routed `stop`. Shared runtime settings stay owner-only. Fabric routes durable removal to the resident owner.
148
152
  - A persisted actor can lose its advertised owner after a host lease expires. If its lineage root is also absent, a residency-matched host may adopt it and change `rootId`. The registry grants ownership only after it stores the new `rootId` and an `adoptedAt` fence under lock. Concurrent starters converge on one adopter. The 30-second fence gives a new adopter time to publish its participant record.
149
- - Shared `actors.json` writes use a stale-safe lock and merge only records owned by the writer. One owner cannot overwrite another owner's newer actor record. Use session scope for independent actor sets or private mailbox histories. Different model or thinking choices do not require it. Mesh events remain append-only until bounded compaction keeps the newest tail. Archive or remove an old mesh root when that retained history is no longer useful.
153
+ - Shared `actors.json` writes use a stale-safe lock and merge only records owned by the writer. One owner cannot overwrite another owner's newer actor record. A missing registry reads as empty. If the file exists but cannot be read or parsed, the write fails and the file is left unchanged. Entries that fail validation are kept as written. Session binding files and the global template library follow the same rule. Use session scope for independent actor sets or private mailbox histories. Different model or thinking choices do not require it. Mesh events remain append-only until bounded compaction keeps the newest tail. Archive or remove an old mesh root when that retained history is no longer useful.
@@ -14,6 +14,7 @@ interface FabricPersistedExecutionDetailsV1 {
14
14
  audits: FabricLegacyRenderAudit[];
15
15
  phases: string[];
16
16
  error?: string;
17
+ omittedCalls?: { count: number; done: number }; // audits the size bound dropped
17
18
  }
18
19
 
19
20
  interface FabricExecutionTraceV1 {
@@ -150,4 +151,4 @@ An invalid or unknown trace, when present, blocks semantic legacy reinterpretati
150
151
 
151
152
  ## Limitations
152
153
 
153
- Persisted audits are verbatim. Resumed final rendering shows read bodies, edit diffs, write bodies, bash output, agent tasks, and provider results. Durable traces still store bounded projections. Bash command text stays in the trace, and arbitrary argument or result content never enters it. That exclusion covers discovery queries, workflow descriptions and data, external and MCP arguments, and provider results. When arguments are omitted from the trace, generic failure resolution keeps only the ref identity. The envelope stays bounded. Past 512 KiB, display-only audits trim first. Trace-only cards, old or trimmed, render `not retained across reload` markers for content the session record does not hold. Workflow activity content stays available only while the live execution result or activity store remains in memory.
154
+ Persisted audits are verbatim. Resumed final rendering shows read bodies, edit diffs, write bodies, bash output, agent tasks, and provider results. Durable traces still store bounded projections. Bash command text stays in the trace, and arbitrary argument or result content never enters it. That exclusion covers discovery queries, workflow descriptions and data, external and MCP arguments, and provider results. When arguments are omitted from the trace, generic failure resolution keeps only the ref identity. The envelope stays bounded. Past 512 KiB, display-only audits trim first, and `omittedCalls` counts the dropped audits so the resumed card still reports every call. Trace-only cards, old or trimmed, render `not retained across reload` markers for content the session record does not hold. Workflow activity content stays available only while the live execution result or activity store remains in memory.
@@ -2,7 +2,10 @@
2
2
 
3
3
  Fabric-managed `pi.bash` and `pi.powershell` commands have session-owned job IDs.
4
4
  `background: true`, the shell hang threshold, or Ctrl+B twice detaches a command;
5
- an explicit shell `timeout` remains a hard cap. Completed jobs have terminal states
5
+ an explicit shell `timeout` remains a hard cap. A foreground shell shows the
6
+ shortcut while it waits, including while output streams; the first keypress prompts
7
+ for confirmation.
8
+ Completed jobs have terminal states
6
9
  (`exited`, `failed`, `killed`, `timed_out`), not the old `spilled` state. `exited`
7
10
  means exit code zero, not that the user's assignment is verified.
8
11
 
@@ -24,6 +27,37 @@ branch navigation discards delivery from old-frontier jobs. Session shutdown/rel
24
27
  closes the inbox before aborting jobs, so cleanup cannot start a new turn.
25
28
  Print-mode processes do not stay alive indefinitely just to receive late events.
26
29
 
30
+ ## Background programs
31
+
32
+ A whole `fabric_exec` program can leave its tool call the same way. Pi delivers
33
+ a steering message to Main only after the current tool calls finish, so while a
34
+ long workflow runs inside one `fabric_exec`, a message typed to Main waits for
35
+ every agent in it. Moving the program to the background ends that tool call and
36
+ Main takes the steer on its next request.
37
+
38
+ - **Ctrl+B twice** within one second, from an empty editor, while a
39
+ `fabric_exec` runs. A nested shell that is still waiting is spilled first, as
40
+ before; press the chord again to move the program. With text in the editor,
41
+ Ctrl+B stays cursor-left.
42
+ - **`background: true`** on the `fabric_exec` call starts the program as a task
43
+ and returns at once. The model uses it for long workflows whose result it
44
+ does not need before continuing.
45
+
46
+ The tool call returns the task ID. The program keeps running with its own
47
+ cancellation signal: Esc and later turns no longer stop it, and `tasks.stop`,
48
+ the task detail's `x`, or session shutdown do (stopping also stops the child
49
+ agents it owns). Its child agents stay steerable through `agents.steer`,
50
+ `/fabric chat`, or the agent list. Progress lines and the final result go to
51
+ the task's bounded log; the result reaches the owning agent as a background
52
+ task event, bounded to about 6,000 characters, with the same batching, wakeup,
53
+ and suspension rules as shell tasks. The live-task reminder lists running
54
+ programs. A background program never claims a Prewalk handoff, and the shell
55
+ timing bridge below does not report programs.
56
+
57
+ Main and a background program can edit the same files at the same time. Detach
58
+ only work whose files Main will not touch, or tell Main what it should leave
59
+ alone.
60
+
27
61
  ## Extension timing bridge
28
62
 
29
63
  Fabric emits `pi-fabric:shell:timing:v1` on the owning session's `pi.events` bus.
@@ -75,20 +109,69 @@ suspension suppresses the reminder until new input, just like automatic delivery
75
109
  Reload/session shutdown removes the context hook along with the inbox. Awareness
76
110
  works without a terminal and does not restore processes across Pi restarts.
77
111
 
112
+ ### Prompt-cache warming while yielded
113
+
114
+ Spilling ends the tool call, so the agent run settles and Pi's cache warmer moves
115
+ to its idle phase. Pi prices idle refreshes with a fixed low continuation
116
+ probability, because an idle session usually waits on a person. While a
117
+ spilled job whose completion wakes this agent is still running, the next real
118
+ request is near-certain. The inbox handles Pi's `cache_warming_decision` and,
119
+ only when Pi chose `stop` in the idle phase, re-prices that refresh at
120
+ probability 1 against Pi's own $0.05 savings threshold, returning `warm` if it
121
+ clears.
122
+
123
+ It never downgrades `warm` or touches streaming-phase decisions, and counts the
124
+ same jobs as the reminder above minus UI-only monitors. Refreshes are ordinary
125
+ paid `cache_warm` usage, not a guarantee of a cache hit or net savings. Fabric
126
+ neither changes Pi's warming setting nor bypasses native request eligibility.
127
+
128
+ To opt in, merge these fields into Pi's **global** `~/.pi/agent/settings.json`
129
+ (or the settings file under your custom Pi agent directory), not project settings:
130
+
131
+ ```json
132
+ {
133
+ "cacheWarming": "idle",
134
+ "showCacheMissNotices": true
135
+ }
136
+ ```
137
+
138
+ `showCacheMissNotices` is optional diagnostics. Restart Pi after a file edit and
139
+ send a new real request; changing the policy cannot revive an already stopped
140
+ warmer or recover a cache entry that has expired. Pi's default `"streaming"` mode
141
+ stops warming when the run settles, before any extension is asked. `"off"`
142
+ remains off. No extra Fabric setting or `cache.hold` call is required for this
143
+ idle-decision override; scoped leases are a separate optional capability.
144
+
145
+ For the five-minute cache tier, Pi's first refresh is due at 270 seconds after
146
+ the real request. Fabric's default 120-second shell spill can settle the run
147
+ before then, which explains why streaming warming records no refresh while the
148
+ agent waits. With idle warming enabled, `/session` shows the native warming
149
+ state/decision; successful refreshes appear as `cache_warm` usage, and
150
+ `cache.status()` exposes their receipts in its bounded observation window.
151
+ A missing receipt alone does not prove a cache miss: small prompts, unsupported
152
+ models, unsafe replays, changed context, or expired refresh deadlines can prevent
153
+ warming.
154
+
155
+ Pi's 30-minute idle safety horizon still applies, measured from the real request
156
+ that started warming, **not** from spill or the latest refresh. Jobs may outlast
157
+ both warming and the cache TTL; this patch does not keep them warm indefinitely.
158
+ `tests/shell-cache-warming-sdk.test.ts` exercises native scheduling, replay,
159
+ receipts, completion wakeup, default/off/UI-only exclusions, and the safety
160
+ horizon with an offline provider; it does not measure live-provider cache hits.
161
+
78
162
  ## Inspection and control
79
163
 
80
- - `/fabric tasks` or **Ctrl+Alt+T** opens the lazy inspector. A single task opens
81
- directly. `/fabric tasks <id-or-unique-prefix>` opens a specific task.
82
- - The widget shows up to three tasks, elapsed time, and the command or short
83
- description. It stays alive after the Fabric program returns. Completion hints
84
- expire after 30 seconds; retained jobs remain in the inspector.
85
- - The rounded, theme-aware inspector groups tasks into **Active**, **Needs
86
- attention** (failed/timed out), and **Finished**. Purpose/command labels lead;
87
- IDs, elapsed time, exit codes and monitor delivery sit beneath each task.
88
- Live tasks use Fabric's activity spinner; completed tasks have fixed status icons.
89
- Arrows/PageUp/PageDown navigate the list without selecting group headings.
90
- - Enter opens detail; arrows/PageUp/PageDown scroll the bounded output tail; G
91
- follows the tail; x twice within three seconds stops; Esc backs out/closes.
164
+ - Focus the footer list with **↓** from an empty editor or `/fabric tasks`, then
165
+ press **Enter** on a task to open its lazy detail.
166
+ `/fabric tasks <id-or-unique-prefix>` opens a specific task directly.
167
+ - The footer lists tasks individually after agents, with elapsed time and the
168
+ command or short description. It stays alive after the Fabric program returns.
169
+ Completion hints expire after 30 seconds; retained jobs remain inspectable by ID.
170
+ - The rounded, theme-aware detail shows one task. Live tasks use Fabric's
171
+ activity spinner; completed tasks have fixed status icons. There is no
172
+ secondary task-list overlay or global task-list shortcut.
173
+ - Arrows/PageUp/PageDown scroll the bounded output tail; G follows the tail;
174
+ x twice within three seconds stops; Esc closes the detail in one step.
92
175
  - Elapsed time and time since last output are separate. A quiet shell is not
93
176
  automatically classified as stuck. Opening/closing the inspector doesn't stop it.
94
177
  - `ui.enabled` and `ui.widget` retain their existing meaning. Rendering is TUI-only;
@@ -200,9 +283,12 @@ Subscribed actors, including durable actors on the resident host, wake on it.
200
283
 
201
284
  The default store is `<cwd>/.jev-fabric-native`, the same one Claude Code,
202
285
  Codex or a shell uses for `jev-fabric` in that project, so it doubles as a
203
- process registry across harnesses. `tasks.external` lists jobs there that no
204
- task of this session tracks (id, state, label, start time). `tasks.adopt({jobId,
205
- description?})` attaches one as a durable task of this session: output,
286
+ process registry across harnesses. Before a durable job or session uses the
287
+ default store, Fabric writes a `.gitignore` containing `*` into it, so the store
288
+ does not show as untracked files in a Git checkout. A configured `home` is left
289
+ as it is. `tasks.external` lists jobs there that no task of this session tracks
290
+ (id, state, label, start time). `tasks.adopt({jobId, description?})` attaches
291
+ one as a durable task of this session: output,
206
292
  completion notification, wait/watch/stop and an inspector row. Adoption never
207
293
  restarts or signals the process; stopping it afterwards does.
208
294
 
@@ -40,7 +40,7 @@ Native results are projected from the final middleware-filtered tool result:
40
40
  - Tools without structured output return text. Native image reads return Pi's image block; call `image(block)` to display it.
41
41
  - Blocked, invalid or unstructured failed calls reject. Content-only middleware redaction never restores the original structured payload.
42
42
 
43
- These are **not aliases of the normalized Fabric results**. `pi.bash` still rejects nonzero exits unless `settle:true`, `pi.edit/write` still return Fabric envelopes, `extensions.*` still returns its captured envelope, and `mcp.*` still normalizes results and throws on MCP errors. Native foreground shell calls do not auto-detach at `executor.shellHangMs`; explicit Fabric background operations retain their existing contract.
43
+ These are **not aliases of the normalized Fabric results**. `pi.bash` still rejects nonzero exits unless `settle:true`, `pi.edit/write` still return Fabric envelopes, `extensions.*` still returns its captured envelope, and `mcp.*` still normalizes results and throws on MCP errors. Native foreground shell calls do not auto-detach at `executor.shellHangMs`; explicit Fabric background operations retain their existing contract. A detached native shell call (`background: true`, `monitor` or `durable: true`) returns the object `{output, taskId}`, not text, so a program can pass `taskId` to `tasks.wait` or `tasks.get`. When an extension overrides a core tool such as `read`, `nativeTools.read` calls the one definition Pi runs; it is not reported as ambiguous.
44
44
 
45
45
  ### Discovery and collisions
46
46
 
@@ -51,7 +51,7 @@ const fabric = await globalThis.fabric.tools.search({ query: "issues" });
51
51
  return { native, fabric };
52
52
  ```
53
53
 
54
- Native `searchTools` returns `{name,description}[]`, with callable identifiers and advisory declarations. `describeTool(name)` returns a declaration/description **string** or `undefined`. `describeNamespace(name)` returns `{name,description?,instructions?,tools:string[]}` or `undefined`. `ALL_TOOLS` uses those same native identifiers. Search uses BM25; declarations are bounded and dispatch schemas remain authoritative. Actual namespace instructions are exposed only for visible tools.
54
+ Native `searchTools` returns `{name,description}[]`, with callable identifiers and advisory declarations. `describeTool(name)` returns a declaration/description **string** or `undefined`. `describeNamespace(name)` returns `{name,description?,instructions?,tools:string[]}` or `undefined`. `ALL_TOOLS` uses those same native identifiers. Search first prefers exact trimmed callable names, raw names, Fabric refs and final `__` name segments within the requested namespace, then uses BM25. Declarations are bounded by rendered size, with field descriptions retained while they fit. Description shortening/removal precedes structural truncation; enum/union/intersection/tuple, depth and size cuts carry visible markers. Member lists are cut only when the rendered-size budget is exhausted. `fabric.tools.describe({ref})` retrieves the unmodified raw `inputSchema`; `describeTool` remains a declaration string. Dispatch schemas remain authoritative. Actual namespace instructions are exposed only for visible tools.
55
55
 
56
56
  The additive globals retain their existing shapes: Fabric-qualified refs, object-valued `describeTool`, and object-valued namespace tool entries. Use `nativeDiscovery` for native shapes in additive mode. In native mode use `fabric.tools.search/describe/list/call` for Fabric discovery. A single property cannot simultaneously be Fabric's `tools.search` and a registered tool named `search`.
57
57