@sixb/core 0.1.19 → 0.1.21

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 (765) hide show
  1. package/dist/actions/execution.d.ts.map +1 -1
  2. package/dist/actions/index.js +54 -47
  3. package/dist/actions/index.js.map +1 -1
  4. package/dist/actions/request.d.ts.map +1 -1
  5. package/dist/actions/run-authorization.d.ts +9 -0
  6. package/dist/actions/run-authorization.d.ts.map +1 -1
  7. package/dist/activity/connection.d.ts +62 -0
  8. package/dist/activity/connection.d.ts.map +1 -0
  9. package/dist/activity/device.d.ts +8 -0
  10. package/dist/activity/device.d.ts.map +1 -0
  11. package/dist/activity/execution.d.ts +48 -0
  12. package/dist/activity/execution.d.ts.map +1 -0
  13. package/dist/activity/service.d.ts +79 -0
  14. package/dist/activity/service.d.ts.map +1 -0
  15. package/dist/activity/shares.d.ts +24 -0
  16. package/dist/activity/shares.d.ts.map +1 -0
  17. package/dist/activity/timeline.d.ts +96 -0
  18. package/dist/activity/timeline.d.ts.map +1 -0
  19. package/dist/agents/index.d.ts +2 -1
  20. package/dist/agents/index.d.ts.map +1 -1
  21. package/dist/agents/index.js +63 -50
  22. package/dist/agents/index.js.map +1 -1
  23. package/dist/agents/request.d.ts.map +1 -1
  24. package/dist/agents/skills.d.ts.map +1 -1
  25. package/dist/agents/streams/index.js +3 -3
  26. package/dist/agents/streams/internal.js +3 -3
  27. package/dist/agents/types.d.ts +8 -8
  28. package/dist/agents/types.d.ts.map +1 -1
  29. package/dist/agents/validation.d.ts +1 -1
  30. package/dist/agents/validation.d.ts.map +1 -1
  31. package/dist/artifacts/address.d.ts +48 -0
  32. package/dist/artifacts/address.d.ts.map +1 -0
  33. package/dist/artifacts/csv.d.ts +22 -0
  34. package/dist/artifacts/csv.d.ts.map +1 -0
  35. package/dist/artifacts/errors.d.ts +11 -0
  36. package/dist/artifacts/errors.d.ts.map +1 -0
  37. package/dist/artifacts/execution.d.ts +43 -0
  38. package/dist/artifacts/execution.d.ts.map +1 -0
  39. package/dist/artifacts/frames/assets.d.ts +28 -0
  40. package/dist/artifacts/frames/assets.d.ts.map +1 -0
  41. package/dist/artifacts/frames/grants.d.ts +37 -0
  42. package/dist/artifacts/frames/grants.d.ts.map +1 -0
  43. package/dist/artifacts/frames/index.d.ts +10 -0
  44. package/dist/artifacts/frames/index.d.ts.map +1 -0
  45. package/dist/artifacts/frames/index.js +892 -0
  46. package/dist/artifacts/frames/index.js.map +14 -0
  47. package/dist/artifacts/frames/kit.d.ts +66 -0
  48. package/dist/artifacts/frames/kit.d.ts.map +1 -0
  49. package/dist/artifacts/frames/probe.d.ts +41 -0
  50. package/dist/artifacts/frames/probe.d.ts.map +1 -0
  51. package/dist/artifacts/frames/protocol.d.ts +98 -0
  52. package/dist/artifacts/frames/protocol.d.ts.map +1 -0
  53. package/dist/artifacts/frames/runtime.d.ts +13 -0
  54. package/dist/artifacts/frames/runtime.d.ts.map +1 -0
  55. package/dist/artifacts/html.d.ts +6 -0
  56. package/dist/artifacts/html.d.ts.map +1 -0
  57. package/dist/artifacts/ids.d.ts +5 -0
  58. package/dist/artifacts/ids.d.ts.map +1 -0
  59. package/dist/artifacts/index.d.ts +16 -0
  60. package/dist/artifacts/index.d.ts.map +1 -0
  61. package/dist/artifacts/index.js +125 -0
  62. package/dist/artifacts/index.js.map +10 -0
  63. package/dist/artifacts/kinds.d.ts +5 -0
  64. package/dist/artifacts/kinds.d.ts.map +1 -0
  65. package/dist/artifacts/limits.d.ts +28 -0
  66. package/dist/artifacts/limits.d.ts.map +1 -0
  67. package/dist/artifacts/outline.d.ts +44 -0
  68. package/dist/artifacts/outline.d.ts.map +1 -0
  69. package/dist/artifacts/publish/files.d.ts +15 -0
  70. package/dist/artifacts/publish/files.d.ts.map +1 -0
  71. package/dist/artifacts/publish/index.d.ts +5 -0
  72. package/dist/artifacts/publish/index.d.ts.map +1 -0
  73. package/dist/artifacts/publish/index.js +36 -0
  74. package/dist/artifacts/publish/index.js.map +9 -0
  75. package/dist/artifacts/publish/publish.d.ts +52 -0
  76. package/dist/artifacts/publish/publish.d.ts.map +1 -0
  77. package/dist/artifacts/publish/references.d.ts +27 -0
  78. package/dist/artifacts/publish/references.d.ts.map +1 -0
  79. package/dist/artifacts/publish/validate/document.d.ts +17 -0
  80. package/dist/artifacts/publish/validate/document.d.ts.map +1 -0
  81. package/dist/artifacts/publish/validate/file.d.ts +8 -0
  82. package/dist/artifacts/publish/validate/file.d.ts.map +1 -0
  83. package/dist/artifacts/publish/validate/sheet.d.ts +15 -0
  84. package/dist/artifacts/publish/validate/sheet.d.ts.map +1 -0
  85. package/dist/artifacts/publish/validate/slides.d.ts +21 -0
  86. package/dist/artifacts/publish/validate/slides.d.ts.map +1 -0
  87. package/dist/artifacts/references.d.ts +12 -0
  88. package/dist/artifacts/references.d.ts.map +1 -0
  89. package/dist/artifacts/resolve.d.ts +41 -0
  90. package/dist/artifacts/resolve.d.ts.map +1 -0
  91. package/dist/artifacts/theme.d.ts +19 -0
  92. package/dist/artifacts/theme.d.ts.map +1 -0
  93. package/dist/artifacts/warnings.d.ts +11 -0
  94. package/dist/artifacts/warnings.d.ts.map +1 -0
  95. package/dist/artifacts/workbook.d.ts +64 -0
  96. package/dist/artifacts/workbook.d.ts.map +1 -0
  97. package/dist/auth/cookies.d.ts +2 -4
  98. package/dist/auth/cookies.d.ts.map +1 -1
  99. package/dist/auth/index.d.ts +0 -2
  100. package/dist/auth/index.d.ts.map +1 -1
  101. package/dist/auth/index.js +14 -20
  102. package/dist/auth/index.js.map +1 -1
  103. package/dist/auth/runtime.d.ts +8 -10
  104. package/dist/auth/runtime.d.ts.map +1 -1
  105. package/dist/auth/session-cache.d.ts +1 -5
  106. package/dist/auth/session-cache.d.ts.map +1 -1
  107. package/dist/auth/strategy.js +1 -1
  108. package/dist/auth/types.d.ts +4 -8
  109. package/dist/auth/types.d.ts.map +1 -1
  110. package/dist/auth/validation.d.ts +0 -1
  111. package/dist/auth/validation.d.ts.map +1 -1
  112. package/dist/authorization/decision.d.ts +2 -4
  113. package/dist/authorization/decision.d.ts.map +1 -1
  114. package/dist/authorization/grant-kinds.d.ts +6 -8
  115. package/dist/authorization/grant-kinds.d.ts.map +1 -1
  116. package/dist/authorization/index.d.ts +0 -1
  117. package/dist/authorization/index.d.ts.map +1 -1
  118. package/dist/authorization/index.js +7 -11
  119. package/dist/authorization/index.js.map +1 -1
  120. package/dist/authorization/resolve.d.ts +1 -1
  121. package/dist/authorization/resolve.d.ts.map +1 -1
  122. package/dist/blob-storage/browser.js +1 -1
  123. package/dist/blob-storage/index.js +2 -2
  124. package/dist/blob-storage/internal.d.ts +1 -1
  125. package/dist/blob-storage/internal.d.ts.map +1 -1
  126. package/dist/blob-storage/internal.js +11 -5
  127. package/dist/blob-storage/internal.js.map +1 -1
  128. package/dist/blob-storage/media-type.d.ts +12 -0
  129. package/dist/blob-storage/media-type.d.ts.map +1 -1
  130. package/dist/bootstrap/index.js +54 -48
  131. package/dist/bootstrap/index.js.map +2 -2
  132. package/dist/{chunk-t6vq7bff.js → chunk-0bphap9y.js} +5 -5
  133. package/dist/{chunk-7mbzgd9m.js → chunk-1cc1xaf3.js} +3 -3
  134. package/dist/chunk-3jms7je7.js +14 -0
  135. package/dist/chunk-3jms7je7.js.map +10 -0
  136. package/dist/{chunk-s54c868q.js → chunk-3qct2mdc.js} +3 -13
  137. package/dist/chunk-3qct2mdc.js.map +12 -0
  138. package/dist/{chunk-6gmfggss.js → chunk-431pyp2c.js} +3 -3
  139. package/dist/{chunk-c85m1hyj.js → chunk-447a5c0p.js} +2 -2
  140. package/dist/chunk-48qjhh6v.js +185 -0
  141. package/dist/chunk-48qjhh6v.js.map +13 -0
  142. package/dist/{chunk-80mc0971.js → chunk-561r0yc9.js} +8 -8
  143. package/dist/{chunk-5e43w60z.js → chunk-5948n82c.js} +2 -2
  144. package/dist/{chunk-yzwja0mj.js → chunk-5hx48dnn.js} +2 -2
  145. package/dist/{chunk-tjb1mk5t.js → chunk-5vems3nx.js} +5 -6
  146. package/dist/{chunk-tjb1mk5t.js.map → chunk-5vems3nx.js.map} +3 -3
  147. package/dist/{chunk-aff7cyea.js → chunk-61y5xs4p.js} +563 -167
  148. package/dist/{chunk-aff7cyea.js.map → chunk-61y5xs4p.js.map} +12 -9
  149. package/dist/chunk-65abf64x.js +13 -0
  150. package/dist/chunk-65abf64x.js.map +10 -0
  151. package/dist/{chunk-z3y5kg1x.js → chunk-6eqsgvxk.js} +3 -3
  152. package/dist/{chunk-z3y5kg1x.js.map → chunk-6eqsgvxk.js.map} +2 -2
  153. package/dist/chunk-6rqgmkde.js +2028 -0
  154. package/dist/chunk-6rqgmkde.js.map +29 -0
  155. package/dist/{chunk-y7rqfrgg.js → chunk-6vb4st8k.js} +29 -38
  156. package/dist/chunk-6vb4st8k.js.map +23 -0
  157. package/dist/chunk-7q8t23v4.js +467 -0
  158. package/dist/chunk-7q8t23v4.js.map +14 -0
  159. package/dist/{chunk-kyzq4wy9.js → chunk-858emn8m.js} +17 -17
  160. package/dist/chunk-858emn8m.js.map +18 -0
  161. package/dist/{chunk-hvsb78a1.js → chunk-8frc8a4j.js} +26 -26
  162. package/dist/{chunk-hvsb78a1.js.map → chunk-8frc8a4j.js.map} +2 -2
  163. package/dist/{chunk-3zxk45er.js → chunk-8ncg20rd.js} +3 -68
  164. package/dist/{chunk-3zxk45er.js.map → chunk-8ncg20rd.js.map} +4 -5
  165. package/dist/{chunk-j2bp5ryw.js → chunk-918wwnaa.js} +495 -28
  166. package/dist/{chunk-j2bp5ryw.js.map → chunk-918wwnaa.js.map} +14 -12
  167. package/dist/{chunk-1f7wpmyp.js → chunk-9j4jw7as.js} +103 -110
  168. package/dist/chunk-9j4jw7as.js.map +14 -0
  169. package/dist/chunk-9kgkfg6v.js +502 -0
  170. package/dist/chunk-9kgkfg6v.js.map +14 -0
  171. package/dist/chunk-a3faa34j.js +74 -0
  172. package/dist/chunk-a3faa34j.js.map +10 -0
  173. package/dist/{chunk-ey3pyej1.js → chunk-akzryx9h.js} +347 -1174
  174. package/dist/{chunk-ey3pyej1.js.map → chunk-akzryx9h.js.map} +19 -25
  175. package/dist/chunk-arns890k.js +10 -0
  176. package/dist/chunk-arns890k.js.map +10 -0
  177. package/dist/{chunk-zrmy8zvw.js → chunk-bk9svbcq.js} +11 -11
  178. package/dist/{chunk-zrmy8zvw.js.map → chunk-bk9svbcq.js.map} +2 -2
  179. package/dist/{chunk-hkc3jct7.js → chunk-c06hmxyy.js} +2 -10
  180. package/dist/chunk-c06hmxyy.js.map +10 -0
  181. package/dist/{chunk-q1vkr2ys.js → chunk-c1rxbz5y.js} +3 -3
  182. package/dist/chunk-cfj9dfbb.js +288 -0
  183. package/dist/chunk-cfj9dfbb.js.map +12 -0
  184. package/dist/{chunk-4tcx876c.js → chunk-cn0fwwhy.js} +19 -19
  185. package/dist/{chunk-4tcx876c.js.map → chunk-cn0fwwhy.js.map} +1 -1
  186. package/dist/{chunk-gc4ntf7d.js → chunk-cwdzcv37.js} +1 -1
  187. package/dist/{chunk-fa02jy15.js → chunk-cy4mbddw.js} +1 -1
  188. package/dist/{chunk-7kg3k1m9.js → chunk-d09e3rax.js} +1 -1
  189. package/dist/chunk-d5rjr8c0.js +176 -0
  190. package/dist/chunk-d5rjr8c0.js.map +12 -0
  191. package/dist/{chunk-rhg02hxq.js → chunk-d7dnxdep.js} +3 -3
  192. package/dist/{chunk-b38szspf.js → chunk-dhcv7yxc.js} +1 -1
  193. package/dist/{chunk-b38szspf.js.map → chunk-dhcv7yxc.js.map} +1 -1
  194. package/dist/{chunk-enpsx8k5.js → chunk-dhdha526.js} +23 -21
  195. package/dist/chunk-dhdha526.js.map +10 -0
  196. package/dist/{chunk-8mx7qw3y.js → chunk-dvd2fp9q.js} +2 -2
  197. package/dist/{chunk-8mx7qw3y.js.map → chunk-dvd2fp9q.js.map} +3 -3
  198. package/dist/{chunk-bwjcehza.js → chunk-e17zdm62.js} +6 -12
  199. package/dist/{chunk-bwjcehza.js.map → chunk-e17zdm62.js.map} +3 -4
  200. package/dist/{chunk-tpn40322.js → chunk-e6k4thh5.js} +11 -10
  201. package/dist/{chunk-tpn40322.js.map → chunk-e6k4thh5.js.map} +3 -3
  202. package/dist/{chunk-tw03bsmb.js → chunk-eptrvnby.js} +224 -3
  203. package/dist/chunk-eptrvnby.js.map +12 -0
  204. package/dist/{chunk-xt1zt7gv.js → chunk-f4pamkt9.js} +30 -23
  205. package/dist/chunk-f4pamkt9.js.map +12 -0
  206. package/dist/chunk-ff5xkv0p.js +211 -0
  207. package/dist/chunk-ff5xkv0p.js.map +10 -0
  208. package/dist/{chunk-bpgy64fw.js → chunk-g257jwnc.js} +10 -4
  209. package/dist/{chunk-bpgy64fw.js.map → chunk-g257jwnc.js.map} +3 -3
  210. package/dist/chunk-g5bvzyyr.js +32 -0
  211. package/dist/chunk-g5bvzyyr.js.map +10 -0
  212. package/dist/{chunk-2jntasmh.js → chunk-hcbyfxbe.js} +25 -49
  213. package/dist/chunk-hcbyfxbe.js.map +12 -0
  214. package/dist/chunk-hke9aeen.js +9 -0
  215. package/dist/chunk-hke9aeen.js.map +10 -0
  216. package/dist/{chunk-1sr8ryzk.js → chunk-hwksyjks.js} +122 -1
  217. package/dist/{chunk-1sr8ryzk.js.map → chunk-hwksyjks.js.map} +3 -3
  218. package/dist/chunk-jcfw4h7m.js +9 -0
  219. package/dist/chunk-jcfw4h7m.js.map +10 -0
  220. package/dist/{chunk-85yvv5n0.js → chunk-k43ct2ke.js} +20 -11
  221. package/dist/chunk-k43ct2ke.js.map +12 -0
  222. package/dist/{chunk-dnmadg9k.js → chunk-kge7k6ey.js} +40 -8
  223. package/dist/chunk-kge7k6ey.js.map +15 -0
  224. package/dist/{chunk-wz0xs816.js → chunk-ky3j490c.js} +2 -2
  225. package/dist/chunk-mjddfa7k.js +129 -0
  226. package/dist/chunk-mjddfa7k.js.map +12 -0
  227. package/dist/{chunk-3gnrh4ve.js → chunk-nn5xnx3s.js} +86 -111
  228. package/dist/chunk-nn5xnx3s.js.map +40 -0
  229. package/dist/{chunk-rz53yb4v.js → chunk-q5e5tv4b.js} +35 -7
  230. package/dist/{chunk-rz53yb4v.js.map → chunk-q5e5tv4b.js.map} +3 -3
  231. package/dist/{chunk-vyf9kfqf.js → chunk-q7gn29y3.js} +1 -1
  232. package/dist/{chunk-d2ync1v3.js → chunk-rmakanzx.js} +10 -12
  233. package/dist/{chunk-d2ync1v3.js.map → chunk-rmakanzx.js.map} +3 -4
  234. package/dist/{chunk-v9xd5wzd.js → chunk-s7jg7pmn.js} +1 -1
  235. package/dist/chunk-tbc1ngpd.js +642 -0
  236. package/dist/chunk-tbc1ngpd.js.map +18 -0
  237. package/dist/chunk-twe4dx8p.js +676 -0
  238. package/dist/chunk-twe4dx8p.js.map +15 -0
  239. package/dist/{chunk-nre82s12.js → chunk-vf57cr4t.js} +2 -2
  240. package/dist/{chunk-9ybhtmg4.js → chunk-vvxtn22d.js} +1 -1
  241. package/dist/{chunk-jhm3zsa7.js → chunk-wkv3h3q7.js} +64 -2
  242. package/dist/{chunk-jhm3zsa7.js.map → chunk-wkv3h3q7.js.map} +3 -3
  243. package/dist/chunk-x0v3jd47.js +124 -0
  244. package/dist/chunk-x0v3jd47.js.map +10 -0
  245. package/dist/{chunk-7t429e3f.js → chunk-xvsc5m8n.js} +1 -1
  246. package/dist/{chunk-kg5j6fct.js → chunk-y5tah2kf.js} +1 -1
  247. package/dist/{chunk-52bk93x8.js → chunk-z58tm0hm.js} +2 -2
  248. package/dist/datasets/builders.d.ts +15 -2
  249. package/dist/datasets/builders.d.ts.map +1 -1
  250. package/dist/datasets/column-index.d.ts +7 -0
  251. package/dist/datasets/column-index.d.ts.map +1 -0
  252. package/dist/datasets/execution.d.ts +3 -2
  253. package/dist/datasets/execution.d.ts.map +1 -1
  254. package/dist/datasets/write.js +8 -8
  255. package/dist/deploy/internal.js +4 -3
  256. package/dist/deploy/internal.js.map +4 -4
  257. package/dist/deploy/services.d.ts.map +1 -1
  258. package/dist/deploy/types.d.ts +1 -2
  259. package/dist/deploy/types.d.ts.map +1 -1
  260. package/dist/error-reporting/internal.js +4 -4
  261. package/dist/errors/internal.d.ts +1 -0
  262. package/dist/errors/internal.d.ts.map +1 -1
  263. package/dist/errors/internal.js +7 -4
  264. package/dist/errors/internal.js.map +1 -1
  265. package/dist/events/execution.d.ts +12 -2
  266. package/dist/events/execution.d.ts.map +1 -1
  267. package/dist/events/index.js +4 -4
  268. package/dist/execution/agent.js +56 -49
  269. package/dist/execution/agent.js.map +1 -1
  270. package/dist/execution/authorization.d.ts.map +1 -1
  271. package/dist/execution/authorized-object-reader.d.ts +52 -11
  272. package/dist/execution/authorized-object-reader.d.ts.map +1 -1
  273. package/dist/execution/object-reader-clearance.d.ts +41 -0
  274. package/dist/execution/object-reader-clearance.d.ts.map +1 -0
  275. package/dist/execution/object-reader-ontology.d.ts +12 -0
  276. package/dist/execution/object-reader-ontology.d.ts.map +1 -0
  277. package/dist/execution/object-reader-security.d.ts +45 -0
  278. package/dist/execution/object-reader-security.d.ts.map +1 -0
  279. package/dist/execution/primitive.js +54 -47
  280. package/dist/execution/primitive.js.map +1 -1
  281. package/dist/execution/request.js +49 -42
  282. package/dist/execution/request.js.map +2 -2
  283. package/dist/http/api-routes.d.ts.map +1 -1
  284. package/dist/http/index.js +1 -1
  285. package/dist/index.d.ts +23 -7
  286. package/dist/index.d.ts.map +1 -1
  287. package/dist/index.js +111 -109
  288. package/dist/index.js.map +1 -1
  289. package/dist/lake-storage/in-memory.d.ts +1 -0
  290. package/dist/lake-storage/in-memory.d.ts.map +1 -1
  291. package/dist/lake-storage/index.d.ts +6 -3
  292. package/dist/lake-storage/index.d.ts.map +1 -1
  293. package/dist/lake-storage/index.js +21 -13
  294. package/dist/lake-storage/index.js.map +1 -1
  295. package/dist/lake-storage/lineage.d.ts +94 -0
  296. package/dist/lake-storage/lineage.d.ts.map +1 -0
  297. package/dist/lake-storage/sql-transforms.d.ts +45 -0
  298. package/dist/lake-storage/sql-transforms.d.ts.map +1 -1
  299. package/dist/lake-storage/types.d.ts +55 -1
  300. package/dist/lake-storage/types.d.ts.map +1 -1
  301. package/dist/lake-storage/version-inputs.d.ts +14 -3
  302. package/dist/lake-storage/version-inputs.d.ts.map +1 -1
  303. package/dist/maintenance/ontology-maintenance.d.ts.map +1 -1
  304. package/dist/materializer/index.js +31 -30
  305. package/dist/materializer/index.js.map +1 -1
  306. package/dist/models/execution/index.js +26 -25
  307. package/dist/models/execution/index.js.map +1 -1
  308. package/dist/objects/clearance-redaction.d.ts +27 -0
  309. package/dist/objects/clearance-redaction.d.ts.map +1 -0
  310. package/dist/objects/index.js +54 -47
  311. package/dist/objects/index.js.map +1 -1
  312. package/dist/objects/link/authorization.d.ts +8 -5
  313. package/dist/objects/link/authorization.d.ts.map +1 -1
  314. package/dist/objects/link/upsert-batch.d.ts.map +1 -1
  315. package/dist/objects/object/delete.d.ts.map +1 -1
  316. package/dist/objects/object/upsert-batch.d.ts.map +1 -1
  317. package/dist/objects/object/upsert.d.ts.map +1 -1
  318. package/dist/objects/property-clearance.d.ts +47 -24
  319. package/dist/objects/property-clearance.d.ts.map +1 -1
  320. package/dist/objects/query/clearance-admission.d.ts +10 -0
  321. package/dist/objects/query/clearance-admission.d.ts.map +1 -0
  322. package/dist/objects/query/index.js +29 -28
  323. package/dist/objects/query/index.js.map +1 -1
  324. package/dist/objects/query/link-query-clearance.d.ts +21 -0
  325. package/dist/objects/query/link-query-clearance.d.ts.map +1 -0
  326. package/dist/objects/vectors/handle.d.ts.map +1 -1
  327. package/dist/objects/vectors/profile.d.ts +5 -0
  328. package/dist/objects/vectors/profile.d.ts.map +1 -1
  329. package/dist/ontology/builders.d.ts.map +1 -1
  330. package/dist/ontology/docs-markdown.d.ts +1 -1
  331. package/dist/ontology/docs-markdown.d.ts.map +1 -1
  332. package/dist/ontology/index.js +7 -7
  333. package/dist/ontology/internal.js +4 -4
  334. package/dist/ontology/internal.js.map +1 -1
  335. package/dist/pipelines/index.d.ts +2 -0
  336. package/dist/pipelines/index.d.ts.map +1 -1
  337. package/dist/pipelines/index.js +47 -35
  338. package/dist/pipelines/index.js.map +1 -1
  339. package/dist/pipelines/lineage.d.ts +17 -0
  340. package/dist/pipelines/lineage.d.ts.map +1 -0
  341. package/dist/projections/internal.d.ts +2 -2
  342. package/dist/projections/internal.js +30 -29
  343. package/dist/projections/internal.js.map +1 -1
  344. package/dist/runtime/create.d.ts +3 -0
  345. package/dist/runtime/create.d.ts.map +1 -1
  346. package/dist/runtime/host.d.ts +6 -0
  347. package/dist/runtime/host.d.ts.map +1 -1
  348. package/dist/runtime/internal.d.ts +2 -0
  349. package/dist/runtime/internal.d.ts.map +1 -1
  350. package/dist/runtime/internal.js +46 -42
  351. package/dist/runtime/internal.js.map +1 -1
  352. package/dist/runtime/ontology-mutations.d.ts +2 -0
  353. package/dist/runtime/ontology-mutations.d.ts.map +1 -1
  354. package/dist/runtime/resolve-definitions.d.ts.map +1 -1
  355. package/dist/runtime/sixb.d.ts +8 -0
  356. package/dist/runtime/sixb.d.ts.map +1 -1
  357. package/dist/sandboxes/auth.d.ts +16 -0
  358. package/dist/sandboxes/auth.d.ts.map +1 -1
  359. package/dist/sandboxes/config.d.ts.map +1 -1
  360. package/dist/sandboxes/configuration.d.ts +26 -0
  361. package/dist/sandboxes/configuration.d.ts.map +1 -1
  362. package/dist/sandboxes/index.d.ts +1 -1
  363. package/dist/sandboxes/index.d.ts.map +1 -1
  364. package/dist/sandboxes/index.js +14 -13
  365. package/dist/sandboxes/index.js.map +1 -1
  366. package/dist/sandboxes/sandbox.d.ts +28 -5
  367. package/dist/sandboxes/sandbox.d.ts.map +1 -1
  368. package/dist/security/applied-markings-contribution.d.ts +58 -0
  369. package/dist/security/applied-markings-contribution.d.ts.map +1 -0
  370. package/dist/security/applied-markings-host.d.ts +10 -0
  371. package/dist/security/applied-markings-host.d.ts.map +1 -0
  372. package/dist/security/applied-markings-snapshot.d.ts +67 -0
  373. package/dist/security/applied-markings-snapshot.d.ts.map +1 -0
  374. package/dist/security/applied-markings.d.ts +73 -0
  375. package/dist/security/applied-markings.d.ts.map +1 -0
  376. package/dist/security/builders.d.ts.map +1 -1
  377. package/dist/security/dataset-version-markings.d.ts +47 -0
  378. package/dist/security/dataset-version-markings.d.ts.map +1 -0
  379. package/dist/security/every.d.ts +1 -4
  380. package/dist/security/every.d.ts.map +1 -1
  381. package/dist/security/grants.d.ts +4 -5
  382. package/dist/security/grants.d.ts.map +1 -1
  383. package/dist/security/index.d.ts +2 -2
  384. package/dist/security/index.d.ts.map +1 -1
  385. package/dist/security/internal.d.ts +15 -0
  386. package/dist/security/internal.d.ts.map +1 -0
  387. package/dist/security/internal.js +135 -0
  388. package/dist/security/internal.js.map +10 -0
  389. package/dist/security/marking-propagation.d.ts +62 -0
  390. package/dist/security/marking-propagation.d.ts.map +1 -0
  391. package/dist/security/marking-sets.d.ts +14 -0
  392. package/dist/security/marking-sets.d.ts.map +1 -0
  393. package/dist/security/markings.d.ts +6 -3
  394. package/dist/security/markings.d.ts.map +1 -1
  395. package/dist/security/membership-policies.d.ts.map +1 -1
  396. package/dist/security/pipeline-markings.d.ts +20 -0
  397. package/dist/security/pipeline-markings.d.ts.map +1 -0
  398. package/dist/security/project.d.ts +4 -0
  399. package/dist/security/project.d.ts.map +1 -0
  400. package/dist/security/projection-markings.d.ts +71 -0
  401. package/dist/security/projection-markings.d.ts.map +1 -0
  402. package/dist/security/public.d.ts +10 -0
  403. package/dist/security/public.d.ts.map +1 -0
  404. package/dist/security/public.js +10 -0
  405. package/dist/security/public.js.map +9 -0
  406. package/dist/security/redactions.d.ts +4 -1
  407. package/dist/security/redactions.d.ts.map +1 -1
  408. package/dist/security/registry.d.ts +0 -1
  409. package/dist/security/registry.d.ts.map +1 -1
  410. package/dist/security/types.d.ts +34 -19
  411. package/dist/security/types.d.ts.map +1 -1
  412. package/dist/security/validation.d.ts +0 -6
  413. package/dist/security/validation.d.ts.map +1 -1
  414. package/dist/shares/internal.js +25 -24
  415. package/dist/shares/internal.js.map +2 -2
  416. package/dist/storage/action-runs/failure.js +3 -3
  417. package/dist/storage/action-runs/in-memory.d.ts +4 -0
  418. package/dist/storage/action-runs/in-memory.d.ts.map +1 -1
  419. package/dist/storage/action-runs/types.d.ts +8 -0
  420. package/dist/storage/action-runs/types.d.ts.map +1 -1
  421. package/dist/storage/activity/in-memory.d.ts +55 -0
  422. package/dist/storage/activity/in-memory.d.ts.map +1 -0
  423. package/dist/storage/activity/index.d.ts +3 -0
  424. package/dist/storage/activity/index.d.ts.map +1 -0
  425. package/dist/storage/activity/policy.d.ts +96 -0
  426. package/dist/storage/activity/policy.d.ts.map +1 -0
  427. package/dist/storage/activity/types.d.ts +191 -0
  428. package/dist/storage/activity/types.d.ts.map +1 -0
  429. package/dist/storage/agents/in-memory.d.ts +4 -0
  430. package/dist/storage/agents/in-memory.d.ts.map +1 -1
  431. package/dist/storage/agents/provider.d.ts.map +1 -1
  432. package/dist/storage/agents/provider.js +2 -5
  433. package/dist/storage/agents/provider.js.map +1 -1
  434. package/dist/storage/agents/types.d.ts +10 -9
  435. package/dist/storage/agents/types.d.ts.map +1 -1
  436. package/dist/storage/ai-limits/enforcement.js +3 -3
  437. package/dist/storage/artifacts/errors.d.ts +8 -0
  438. package/dist/storage/artifacts/errors.d.ts.map +1 -0
  439. package/dist/storage/artifacts/in-memory.d.ts +34 -0
  440. package/dist/storage/artifacts/in-memory.d.ts.map +1 -0
  441. package/dist/storage/artifacts/index.d.ts +5 -0
  442. package/dist/storage/artifacts/index.d.ts.map +1 -0
  443. package/dist/storage/artifacts/record.d.ts +17 -0
  444. package/dist/storage/artifacts/record.d.ts.map +1 -0
  445. package/dist/storage/artifacts/types.d.ts +184 -0
  446. package/dist/storage/artifacts/types.d.ts.map +1 -0
  447. package/dist/storage/auth/in-memory/auth-storage.d.ts.map +1 -1
  448. package/dist/storage/auth/in-memory/magic-links.d.ts.map +1 -1
  449. package/dist/storage/auth/in-memory/oidc-attempts.d.ts.map +1 -1
  450. package/dist/storage/auth/in-memory/sessions.d.ts +2 -11
  451. package/dist/storage/auth/in-memory/sessions.d.ts.map +1 -1
  452. package/dist/storage/auth/in-memory/shared.d.ts +1 -2
  453. package/dist/storage/auth/in-memory/shared.d.ts.map +1 -1
  454. package/dist/storage/auth/index.d.ts +1 -1
  455. package/dist/storage/auth/index.d.ts.map +1 -1
  456. package/dist/storage/auth/types.d.ts +20 -17
  457. package/dist/storage/auth/types.d.ts.map +1 -1
  458. package/dist/storage/connector-connections/provider.js +2 -2
  459. package/dist/storage/executions/in-memory.d.ts +2 -1
  460. package/dist/storage/executions/in-memory.d.ts.map +1 -1
  461. package/dist/storage/executions/index.d.ts +1 -1
  462. package/dist/storage/executions/index.d.ts.map +1 -1
  463. package/dist/storage/executions/provider.d.ts +2 -0
  464. package/dist/storage/executions/provider.d.ts.map +1 -1
  465. package/dist/storage/executions/provider.js +9 -223
  466. package/dist/storage/executions/provider.js.map +3 -4
  467. package/dist/storage/executions/types.d.ts +31 -0
  468. package/dist/storage/executions/types.d.ts.map +1 -1
  469. package/dist/storage/file-upload-sessions/provider.js +12 -12
  470. package/dist/storage/in-memory/index.d.ts +8 -0
  471. package/dist/storage/in-memory/index.d.ts.map +1 -1
  472. package/dist/storage/index.d.ts +6 -4
  473. package/dist/storage/index.d.ts.map +1 -1
  474. package/dist/storage/index.js +47 -46
  475. package/dist/storage/index.js.map +1 -1
  476. package/dist/storage/internal.d.ts +3 -0
  477. package/dist/storage/internal.d.ts.map +1 -1
  478. package/dist/storage/internal.js +66 -16
  479. package/dist/storage/internal.js.map +1 -1
  480. package/dist/storage/ontology/in-memory/sources.d.ts +2 -1
  481. package/dist/storage/ontology/in-memory/sources.d.ts.map +1 -1
  482. package/dist/storage/ontology/index.d.ts +1 -1
  483. package/dist/storage/ontology/index.d.ts.map +1 -1
  484. package/dist/storage/ontology/sources.d.ts +15 -0
  485. package/dist/storage/ontology/sources.d.ts.map +1 -1
  486. package/dist/storage/projection-runs/provider.js +3 -3
  487. package/dist/storage/share-grants/in-memory.d.ts +2 -1
  488. package/dist/storage/share-grants/in-memory.d.ts.map +1 -1
  489. package/dist/storage/share-grants/index.d.ts +1 -1
  490. package/dist/storage/share-grants/index.d.ts.map +1 -1
  491. package/dist/storage/share-grants/types.d.ts +6 -0
  492. package/dist/storage/share-grants/types.d.ts.map +1 -1
  493. package/dist/storage/types.d.ts +4 -0
  494. package/dist/storage/types.d.ts.map +1 -1
  495. package/dist/storage/workflow-runs/in-memory.d.ts +4 -0
  496. package/dist/storage/workflow-runs/in-memory.d.ts.map +1 -1
  497. package/dist/storage/workflow-runs/provider.js +14 -13
  498. package/dist/storage/workflow-runs/provider.js.map +1 -1
  499. package/dist/storage/workflow-runs/types.d.ts +5 -0
  500. package/dist/storage/workflow-runs/types.d.ts.map +1 -1
  501. package/dist/syncs/index.js +35 -34
  502. package/dist/syncs/index.js.map +1 -1
  503. package/dist/testing/action-run-storage-contract.d.ts.map +1 -1
  504. package/dist/testing/activity-storage-contract.d.ts +14 -0
  505. package/dist/testing/activity-storage-contract.d.ts.map +1 -0
  506. package/dist/testing/agent-storage-contract.d.ts.map +1 -1
  507. package/dist/testing/artifact-storage-contract.d.ts +13 -0
  508. package/dist/testing/artifact-storage-contract.d.ts.map +1 -0
  509. package/dist/testing/auth-storage-contract.d.ts.map +1 -1
  510. package/dist/testing/execution-storage-contract.d.ts.map +1 -1
  511. package/dist/testing/index.d.ts +2 -0
  512. package/dist/testing/index.d.ts.map +1 -1
  513. package/dist/testing/index.js +4493 -3225
  514. package/dist/testing/index.js.map +14 -12
  515. package/dist/testing/lake-merge-storage-contract.d.ts.map +1 -1
  516. package/dist/testing/lake-storage-contract.d.ts +2 -0
  517. package/dist/testing/lake-storage-contract.d.ts.map +1 -1
  518. package/dist/testing/ontology-storage-contract.d.ts.map +1 -1
  519. package/dist/testing/share-grant-storage-contract.d.ts.map +1 -1
  520. package/dist/webhooks/internal.js +28 -27
  521. package/dist/webhooks/internal.js.map +2 -2
  522. package/dist/workers/index.js +2 -2
  523. package/dist/workflows/builders.d.ts.map +1 -1
  524. package/dist/workflows/index.js +57 -51
  525. package/dist/workflows/index.js.map +1 -1
  526. package/dist/workflows/types.d.ts +9 -0
  527. package/dist/workflows/types.d.ts.map +1 -1
  528. package/dist/workflows/validation.d.ts +7 -0
  529. package/dist/workflows/validation.d.ts.map +1 -1
  530. package/package.json +32 -2
  531. package/src/actions/execution.ts +18 -13
  532. package/src/actions/request.ts +18 -3
  533. package/src/actions/run-authorization.ts +23 -0
  534. package/src/activity/README.md +155 -0
  535. package/src/activity/connection.ts +217 -0
  536. package/src/activity/device.ts +41 -0
  537. package/src/activity/execution.ts +210 -0
  538. package/src/activity/service.ts +274 -0
  539. package/src/activity/shares.ts +62 -0
  540. package/src/activity/timeline.ts +424 -0
  541. package/src/agents/index.ts +8 -3
  542. package/src/agents/request.ts +5 -0
  543. package/src/agents/skills.ts +6 -0
  544. package/src/agents/types.ts +8 -8
  545. package/src/agents/validation.ts +2 -0
  546. package/src/artifacts/address.ts +132 -0
  547. package/src/artifacts/csv.ts +108 -0
  548. package/src/artifacts/errors.ts +21 -0
  549. package/src/artifacts/execution.ts +153 -0
  550. package/src/artifacts/frames/assets.ts +88 -0
  551. package/src/artifacts/frames/grants.ts +124 -0
  552. package/src/artifacts/frames/index.ts +15 -0
  553. package/src/artifacts/frames/kit.ts +392 -0
  554. package/src/artifacts/frames/probe.ts +309 -0
  555. package/src/artifacts/frames/protocol.ts +174 -0
  556. package/src/artifacts/frames/runtime.ts +213 -0
  557. package/src/artifacts/html.ts +25 -0
  558. package/src/artifacts/ids.ts +18 -0
  559. package/src/artifacts/index.ts +61 -0
  560. package/src/artifacts/kinds.ts +8 -0
  561. package/src/artifacts/limits.ts +27 -0
  562. package/src/artifacts/outline.ts +62 -0
  563. package/src/artifacts/publish/files.ts +87 -0
  564. package/src/artifacts/publish/index.ts +12 -0
  565. package/src/artifacts/publish/publish.ts +250 -0
  566. package/src/artifacts/publish/references.ts +130 -0
  567. package/src/artifacts/publish/validate/document.ts +114 -0
  568. package/src/artifacts/publish/validate/file.ts +19 -0
  569. package/src/artifacts/publish/validate/sheet.ts +251 -0
  570. package/src/artifacts/publish/validate/slides.ts +134 -0
  571. package/src/artifacts/references.ts +11 -0
  572. package/src/artifacts/resolve.ts +97 -0
  573. package/src/artifacts/theme.ts +116 -0
  574. package/src/artifacts/warnings.ts +10 -0
  575. package/src/artifacts/workbook.ts +315 -0
  576. package/src/auth/cookies.ts +3 -20
  577. package/src/auth/index.ts +0 -6
  578. package/src/auth/runtime.ts +59 -76
  579. package/src/auth/session-cache.ts +2 -9
  580. package/src/auth/types.ts +4 -8
  581. package/src/auth/validation.ts +0 -2
  582. package/src/authorization/decision.ts +13 -23
  583. package/src/authorization/grant-kinds.ts +33 -28
  584. package/src/authorization/index.ts +0 -1
  585. package/src/authorization/resolve.ts +10 -6
  586. package/src/blob-storage/internal.ts +1 -1
  587. package/src/blob-storage/media-type.ts +69 -0
  588. package/src/datasets/builders.ts +66 -2
  589. package/src/datasets/column-index.ts +19 -0
  590. package/src/datasets/execution.ts +23 -9
  591. package/src/deploy/services.ts +0 -1
  592. package/src/deploy/types.ts +1 -2
  593. package/src/deploy/validation.ts +3 -1
  594. package/src/errors/internal.ts +1 -0
  595. package/src/events/execution.ts +134 -21
  596. package/src/execution/authorization.ts +11 -5
  597. package/src/execution/authorized-object-reader.ts +270 -256
  598. package/src/execution/object-reader-clearance.ts +91 -0
  599. package/src/execution/object-reader-ontology.ts +63 -0
  600. package/src/execution/object-reader-security.ts +146 -0
  601. package/src/http/api-routes.ts +125 -0
  602. package/src/index.ts +72 -17
  603. package/src/lake-storage/in-memory.ts +26 -3
  604. package/src/lake-storage/index.ts +13 -1
  605. package/src/lake-storage/lineage.ts +385 -0
  606. package/src/lake-storage/sql-transforms.ts +45 -0
  607. package/src/lake-storage/types.ts +59 -1
  608. package/src/lake-storage/version-inputs.ts +35 -6
  609. package/src/maintenance/ontology-maintenance.ts +15 -0
  610. package/src/models/execution/embedding.ts +6 -6
  611. package/src/objects/clearance-redaction.ts +138 -0
  612. package/src/objects/link/authorization.ts +27 -7
  613. package/src/objects/link/remove.ts +2 -2
  614. package/src/objects/link/upsert-batch.ts +7 -5
  615. package/src/objects/link/upsert.ts +2 -2
  616. package/src/objects/object/delete.ts +2 -0
  617. package/src/objects/object/upsert-batch.ts +2 -4
  618. package/src/objects/object/upsert.ts +2 -3
  619. package/src/objects/property-clearance.ts +171 -152
  620. package/src/objects/query/clearance-admission.ts +112 -0
  621. package/src/objects/query/link-query-clearance.ts +73 -0
  622. package/src/objects/vectors/README.md +4 -0
  623. package/src/objects/vectors/handle.ts +11 -2
  624. package/src/objects/vectors/indexing-generate.ts +2 -2
  625. package/src/objects/vectors/profile.ts +5 -0
  626. package/src/ontology/builders.ts +12 -1
  627. package/src/ontology/docs-markdown.ts +1 -1
  628. package/src/pipelines/index.ts +2 -0
  629. package/src/pipelines/lineage.ts +45 -0
  630. package/src/projections/internal.ts +2 -2
  631. package/src/runtime/create.ts +4 -0
  632. package/src/runtime/host.ts +55 -0
  633. package/src/runtime/internal.ts +2 -0
  634. package/src/runtime/ontology-mutations.ts +19 -4
  635. package/src/runtime/resolve-definitions.ts +66 -3
  636. package/src/runtime/sixb.ts +18 -1
  637. package/src/sandboxes/README.md +29 -7
  638. package/src/sandboxes/auth.ts +16 -0
  639. package/src/sandboxes/config.ts +2 -7
  640. package/src/sandboxes/configuration.ts +61 -7
  641. package/src/sandboxes/index.ts +1 -0
  642. package/src/sandboxes/sandbox.ts +27 -5
  643. package/src/security/applied-markings-contribution.ts +277 -0
  644. package/src/security/applied-markings-host.ts +41 -0
  645. package/src/security/applied-markings-snapshot.ts +235 -0
  646. package/src/security/applied-markings.ts +405 -0
  647. package/src/security/builders.ts +7 -2
  648. package/src/security/dataset-version-markings.ts +163 -0
  649. package/src/security/every.ts +0 -4
  650. package/src/security/grants.ts +42 -27
  651. package/src/security/index.ts +3 -3
  652. package/src/security/internal.ts +18 -0
  653. package/src/security/marking-propagation.ts +255 -0
  654. package/src/security/marking-sets.ts +42 -0
  655. package/src/security/markings.ts +29 -178
  656. package/src/security/membership-policies.ts +3 -1
  657. package/src/security/pipeline-markings.ts +175 -0
  658. package/src/security/project.ts +8 -0
  659. package/src/security/projection-markings.ts +421 -0
  660. package/src/security/public.ts +10 -0
  661. package/src/security/redactions.ts +7 -2
  662. package/src/security/registry.ts +0 -8
  663. package/src/security/types.ts +38 -26
  664. package/src/security/validation.ts +28 -19
  665. package/src/storage/action-runs/in-memory.ts +18 -0
  666. package/src/storage/action-runs/types.ts +8 -0
  667. package/src/storage/activity/in-memory.ts +374 -0
  668. package/src/storage/activity/index.ts +27 -0
  669. package/src/storage/activity/policy.ts +430 -0
  670. package/src/storage/activity/types.ts +211 -0
  671. package/src/storage/agents/in-memory.ts +10 -0
  672. package/src/storage/agents/provider.ts +2 -13
  673. package/src/storage/agents/types.ts +10 -17
  674. package/src/storage/artifacts/errors.ts +16 -0
  675. package/src/storage/artifacts/in-memory.ts +240 -0
  676. package/src/storage/artifacts/index.ts +30 -0
  677. package/src/storage/artifacts/record.ts +200 -0
  678. package/src/storage/artifacts/types.ts +209 -0
  679. package/src/storage/auth/in-memory/auth-storage.ts +0 -18
  680. package/src/storage/auth/in-memory/magic-links.ts +0 -3
  681. package/src/storage/auth/in-memory/oidc-attempts.ts +0 -3
  682. package/src/storage/auth/in-memory/sessions.ts +22 -25
  683. package/src/storage/auth/in-memory/shared.ts +1 -10
  684. package/src/storage/auth/index.ts +2 -0
  685. package/src/storage/auth/types.ts +20 -18
  686. package/src/storage/executions/in-memory.ts +61 -1
  687. package/src/storage/executions/index.ts +3 -0
  688. package/src/storage/executions/provider.ts +12 -0
  689. package/src/storage/executions/types.ts +30 -0
  690. package/src/storage/in-memory/index.ts +16 -0
  691. package/src/storage/index.ts +63 -0
  692. package/src/storage/internal.ts +30 -0
  693. package/src/storage/ontology/in-memory/sources.ts +23 -0
  694. package/src/storage/ontology/index.ts +2 -0
  695. package/src/storage/ontology/sources.ts +17 -0
  696. package/src/storage/share-grants/in-memory.ts +8 -0
  697. package/src/storage/share-grants/index.ts +1 -0
  698. package/src/storage/share-grants/types.ts +8 -0
  699. package/src/storage/types.ts +4 -0
  700. package/src/storage/workflow-runs/in-memory.ts +16 -0
  701. package/src/storage/workflow-runs/types.ts +5 -0
  702. package/src/testing/action-run-storage-contract.ts +25 -0
  703. package/src/testing/activity-storage-contract.ts +840 -0
  704. package/src/testing/agent-storage-contract.ts +22 -21
  705. package/src/testing/artifact-storage-contract.ts +517 -0
  706. package/src/testing/auth-storage-contract.ts +61 -107
  707. package/src/testing/execution-storage-contract.ts +147 -3
  708. package/src/testing/index.ts +9 -0
  709. package/src/testing/lake-merge-storage-contract.ts +38 -0
  710. package/src/testing/lake-storage-contract.ts +247 -2
  711. package/src/testing/materializer-storage-contract.ts +1 -0
  712. package/src/testing/ontology-storage-contract.ts +57 -2
  713. package/src/testing/share-grant-storage-contract.ts +15 -0
  714. package/src/workflows/builders.ts +14 -0
  715. package/src/workflows/types.ts +9 -0
  716. package/src/workflows/validation.ts +72 -0
  717. package/dist/auth/audience.d.ts +0 -8
  718. package/dist/auth/audience.d.ts.map +0 -1
  719. package/dist/authorization/application-access.d.ts +0 -18
  720. package/dist/authorization/application-access.d.ts.map +0 -1
  721. package/dist/chunk-1f7wpmyp.js.map +0 -14
  722. package/dist/chunk-1k89ecfr.js +0 -85
  723. package/dist/chunk-1k89ecfr.js.map +0 -10
  724. package/dist/chunk-2jntasmh.js.map +0 -13
  725. package/dist/chunk-3gnrh4ve.js.map +0 -40
  726. package/dist/chunk-85yvv5n0.js.map +0 -12
  727. package/dist/chunk-9gyp8hg1.js +0 -363
  728. package/dist/chunk-9gyp8hg1.js.map +0 -14
  729. package/dist/chunk-dnmadg9k.js.map +0 -15
  730. package/dist/chunk-enpsx8k5.js.map +0 -10
  731. package/dist/chunk-hkc3jct7.js.map +0 -10
  732. package/dist/chunk-kyzq4wy9.js.map +0 -18
  733. package/dist/chunk-s16apyk9.js +0 -256
  734. package/dist/chunk-s16apyk9.js.map +0 -16
  735. package/dist/chunk-s54c868q.js.map +0 -12
  736. package/dist/chunk-tw03bsmb.js.map +0 -11
  737. package/dist/chunk-wwdfe68s.js +0 -128
  738. package/dist/chunk-wwdfe68s.js.map +0 -11
  739. package/dist/chunk-xt1zt7gv.js.map +0 -13
  740. package/dist/chunk-y7rqfrgg.js.map +0 -24
  741. package/dist/security/applications.d.ts +0 -15
  742. package/dist/security/applications.d.ts.map +0 -1
  743. package/src/auth/audience.ts +0 -28
  744. package/src/authorization/application-access.ts +0 -34
  745. package/src/security/applications.ts +0 -11
  746. /package/dist/{chunk-t6vq7bff.js.map → chunk-0bphap9y.js.map} +0 -0
  747. /package/dist/{chunk-7mbzgd9m.js.map → chunk-1cc1xaf3.js.map} +0 -0
  748. /package/dist/{chunk-6gmfggss.js.map → chunk-431pyp2c.js.map} +0 -0
  749. /package/dist/{chunk-c85m1hyj.js.map → chunk-447a5c0p.js.map} +0 -0
  750. /package/dist/{chunk-80mc0971.js.map → chunk-561r0yc9.js.map} +0 -0
  751. /package/dist/{chunk-5e43w60z.js.map → chunk-5948n82c.js.map} +0 -0
  752. /package/dist/{chunk-yzwja0mj.js.map → chunk-5hx48dnn.js.map} +0 -0
  753. /package/dist/{chunk-q1vkr2ys.js.map → chunk-c1rxbz5y.js.map} +0 -0
  754. /package/dist/{chunk-gc4ntf7d.js.map → chunk-cwdzcv37.js.map} +0 -0
  755. /package/dist/{chunk-fa02jy15.js.map → chunk-cy4mbddw.js.map} +0 -0
  756. /package/dist/{chunk-7kg3k1m9.js.map → chunk-d09e3rax.js.map} +0 -0
  757. /package/dist/{chunk-rhg02hxq.js.map → chunk-d7dnxdep.js.map} +0 -0
  758. /package/dist/{chunk-wz0xs816.js.map → chunk-ky3j490c.js.map} +0 -0
  759. /package/dist/{chunk-vyf9kfqf.js.map → chunk-q7gn29y3.js.map} +0 -0
  760. /package/dist/{chunk-v9xd5wzd.js.map → chunk-s7jg7pmn.js.map} +0 -0
  761. /package/dist/{chunk-nre82s12.js.map → chunk-vf57cr4t.js.map} +0 -0
  762. /package/dist/{chunk-9ybhtmg4.js.map → chunk-vvxtn22d.js.map} +0 -0
  763. /package/dist/{chunk-7t429e3f.js.map → chunk-xvsc5m8n.js.map} +0 -0
  764. /package/dist/{chunk-kg5j6fct.js.map → chunk-y5tah2kf.js.map} +0 -0
  765. /package/dist/{chunk-52bk93x8.js.map → chunk-z58tm0hm.js.map} +0 -0
@@ -12,7 +12,7 @@ import {
12
12
  resolveObjectActionSubject,
13
13
  SYSTEM_PRINCIPAL2,
14
14
  principalsEqual2
15
- } from "./chunk-3gnrh4ve.js";
15
+ } from "./chunk-nn5xnx3s.js";
16
16
  import {
17
17
  ActionValidationError2,
18
18
  createSixbError2,
@@ -20,16 +20,14 @@ import {
20
20
  isSixbError2,
21
21
  toSixbFailure2,
22
22
  summarizeErrorMessage2
23
- } from "./chunk-8mx7qw3y.js";
23
+ } from "./chunk-dvd2fp9q.js";
24
24
  import {
25
25
  agentServiceAccountId2,
26
- MAX_OBJECT_READ_FACETS2,
27
26
  ObjectReadLimitExceededError2,
28
27
  assertObjectReadOutputWithinLimit2,
29
28
  createAgentRuntimeAuthorization,
30
29
  resolveRuntimeAuthorizationForProject,
31
30
  getAuthorizationRef,
32
- captureExecutionScope,
33
31
  resolveExecutionScopeAuthorization,
34
32
  AuthorizationError2,
35
33
  isAllowed2,
@@ -48,14 +46,14 @@ import {
48
46
  canViewPipelineRun2,
49
47
  canViewProjectionRun2,
50
48
  canViewProjection2
51
- } from "./chunk-y7rqfrgg.js";
49
+ } from "./chunk-6vb4st8k.js";
52
50
  import {
53
51
  canonicalMediaType2,
54
52
  isFileRef2,
55
53
  isValidFileRef,
56
54
  supportsDirectUpload2,
57
55
  supportsRangeRead2
58
- } from "./chunk-jhm3zsa7.js";
56
+ } from "./chunk-wkv3h3q7.js";
59
57
  import {
60
58
  collectUserRefIds,
61
59
  userReferenceProblem,
@@ -75,29 +73,33 @@ import {
75
73
  normalizeLinkProperties2,
76
74
  validateLinkProperties2,
77
75
  assertTelemetryProperty2
78
- } from "./chunk-hvsb78a1.js";
76
+ } from "./chunk-8frc8a4j.js";
79
77
  import {
80
78
  isObjectRefSchema2,
81
79
  validateSchemaOrRefValue2
82
- } from "./chunk-v9xd5wzd.js";
80
+ } from "./chunk-s7jg7pmn.js";
83
81
  import {
84
82
  missingClearanceRedactions,
85
- resolvePropertyClearance,
86
- redactObjectRow,
87
- redactDomainEvent,
88
- createClearanceQueryAdmission,
89
83
  WorkflowRunError2
90
- } from "./chunk-1f7wpmyp.js";
84
+ } from "./chunk-9j4jw7as.js";
91
85
  import {
92
86
  objectRefKey2,
93
87
  linkRefKey2,
94
88
  telemetryPointKey2,
95
89
  linkScopeKey
96
90
  } from "./chunk-7n440zgt.js";
91
+ import {
92
+ INDEXING_EMBEDDING_TIMEOUT_MS,
93
+ vectorConfiguration,
94
+ vectorSources,
95
+ normalizeVector2,
96
+ objectBatchKey2,
97
+ WORKFLOW_RUN_FAILURE_CODES2
98
+ } from "./chunk-918wwnaa.js";
97
99
  import {
98
100
  ACTION_RUN_FAILURE_CODES2,
99
101
  parseActionRunFailure2
100
- } from "./chunk-b38szspf.js";
102
+ } from "./chunk-dhcv7yxc.js";
101
103
  import {
102
104
  isModelReasoning2,
103
105
  modelReasoningSupportIssue2
@@ -117,50 +119,48 @@ import {
117
119
  import {
118
120
  AgentStorageError2,
119
121
  AGENT_REASONING_LEVELS2
120
- } from "./chunk-s54c868q.js";
122
+ } from "./chunk-3qct2mdc.js";
121
123
  import {
122
- ExecutionStorageError2
123
- } from "./chunk-tw03bsmb.js";
124
- import {
125
- snapshotVectorProfiles
126
- } from "./chunk-bpgy64fw.js";
124
+ actionRunRequestsEqual,
125
+ ObjectNotFoundError2
126
+ } from "./chunk-tbc1ngpd.js";
127
127
  import {
128
- vectorConfiguration,
129
- vectorSources,
130
- normalizeVector2,
131
- objectBatchKey2,
132
- WORKFLOW_RUN_FAILURE_CODES2
133
- } from "./chunk-j2bp5ryw.js";
128
+ ExecutionStorageError2
129
+ } from "./chunk-eptrvnby.js";
134
130
  import {
135
- composeObjectQueryAdmissions,
136
131
  validateObjectQuery2,
137
- validateObjectQueryWithAdmission,
138
- executeObjectQuery2,
139
- countObjects2,
140
- existsObjects2,
141
- facetObjects2,
142
- validateObjectFacetRequests,
143
- explainObjectQuery2,
144
- preflightObjectQueryLinks,
145
- executeObjectQueryLinks2
146
- } from "./chunk-4tcx876c.js";
147
- import {
148
- shareSixbErrorReporter2,
149
- reportActionPhaseFailure2,
150
- reportRunFailure2
151
- } from "./chunk-fa02jy15.js";
132
+ explainObjectQuery2
133
+ } from "./chunk-cn0fwwhy.js";
152
134
  import {
135
+ redactDomainEvent,
136
+ assertAuthorizedObjectReaderBinding,
137
+ getAuthorizedOntologyView,
138
+ readerClearance,
139
+ readerEventClearance,
153
140
  getOntologyMutationRuntime2,
154
141
  shareOntologyMutationRuntime2,
142
+ canReadActionRunSubject,
143
+ unreadableActionRunTypes,
144
+ canDelegationAccessActionRun,
145
+ actionRunBelongsToShareGrant,
146
+ resolveExecutionCosts,
147
+ createActivityRuntime,
148
+ createActivityCaptureRuntime,
149
+ registerActivityCaptureRuntime,
155
150
  ModelExecutionSession
156
- } from "./chunk-wwdfe68s.js";
151
+ } from "./chunk-6rqgmkde.js";
152
+ import {
153
+ shareSixbErrorReporter2,
154
+ reportActionPhaseFailure2,
155
+ reportRunFailure2
156
+ } from "./chunk-cy4mbddw.js";
157
157
  import {
158
158
  resolveLoggingService2
159
159
  } from "./chunk-3qms4nax.js";
160
160
  import {
161
161
  createLinkScopeFingerprint2,
162
162
  normalizeJsonProperties2
163
- } from "./chunk-zrmy8zvw.js";
163
+ } from "./chunk-bk9svbcq.js";
164
164
  import {
165
165
  EditBatchError2,
166
166
  lowerEditBatch2
@@ -170,96 +170,98 @@ import {
170
170
  applicableAiLimitPolicyStatuses2,
171
171
  aiUsageLimitExceededError2,
172
172
  aiUsageLimitUnavailableError2
173
- } from "./chunk-vyf9kfqf.js";
173
+ } from "./chunk-q7gn29y3.js";
174
174
  import {
175
175
  AgentRequestError2,
176
176
  normalizeAgentContextEntries2
177
177
  } from "./chunk-pfp1txq2.js";
178
178
  import {
179
179
  publishAgentRunActivity2
180
- } from "./chunk-5e43w60z.js";
180
+ } from "./chunk-5948n82c.js";
181
+ import {
182
+ ArtifactRequestError2
183
+ } from "./chunk-48qjhh6v.js";
181
184
  import {
182
185
  createFileDownloadUrl,
183
- revokeFileDownloadUrl,
184
- resolveFileRefAtPath2,
185
- openFileRef2,
186
- jsonPointerSegment2
187
- } from "./chunk-3zxk45er.js";
186
+ revokeFileDownloadUrl
187
+ } from "./chunk-8ncg20rd.js";
188
188
  import {
189
189
  registerConnectorConnectionsRuntime
190
190
  } from "./chunk-5a4a52tq.js";
191
191
  import {
192
192
  createConnectorRuntime
193
- } from "./chunk-wz0xs816.js";
193
+ } from "./chunk-ky3j490c.js";
194
194
  import {
195
195
  writeDataset2
196
- } from "./chunk-6gmfggss.js";
196
+ } from "./chunk-431pyp2c.js";
197
197
  import {
198
198
  SyncValidationError2,
199
199
  requestSyncRun2
200
- } from "./chunk-t6vq7bff.js";
200
+ } from "./chunk-0bphap9y.js";
201
+ import {
202
+ SandboxError2,
203
+ sandboxCredentialIssue2,
204
+ staticSandboxRecipe2
205
+ } from "./chunk-cfj9dfbb.js";
201
206
  import {
202
207
  compileShareAccessPlan
203
- } from "./chunk-52bk93x8.js";
208
+ } from "./chunk-z58tm0hm.js";
209
+ import {
210
+ schemaRecordToJsonSchema2
211
+ } from "./chunk-6x0pqh32.js";
212
+ import {
213
+ requestPipelineRun2
214
+ } from "./chunk-rmakanzx.js";
215
+ import {
216
+ PipelineError2
217
+ } from "./chunk-hke9aeen.js";
204
218
  import {
205
219
  createObjectQueryBuilder2,
206
220
  decorateObjectQueryExecutor
207
221
  } from "./chunk-9k93ah50.js";
222
+ import {
223
+ executionRecordInputFromRuntime,
224
+ ensureExecutionRecord2,
225
+ createPrimitiveExecutionRecord,
226
+ restoreTrustedPrimitiveExecutionScope
227
+ } from "./chunk-vf57cr4t.js";
208
228
  import {
209
229
  resolveLanguageModel2
210
230
  } from "./chunk-mfs23znk.js";
211
231
  import {
212
232
  AI_MODEL_CALL_OUTPUT_TOKEN_ALLOWANCE,
213
233
  aiModelCallOutputTokenAllowance
214
- } from "./chunk-7mbzgd9m.js";
234
+ } from "./chunk-1cc1xaf3.js";
215
235
  import {
216
- ObjectQueryValidationError2,
217
236
  ObjectQueryPlanningError2
218
237
  } from "./chunk-91mg3nj9.js";
219
- import {
220
- schemaRecordToJsonSchema2
221
- } from "./chunk-6x0pqh32.js";
222
- import {
223
- PipelineError2,
224
- requestPipelineRun2
225
- } from "./chunk-d2ync1v3.js";
226
- import {
227
- executionRecordInputFromRuntime,
228
- ensureExecutionRecord2,
229
- createPrimitiveExecutionRecord,
230
- restoreTrustedPrimitiveExecutionScope
231
- } from "./chunk-nre82s12.js";
232
238
  import {
233
239
  ShareGrantStorageError2
234
240
  } from "./chunk-br3k6qbf.js";
235
- import {
236
- actionRunRequestsEqual,
237
- ObjectNotFoundError2
238
- } from "./chunk-s16apyk9.js";
239
241
  import {
240
242
  ActionRunError2
241
243
  } from "./chunk-y0c4e6ex.js";
242
- import {
243
- findPrimitiveParentRequestExecution
244
- } from "./chunk-ey1nk510.js";
245
- import {
246
- RuntimeError2
247
- } from "./chunk-m4ehq95f.js";
248
- import {
249
- createPropertyTokenMap2,
250
- createLinkTokenMap2
251
- } from "./chunk-rdghfsss.js";
252
244
  import {
253
245
  MaterializationValidationError2,
254
246
  MaterializationObjectNotFoundError2,
255
247
  isMaterializationConflictError2
256
248
  } from "./chunk-96yw3pwd.js";
249
+ import {
250
+ RuntimeError2
251
+ } from "./chunk-m4ehq95f.js";
257
252
  import {
258
253
  getDatasetPrimaryKeyColumns2
259
- } from "./chunk-bwjcehza.js";
254
+ } from "./chunk-e17zdm62.js";
255
+ import {
256
+ publishArtifact2
257
+ } from "./chunk-9kgkfg6v.js";
260
258
  import {
261
259
  normalizeParams
262
- } from "./chunk-c85m1hyj.js";
260
+ } from "./chunk-447a5c0p.js";
261
+ import {
262
+ OntologyValidationError2,
263
+ OntologyNotFoundError2
264
+ } from "./chunk-cqr3acm1.js";
263
265
  import {
264
266
  ModelProviderError2,
265
267
  ModelStreamError2,
@@ -268,10 +270,10 @@ import {
268
270
  sameEmbeddingModel
269
271
  } from "./chunk-kyjcwqz6.js";
270
272
  import {
271
- OntologyValidationError2,
272
- OntologyNotFoundError2,
273
- formatUnknownObjectTypeMessage
274
- } from "./chunk-cqr3acm1.js";
273
+ resolveFileRefAtPath2,
274
+ openFileRef2,
275
+ jsonPointerSegment2
276
+ } from "./chunk-a3faa34j.js";
275
277
  import {
276
278
  isJsonValue2,
277
279
  assertJsonValue2,
@@ -312,1003 +314,10 @@ function bindModelExecutionAttempt(models, input) {
312
314
  bindings.delete(models);
313
315
  }
314
316
 
315
- // src/assert-never.ts
316
- function assertNever(_value, message) {
317
- throw new Error(message);
318
- }
319
-
320
- // src/objects/authorized-ontology-view.ts
321
- function createAuthorizedOntologyView(input) {
322
- const allObjectTypes = input.ontology.listObjectTypes();
323
- const registeredObjectTypeIds = new Set(allObjectTypes.map((objectType) => objectType.id));
324
- const requestedObjectTypeIds = selectedObjectTypeIds(input.selection, allObjectTypes);
325
- const visibleObjectTypeIds = new Set([...requestedObjectTypeIds].filter((objectTypeId) => registeredObjectTypeIds.has(objectTypeId)));
326
- const selectedSchema = input.selection.kind === "selected" ? collectSelectedSchema(input.selection.scope) : undefined;
327
- const projectedObjectTypes = [];
328
- for (const objectType of allObjectTypes) {
329
- if (!visibleObjectTypeIds.has(objectType.id))
330
- continue;
331
- const propertyIds = selectedSchema?.propertyIdsByObjectType.get(objectType.id) ?? new Set(objectType.properties.map((property) => property.id));
332
- const links = selectedSchema ? selectedSchema.linksBySourceType.get(objectType.id) ?? new Map : input.selection.kind === "all" ? allDeclaredLinks(objectType) : allVisibleLinks(input.ontology, objectType, visibleObjectTypeIds);
333
- projectedObjectTypes.push(projectObjectType({
334
- objectType,
335
- propertyIds,
336
- links,
337
- visibleObjectTypeIds,
338
- ontology: input.ontology,
339
- targetMode: input.selection.kind === "all" ? "original" : input.selection.kind === "types" ? "principal" : "exact",
340
- exposeContracts: input.selection.kind !== "selected"
341
- }));
342
- }
343
- const objectTypes = projectedObjectTypes;
344
- const objectTypesById = new Map(objectTypes.map((objectType) => [objectType.id, objectType]));
345
- const valueTypesById = input.selection.kind === "selected" ? collectVisibleValueTypes(input.ontology.getValueTypesById(), objectTypes) : snapshotAllValueTypes(input.ontology.getValueTypesById());
346
- const release = (value, budgetValue = value) => {
347
- input.assertOutputWithinLimit?.(budgetValue);
348
- return value;
349
- };
350
- const cloneObjectType = (objectType) => structuredClone(objectType);
351
- const cloneValueTypes = () => new Map([...valueTypesById].map(([valueTypeId, valueType]) => [
352
- valueTypeId,
353
- structuredClone(valueType)
354
- ]));
355
- return Object.freeze({
356
- listObjectTypes: () => release(objectTypes.map(cloneObjectType)),
357
- getObjectTypeById: (objectTypeId) => {
358
- const objectType = objectTypesById.get(objectTypeId);
359
- return release(objectType ? cloneObjectType(objectType) : null);
360
- },
361
- resolveObjectType: (objectTypeId) => {
362
- const objectType = objectTypesById.get(objectTypeId);
363
- return objectType ? release(cloneObjectType(objectType)) : unknownObjectType(objectTypeId);
364
- },
365
- getValueTypesById: () => {
366
- const valueTypes = cloneValueTypes();
367
- return release(valueTypes, [...valueTypes.entries()]);
368
- },
369
- getPrimaryPropertyId: (objectTypeId) => {
370
- const objectType = objectTypesById.get(objectTypeId);
371
- if (!objectType)
372
- return unknownObjectType(objectTypeId);
373
- const primary = objectType.properties.find((property) => property.primary);
374
- if (!primary) {
375
- throw new OntologyValidationError2(`[Sixb] Object type '${objectTypeId}' does not expose its primary property in this execution scope.`);
376
- }
377
- return release(primary.id);
378
- },
379
- listSubTypes: (objectTypeId) => {
380
- const subTypes = visibleObjectTypeIds.has(objectTypeId) ? input.ontology.listSubTypes(objectTypeId).filter((subTypeId) => visibleObjectTypeIds.has(subTypeId)) : [];
381
- return release(subTypes);
382
- },
383
- isValidLinkTarget: (expected, actual) => {
384
- if (input.selection.kind === "all") {
385
- return release(input.ontology.isValidLinkTarget(expected, actual));
386
- }
387
- if (!visibleObjectTypeIds.has(actual))
388
- return release(false);
389
- const expectedTypes = Array.isArray(expected) ? expected : [expected];
390
- if (input.selection.kind === "selected") {
391
- return release(expectedTypes.some((expectedType) => expectedType === "*" || expectedType === actual));
392
- }
393
- return release(expectedTypes.some((expectedType) => expectedType === "*" || visibleObjectTypeIds.has(expectedType) && input.ontology.isValidLinkTarget(expectedType, actual)));
394
- }
395
- });
396
- }
397
- function selectedObjectTypeIds(selection, allObjectTypes) {
398
- switch (selection.kind) {
399
- case "all":
400
- return new Set(allObjectTypes.map((objectType) => objectType.id));
401
- case "types":
402
- return new Set(selection.objectTypeIds);
403
- case "selected":
404
- return new Set(selection.scope.objects.map((object) => object.objectTypeId));
405
- }
406
- }
407
- function collectSelectedSchema(scope) {
408
- const propertyIdsByObjectType = new Map;
409
- for (const object of scope.objects) {
410
- const properties = propertyIdsByObjectType.get(object.objectTypeId) ?? new Set;
411
- for (const propertyId of object.propertyIds)
412
- properties.add(propertyId);
413
- propertyIdsByObjectType.set(object.objectTypeId, properties);
414
- }
415
- const linksBySourceType = new Map;
416
- for (const step of scope.steps) {
417
- const links = linksBySourceType.get(step.sourceObjectTypeId) ?? new Map;
418
- const selected = links.get(step.linkId) ?? {
419
- targetObjectTypeIds: new Set,
420
- propertyIds: new Set
421
- };
422
- selected.targetObjectTypeIds.add(step.targetObjectTypeId);
423
- for (const propertyId of step.propertyIds)
424
- selected.propertyIds.add(propertyId);
425
- links.set(step.linkId, selected);
426
- linksBySourceType.set(step.sourceObjectTypeId, links);
427
- }
428
- return { propertyIdsByObjectType, linksBySourceType };
429
- }
430
- function allDeclaredLinks(objectType) {
431
- return new Map(objectType.links.map((link) => [
432
- link.id,
433
- {
434
- targetObjectTypeIds: new Set(typeof link.targetObjectTypeId === "string" ? [link.targetObjectTypeId] : link.targetObjectTypeId),
435
- propertyIds: new Set(link.properties?.map((property) => property.id) ?? [])
436
- }
437
- ]));
438
- }
439
- function allVisibleLinks(ontology, objectType, visibleObjectTypeIds) {
440
- const links = new Map;
441
- for (const link of objectType.links) {
442
- const targetObjectTypeIds = new Set([...visibleObjectTypeIds].filter((targetObjectTypeId) => ontology.isValidLinkTarget(link.targetObjectTypeId, targetObjectTypeId)));
443
- if (targetObjectTypeIds.size === 0)
444
- continue;
445
- links.set(link.id, {
446
- targetObjectTypeIds,
447
- propertyIds: new Set(link.properties?.map((property) => property.id) ?? [])
448
- });
449
- }
450
- return links;
451
- }
452
- function projectObjectType(input) {
453
- const properties = input.objectType.properties.filter((property) => input.propertyIds.has(property.id)).map(snapshotProperty);
454
- const visiblePropertyIds = new Set(properties.map((property) => property.id));
455
- const links = input.objectType.links.flatMap((link) => {
456
- const selected = input.links.get(link.id);
457
- if (!selected)
458
- return [];
459
- if (input.targetMode === "original") {
460
- return [snapshotLink(link, snapshotLinkTarget(link.targetObjectTypeId), selected.propertyIds)];
461
- }
462
- const targetObjectTypeIds = new Set([...selected.targetObjectTypeIds].filter((targetObjectTypeId) => input.visibleObjectTypeIds.has(targetObjectTypeId) && input.ontology.isValidLinkTarget(link.targetObjectTypeId, targetObjectTypeId)));
463
- if (targetObjectTypeIds.size === 0)
464
- return [];
465
- const target = input.targetMode === "principal" ? principalLinkTargets(link, targetObjectTypeIds, input.visibleObjectTypeIds) : exactLinkTargets(targetObjectTypeIds);
466
- return [snapshotLink(link, target, selected.propertyIds, { omitEmptyProperties: true })];
467
- });
468
- const projected = {
469
- id: input.objectType.id,
470
- name: input.objectType.name,
471
- description: input.objectType.description,
472
- quantityKind: input.objectType.quantityKind,
473
- seeAlso: input.objectType.seeAlso ? [...input.objectType.seeAlso] : undefined,
474
- extends: input.objectType.extends && input.visibleObjectTypeIds.has(input.objectType.extends) ? input.objectType.extends : undefined,
475
- parents: projectOptionalIds(input.objectType.parents, input.visibleObjectTypeIds, input.targetMode === "original"),
476
- implements: input.exposeContracts && input.objectType.implements ? [...input.objectType.implements] : undefined,
477
- properties,
478
- links,
479
- search: projectSearch(input.objectType.search, visiblePropertyIds, {
480
- preserveEmpty: input.targetMode !== "exact"
481
- })
482
- };
483
- const withTokens = {
484
- ...projected,
485
- p: createPropertyTokenMap2(projected),
486
- l: createLinkTokenMap2(projected)
487
- };
488
- return deepFreeze(withTokens);
489
- }
490
- function principalLinkTargets(link, allowedTargetObjectTypeIds, visibleObjectTypeIds) {
491
- if (link.targetObjectTypeId === "*")
492
- return exactLinkTargets(allowedTargetObjectTypeIds);
493
- const declared = Array.isArray(link.targetObjectTypeId) ? link.targetObjectTypeId : [link.targetObjectTypeId];
494
- if (declared.every((objectTypeId) => visibleObjectTypeIds.has(objectTypeId))) {
495
- return snapshotLinkTarget(link.targetObjectTypeId);
496
- }
497
- return exactLinkTargets(allowedTargetObjectTypeIds);
498
- }
499
- function exactLinkTargets(targetObjectTypeIds) {
500
- const targets = [...targetObjectTypeIds].sort();
501
- return targets.length === 1 ? targets[0] : targets;
502
- }
503
- function projectOptionalIds(ids, visibleObjectTypeIds, preserveOriginal) {
504
- if (!ids)
505
- return;
506
- if (preserveOriginal)
507
- return [...ids];
508
- const visible = ids.filter((id) => visibleObjectTypeIds.has(id));
509
- return visible.length > 0 ? visible : undefined;
510
- }
511
- function snapshotLink(link, targetObjectTypeId, propertyIds, options = {}) {
512
- const properties = link.properties?.filter((property) => propertyIds.has(property.id)).map(snapshotProperty);
513
- return {
514
- id: link.id,
515
- name: link.name,
516
- description: link.description,
517
- targetObjectTypeId,
518
- cardinality: link.cardinality,
519
- properties: options.omitEmptyProperties && properties?.length === 0 ? undefined : properties
520
- };
521
- }
522
- function snapshotLinkTarget(target) {
523
- return typeof target === "string" ? target : [...target];
524
- }
525
- function snapshotProperty(property) {
526
- return {
527
- id: property.id,
528
- name: property.name,
529
- schema: snapshotSchema(property.schema),
530
- description: property.description,
531
- required: property.required,
532
- nullable: property.nullable,
533
- primary: property.primary,
534
- mode: property.mode,
535
- semanticType: property.semanticType,
536
- query: snapshotPropertyQuery(property.query)
537
- };
538
- }
539
- function snapshotPropertyQuery(query) {
540
- if (!query)
541
- return;
542
- return {
543
- searchable: query.searchable,
544
- filterable: query.filterable,
545
- sortable: query.sortable,
546
- text: query.text,
547
- exact: query.exact,
548
- facet: query.facet,
549
- weight: query.weight
550
- };
551
- }
552
- function projectSearch(search, visiblePropertyIds, options) {
553
- if (!search)
554
- return;
555
- const title = search.title && visiblePropertyIds.has(search.title) ? search.title : undefined;
556
- const selectedDefaultText = search.defaultText?.filter((propertyId) => visiblePropertyIds.has(propertyId));
557
- const selectedExact = search.exact?.filter((propertyId) => visiblePropertyIds.has(propertyId));
558
- const defaultText = options.preserveEmpty || selectedDefaultText?.length ? selectedDefaultText : undefined;
559
- const exact = options.preserveEmpty || selectedExact?.length ? selectedExact : undefined;
560
- const vectors = search.vectors === undefined ? undefined : snapshotVectorProfiles(Object.fromEntries(Object.entries(search.vectors).filter(([, profile]) => profile.source.every((id) => visiblePropertyIds.has(id)))));
561
- const projected = {
562
- ...vectors === undefined || Object.keys(vectors).length === 0 ? {} : { vectors },
563
- ...title === undefined ? {} : { title },
564
- ...defaultText === undefined ? {} : { defaultText },
565
- ...exact === undefined ? {} : { exact }
566
- };
567
- return Object.keys(projected).length > 0 || options.preserveEmpty ? projected : undefined;
568
- }
569
- function snapshotAllValueTypes(registered) {
570
- return new Map([...registered.values()].map((valueType) => {
571
- const snapshot = snapshotValueType(valueType);
572
- return [snapshot.id, snapshot];
573
- }));
574
- }
575
- function collectVisibleValueTypes(registered, objectTypes) {
576
- const referencedIds = new Set;
577
- const pendingSchemas = [];
578
- const visitedSchemas = new Set;
579
- for (const objectType of objectTypes) {
580
- for (const property of objectType.properties)
581
- pendingSchemas.push(property.schema);
582
- for (const link of objectType.links) {
583
- for (const property of link.properties ?? [])
584
- pendingSchemas.push(property.schema);
585
- }
586
- }
587
- while (pendingSchemas.length > 0) {
588
- const schema = pendingSchemas.pop();
589
- if (typeof schema === "string" || visitedSchemas.has(schema))
590
- continue;
591
- visitedSchemas.add(schema);
592
- if (schema.type === "valueTypeRef") {
593
- if (!referencedIds.has(schema.valueTypeId)) {
594
- referencedIds.add(schema.valueTypeId);
595
- const valueType = registered.get(schema.valueTypeId);
596
- if (valueType)
597
- pendingSchemas.push(valueType.schema);
598
- }
599
- if (schema._resolved)
600
- pendingSchemas.push(schema._resolved);
601
- } else if (schema.type === "object") {
602
- for (const field of Object.values(schema.properties))
603
- pendingSchemas.push(field.schema);
604
- } else if (schema.type === "array") {
605
- pendingSchemas.push(schema.items);
606
- } else if (schema.type === "map") {
607
- pendingSchemas.push(schema.valueSchema);
608
- }
609
- }
610
- return new Map([...referencedIds].map((valueTypeId) => registered.get(valueTypeId)).filter((valueType) => valueType !== undefined).map((valueType) => {
611
- const snapshot = snapshotValueType(valueType);
612
- return [snapshot.id, snapshot];
613
- }));
614
- }
615
- function snapshotValueType(valueType) {
616
- return deepFreeze({
617
- id: valueType.id,
618
- name: valueType.name,
619
- description: valueType.description,
620
- schema: snapshotSchema(valueType.schema),
621
- semanticType: valueType.semanticType
622
- });
623
- }
624
- function snapshotSchema(schema) {
625
- return deepFreeze(structuredClone(schema));
626
- }
627
- function deepFreeze(value, seen = new Set) {
628
- if (typeof value !== "object" || value === null || seen.has(value))
629
- return value;
630
- seen.add(value);
631
- for (const key of Reflect.ownKeys(value)) {
632
- const descriptor = Object.getOwnPropertyDescriptor(value, key);
633
- if (descriptor && "value" in descriptor)
634
- deepFreeze(descriptor.value, seen);
635
- }
636
- return Object.freeze(value);
637
- }
638
- function unknownObjectType(objectTypeId) {
639
- throw new OntologyNotFoundError2(formatUnknownObjectTypeMessage(objectTypeId));
640
- }
641
-
642
- // src/objects/query/selected-read-admission.ts
643
- var selectedStateBrand = Symbol("sixb.selected-object-query-admission-state");
644
- function createSelectedObjectQueryAdmission(scope) {
645
- const selectionByKey = new Map;
646
- const selectionsByType = new Map;
647
- const propertiesBySelection = new Map;
648
- for (const selection of scope.objects) {
649
- const key = selectionKey(selection.nodeId, selection.objectTypeId);
650
- selectionByKey.set(key, selection);
651
- propertiesBySelection.set(key, new Set(selection.propertyIds));
652
- const byType = selectionsByType.get(selection.objectTypeId) ?? [];
653
- byType.push(selection);
654
- selectionsByType.set(selection.objectTypeId, byType);
655
- }
656
- const outgoing = indexSteps(scope.steps, "outgoing", selectionByKey);
657
- const incoming = indexSteps(scope.steps, "incoming", selectionByKey);
658
- const emptyState = selectedState([]);
659
- const admission = {
660
- empty: () => emptyState,
661
- source: (input) => {
662
- const selections = input.result.objectTypeIds.flatMap((objectTypeId) => selectionsByType.get(objectTypeId) ?? []);
663
- const state = selectedState(selections);
664
- if (input.kind === "refs") {
665
- const missingType = [...new Set(input.refs?.map((ref) => ref.objectTypeId) ?? [])].sort().find((objectTypeId) => !selectionsByType.has(objectTypeId));
666
- if (missingType) {
667
- return denied(state, new AuthorizationError2(`view:object:${missingType}`, `[Sixb] Delegated query cannot reference object type '${missingType}' at '${input.path}': the selected object scope does not contain that type.`));
668
- }
669
- }
670
- if (state.selections.length > 0)
671
- return { state };
672
- const objectTypeId = input.objectTypeId ?? input.result.objectTypeIds[0] ?? "unknown";
673
- return denied(state, new AuthorizationError2(`view:object:${objectTypeId}`, `[Sixb] Delegated query cannot start from object type '${objectTypeId}' at '${input.path}': the selected object scope does not contain that type.`));
674
- },
675
- property: (input) => propertyDenial(asSelectedState(input.state), input.propertyId, input.objectTypeId, input.use, input.path, propertiesBySelection),
676
- edge: (input) => {
677
- const state = asSelectedState(input.state);
678
- const next = followEdge(state, input.linkId, input.direction, input.sourceObjectTypeId, outgoing, incoming, input.result.objectTypeIds);
679
- if (next.selections.length > 0 || state.selections.length === 0)
680
- return { state: next };
681
- return denied(next, edgeDenial(state, input.linkId, input.direction, input.sourceObjectTypeId, input.use, input.path));
682
- },
683
- set: ({ op, states }) => {
684
- if (op === "subtract")
685
- return asSelectedState(states[0] ?? emptyState);
686
- return selectedState(states.flatMap((state) => asSelectedState(state).selections));
687
- },
688
- assertPropertySelected: (input) => {
689
- const denial = propertyDenial(asSelectedState(input.state), input.propertyId, input.objectTypeId, input.use, input.path, propertiesBySelection);
690
- if (denial)
691
- throw denial;
692
- },
693
- assertIncidentEdgeSelected: (input) => {
694
- if (input.linkId === undefined)
695
- return;
696
- const state = asSelectedState(input.state);
697
- const directions = input.direction === "both" ? ["outgoing", "incoming"] : [input.direction];
698
- const next = selectedState(directions.flatMap((direction) => followEdge(state, input.linkId, direction, undefined, outgoing, incoming).selections));
699
- if (next.selections.length > 0 || state.selections.length === 0)
700
- return;
701
- throw edgeDenial(state, input.linkId, input.direction, undefined, "queryLinks", input.path);
702
- }
703
- };
704
- return Object.freeze(admission);
705
- }
706
- function indexSteps(steps, direction, selectionByKey) {
707
- const index = new Map;
708
- for (const step of steps) {
709
- const fromKey = direction === "outgoing" ? selectionKey(step.parentNodeId, step.sourceObjectTypeId) : selectionKey(step.nodeId, step.targetObjectTypeId);
710
- const toKey = direction === "outgoing" ? selectionKey(step.nodeId, step.targetObjectTypeId) : selectionKey(step.parentNodeId, step.sourceObjectTypeId);
711
- const target = selectionByKey.get(toKey);
712
- if (!selectionByKey.has(fromKey) || !target) {
713
- throw new Error("[Sixb] Compiled selected object scope contains an invalid query path step.");
714
- }
715
- const key = edgeKey(direction === "outgoing" ? step.parentNodeId : step.nodeId, direction === "outgoing" ? step.sourceObjectTypeId : step.targetObjectTypeId, step.linkId);
716
- const targets = index.get(key) ?? [];
717
- targets.push(target);
718
- index.set(key, targets);
719
- }
720
- return index;
721
- }
722
- function followEdge(state, linkId, direction, sourceObjectTypeId, outgoing, incoming, resultObjectTypeIds) {
723
- const index = direction === "outgoing" ? outgoing : incoming;
724
- const resultTypes = resultObjectTypeIds ? new Set(resultObjectTypeIds) : undefined;
725
- const selections = state.selections.flatMap((selection) => {
726
- const candidates = index.get(edgeKey(selection.nodeId, selection.objectTypeId, linkId)) ?? [];
727
- return candidates.filter((candidate) => (resultTypes === undefined || resultTypes.has(candidate.objectTypeId)) && (direction === "outgoing" || sourceObjectTypeId === undefined || candidate.objectTypeId === sourceObjectTypeId));
728
- });
729
- return selectedState(selections);
730
- }
731
- function propertyDenial(state, propertyId, objectTypeId, use, path, propertiesBySelection) {
732
- const candidates = objectTypeId ? state.selections.filter((selection) => selection.objectTypeId === objectTypeId) : state.selections;
733
- if (candidates.length === 0)
734
- return;
735
- const missing = candidates.find((selection) => !propertiesBySelection.get(selectionKey(selection.nodeId, selection.objectTypeId))?.has(propertyId));
736
- if (!missing)
737
- return;
738
- const objectTypeIds = [...new Set(candidates.map((selection) => selection.objectTypeId))].sort();
739
- return new AuthorizationError2(`view:object:${objectTypeIds.join(",")}:property:${propertyId}`, `[Sixb] Delegated query cannot use property '${propertyId}' for ${use} at '${path}': it is not selected on every matching read-scope path (missing on ${formatSelection(missing)}).`);
740
- }
741
- function edgeDenial(state, linkId, direction, sourceObjectTypeId, use, path) {
742
- const source = sourceObjectTypeId ? `:${sourceObjectTypeId}` : "";
743
- return new AuthorizationError2(`view:link:${direction}${source}:${linkId}`, `[Sixb] Delegated query cannot use ${direction} link '${linkId}' for ${use} from ${formatState(state)} at '${path}': that exact read-scope path is not selected.`);
744
- }
745
- function formatState(state) {
746
- if (state.selections.length === 0)
747
- return "an empty read-scope provenance";
748
- return `read-scope provenance ${state.selections.map(formatSelection).join(", ")}`;
749
- }
750
- function formatSelection(selection) {
751
- return `'${selection.objectTypeId}'@node ${selection.nodeId}`;
752
- }
753
- function selectedState(selections) {
754
- const unique = new Map;
755
- for (const selection of selections) {
756
- unique.set(selectionKey(selection.nodeId, selection.objectTypeId), selection);
757
- }
758
- return Object.freeze({
759
- [selectedStateBrand]: true,
760
- selections: Object.freeze([...unique.values()].sort((left, right) => left.nodeId - right.nodeId || left.objectTypeId.localeCompare(right.objectTypeId)))
761
- });
762
- }
763
- function asSelectedState(state) {
764
- if (state[selectedStateBrand] !== true) {
765
- throw new Error("[Sixb] Object query admission state belongs to another semantic admission.");
766
- }
767
- return state;
768
- }
769
- function denied(state, denial) {
770
- return { state, denial };
771
- }
772
- function selectionKey(nodeId, objectTypeId) {
773
- return JSON.stringify([nodeId, objectTypeId]);
774
- }
775
- function edgeKey(nodeId, objectTypeId, linkId) {
776
- return JSON.stringify([nodeId, objectTypeId, linkId]);
777
- }
778
-
779
- // src/objects/telemetry/workload.ts
780
- var MAX_DELEGATED_TELEMETRY_HISTORY_SERIES = 100;
781
- var MAX_DELEGATED_TELEMETRY_HISTORY_POINTS = 1e4;
782
- var DEFAULT_DELEGATED_TELEMETRY_HISTORY_LIMIT_PER_SERIES = 100;
783
-
784
- class TelemetryHistoryWorkloadExceededError extends Error {
785
- metric;
786
- limit;
787
- name = "TelemetryHistoryWorkloadExceededError";
788
- code = "telemetry_history_workload_exceeded";
789
- constructor(metric, limit) {
790
- super(`[Sixb] Delegated telemetry history exceeded its ${metric} limit (${limit}).`);
791
- this.metric = metric;
792
- this.limit = limit;
793
- }
794
- }
795
- function admitTelemetryHistoryReadWorkload(input, delegated) {
796
- const seriesCount = input.seriesCount;
797
- const limitPerSeries = input.limitPerSeries;
798
- if (!Number.isSafeInteger(seriesCount) || seriesCount < 0) {
799
- throw new Error("[Sixb] Telemetry history series must have a non-negative safe integer length.");
800
- }
801
- if (limitPerSeries !== undefined && (!Number.isSafeInteger(limitPerSeries) || limitPerSeries < 0)) {
802
- throw new Error("[Sixb] Telemetry history limit must be a non-negative safe integer.");
803
- }
804
- if (!delegated) {
805
- const admission = limitPerSeries === undefined ? {} : { limitPerSeries };
806
- return Object.freeze(admission);
807
- }
808
- if (seriesCount > MAX_DELEGATED_TELEMETRY_HISTORY_SERIES) {
809
- throw new TelemetryHistoryWorkloadExceededError("series", MAX_DELEGATED_TELEMETRY_HISTORY_SERIES);
810
- }
811
- if (seriesCount === 0) {
812
- return Object.freeze({
813
- ...limitPerSeries === undefined ? {} : { limitPerSeries },
814
- maxPointOccurrences: MAX_DELEGATED_TELEMETRY_HISTORY_POINTS
815
- });
816
- }
817
- const maxLimitPerSeries = Math.floor(MAX_DELEGATED_TELEMETRY_HISTORY_POINTS / seriesCount);
818
- const effectiveLimitPerSeries = limitPerSeries ?? Math.min(DEFAULT_DELEGATED_TELEMETRY_HISTORY_LIMIT_PER_SERIES, maxLimitPerSeries);
819
- if (effectiveLimitPerSeries > maxLimitPerSeries) {
820
- throw new TelemetryHistoryWorkloadExceededError("points", MAX_DELEGATED_TELEMETRY_HISTORY_POINTS);
821
- }
822
- return Object.freeze({
823
- limitPerSeries: effectiveLimitPerSeries,
824
- maxPointOccurrences: MAX_DELEGATED_TELEMETRY_HISTORY_POINTS
825
- });
826
- }
827
-
828
- // src/execution/authorized-object-reader.ts
829
- var readerConstructionKey = Object.freeze({});
830
-
831
- class AuthorizedObjectReaderImpl {
832
- #authorization;
833
- #authority;
834
- #runtime;
835
- #ontology;
836
- #embeddingModels;
837
- #rerankingModels;
838
- #ontologyView;
839
- #storage;
840
- #delegatedObjectTypeIds;
841
- #delegatedLinkDefinitions;
842
- #delegatedQueryAdmission;
843
- #clearance;
844
- constructor(key, input) {
845
- if (key !== readerConstructionKey) {
846
- throw new Error("[Sixb] AuthorizedObjectReader can only be created by Core.");
847
- }
848
- this.#authorization = input.scope.authorization;
849
- this.#authority = input.authority;
850
- this.#ontology = input.ontology;
851
- this.#embeddingModels = input.embeddingModels;
852
- this.#rerankingModels = input.rerankingModels;
853
- this.#storage = input.storage;
854
- this.#delegatedObjectTypeIds = input.authority.type === "delegated" ? new Set(input.authority.objectRead.scope.objects.map((object) => object.objectTypeId)) : undefined;
855
- this.#delegatedLinkDefinitions = input.authority.type === "delegated" ? new Set(input.authority.objectRead.scope.steps.map(delegatedLinkDefinitionKey)) : undefined;
856
- this.#delegatedQueryAdmission = input.authority.type === "delegated" ? createSelectedObjectQueryAdmission(input.authority.objectRead.scope) : undefined;
857
- this.#clearance = clearanceForAuthority(input.authority, input.ontology);
858
- this.#runtime = Object.freeze({
859
- projectId: input.scope.execution.projectId,
860
- runtimeAuthorization: input.scope.authorization,
861
- ...input.authority.type === "principal" ? { authorization: input.authority.context } : {}
862
- });
863
- }
864
- static assertBound(reader, scope) {
865
- const capturedScope = captureExecutionScope(scope);
866
- resolveExecutionScopeAuthorization(reader.#runtime.projectId, capturedScope);
867
- if (capturedScope.authorization !== reader.#authorization) {
868
- throw new Error("[Sixb] AuthorizedObjectReader is not bound to this exact execution authority.");
869
- }
870
- }
871
- static ontologyView(reader) {
872
- const authority = reader.#authority;
873
- reader.#ontologyView ??= createAuthorizedOntologyView({
874
- ontology: reader.#ontology,
875
- selection: ontologySelectionForAuthority(authority, reader.#ontology),
876
- ...authority.type === "delegated" ? {
877
- assertOutputWithinLimit: (value) => assertObjectReadOutputWithinLimit2(value, authority.objectRead.limits)
878
- } : {}
879
- });
880
- return reader.#ontologyView;
881
- }
882
- get projectId() {
883
- return this.#runtime.projectId;
884
- }
885
- async getByPrimaryId(input) {
886
- const request = snapshotReadValue({
887
- objectTypeId: input.objectTypeId,
888
- primaryId: input.primaryId
889
- });
890
- this.#assertObjectTypesViewable([request.objectTypeId]);
891
- const row = await this.#storage.getByPrimaryId({
892
- ...request,
893
- projectId: this.#runtime.projectId
894
- });
895
- return detachReadResult(row && this.#redact(row));
896
- }
897
- async getByPrimaryIdBatch(input) {
898
- const request = snapshotReadValue({
899
- items: input.items.map((item) => ({
900
- objectTypeId: item.objectTypeId,
901
- primaryId: item.primaryId
902
- }))
903
- });
904
- this.#assertObjectTypesViewable(request.items.map((item) => item.objectTypeId));
905
- const rows = await this.#storage.getByPrimaryIdBatch({
906
- ...request,
907
- projectId: this.#runtime.projectId
908
- });
909
- return detachReadResult(new Map([...rows].map(([key, row]) => [key, this.#redact(row)])));
910
- }
911
- async canReadObjectProperty(input) {
912
- const request = snapshotReadValue({
913
- objectTypeId: input.objectTypeId,
914
- primaryId: input.primaryId,
915
- propertyId: input.propertyId
916
- });
917
- this.#assertObjectTypesViewable([request.objectTypeId]);
918
- if (this.#hidesProperty(request))
919
- return false;
920
- if (this.#authority.type !== "delegated")
921
- return true;
922
- const [readable] = await this.#storage.selectsObjectProperties({
923
- projectId: this.#runtime.projectId,
924
- items: [request]
925
- });
926
- return readable ?? false;
927
- }
928
- async canReadObjectPropertiesBatch(input) {
929
- const request = snapshotReadValue({
930
- items: input.items.map((item) => ({
931
- objectTypeId: item.objectTypeId,
932
- primaryId: item.primaryId,
933
- propertyId: item.propertyId
934
- }))
935
- });
936
- this.#assertObjectTypesViewable(request.items.map((item) => item.objectTypeId));
937
- const selected = this.#authority.type === "delegated" ? await this.#storage.selectsObjectProperties({
938
- ...request,
939
- projectId: this.#runtime.projectId
940
- }) : request.items.map(() => true);
941
- return request.items.map((item, index) => !this.#hidesProperty(item) && selected[index] === true);
942
- }
943
- async list(input) {
944
- const request = snapshotReadValue({
945
- objectTypeId: typeof input.objectTypeId === "string" ? input.objectTypeId : input.objectTypeId === undefined ? undefined : [...input.objectTypeId],
946
- primaryIdPrefix: input.primaryIdPrefix,
947
- primaryIdSuffix: input.primaryIdSuffix,
948
- updatedAfter: input.updatedAfter,
949
- updatedBefore: input.updatedBefore,
950
- createdAfter: input.createdAfter,
951
- createdBefore: input.createdBefore,
952
- limit: input.limit,
953
- offset: input.offset,
954
- orderBy: input.orderBy,
955
- order: input.order
956
- });
957
- const objectTypeId = this.#resolveListObjectTypes(request.objectTypeId);
958
- if (Array.isArray(objectTypeId) && objectTypeId.length === 0) {
959
- return { objects: [], hasMore: false, total: 0 };
960
- }
961
- const page = await this.#storage.list({
962
- ...request,
963
- ...objectTypeId === undefined ? {} : { objectTypeId },
964
- projectId: this.#runtime.projectId
965
- });
966
- return detachReadResult({ ...page, objects: page.objects.map((row) => this.#redact(row)) });
967
- }
968
- async listLinks(input) {
969
- const request = snapshotReadValue({
970
- objectTypeId: input.objectTypeId,
971
- objectId: input.objectId,
972
- linkId: input.linkId,
973
- direction: input.direction
974
- });
975
- this.#assertObjectTypesViewable([request.objectTypeId]);
976
- const links = detachReadResult(await this.#storage.listLinks({
977
- ...request,
978
- projectId: this.#runtime.projectId
979
- }));
980
- return links.filter((link) => this.#isLinkViewable(link));
981
- }
982
- async listLinksBatch(input) {
983
- const request = snapshotReadValue({
984
- direction: input.direction,
985
- items: input.items.map((item) => ({
986
- objectTypeId: item.objectTypeId,
987
- objectId: item.objectId,
988
- linkId: item.linkId
989
- }))
990
- });
991
- this.#assertObjectTypesViewable(request.items.map((item) => item.objectTypeId));
992
- const pages = detachReadResult(await this.#storage.listLinksBatch({
993
- ...request,
994
- projectId: this.#runtime.projectId
995
- }));
996
- const filtered = new Map;
997
- for (const [key, links] of pages) {
998
- filtered.set(key, links.filter((link) => this.#isLinkViewable(link)));
999
- }
1000
- return filtered;
1001
- }
1002
- async executeQuery(input) {
1003
- const query = snapshotAuthoredQuery(input.query);
1004
- const includeTotal = snapshotReadValue(input.includeTotal);
1005
- const executionQuery = this.#admitDelegatedQuery(query)?.query ?? query;
1006
- const result = await executeObjectQuery2({
1007
- query: executionQuery,
1008
- ...includeTotal === undefined ? {} : { includeTotal },
1009
- projectId: this.#runtime.projectId,
1010
- signal: input.signal
1011
- }, this.#queryExecutorOptions());
1012
- return detachReadResult({ ...result, objects: result.objects.map((row) => this.#redact(row)) });
1013
- }
1014
- async queryLinks(input) {
1015
- const query = snapshotAuthoredQuery(input.query);
1016
- const request = snapshotReadValue({
1017
- direction: input.direction,
1018
- linkId: input.linkId,
1019
- includeObjects: input.includeObjects,
1020
- pageSize: input.pageSize,
1021
- pageToken: input.pageToken
1022
- });
1023
- let executionQuery = query;
1024
- const admission = this.#delegatedQueryAdmission;
1025
- if (admission) {
1026
- const preflight = preflightObjectQueryLinks({ query, ...request, projectId: this.#runtime.projectId }, { ontology: this.#ontology });
1027
- const admitted = validateObjectQueryWithAdmission(preflight.validated.query, { ontology: this.#ontology, normalize: false }, admission);
1028
- admission.assertIncidentEdgeSelected({
1029
- state: admitted.admissionState,
1030
- ...preflight.linkId === undefined ? {} : { linkId: preflight.linkId },
1031
- direction: preflight.direction,
1032
- path: "$.linkId"
1033
- });
1034
- executionQuery = admitted.query;
1035
- }
1036
- const result = detachReadResult(await executeObjectQueryLinks2({ query: executionQuery, ...request, projectId: this.#runtime.projectId }, this.#queryExecutorOptions()));
1037
- if (result.objects.some((row) => !this.#isObjectTypeViewable(row.objectTypeId)) || result.links.some((link) => !this.#isLinkViewable(link))) {
1038
- throw new Error("[Sixb] Object storage returned a link page outside its authorized scope.");
1039
- }
1040
- return { ...result, objects: result.objects.map((row) => this.#redact(row)) };
1041
- }
1042
- async count(input) {
1043
- const query = snapshotAuthoredQuery(input.query);
1044
- const executionQuery = this.#admitDelegatedQuery(query)?.query ?? query;
1045
- return detachReadResult(await countObjects2({ query: executionQuery, projectId: this.#runtime.projectId }, this.#queryExecutorOptions()));
1046
- }
1047
- async exists(input) {
1048
- const query = snapshotAuthoredQuery(input.query);
1049
- const executionQuery = this.#admitDelegatedQuery(query)?.query ?? query;
1050
- return detachReadResult(await existsObjects2({ query: executionQuery, projectId: this.#runtime.projectId }, this.#queryExecutorOptions()));
1051
- }
1052
- async facet(input) {
1053
- const query = snapshotAuthoredQuery(input.query);
1054
- const facets = snapshotFacetRequests(input.facets);
1055
- let executionQuery = query;
1056
- let executionFacets = facets;
1057
- const admission = this.#delegatedQueryAdmission;
1058
- if (admission) {
1059
- const validated = validateObjectQuery2(query, { ontology: this.#ontology });
1060
- const normalizedFacets = validateObjectFacetRequests(facets, validated.result.objectTypeIds, {
1061
- ontology: this.#ontology
1062
- });
1063
- const admitted = validateObjectQueryWithAdmission(validated.query, { ontology: this.#ontology, normalize: false }, admission);
1064
- normalizedFacets.forEach((facet, index) => {
1065
- admission.assertPropertySelected({
1066
- state: admitted.admissionState,
1067
- propertyId: facet.propertyId,
1068
- use: "facet",
1069
- path: `$.facets[${index}].propertyId`
1070
- });
1071
- });
1072
- executionQuery = admitted.query;
1073
- executionFacets = normalizedFacets;
1074
- }
1075
- return detachReadResult(await facetObjects2({
1076
- query: executionQuery,
1077
- facets: executionFacets,
1078
- projectId: this.#runtime.projectId
1079
- }, this.#queryExecutorOptions()));
1080
- }
1081
- redactWrittenRow(row) {
1082
- return this.#redact(row);
1083
- }
1084
- assertVisibleOutputWithinLimit(value) {
1085
- if (this.#authority.type !== "delegated")
1086
- return;
1087
- assertObjectReadOutputWithinLimit2(value, this.#authority.objectRead.limits);
1088
- }
1089
- admitTelemetryHistoryRead(input) {
1090
- return admitTelemetryHistoryReadWorkload(input, this.#authority.type === "delegated");
1091
- }
1092
- #queryExecutorOptions() {
1093
- const admission = this.#executorAdmission();
1094
- if (this.#authority.type === "delegated") {
1095
- return {
1096
- ontology: this.#ontology,
1097
- storage: this.#storage,
1098
- embeddingModels: this.#embeddingModels,
1099
- rerankingModels: this.#rerankingModels,
1100
- ...admission === undefined ? {} : { admission }
1101
- };
1102
- }
1103
- return {
1104
- ontology: this.#ontology,
1105
- embeddingModels: this.#embeddingModels,
1106
- rerankingModels: this.#rerankingModels,
1107
- storage: this.#storage,
1108
- runtimeAuthorization: this.#runtime.runtimeAuthorization,
1109
- ...this.#runtime.authorization === undefined ? {} : { authorization: this.#runtime.authorization },
1110
- ...admission === undefined ? {} : { admission }
1111
- };
1112
- }
1113
- #executorAdmission() {
1114
- const clearance = this.#clearance && createClearanceQueryAdmission(this.#clearance);
1115
- const selected = this.#delegatedQueryAdmission;
1116
- if (selected && clearance)
1117
- return composeObjectQueryAdmissions(selected, clearance);
1118
- return selected ?? clearance;
1119
- }
1120
- #redact(row) {
1121
- return this.#clearance ? redactObjectRow(row, this.#clearance) : row;
1122
- }
1123
- #hidesProperty(item) {
1124
- return this.#clearance?.hiddenPropertyIds(item.objectTypeId).has(item.propertyId) ?? false;
1125
- }
1126
- #admitDelegatedQuery(query) {
1127
- if (!this.#delegatedQueryAdmission)
1128
- return;
1129
- return validateObjectQueryWithAdmission(query, { ontology: this.#ontology }, this.#delegatedQueryAdmission);
1130
- }
1131
- #assertObjectTypesViewable(objectTypeIds) {
1132
- if (this.#authority.type === "delegated") {
1133
- for (const objectTypeId of new Set(objectTypeIds)) {
1134
- if (this.#delegatedObjectTypeIds?.has(objectTypeId))
1135
- continue;
1136
- throw new AuthorizationError2(`delegated:object.view:${objectTypeId}`, `[Sixb] Delegated authorization does not select object type '${objectTypeId}'.`);
1137
- }
1138
- return;
1139
- }
1140
- for (const objectTypeId of new Set(objectTypeIds)) {
1141
- assertAuthorized2(this.#runtime, { kind: "object.view", objectTypeId });
1142
- }
1143
- }
1144
- #resolveListObjectTypes(requested) {
1145
- if (requested !== undefined) {
1146
- const objectTypeIds = typeof requested === "string" ? [requested] : [...new Set(requested)];
1147
- for (const objectTypeId of objectTypeIds) {
1148
- this.#ontology.resolveObjectType(objectTypeId);
1149
- }
1150
- this.#assertObjectTypesViewable(objectTypeIds);
1151
- return typeof requested === "string" ? requested : objectTypeIds;
1152
- }
1153
- if (this.#authority.type === "unrestricted")
1154
- return;
1155
- return this.#ontology.listObjectTypes().map((objectType) => objectType.id).filter((objectTypeId) => this.#isObjectTypeViewable(objectTypeId));
1156
- }
1157
- #isObjectTypeViewable(objectTypeId) {
1158
- if (this.#authority.type === "delegated") {
1159
- return this.#delegatedObjectTypeIds?.has(objectTypeId) ?? false;
1160
- }
1161
- return isAllowed2(this.#runtime.authorization, { kind: "object.view", objectTypeId });
1162
- }
1163
- #isLinkViewable(link) {
1164
- if (!this.#isObjectTypeViewable(link.sourceTypeId) || !this.#isObjectTypeViewable(link.targetTypeId)) {
1165
- return false;
1166
- }
1167
- return this.#delegatedLinkDefinitions?.has(delegatedLinkDefinitionKey(link)) ?? this.#authority.type !== "delegated";
1168
- }
1169
- }
1170
- Object.freeze(AuthorizedObjectReaderImpl.prototype);
1171
- Object.freeze(AuthorizedObjectReaderImpl);
1172
- function createAuthorizedObjectReader(input) {
1173
- const scope = captureExecutionScope(input.scope);
1174
- const projectId = scope.execution.projectId;
1175
- const authority = resolveExecutionScopeAuthorization(projectId, scope);
1176
- const storage = objectStorageForAuthority(authority, input.objectStorage);
1177
- const reader = new AuthorizedObjectReaderImpl(readerConstructionKey, {
1178
- scope,
1179
- ontology: input.ontology,
1180
- embeddingModels: input.embeddingModels,
1181
- rerankingModels: input.rerankingModels,
1182
- storage,
1183
- authority
1184
- });
1185
- Object.freeze(reader);
1186
- return reader;
1187
- }
1188
- function assertAuthorizedObjectReaderBinding(input) {
1189
- AuthorizedObjectReaderImpl.assertBound(input.reader, input.scope);
1190
- }
1191
- function getAuthorizedOntologyView(reader) {
1192
- return AuthorizedObjectReaderImpl.ontologyView(reader);
1193
- }
1194
- function clearanceForAuthority(authority, ontology) {
1195
- switch (authority.type) {
1196
- case "unrestricted":
1197
- return;
1198
- case "principal":
1199
- return resolvePropertyClearance(ontology, authority.context.clearances ?? new Set);
1200
- case "delegated":
1201
- return resolvePropertyClearance(ontology, new Set);
1202
- }
1203
- }
1204
- function objectStorageForAuthority(authority, objectStorage) {
1205
- switch (authority.type) {
1206
- case "principal":
1207
- case "unrestricted":
1208
- return objectStorage;
1209
- case "delegated":
1210
- return objectStorage.createSelectedReadScope({
1211
- projectId: authority.projectId,
1212
- scope: authority.objectRead.scope,
1213
- limits: authority.objectRead.limits
1214
- });
1215
- default:
1216
- return assertNever(authority, `[Sixb] Unsupported object reader authority '${String(authority.type)}'.`);
1217
- }
1218
- }
1219
- function ontologySelectionForAuthority(authority, ontology) {
1220
- switch (authority.type) {
1221
- case "unrestricted":
1222
- return { kind: "all" };
1223
- case "principal":
1224
- return {
1225
- kind: "types",
1226
- objectTypeIds: ontology.listObjectTypes().filter((objectType) => isAllowed2(authority.context, {
1227
- kind: "object.view",
1228
- objectTypeId: objectType.id
1229
- })).map((objectType) => objectType.id)
1230
- };
1231
- case "delegated":
1232
- return { kind: "selected", scope: authority.objectRead.scope };
1233
- }
1234
- }
1235
- function delegatedLinkDefinitionKey(input) {
1236
- return "sourceObjectTypeId" in input ? JSON.stringify([input.sourceObjectTypeId, input.linkId, input.targetObjectTypeId]) : JSON.stringify([input.sourceTypeId, input.linkId, input.targetTypeId]);
1237
- }
1238
- function detachReadResult(value) {
1239
- return structuredClone(value);
1240
- }
1241
- function snapshotReadValue(value) {
1242
- return structuredClone(value);
1243
- }
1244
- function snapshotFacetRequests(facets) {
1245
- if (!Array.isArray(facets)) {
1246
- throw new ObjectQueryValidationError2([
1247
- {
1248
- path: "$.facets",
1249
- code: "invalid_facets",
1250
- message: "facets must be an array"
1251
- }
1252
- ]);
1253
- }
1254
- const length = facets.length;
1255
- if (!Number.isSafeInteger(length) || length > MAX_OBJECT_READ_FACETS2) {
1256
- throw new ObjectQueryValidationError2([
1257
- {
1258
- path: "$.facets",
1259
- code: "too_many_facets",
1260
- message: `facets must include at most ${MAX_OBJECT_READ_FACETS2} facet requests`
1261
- }
1262
- ]);
1263
- }
1264
- const snapshot = [];
1265
- for (let index = 0;index < length; index += 1) {
1266
- const facet = facets[index];
1267
- snapshot.push({ propertyId: facet.propertyId, limit: facet.limit });
1268
- }
1269
- return snapshot;
1270
- }
1271
- function snapshotAuthoredQuery(query) {
1272
- try {
1273
- const snapshot = structuredClone(query);
1274
- const pending = [snapshot];
1275
- const seen = new Set;
1276
- for (const node of pending) {
1277
- if (seen.has(node))
1278
- continue;
1279
- seen.add(node);
1280
- if (node.kind === "vector" && (typeof node.vector !== "string" || typeof node.profile !== "string" || ("propertyId" in node))) {
1281
- throw new ObjectQueryValidationError2([
1282
- {
1283
- path: "$",
1284
- code: "invalid_vector_search_input",
1285
- message: "Vector search requires a named profile and search text"
1286
- }
1287
- ]);
1288
- }
1289
- if ("input" in node)
1290
- pending.push(node.input);
1291
- if (node.kind === "set")
1292
- pending.push(...node.inputs);
1293
- }
1294
- return snapshot;
1295
- } catch (error) {
1296
- if (error instanceof ObjectQueryValidationError2)
1297
- throw error;
1298
- throw new ObjectQueryValidationError2([
1299
- {
1300
- path: "$",
1301
- code: "query_not_cloneable",
1302
- message: "Object query must contain only structured-cloneable data"
1303
- }
1304
- ]);
1305
- }
1306
- }
1307
-
1308
317
  // src/actions/descriptor.ts
1309
318
  function snapshotActionDescriptor(action) {
1310
319
  const params = Object.fromEntries(Object.entries(action.params).map(([id, config]) => [id, structuredClone(config)]));
1311
- return deepFreeze2({
320
+ return deepFreeze({
1312
321
  id: action.id,
1313
322
  ...action.description === undefined ? {} : { description: action.description },
1314
323
  binding: action.binding.kind === "global" ? { kind: "global" } : { kind: "object", objectTypeId: action.binding.objectType.id },
@@ -1321,14 +330,14 @@ function snapshotActionDescriptor(action) {
1321
330
  }
1322
331
  });
1323
332
  }
1324
- function deepFreeze2(value, seen = new Set) {
333
+ function deepFreeze(value, seen = new Set) {
1325
334
  if (typeof value !== "object" || value === null || seen.has(value))
1326
335
  return value;
1327
336
  seen.add(value);
1328
337
  for (const key of Reflect.ownKeys(value)) {
1329
338
  const descriptor = Object.getOwnPropertyDescriptor(value, key);
1330
339
  if (descriptor && "value" in descriptor)
1331
- deepFreeze2(descriptor.value, seen);
340
+ deepFreeze(descriptor.value, seen);
1332
341
  }
1333
342
  return Object.freeze(value);
1334
343
  }
@@ -1361,7 +370,7 @@ async function assertParamUsersActive(input) {
1361
370
  function assertDelegatedActionTarget(input) {
1362
371
  const { actionId, authorization, subject } = input;
1363
372
  if (subject.kind !== "object" || !authorization.actionApply.some((target) => target.actionId === actionId && target.subject.objectTypeId === subject.objectTypeId && target.subject.primaryId === subject.primaryId)) {
1364
- throw denied2(actionId, subject);
373
+ throw denied(actionId, subject);
1365
374
  }
1366
375
  return subject;
1367
376
  }
@@ -1369,7 +378,7 @@ async function admitDelegatedObjectAction(input) {
1369
378
  const { action, authorization, execution, objectReader, runtimeAuthorization, subject } = input;
1370
379
  assertDelegatedActionTarget({ authorization, actionId: action.id, subject });
1371
380
  if (action.binding.kind !== "object" || action.binding.objectType.id !== subject.objectTypeId) {
1372
- throw denied2(action.id, subject);
381
+ throw denied(action.id, subject);
1373
382
  }
1374
383
  assertAuthorizedObjectReaderBinding({
1375
384
  reader: objectReader,
@@ -1381,14 +390,14 @@ async function admitDelegatedObjectAction(input) {
1381
390
  primaryId: subject.primaryId
1382
391
  });
1383
392
  if (!visible)
1384
- throw denied2(action.id, subject);
393
+ throw denied(action.id, subject);
1385
394
  } catch (error) {
1386
395
  if (error instanceof AuthorizationError2)
1387
- throw denied2(action.id, subject);
396
+ throw denied(action.id, subject);
1388
397
  throw error;
1389
398
  }
1390
399
  }
1391
- function denied2(actionId, subject) {
400
+ function denied(actionId, subject) {
1392
401
  const target = subject.kind === "object" ? `${subject.objectTypeId}:${subject.primaryId}` : "global";
1393
402
  return new AuthorizationError2(`apply:action:${actionId}:${target}`, `[Sixb] Delegated authority cannot apply Action '${actionId}' to '${target}'.`);
1394
403
  }
@@ -2869,30 +1878,6 @@ async function settleWithin(promises, timeoutMs) {
2869
1878
  }
2870
1879
  }
2871
1880
 
2872
- // src/actions/run-authorization.ts
2873
- async function canDelegationAccessActionRun(input) {
2874
- const subject = input.run.subject;
2875
- if (!input.authority.delegation || subject.kind !== "object" || !input.authority.actionApply.some((target) => target.actionId === input.run.actionId && target.subject.objectTypeId === subject.objectTypeId && target.subject.primaryId === subject.primaryId)) {
2876
- return false;
2877
- }
2878
- return actionRunBelongsToShareGrant({
2879
- storage: input.storage,
2880
- projectId: input.projectId,
2881
- run: input.run,
2882
- grantId: input.authority.delegation.grantId
2883
- });
2884
- }
2885
- async function actionRunBelongsToShareGrant(input) {
2886
- const parent = await findPrimitiveParentRequestExecution({
2887
- executions: input.storage.executions,
2888
- projectId: input.projectId,
2889
- executionId: input.run.executionId,
2890
- primitive: { kind: "action", id: input.run.actionId, runId: input.run.id }
2891
- });
2892
- const authorization = parent?.authorizationRef;
2893
- return authorization?.type === "delegated" && authorization.delegation.kind === "share" && authorization.delegation.grantId === input.grantId;
2894
- }
2895
-
2896
1881
  // src/actions/request.ts
2897
1882
  function getActionDefinition(runtime, actionId) {
2898
1883
  const action = runtime.actionRegistry.getById(actionId);
@@ -2935,6 +1920,9 @@ async function requestAction3(runtime, execution, input) {
2935
1920
  assertAuthorized2({ projectId, runtimeAuthorization }, { kind: "object.view", objectTypeId: action.binding.objectType.id });
2936
1921
  }
2937
1922
  validateActionSubject(action, subject);
1923
+ if (authorization.type !== "delegated" && subject.kind === "object") {
1924
+ await objectReader.assertReadable({ objectTypeIds: [subject.objectTypeId] });
1925
+ }
2938
1926
  let pathPrefix = action.id;
2939
1927
  let objectType = null;
2940
1928
  if (isObjectActionDefinition2(action)) {
@@ -2950,7 +1938,13 @@ async function requestAction3(runtime, execution, input) {
2950
1938
  const executor = getActionRunExecutor(runtime);
2951
1939
  request.signal?.throwIfAborted();
2952
1940
  const payload = { actionId, subject, params: actionParams };
2953
- const assertCanReuse = (run) => assertCallerMayHaveRun({ storage: runtime.storage, projectId, authorization, run });
1941
+ const assertCanReuse = (run) => assertCallerMayHaveRun({
1942
+ storage: runtime.storage,
1943
+ projectId,
1944
+ authorization,
1945
+ objectReader,
1946
+ run
1947
+ });
2954
1948
  const persist = () => persistActionRun({
2955
1949
  projectId,
2956
1950
  storage: runtime.storage,
@@ -2995,7 +1989,7 @@ async function assertCallerMayHaveRun(input) {
2995
1989
  projectId: input.projectId,
2996
1990
  run,
2997
1991
  grantId: authorization.delegation.grantId
2998
- }) : authorization.type !== "principal" || canViewActionRun2(authorization.context, run);
1992
+ }) : authorization.type !== "principal" || canViewActionRun2(authorization.context, run) && await canReadActionRunSubject(input.objectReader, run);
2999
1993
  if (!visible) {
3000
1994
  throw new AuthorizationError2(`apply:action:${run.actionId}`, authorization.type === "delegated" ? "[Sixb] Delegated authority cannot reuse this Action run." : `[Sixb] Action run '${run.id}' is not visible to this principal.`);
3001
1995
  }
@@ -3087,40 +2081,29 @@ function createActionsRuntime(runtime, execution) {
3087
2081
  projectId,
3088
2082
  authority: authorization,
3089
2083
  run
3090
- })) ? release(run) : null;
2084
+ })) && await canReadActionRunSubject(objectReader, run) ? release(run) : null;
3091
2085
  },
3092
- list: (input = {}) => {
2086
+ list: async (input = {}) => {
3093
2087
  if (authorization.type === "denied" || authorization.type === "delegated") {
3094
- return Promise.resolve({ runs: [], hasMore: false, total: 0 });
2088
+ return { runs: [], hasMore: false, total: 0 };
3095
2089
  }
3096
2090
  const storage = runtime.storage.actionRuns;
3097
2091
  if (!storage)
3098
- return Promise.resolve({ runs: [], hasMore: false, total: 0 });
2092
+ return { runs: [], hasMore: false, total: 0 };
2093
+ if (authorization.type === "unrestricted")
2094
+ return storage.list({ ...input, projectId });
2095
+ const unreadable = await unreadableActionRunTypes(objectReader);
3099
2096
  return storage.list({
3100
2097
  ...input,
3101
2098
  projectId,
3102
- actionIds: authorization.type === "principal" ? [...authorization.context.grants["apply:action"]] : undefined,
3103
- objectTypeIds: authorization.type === "principal" ? [...authorization.context.grants["view:object"]] : undefined
2099
+ actionIds: [...authorization.context.grants["apply:action"]],
2100
+ objectTypeIds: [...authorization.context.grants["view:object"]].filter((objectTypeId) => !unreadable.has(objectTypeId))
3104
2101
  });
3105
2102
  }
3106
2103
  }
3107
2104
  };
3108
2105
  }
3109
2106
 
3110
- // src/runtime/ai-cost.ts
3111
- async function resolveExecutionCosts(input) {
3112
- if (input.executionIds.length === 0)
3113
- return [];
3114
- if (!input.storage)
3115
- return input.executionIds.map(() => {
3116
- return;
3117
- });
3118
- return input.storage.summarizeExecutions({
3119
- projectId: input.projectId,
3120
- executionIds: input.executionIds
3121
- });
3122
- }
3123
-
3124
2107
  // src/runtime/ai-usage.ts
3125
2108
  async function resolveExecutionUsage(input) {
3126
2109
  if (input.executionIds.length === 0)
@@ -3448,6 +2431,10 @@ async function retryAgentRun2(runtime, execution, models, failedRun) {
3448
2431
  threadId: failedRun.threadId,
3449
2432
  runId: failedRun.id
3450
2433
  });
2434
+ await tx.artifacts?.deleteVersionsByOrigin({
2435
+ projectId: runtime.projectId,
2436
+ runId: failedRun.id
2437
+ });
3451
2438
  await tx.executions.create(durableExecution);
3452
2439
  return agents.runs.create({
3453
2440
  id: runId,
@@ -3962,6 +2949,75 @@ function createAiUsageRuntime(runtime, security) {
3962
2949
  }
3963
2950
  };
3964
2951
  }
2952
+ // src/artifacts/execution.ts
2953
+ function createArtifactsRuntime(runtime, blobStorage) {
2954
+ const authority = resolveRuntimeAuthorizationForProject(runtime);
2955
+ const caller = authority.type === "principal" ? authority.context.principal : authority.type === "unrestricted" ? SYSTEM_PRINCIPAL2 : null;
2956
+ const ownerFilter = authority.type === "principal" ? caller : null;
2957
+ const requireStorage = () => {
2958
+ const storage = runtime.storage.artifacts;
2959
+ if (!storage) {
2960
+ throw new ArtifactRequestError2("storage_unavailable", "[Sixb] Artifacts need storage that supports them.");
2961
+ }
2962
+ return storage;
2963
+ };
2964
+ const requireCaller = () => {
2965
+ if (!caller) {
2966
+ throw new ArtifactRequestError2("not_allowed", "[Sixb] This caller cannot publish artifacts.");
2967
+ }
2968
+ return caller;
2969
+ };
2970
+ const visible = (artifact) => artifact && caller && (!ownerFilter || principalsEqual2(ownerFilter, artifact.owner)) ? artifact : null;
2971
+ const getVisible = async (artifactId) => caller ? visible(await requireStorage().get({ projectId: runtime.projectId, id: artifactId })) : null;
2972
+ return {
2973
+ async create(input) {
2974
+ return publishArtifact2({ projectId: runtime.projectId, storage: requireStorage(), blobStorage }, { ...input, author: requireCaller() });
2975
+ },
2976
+ async publish(artifactId, input) {
2977
+ const author = requireCaller();
2978
+ if (!await getVisible(artifactId))
2979
+ throw notFound(artifactId);
2980
+ return publishArtifact2({ projectId: runtime.projectId, storage: requireStorage(), blobStorage }, { ...input, artifactId, author });
2981
+ },
2982
+ get: getVisible,
2983
+ async list(input = {}) {
2984
+ if (!caller)
2985
+ return { artifacts: [], hasMore: false, total: 0 };
2986
+ return requireStorage().list({
2987
+ projectId: runtime.projectId,
2988
+ ...ownerFilter ? { owner: ownerFilter } : {},
2989
+ ...input.threadId === undefined ? {} : { originThreadId: input.threadId },
2990
+ ...input.kind === undefined ? {} : { kind: input.kind },
2991
+ ...input.limit === undefined ? {} : { limit: input.limit },
2992
+ ...input.offset === undefined ? {} : { offset: input.offset }
2993
+ });
2994
+ },
2995
+ async getVersion(artifactId, version) {
2996
+ const artifact = await getVisible(artifactId);
2997
+ if (!artifact)
2998
+ return null;
2999
+ return requireStorage().getVersion({
3000
+ projectId: runtime.projectId,
3001
+ artifactId,
3002
+ version: version === "latest" ? artifact.latestVersion : version
3003
+ });
3004
+ },
3005
+ async listVersions(artifactId, input = {}) {
3006
+ if (!await getVisible(artifactId))
3007
+ return null;
3008
+ return requireStorage().listVersions({ projectId: runtime.projectId, artifactId, ...input });
3009
+ },
3010
+ async delete(artifactId) {
3011
+ if (!await getVisible(artifactId))
3012
+ return false;
3013
+ return requireStorage().delete({ projectId: runtime.projectId, id: artifactId });
3014
+ }
3015
+ };
3016
+ }
3017
+ function notFound(artifactId) {
3018
+ return new ArtifactRequestError2("artifact_not_found", `[Sixb] Artifact '${artifactId}' was not found.`);
3019
+ }
3020
+
3965
3021
  // src/blob-storage/execution.ts
3966
3022
  function createBlobsRuntime(runtime, execution, blobStorage, apiPublicOrigin) {
3967
3023
  const assertAccess = () => assertProviderAccess2(runtime, execution, "blobs.access");
@@ -4070,7 +3126,7 @@ function commandContext(runtime, execution, connectorId) {
4070
3126
  }
4071
3127
 
4072
3128
  // src/datasets/execution.ts
4073
- function createDatasetsRuntime(runtime, execution, source, lakeStorage, blobStorage) {
3129
+ function createDatasetsRuntime(runtime, execution, source, lakeStorage, blobStorage, versionMarkings) {
4074
3130
  const authority = resolveRuntimeAuthorizationForProject(runtime);
4075
3131
  const allowed = (datasetId) => isRuntimeAllowed2(runtime, { kind: "dataset.view", datasetId });
4076
3132
  return {
@@ -4089,7 +3145,7 @@ function createDatasetsRuntime(runtime, execution, source, lakeStorage, blobStor
4089
3145
  const version = input.versionId === undefined ? await lakeStorage.getLatestVersion(registered.id) : await lakeStorage.getVersion(registered.id, input.versionId);
4090
3146
  if (!version)
4091
3147
  return null;
4092
- const redacted = redactedColumns(registered, assertRuntimeAuthorizationBound2(runtime));
3148
+ const redacted = redactedColumns(version, versionMarkings, assertRuntimeAuthorizationBound2(runtime));
4093
3149
  const selected = selectColumns(version, input.columns);
4094
3150
  const columns = selected.filter((column) => !redacted.has(column));
4095
3151
  const read = (readColumns) => lakeStorage.readRows({
@@ -4163,11 +3219,14 @@ function selectColumns(version, requested) {
4163
3219
  }
4164
3220
  return [...requested];
4165
3221
  }
4166
- function redactedColumns(dataset, authority) {
3222
+ function redactedColumns(version, versionMarkings, authority) {
4167
3223
  if (authority.type === "unrestricted")
4168
3224
  return new Set;
4169
3225
  const clearances = authority.type === "principal" ? authority.context.clearances ?? new Set : new Set;
4170
- return new Set(dataset.schema.columns.filter((column) => column.markings?.some((markingId) => !clearances.has(markingId))).map((column) => column.name));
3226
+ if ([...versionMarkings.everyMarking()].every((id) => clearances.has(id)))
3227
+ return new Set;
3228
+ const { columns } = versionMarkings.classify(version);
3229
+ return new Set([...columns].filter(([, columnMarkings]) => [...columnMarkings].some((id) => !clearances.has(id))).map(([column]) => column));
4171
3230
  }
4172
3231
  async function* emptyRows(rows) {
4173
3232
  for await (const _row of rows)
@@ -4177,23 +3236,30 @@ async function* emptyRows(rows) {
4177
3236
  // src/events/execution.ts
4178
3237
  function createEventsRuntime(runtime) {
4179
3238
  const authority = resolveRuntimeAuthorizationForProject(runtime);
4180
- const clearance = authority.type === "principal" ? resolvePropertyClearance(runtime.ontology, authority.context.clearances ?? new Set) : undefined;
4181
- const readable = (event) => {
3239
+ const visible = async (events) => {
4182
3240
  switch (authority.type) {
4183
3241
  case "denied":
4184
3242
  case "delegated":
4185
- return;
4186
- case "principal":
4187
- if (!canViewEvent2(authority.context, event))
4188
- return;
4189
- return clearance ? redactDomainEvent(event, clearance) : event;
3243
+ return [];
4190
3244
  case "unrestricted":
4191
- return event;
3245
+ return events;
3246
+ case "principal": {
3247
+ const viewable = events.filter((event) => canViewEvent2(authority.context, event));
3248
+ if (viewable.length === 0)
3249
+ return viewable;
3250
+ const clearance = await readerClearance(runtime.objectReader);
3251
+ const clearanceFor = await eventClearances(runtime.objectReader, viewable, clearance);
3252
+ return viewable.flatMap((event) => {
3253
+ if (clearance && readsUnreadable(event, clearance))
3254
+ return [];
3255
+ const redacting = clearanceFor(event);
3256
+ return [redacting ? redactDomainEvent(event, redacting) : event];
3257
+ });
3258
+ }
4192
3259
  }
4193
3260
  };
4194
- const visibleEvents = (events) => events.flatMap((event) => readable(event) ?? []);
4195
3261
  return {
4196
- readable,
3262
+ visible,
4197
3263
  append: (input) => {
4198
3264
  assertPrivileged2(runtime, "events.append");
4199
3265
  return runtime.events.append(input);
@@ -4211,8 +3277,7 @@ function createEventsRuntime(runtime) {
4211
3277
  case "unrestricted":
4212
3278
  break;
4213
3279
  }
4214
- const events = await runtime.events.read(input);
4215
- return visibleEvents(events);
3280
+ return visible(await runtime.events.read(input));
4216
3281
  },
4217
3282
  latestCursor: () => {
4218
3283
  switch (authority.type) {
@@ -4233,14 +3298,63 @@ function createEventsRuntime(runtime) {
4233
3298
  case "unrestricted":
4234
3299
  break;
4235
3300
  }
4236
- return runtime.events.subscribe(input, (events) => {
4237
- const visible = visibleEvents(events);
4238
- if (visible.length > 0)
4239
- return handler(visible);
3301
+ return runtime.events.subscribe(input, async (events) => {
3302
+ let shown;
3303
+ try {
3304
+ shown = await visible(events);
3305
+ } catch (error) {
3306
+ const message = error instanceof Error ? error.message : String(error);
3307
+ console.warn(`[Sixb] Dropped ${events.length} event(s) from cursor '${events[0]?.cursor}' of a subscription, whose markings could not be enforced: ${message}`);
3308
+ return;
3309
+ }
3310
+ if (shown.length > 0)
3311
+ return handler(shown);
4240
3312
  });
4241
3313
  }
4242
3314
  };
4243
3315
  }
3316
+ async function eventClearances(reader, events, clearance) {
3317
+ const kinds = new Map;
3318
+ for (const event of events) {
3319
+ const kind = eventSources(event);
3320
+ if (kind)
3321
+ kinds.set(kind.key, kind.sources);
3322
+ }
3323
+ const resolved = await Promise.all([...kinds].map(async ([key, sources]) => [key, await readerEventClearance(reader, sources)]));
3324
+ const byKind = new Map(resolved);
3325
+ return (event) => {
3326
+ const kind = eventSources(event);
3327
+ return kind ? byKind.get(kind.key) : clearance;
3328
+ };
3329
+ }
3330
+ function eventSources(event) {
3331
+ if (event.topic !== "objects")
3332
+ return;
3333
+ const objectTypeId = event.payload.objectTypeId;
3334
+ const earlier = event.type !== "object.created";
3335
+ if (event.origin?.kind !== "projection") {
3336
+ if (!earlier)
3337
+ return;
3338
+ return { key: JSON.stringify([objectTypeId]), sources: { objectTypeId, earlier } };
3339
+ }
3340
+ const { projectionId, datasetId, datasetVersionId } = event.origin;
3341
+ const origin = { projectionId, datasetId, datasetVersionId, objectTypeId };
3342
+ return {
3343
+ key: JSON.stringify([objectTypeId, projectionId, datasetId, datasetVersionId, earlier]),
3344
+ sources: { objectTypeId, origin, earlier }
3345
+ };
3346
+ }
3347
+ function readsUnreadable(event, clearance) {
3348
+ switch (event.topic) {
3349
+ case "objects":
3350
+ case "telemetry":
3351
+ return clearance.unreadableType(event.payload.objectTypeId) !== undefined;
3352
+ case "links":
3353
+ return clearance.unreadableType(event.payload.sourceTypeId) !== undefined || clearance.unreadableType(event.payload.targetTypeId) !== undefined || clearance.unreadableLink(event.payload.sourceTypeId, event.payload.linkId) !== undefined;
3354
+ default:
3355
+ return false;
3356
+ }
3357
+ }
4244
3358
 
4245
3359
  // src/logging/execution.ts
4246
3360
  function createLogsRuntime(runtime, source) {
@@ -5586,16 +4700,24 @@ function requireOutcome(outcomes, id) {
5586
4700
  }
5587
4701
 
5588
4702
  // src/objects/link/authorization.ts
5589
- function assertCanWriteLink(ctx, endpoints) {
5590
- assertCanEdit2(ctx, endpoints.sourceTypeId);
5591
- assertAuthorized2(ctx, { kind: "object.view", objectTypeId: endpoints.targetTypeId });
4703
+ async function assertCanWriteLinks(ctx, writes) {
4704
+ for (const write of writes) {
4705
+ assertCanEdit2(ctx, write.sourceTypeId);
4706
+ assertAuthorized2(ctx, { kind: "object.view", objectTypeId: write.targetTypeId });
4707
+ }
4708
+ await ctx.objectReader.assertReadable({
4709
+ objectTypeIds: [
4710
+ ...new Set(writes.flatMap((write) => [write.sourceTypeId, write.targetTypeId]))
4711
+ ],
4712
+ links: writes.map((write) => ({ objectTypeId: write.sourceTypeId, linkId: write.linkId }))
4713
+ });
5592
4714
  }
5593
4715
 
5594
4716
  // src/objects/link/remove.ts
5595
4717
  async function removeLink2(ctx, params) {
5596
4718
  const { objectType, linkDefinition, ontology } = ctx;
5597
4719
  const { sourceId, linkId, targetTypeId, targetId } = params;
5598
- assertCanWriteLink(ctx, { sourceTypeId: objectType.id, targetTypeId });
4720
+ await assertCanWriteLinks(ctx, [{ sourceTypeId: objectType.id, linkId, targetTypeId }]);
5599
4721
  assertLinkTargetType2(objectType.id, linkId, linkDefinition, targetTypeId, (expected, actual) => ontology.isValidLinkTarget(expected, actual));
5600
4722
  await commitRuntimeOperations(ctx, [
5601
4723
  linkDeleteOperation({
@@ -5651,7 +4773,7 @@ function endpointKey(objectTypeId, primaryId) {
5651
4773
  async function upsertLink2(ctx, params) {
5652
4774
  const { objectType, linkDefinition, ontology } = ctx;
5653
4775
  const { sourceId, linkId, targetTypeId, targetId, properties } = params;
5654
- assertCanWriteLink(ctx, { sourceTypeId: objectType.id, targetTypeId });
4776
+ await assertCanWriteLinks(ctx, [{ sourceTypeId: objectType.id, linkId, targetTypeId }]);
5655
4777
  const endpoints = { objectType, sourceId, targetTypeId, targetId };
5656
4778
  requireEndpoints(endpoints, await loadEndpointExistence(ctx, collectEndpointLookups([endpoints])));
5657
4779
  const normalizedProperties = normalizeRuntimeLink({
@@ -5727,12 +4849,11 @@ async function upsertLinkBatch2(ctx, items) {
5727
4849
  const { ontology } = ctx;
5728
4850
  if (items.length === 0)
5729
4851
  return [];
5730
- for (const item of items) {
5731
- assertCanWriteLink(ctx, {
5732
- sourceTypeId: item.objectType.id,
5733
- targetTypeId: item.targetTypeId
5734
- });
5735
- }
4852
+ await assertCanWriteLinks(ctx, items.map((item) => ({
4853
+ sourceTypeId: item.objectType.id,
4854
+ linkId: item.linkId,
4855
+ targetTypeId: item.targetTypeId
4856
+ })));
5736
4857
  const existing = await loadEndpointExistence(ctx, collectEndpointLookups(items));
5737
4858
  const valueTypesById = ontology.getValueTypesById();
5738
4859
  return runRuntimeItemBatch({
@@ -5776,6 +4897,7 @@ async function upsertLinkBatch2(ctx, items) {
5776
4897
  // src/objects/object/delete.ts
5777
4898
  async function deleteObject2(ctx, primaryId) {
5778
4899
  assertCanEdit2(ctx, ctx.objectType.id);
4900
+ await ctx.objectReader.assertReadable({ objectTypeIds: [ctx.objectType.id] });
5779
4901
  await commitRuntimeOperations(ctx, [
5780
4902
  objectDeleteOperation({
5781
4903
  id: runtimeOperationId(0),
@@ -5785,6 +4907,7 @@ async function deleteObject2(ctx, primaryId) {
5785
4907
  }
5786
4908
  async function restoreObject2(ctx, primaryId) {
5787
4909
  assertCanEdit2(ctx, ctx.objectType.id);
4910
+ await ctx.objectReader.assertReadable({ objectTypeIds: [ctx.objectType.id] });
5788
4911
  await commitRuntimeOperations(ctx, [
5789
4912
  objectRestoreOperation({
5790
4913
  id: runtimeOperationId(0),
@@ -5796,6 +4919,7 @@ async function restoreObject2(ctx, primaryId) {
5796
4919
  async function upsertObject2(ctx, properties) {
5797
4920
  assertCanEdit2(ctx, ctx.objectType.id);
5798
4921
  const { objectType, primaryPropertyId, ontology } = ctx;
4922
+ const redact = await ctx.objectReader.writtenRowRedactor(objectType.id);
5799
4923
  const normalized = normalizeRuntimeObject({
5800
4924
  objectType,
5801
4925
  primaryPropertyId,
@@ -5806,13 +4930,14 @@ async function upsertObject2(ctx, properties) {
5806
4930
  const commit = await commitRuntimeOperations(ctx, [
5807
4931
  objectUpsertOperation({ id: runtimeOperationId(0), ref, properties: normalized.properties })
5808
4932
  ]);
5809
- return ctx.objectReader.redactWrittenRow(toObjectRow(ctx.projectId, requireEffectiveObject(commit.outcomes[0])));
4933
+ return redact(toObjectRow(ctx.projectId, requireEffectiveObject(commit.outcomes[0])));
5810
4934
  }
5811
4935
  // src/objects/object/upsert-batch.ts
5812
4936
  async function upsertObjectBatch2(ctx, items) {
5813
4937
  assertCanEdit2(ctx, ctx.objectType.id);
5814
4938
  const { objectType, primaryPropertyId, ontology } = ctx;
5815
4939
  const valueTypesById = ontology.getValueTypesById();
4940
+ const redact = await ctx.objectReader.writtenRowRedactor(objectType.id);
5816
4941
  return runRuntimeItemBatch({
5817
4942
  ctx,
5818
4943
  items,
@@ -5837,7 +4962,7 @@ async function upsertObjectBatch2(ctx, items) {
5837
4962
  ]
5838
4963
  };
5839
4964
  },
5840
- value: ([outcome]) => ctx.objectReader.redactWrittenRow(toObjectRow(ctx.projectId, requireEffectiveObject(outcome)))
4965
+ value: ([outcome]) => redact(toObjectRow(ctx.projectId, requireEffectiveObject(outcome)))
5841
4966
  });
5842
4967
  }
5843
4968
  // src/objects/vectors/handle.ts
@@ -5882,7 +5007,11 @@ function createObjectVectorHandle(ctx, primaryId, profileName) {
5882
5007
  expectedObject: { ref, exists: true, version: row.version, lastCommitId: row.lastCommitId },
5883
5008
  expectedVectorCommitId: current?.lastCommitId ?? null
5884
5009
  };
5885
- const result = await model.embed({ texts: [input.text], purpose: "document" });
5010
+ const result = await model.embed({
5011
+ texts: [input.text],
5012
+ purpose: "document",
5013
+ signal: AbortSignal.timeout(INDEXING_EMBEDDING_TIMEOUT_MS)
5014
+ });
5886
5015
  if (!Array.isArray(result?.vectors) || result.vectors.length !== 1) {
5887
5016
  throw new MaterializationValidationError2("Embedding model must return exactly one vector for one input text.");
5888
5017
  }
@@ -7744,10 +6873,51 @@ function validateAgentNodeDefinition(workflowId, node) {
7744
6873
  assertUniqueNonEmptyAgentStepValues(workflowId, node.id, "group", node.agentStep.groupIds);
7745
6874
  assertUniqueNonEmptyAgentStepValues(workflowId, node.id, "tool", node.agentStep.toolNames);
7746
6875
  assertUniqueNonEmptyAgentStepValues(workflowId, node.id, "skill", node.agentStep.skillNames);
6876
+ if (node.agentStep.sandbox !== undefined) {
6877
+ assertAgentStepSandbox(node.agentStep.sandbox, `Workflow "${workflowId}" agent step "${node.id}"`);
6878
+ }
7747
6879
  if (node.mapper !== undefined && typeof node.mapper !== "function") {
7748
6880
  throw new WorkflowDefinitionError2(`Workflow "${workflowId}" agent node "${node.id}" mapper must be a function.`);
7749
6881
  }
7750
6882
  }
6883
+ function assertAgentStepSandbox(value, step) {
6884
+ const fail = (issue, cause) => {
6885
+ throw new WorkflowDefinitionError2(`${step} sandbox ${issue}`, cause === undefined ? undefined : { cause });
6886
+ };
6887
+ if (!isRecord(value) || typeof value.create !== "function") {
6888
+ return fail("must be a sandbox factory with a create function.");
6889
+ }
6890
+ const { configuration } = value;
6891
+ if (configuration === undefined)
6892
+ return;
6893
+ if (!isRecord(configuration))
6894
+ return fail("configuration must be a sandbox recipe object.");
6895
+ if (configuration.params !== undefined || configuration.resolve !== undefined) {
6896
+ return fail("must use a static recipe: params and resolve are not supported in workflow steps.");
6897
+ }
6898
+ let recipe;
6899
+ try {
6900
+ recipe = staticSandboxRecipe2(configuration);
6901
+ } catch (error) {
6902
+ if (!(error instanceof SandboxError2))
6903
+ throw error;
6904
+ return fail(`recipe is invalid: ${error.message.replace(/^\[Sixb\] /, "")}`, error);
6905
+ }
6906
+ if (recipe.network?.mode === "none") {
6907
+ return fail('network mode "none" cannot run an agent: the agent needs the Sixb API. Use { mode: "restricted", allow: [...] } with the origins the project needs; Sixb adds its own.');
6908
+ }
6909
+ const { auth } = configuration;
6910
+ if (auth !== undefined && !(isRecord(auth) && typeof auth.authorize === "function")) {
6911
+ return fail("auth requires an authorize function.");
6912
+ }
6913
+ const credentialIssue = sandboxCredentialIssue2({
6914
+ supportsRequestCredentials: value.supportsRequestCredentials === true,
6915
+ auth,
6916
+ source: recipe.source
6917
+ });
6918
+ if (credentialIssue)
6919
+ fail(`is invalid: ${credentialIssue}`);
6920
+ }
7751
6921
  function assertUniqueNonEmptyAgentStepValues(workflowId, stepId, kind, values) {
7752
6922
  const seen = new Set;
7753
6923
  for (const value of values) {
@@ -8651,6 +7821,7 @@ function createBoundSixb(runtime, dependencies, execution) {
8651
7821
  ...createExecutionFacades(runtime, execution, dependencies)
8652
7822
  };
8653
7823
  shareOntologyMutationRuntime2(runtime, sixb);
7824
+ registerActivityCaptureRuntime(sixb, createActivityCaptureRuntime(runtime, dependencies.activity));
8654
7825
  if (dependencies.connectorConnections) {
8655
7826
  registerConnectorConnectionsRuntime(sixb, createConnectorConnectionsRuntime(runtime, execution, dependencies.connectorConnections));
8656
7827
  }
@@ -8664,17 +7835,19 @@ function createExecutionFacades(runtime, execution, dependencies) {
8664
7835
  return {
8665
7836
  objects: createObjectsRuntime(runtime, execution, dependencies.blobStorage),
8666
7837
  actions: createActionsRuntime(runtime, execution),
8667
- datasets: createDatasetsRuntime(runtime, execution, dependencies.definitions.datasets, dependencies.lakeStorage, dependencies.blobStorage),
7838
+ datasets: createDatasetsRuntime(runtime, execution, dependencies.definitions.datasets, dependencies.lakeStorage, dependencies.blobStorage, dependencies.datasetVersionMarkings),
8668
7839
  workflows: createWorkflowsRuntime(runtime, execution, dependencies.definitions.workflows),
8669
7840
  syncs: createSyncsRuntime(runtime, execution, dependencies.definitions.syncs),
8670
7841
  pipelines: createPipelinesRuntime(runtime, execution, dependencies.definitions.pipelines),
8671
7842
  projections: createProjectionsRuntime(runtime, dependencies.definitions.projections),
8672
7843
  rules: createRulesRuntime(runtime, dependencies.definitions.rules),
8673
7844
  agent: createAgentRuntime(runtime, execution, dependencies.definitions.models, dependencies.sandbox),
7845
+ artifacts: createArtifactsRuntime(runtime, dependencies.blobStorage),
8674
7846
  models: createModelsRuntime(runtime, execution, dependencies.definitions.models, dependencies.blobStorage),
8675
7847
  aiUsage: createAiUsageRuntime(runtime, dependencies.definitions.security),
8676
7848
  events: createEventsRuntime(runtime),
8677
7849
  logs: createLogsRuntime(runtime, dependencies.logging),
7850
+ activity: createActivityRuntime(runtime, dependencies.activity),
8678
7851
  schedules: createSchedulesRuntime(runtime, dependencies.definitions.schedules),
8679
7852
  shares: createSharesRuntime(runtime, execution, dependencies.definitions.shares),
8680
7853
  connector: createConnectorRuntime(runtime, execution, dependencies.connectorService),
@@ -8802,6 +7975,6 @@ function invalidAgentExecution(executionId, runId) {
8802
7975
  throw new ExecutionStorageError2("invalid_input", `[Sixb] Execution '${executionId}' does not authorize Agent run '${runId}'.`);
8803
7976
  }
8804
7977
 
8805
- export { defineAction2, param2, optional2, ActionRegistry2, createAuthorizedObjectReader, bindModelExecutionAttempt, createAgentThreadId2, createAgentThreadSandboxName2, createAgentRunId2, createSubagentRunId2, createSubagentExecutionId2, createAgentMessageId2, agentContextCheckpointId2, createAgentRunExecutionToken2, canInheritAgentRequestAuthorization2, createAgentExecutionRecord2, createInheritedAgentExecutionRecord2, bindDurableAgentExecution2, bindAgentModelExecution2, restoreAgentExecutionScope2, assertAgentExecutionRecord2, DEFAULT_PROJECT_LOCALE, DEFAULT_PROJECT_TIME_ZONE, canonicalLocale, canonicalTimeZone, resolveAgentContextParts2, agentRunQueueJobId2, subagentRunQueueJobId2, workflowAgentNodeQueueJobId2, dispatchQueuedAgentRuns2, dispatchQueuedSubagentRuns2, assertNoAgentDefinitions, requestAgentRun2, isRetryableAgentRun2, retryAgentRun2, runModelLoop2, requestAction2, ObjectError2, removeLink2, upsertLink2, upsertLinkBatch2, deleteObject2, restoreObject2, upsertObject2, upsertObjectBatch2, writeTelemetryBatch2, appendTelemetryBatch2, getTelemetryHistoryBatch2, requireLinkDefinition2, resolveObjectContext2, resolveLinkContext2, createObjectSet2, exports_service, ShareError2, WorkflowDefinitionError2, WorkflowValidationError2, assertNonEmpty, isStepDefinition2, isAgentStepDefinition2, isInterventionDefinition2, isWorkflowDefinition2, validateWorkflowDefinition2, validateWorkflowsAtStartup2, validateWorkflowAgentStepGroupReferences2, validateWorkflowInput2, validateWorkflowStepInput2, validateWorkflowStepOutput2, validateWorkflowInterventionInput2, validateWorkflowInterventionResponse2, validateWorkflowInterventionDefaultResponse2, validateWorkflowAgentStepInput2, validateWorkflowAgentStepOutput2, snapshotWorkflowAgentStepInput2, snapshotWorkflowAgentStepOutput2, snapshotWorkflowInput2, snapshotWorkflowStepInput2, snapshotWorkflowStepOutput2, snapshotWorkflowInterventionInput2, snapshotWorkflowInterventionResponse2, snapshotWorkflowInterventionDefaultResponse2, snapshotWorkflowActionInput2, WorkflowRunDispatcher2, requestWorkflowRun2, createBoundSixb, isBoundSixb, bindDurablePrimitiveExecution2, ACTION_RUN_DRAIN_TIMEOUT_MS2, ActionRunExecutor, registerActionRunExecutor, drainActionRuns2, requestAction3 };
7978
+ export { defineAction2, param2, optional2, ActionRegistry2, bindModelExecutionAttempt, createAgentThreadId2, createAgentThreadSandboxName2, createAgentRunId2, createSubagentRunId2, createSubagentExecutionId2, createAgentMessageId2, agentContextCheckpointId2, createAgentRunExecutionToken2, canInheritAgentRequestAuthorization2, createAgentExecutionRecord2, createInheritedAgentExecutionRecord2, bindDurableAgentExecution2, bindAgentModelExecution2, restoreAgentExecutionScope2, assertAgentExecutionRecord2, DEFAULT_PROJECT_LOCALE, DEFAULT_PROJECT_TIME_ZONE, canonicalLocale, canonicalTimeZone, resolveAgentContextParts2, agentRunQueueJobId2, subagentRunQueueJobId2, workflowAgentNodeQueueJobId2, dispatchQueuedAgentRuns2, dispatchQueuedSubagentRuns2, assertNoAgentDefinitions, requestAgentRun2, isRetryableAgentRun2, retryAgentRun2, runModelLoop2, requestAction2, ObjectError2, removeLink2, upsertLink2, upsertLinkBatch2, deleteObject2, restoreObject2, upsertObject2, upsertObjectBatch2, writeTelemetryBatch2, appendTelemetryBatch2, getTelemetryHistoryBatch2, requireLinkDefinition2, resolveObjectContext2, resolveLinkContext2, createObjectSet2, exports_service, ShareError2, WorkflowDefinitionError2, WorkflowValidationError2, assertNonEmpty, isStepDefinition2, isAgentStepDefinition2, isInterventionDefinition2, isWorkflowDefinition2, validateWorkflowDefinition2, validateWorkflowsAtStartup2, validateWorkflowAgentStepGroupReferences2, validateWorkflowInput2, validateWorkflowStepInput2, validateWorkflowStepOutput2, validateWorkflowInterventionInput2, validateWorkflowInterventionResponse2, validateWorkflowInterventionDefaultResponse2, assertAgentStepSandbox, validateWorkflowAgentStepInput2, validateWorkflowAgentStepOutput2, snapshotWorkflowAgentStepInput2, snapshotWorkflowAgentStepOutput2, snapshotWorkflowInput2, snapshotWorkflowStepInput2, snapshotWorkflowStepOutput2, snapshotWorkflowInterventionInput2, snapshotWorkflowInterventionResponse2, snapshotWorkflowInterventionDefaultResponse2, snapshotWorkflowActionInput2, WorkflowRunDispatcher2, requestWorkflowRun2, createBoundSixb, isBoundSixb, bindDurablePrimitiveExecution2, ACTION_RUN_DRAIN_TIMEOUT_MS2, ActionRunExecutor, registerActionRunExecutor, drainActionRuns2, requestAction3 };
8806
7979
 
8807
- //# debugId=A7BB24994C0EBFAB64756E2164756E21
7980
+ //# debugId=BC1E3E649140D38B64756E2164756E21