@sixb/core 0.2.1 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/actions/index.js +60 -54
- package/dist/actions/index.js.map +1 -1
- package/dist/actions/request.d.ts.map +1 -1
- package/dist/actions/run/executor.d.ts +0 -2
- package/dist/actions/run/executor.d.ts.map +1 -1
- package/dist/actions/types/context.d.ts +5 -1
- package/dist/actions/types/context.d.ts.map +1 -1
- package/dist/agents/cancel.d.ts.map +1 -1
- package/dist/agents/execution.d.ts +2 -1
- package/dist/agents/execution.d.ts.map +1 -1
- package/dist/agents/fork.d.ts.map +1 -1
- package/dist/agents/index.d.ts +6 -4
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/agents/index.js +95 -82
- package/dist/agents/index.js.map +1 -1
- package/dist/agents/request.d.ts +7 -1
- package/dist/agents/request.d.ts.map +1 -1
- package/dist/agents/run-artifacts.d.ts +73 -10
- package/dist/agents/run-artifacts.d.ts.map +1 -1
- package/dist/agents/run-plan.d.ts +15 -1
- package/dist/agents/run-plan.d.ts.map +1 -1
- package/dist/agents/run-session-http.d.ts.map +1 -1
- package/dist/agents/run-session-serve.d.ts.map +1 -1
- package/dist/agents/run-session.d.ts +17 -2
- package/dist/agents/run-session.d.ts.map +1 -1
- package/dist/agents/skills.d.ts +3 -0
- package/dist/agents/skills.d.ts.map +1 -1
- package/dist/agents/step-limits.d.ts +6 -0
- package/dist/agents/step-limits.d.ts.map +1 -1
- package/dist/agents/streams/index.js +2 -2
- package/dist/agents/streams/internal.js +2 -2
- package/dist/agents/streams/protocol.d.ts +8 -2
- package/dist/agents/streams/protocol.d.ts.map +1 -1
- package/dist/agents/tool-files.d.ts +3 -1
- package/dist/agents/tool-files.d.ts.map +1 -1
- package/dist/agents/validation.d.ts +1 -1
- package/dist/agents/validation.d.ts.map +1 -1
- package/dist/agents/web.d.ts +47 -0
- package/dist/agents/web.d.ts.map +1 -0
- package/dist/artifacts/access.d.ts +37 -17
- package/dist/artifacts/access.d.ts.map +1 -1
- package/dist/artifacts/canvas-display.d.ts +65 -0
- package/dist/artifacts/canvas-display.d.ts.map +1 -0
- package/dist/artifacts/canvas.d.ts +6 -1
- package/dist/artifacts/canvas.d.ts.map +1 -1
- package/dist/artifacts/comment-text.d.ts +19 -0
- package/dist/artifacts/comment-text.d.ts.map +1 -0
- package/dist/artifacts/comments.d.ts +52 -0
- package/dist/artifacts/comments.d.ts.map +1 -0
- package/dist/artifacts/errors.d.ts +3 -3
- package/dist/artifacts/errors.d.ts.map +1 -1
- package/dist/artifacts/events.d.ts +14 -0
- package/dist/artifacts/events.d.ts.map +1 -0
- package/dist/artifacts/execution.d.ts +129 -22
- package/dist/artifacts/execution.d.ts.map +1 -1
- package/dist/artifacts/frames/assets.d.ts +12 -1
- package/dist/artifacts/frames/assets.d.ts.map +1 -1
- package/dist/artifacts/frames/grants.d.ts +8 -5
- package/dist/artifacts/frames/grants.d.ts.map +1 -1
- package/dist/artifacts/frames/index.d.ts +1 -1
- package/dist/artifacts/frames/index.d.ts.map +1 -1
- package/dist/artifacts/frames/index.js +32 -964
- package/dist/artifacts/frames/index.js.map +4 -8
- package/dist/artifacts/frames/kit.d.ts.map +1 -1
- package/dist/artifacts/frames/protocol.d.ts +78 -0
- package/dist/artifacts/frames/protocol.d.ts.map +1 -1
- package/dist/artifacts/frames/runtime.d.ts +17 -7
- package/dist/artifacts/frames/runtime.d.ts.map +1 -1
- package/dist/artifacts/holders.d.ts +23 -0
- package/dist/artifacts/holders.d.ts.map +1 -0
- package/dist/artifacts/ids.d.ts +2 -0
- package/dist/artifacts/ids.d.ts.map +1 -1
- package/dist/artifacts/index.d.ts +6 -4
- package/dist/artifacts/index.d.ts.map +1 -1
- package/dist/artifacts/index.js +108 -13
- package/dist/artifacts/index.js.map +5 -4
- package/dist/artifacts/limits.d.ts +24 -3
- package/dist/artifacts/limits.d.ts.map +1 -1
- package/dist/artifacts/live/board.d.ts +103 -0
- package/dist/artifacts/live/board.d.ts.map +1 -0
- package/dist/artifacts/live/diff.d.ts +43 -0
- package/dist/artifacts/live/diff.d.ts.map +1 -0
- package/dist/artifacts/live/document.d.ts +55 -0
- package/dist/artifacts/live/document.d.ts.map +1 -0
- package/dist/artifacts/live/files.d.ts +16 -0
- package/dist/artifacts/live/files.d.ts.map +1 -0
- package/dist/artifacts/live/index.d.ts +9 -0
- package/dist/artifacts/live/index.d.ts.map +1 -0
- package/dist/artifacts/live/index.js +593 -0
- package/dist/artifacts/live/index.js.map +10 -0
- package/dist/artifacts/live/presence.d.ts +55 -0
- package/dist/artifacts/live/presence.d.ts.map +1 -0
- package/dist/artifacts/live/protocol.d.ts +109 -0
- package/dist/artifacts/live/protocol.d.ts.map +1 -0
- package/dist/artifacts/live/protocol.js +21 -0
- package/dist/artifacts/live/protocol.js.map +9 -0
- package/dist/artifacts/live/server.d.ts +10 -0
- package/dist/artifacts/live/server.d.ts.map +1 -0
- package/dist/artifacts/live/server.js +86 -0
- package/dist/artifacts/live/server.js.map +9 -0
- package/dist/artifacts/live/state.d.ts +26 -0
- package/dist/artifacts/live/state.d.ts.map +1 -0
- package/dist/artifacts/outline.d.ts +11 -0
- package/dist/artifacts/outline.d.ts.map +1 -1
- package/dist/artifacts/publish/index.d.ts +8 -1
- package/dist/artifacts/publish/index.d.ts.map +1 -1
- package/dist/artifacts/publish/index.js +67 -39
- package/dist/artifacts/publish/index.js.map +1 -1
- package/dist/artifacts/publish/merge.d.ts +75 -0
- package/dist/artifacts/publish/merge.d.ts.map +1 -0
- package/dist/artifacts/publish/previews.d.ts +153 -0
- package/dist/artifacts/publish/previews.d.ts.map +1 -0
- package/dist/artifacts/publish/publish.d.ts +29 -8
- package/dist/artifacts/publish/publish.d.ts.map +1 -1
- package/dist/artifacts/publish/query-answers.d.ts +20 -0
- package/dist/artifacts/publish/query-answers.d.ts.map +1 -0
- package/dist/artifacts/publish/references.d.ts +4 -3
- package/dist/artifacts/publish/references.d.ts.map +1 -1
- package/dist/artifacts/publish/validate/canvas.d.ts.map +1 -1
- package/dist/artifacts/theme.d.ts +5 -1
- package/dist/artifacts/theme.d.ts.map +1 -1
- package/dist/auth/directory.d.ts +33 -0
- package/dist/auth/directory.d.ts.map +1 -0
- package/dist/auth/index.js +13 -12
- package/dist/auth/index.js.map +1 -1
- package/dist/auth/member-events.d.ts +5 -1
- package/dist/auth/member-events.d.ts.map +1 -1
- package/dist/auth/runtime.d.ts +22 -1
- package/dist/auth/runtime.d.ts.map +1 -1
- package/dist/auth/strategy.d.ts +2 -2
- package/dist/auth/strategy.d.ts.map +1 -1
- package/dist/auth/types.d.ts +42 -1
- package/dist/auth/types.d.ts.map +1 -1
- package/dist/authorization/decision.d.ts +6 -5
- package/dist/authorization/decision.d.ts.map +1 -1
- package/dist/authorization/event-visibility.d.ts.map +1 -1
- package/dist/authorization/index.js +7 -6
- package/dist/authorization/index.js.map +1 -1
- package/dist/authorization/resolve.d.ts +4 -3
- package/dist/authorization/resolve.d.ts.map +1 -1
- package/dist/authorization/types.d.ts +5 -5
- package/dist/authorization/types.d.ts.map +1 -1
- package/dist/blob-storage/index.js +4 -4
- package/dist/blob-storage/index.js.map +1 -1
- package/dist/bootstrap/index.js +70 -64
- package/dist/bootstrap/index.js.map +2 -2
- package/dist/broker/in-memory.d.ts.map +1 -1
- package/dist/broker/index.js +1 -1
- package/dist/broker/types.d.ts +4 -0
- package/dist/broker/types.d.ts.map +1 -1
- package/dist/{chunk-3x3bebz7.js → chunk-0k3r5kb3.js} +414 -101
- package/dist/chunk-0k3r5kb3.js.map +51 -0
- package/dist/{chunk-e5wf5vz0.js → chunk-0kgrghqx.js} +13 -1
- package/dist/chunk-0kgrghqx.js.map +10 -0
- package/dist/{chunk-2pk5hjj9.js → chunk-186k5yz3.js} +1 -1
- package/dist/chunk-191jz8a6.js +61 -0
- package/dist/chunk-191jz8a6.js.map +10 -0
- package/dist/{chunk-mmagke4x.js → chunk-22d3qg4x.js} +2 -2
- package/dist/{chunk-mmagke4x.js.map → chunk-22d3qg4x.js.map} +3 -3
- package/dist/{chunk-8yzhjawq.js → chunk-26qet7wh.js} +64 -23
- package/dist/{chunk-8yzhjawq.js.map → chunk-26qet7wh.js.map} +5 -5
- package/dist/{chunk-cb21tx14.js → chunk-2by73sm2.js} +1055 -201
- package/dist/chunk-2by73sm2.js.map +75 -0
- package/dist/chunk-2c4j899j.js.map +2 -2
- package/dist/{chunk-e6xgz4h4.js → chunk-3014rfjz.js} +197 -18
- package/dist/chunk-3014rfjz.js.map +21 -0
- package/dist/{chunk-nghc7eq0.js → chunk-3723kgba.js} +1 -1
- package/dist/chunk-38yvdqzd.js +70 -0
- package/dist/chunk-38yvdqzd.js.map +10 -0
- package/dist/{chunk-ytzcxtpt.js → chunk-3ba89vm7.js} +1 -1
- package/dist/chunk-3hzhcfsv.js +139 -0
- package/dist/chunk-3hzhcfsv.js.map +10 -0
- package/dist/chunk-3sgvd10b.js +69 -0
- package/dist/chunk-3sgvd10b.js.map +10 -0
- package/dist/{chunk-djs3hw9p.js → chunk-3zagkr6w.js} +73 -6
- package/dist/chunk-3zagkr6w.js.map +21 -0
- package/dist/{chunk-fg1db9xx.js → chunk-48c1z8nj.js} +10 -10
- package/dist/chunk-48c1z8nj.js.map +10 -0
- package/dist/{chunk-rjeeyssy.js → chunk-4j0sagwv.js} +134 -19
- package/dist/{chunk-rjeeyssy.js.map → chunk-4j0sagwv.js.map} +11 -10
- package/dist/{chunk-qsg8rw04.js → chunk-5qqmndhm.js} +2 -2
- package/dist/{chunk-scyq22td.js → chunk-5rqqp8cr.js} +19 -4
- package/dist/chunk-5rqqp8cr.js.map +12 -0
- package/dist/{chunk-ax10ft8d.js → chunk-6gtxshcc.js} +6 -6
- package/dist/{chunk-ax10ft8d.js.map → chunk-6gtxshcc.js.map} +1 -1
- package/dist/{chunk-jspskey0.js → chunk-7j4yydm2.js} +67 -45
- package/dist/chunk-7j4yydm2.js.map +11 -0
- package/dist/{chunk-8wsjr52f.js → chunk-7qe46788.js} +1 -1
- package/dist/{chunk-edx8xcsm.js → chunk-7z5rkf0m.js} +29 -6
- package/dist/chunk-7z5rkf0m.js.map +13 -0
- package/dist/{chunk-23s66j86.js → chunk-855w9nvw.js} +1 -1
- package/dist/{chunk-e7v3trpz.js → chunk-8a8k38tz.js} +4 -3
- package/dist/chunk-8a8k38tz.js.map +10 -0
- package/dist/{chunk-tvbmh7tj.js → chunk-8p7bze4c.js} +14 -10
- package/dist/chunk-8p7bze4c.js.map +18 -0
- package/dist/{chunk-jftd33rc.js → chunk-8t2ynwg0.js} +105 -9
- package/dist/chunk-8t2ynwg0.js.map +11 -0
- package/dist/{chunk-qbrmpgvv.js → chunk-8tqnsx3q.js} +1 -1
- package/dist/{chunk-s3we74h8.js → chunk-9nsjjd44.js} +38 -5
- package/dist/chunk-9nsjjd44.js.map +12 -0
- package/dist/{chunk-hz5d43gn.js → chunk-9vsc919v.js} +14 -6
- package/dist/chunk-9vsc919v.js.map +10 -0
- package/dist/{chunk-waqk73p1.js → chunk-a6fjkcne.js} +185 -341
- package/dist/{chunk-waqk73p1.js.map → chunk-a6fjkcne.js.map} +6 -7
- package/dist/{chunk-tvefbgvw.js → chunk-az95tsh3.js} +4 -2
- package/dist/chunk-az95tsh3.js.map +11 -0
- package/dist/{chunk-s038wa5v.js → chunk-b9qfh2ya.js} +1 -1
- package/dist/{chunk-5taem5aw.js → chunk-bc3y6gff.js} +13 -4
- package/dist/chunk-bc3y6gff.js.map +10 -0
- package/dist/{chunk-ks87m383.js → chunk-bkmnd7zq.js} +556 -262
- package/dist/chunk-bkmnd7zq.js.map +49 -0
- package/dist/chunk-bz5bnjjt.js +358 -0
- package/dist/chunk-bz5bnjjt.js.map +12 -0
- package/dist/{chunk-7hd2ez3q.js → chunk-c4nrycdy.js} +1 -1
- package/dist/{chunk-w976a4me.js → chunk-czct88ht.js} +28 -4
- package/dist/chunk-czct88ht.js.map +10 -0
- package/dist/{chunk-5kyvrtjh.js → chunk-d9xbwh3h.js} +131 -32
- package/dist/chunk-d9xbwh3h.js.map +13 -0
- package/dist/{chunk-kfee1h52.js → chunk-dfveegqq.js} +28 -8
- package/dist/chunk-dfveegqq.js.map +13 -0
- package/dist/{chunk-2g0r46hy.js → chunk-dhkc9b23.js} +15 -2
- package/dist/chunk-dhkc9b23.js.map +12 -0
- package/dist/chunk-dmnd9ea6.js +106 -0
- package/dist/chunk-dmnd9ea6.js.map +10 -0
- package/dist/{chunk-nz7815t3.js → chunk-e0hnbb1m.js} +27 -2
- package/dist/chunk-e0hnbb1m.js.map +14 -0
- package/dist/chunk-e91fmg6t.js +288 -0
- package/dist/chunk-e91fmg6t.js.map +11 -0
- package/dist/{chunk-z3evap21.js → chunk-e9w4mgdh.js} +314 -225
- package/dist/{chunk-z3evap21.js.map → chunk-e9w4mgdh.js.map} +22 -20
- package/dist/{chunk-w122ymx4.js → chunk-f6ahf5gf.js} +15 -4
- package/dist/{chunk-w122ymx4.js.map → chunk-f6ahf5gf.js.map} +3 -3
- package/dist/{chunk-jjmggm9a.js → chunk-fe6r7yhg.js} +1 -1
- package/dist/{chunk-165c9wm6.js → chunk-g2ph4873.js} +1 -1
- package/dist/chunk-hgj98cbb.js +22 -0
- package/dist/chunk-hgj98cbb.js.map +10 -0
- package/dist/{chunk-nqnfz3jg.js → chunk-hkaa807g.js} +18 -7
- package/dist/{chunk-nqnfz3jg.js.map → chunk-hkaa807g.js.map} +3 -3
- package/dist/chunk-hn2r7z41.js.map +3 -3
- package/dist/chunk-j0wgh8gv.js +250 -0
- package/dist/chunk-j0wgh8gv.js.map +10 -0
- package/dist/{chunk-z8fx5cgb.js → chunk-j2zm215x.js} +37 -3
- package/dist/chunk-j2zm215x.js.map +12 -0
- package/dist/{chunk-j1ny5fwh.js → chunk-k1g14kk3.js} +11 -83
- package/dist/{chunk-j1ny5fwh.js.map → chunk-k1g14kk3.js.map} +4 -5
- package/dist/{chunk-b7a97n8b.js → chunk-k66rp2hr.js} +7 -7
- package/dist/{chunk-b7a97n8b.js.map → chunk-k66rp2hr.js.map} +2 -2
- package/dist/chunk-kr6dx38r.js +25 -0
- package/dist/chunk-kr6dx38r.js.map +10 -0
- package/dist/{chunk-w53trr0c.js → chunk-kv0kvknv.js} +14 -14
- package/dist/{chunk-w53trr0c.js.map → chunk-kv0kvknv.js.map} +1 -1
- package/dist/chunk-m2jerfef.js +474 -0
- package/dist/chunk-m2jerfef.js.map +11 -0
- package/dist/chunk-m7b9q5dk.js +234 -0
- package/dist/chunk-m7b9q5dk.js.map +12 -0
- package/dist/{chunk-escedwyt.js → chunk-mvz89age.js} +6 -1
- package/dist/{chunk-escedwyt.js.map → chunk-mvz89age.js.map} +3 -3
- package/dist/chunk-mwcqz3e3.js +30 -0
- package/dist/chunk-mwcqz3e3.js.map +10 -0
- package/dist/chunk-n2ay51px.js +21 -0
- package/dist/chunk-n2ay51px.js.map +10 -0
- package/dist/{chunk-jk97v21j.js → chunk-n4zzaf6q.js} +3 -2
- package/dist/chunk-n4zzaf6q.js.map +10 -0
- package/dist/{chunk-cgznz22f.js → chunk-n68vz95m.js} +5 -5
- package/dist/{chunk-cgznz22f.js.map → chunk-n68vz95m.js.map} +3 -3
- package/dist/{chunk-neftrg0n.js → chunk-p351afzm.js} +14 -14
- package/dist/{chunk-neftrg0n.js.map → chunk-p351afzm.js.map} +4 -4
- package/dist/chunk-pk539cwv.js +370 -0
- package/dist/chunk-pk539cwv.js.map +11 -0
- package/dist/{chunk-jbw70d6t.js → chunk-ppxf7gw2.js} +52 -10
- package/dist/chunk-ppxf7gw2.js.map +11 -0
- package/dist/{chunk-9x8dybsb.js → chunk-pvpq483h.js} +10 -2
- package/dist/chunk-pvpq483h.js.map +10 -0
- package/dist/{chunk-jhbk10wf.js → chunk-q9nkpr8k.js} +1 -1
- package/dist/chunk-qafng88v.js +225 -0
- package/dist/chunk-qafng88v.js.map +11 -0
- package/dist/chunk-qds484t8.js +1363 -0
- package/dist/chunk-qds484t8.js.map +18 -0
- package/dist/{chunk-47e09r7z.js → chunk-qttqe1ah.js} +86 -6
- package/dist/{chunk-47e09r7z.js.map → chunk-qttqe1ah.js.map} +5 -4
- package/dist/{chunk-4zm1k3xj.js → chunk-r2psmn42.js} +1 -1
- package/dist/{chunk-31khg3g0.js → chunk-rt9deb92.js} +76 -4
- package/dist/{chunk-31khg3g0.js.map → chunk-rt9deb92.js.map} +3 -3
- package/dist/{chunk-r1cxq7vv.js → chunk-rtdrm592.js} +2 -2
- package/dist/{chunk-t5daew4g.js → chunk-s5n9617r.js} +18 -18
- package/dist/{chunk-t5daew4g.js.map → chunk-s5n9617r.js.map} +1 -1
- package/dist/{chunk-m3qe54bb.js → chunk-smnt672s.js} +1 -1
- package/dist/{chunk-21q0j5f2.js → chunk-stmxh0hv.js} +2 -2
- package/dist/{chunk-y2x2935j.js → chunk-sysnvjce.js} +5 -5
- package/dist/{chunk-y2x2935j.js.map → chunk-sysnvjce.js.map} +3 -3
- package/dist/{chunk-57g0215c.js → chunk-t24yktqr.js} +296 -7
- package/dist/{chunk-57g0215c.js.map → chunk-t24yktqr.js.map} +6 -3
- package/dist/{chunk-ff5xkv0p.js → chunk-tfzvjdms.js} +1 -1
- package/dist/chunk-tqa68kj7.js +1322 -0
- package/dist/chunk-tqa68kj7.js.map +25 -0
- package/dist/chunk-vtjzwymr.js +37 -0
- package/dist/chunk-vtjzwymr.js.map +10 -0
- package/dist/{chunk-dz7a4t3a.js → chunk-vzkxqf8h.js} +26 -21
- package/dist/{chunk-dz7a4t3a.js.map → chunk-vzkxqf8h.js.map} +8 -8
- package/dist/{chunk-6b61s40c.js → chunk-w3t94hm6.js} +1 -1
- package/dist/{chunk-t9xyr7y9.js → chunk-w9s23r24.js} +1218 -101
- package/dist/chunk-w9s23r24.js.map +30 -0
- package/dist/{chunk-9rh8ncs5.js → chunk-wa05txmk.js} +20 -7
- package/dist/{chunk-9rh8ncs5.js.map → chunk-wa05txmk.js.map} +3 -3
- package/dist/chunk-whbwf3np.js +12 -0
- package/dist/chunk-whbwf3np.js.map +10 -0
- package/dist/{chunk-agn8d8ys.js → chunk-xtztwpkh.js} +1 -1
- package/dist/{chunk-t5608tkq.js → chunk-yv8hv4wq.js} +3 -1
- package/dist/{chunk-t5608tkq.js.map → chunk-yv8hv4wq.js.map} +3 -3
- package/dist/{chunk-ratj7t3t.js → chunk-z0t4p2sk.js} +465 -76
- package/dist/chunk-z0t4p2sk.js.map +47 -0
- package/dist/{chunk-0g5nyx0k.js → chunk-zeykm8my.js} +2 -2
- package/dist/connectors/builders.d.ts +2 -2
- package/dist/connectors/builders.d.ts.map +1 -1
- package/dist/connectors/connections/access.d.ts +11 -0
- package/dist/connectors/connections/access.d.ts.map +1 -0
- package/dist/connectors/connections/contracts.d.ts +6 -1
- package/dist/connectors/connections/contracts.d.ts.map +1 -1
- package/dist/connectors/connections/internal.js +1 -1
- package/dist/connectors/connections/runs.d.ts +13 -0
- package/dist/connectors/connections/runs.d.ts.map +1 -1
- package/dist/connectors/connections/service.d.ts +25 -0
- package/dist/connectors/connections/service.d.ts.map +1 -1
- package/dist/connectors/connections/views.d.ts +1 -1
- package/dist/connectors/connections/views.d.ts.map +1 -1
- package/dist/connectors/execution.d.ts.map +1 -1
- package/dist/connectors/index.d.ts +1 -1
- package/dist/connectors/index.d.ts.map +1 -1
- package/dist/connectors/service.d.ts +3 -0
- package/dist/connectors/service.d.ts.map +1 -1
- package/dist/connectors/types.d.ts +21 -2
- package/dist/connectors/types.d.ts.map +1 -1
- package/dist/datasets/execution.d.ts +12 -6
- package/dist/datasets/execution.d.ts.map +1 -1
- package/dist/datasets/ingest-flush-batch.d.ts +59 -0
- package/dist/datasets/ingest-flush-batch.d.ts.map +1 -0
- package/dist/datasets/ingest-flush-job.d.ts +33 -0
- package/dist/datasets/ingest-flush-job.d.ts.map +1 -0
- package/dist/datasets/ingest-flush.d.ts +66 -0
- package/dist/datasets/ingest-flush.d.ts.map +1 -0
- package/dist/datasets/produced-version.d.ts +21 -0
- package/dist/datasets/produced-version.d.ts.map +1 -0
- package/dist/datasets/write.d.ts +22 -1
- package/dist/datasets/write.d.ts.map +1 -1
- package/dist/datasets/write.js +8 -4
- package/dist/datasets/write.js.map +1 -1
- package/dist/deploy/internal.js +5 -4
- package/dist/deploy/internal.js.map +4 -4
- package/dist/deploy/types.d.ts +2 -3
- package/dist/deploy/types.d.ts.map +1 -1
- package/dist/error-reporting/capability.d.ts +8 -2
- package/dist/error-reporting/capability.d.ts.map +1 -1
- package/dist/error-reporting/internal.d.ts +1 -1
- package/dist/error-reporting/internal.d.ts.map +1 -1
- package/dist/error-reporting/internal.js +17 -5
- package/dist/error-reporting/internal.js.map +1 -1
- package/dist/error-reporting/reporter.d.ts.map +1 -1
- package/dist/error-reporting/reports.d.ts +55 -0
- package/dist/error-reporting/reports.d.ts.map +1 -1
- package/dist/error-reporting/types.d.ts +82 -1
- package/dist/error-reporting/types.d.ts.map +1 -1
- package/dist/errors/catalog.d.ts +5 -0
- package/dist/errors/catalog.d.ts.map +1 -1
- package/dist/errors/internal.js +1 -1
- package/dist/events/definitions.d.ts +4 -0
- package/dist/events/definitions.d.ts.map +1 -1
- package/dist/events/execution.d.ts +1 -0
- package/dist/events/execution.d.ts.map +1 -1
- package/dist/events/index.d.ts +1 -1
- package/dist/events/index.d.ts.map +1 -1
- package/dist/events/index.js +5 -5
- package/dist/events/scope.d.ts.map +1 -1
- package/dist/events/scope.js +1 -1
- package/dist/events/selectors/index.js +2 -2
- package/dist/events/types/artifacts.d.ts +38 -0
- package/dist/events/types/artifacts.d.ts.map +1 -0
- package/dist/events/types/index.d.ts +3 -1
- package/dist/events/types/index.d.ts.map +1 -1
- package/dist/events/types/users.d.ts +5 -2
- package/dist/events/types/users.d.ts.map +1 -1
- package/dist/execution/agent.js +61 -55
- package/dist/execution/agent.js.map +1 -1
- package/dist/execution/authorized-object-reader.d.ts +10 -0
- package/dist/execution/authorized-object-reader.d.ts.map +1 -1
- package/dist/execution/object-reader-clearance.d.ts +6 -0
- package/dist/execution/object-reader-clearance.d.ts.map +1 -1
- package/dist/execution/object-reader-security.d.ts +9 -2
- package/dist/execution/object-reader-security.d.ts.map +1 -1
- package/dist/execution/primitive.js +60 -54
- package/dist/execution/primitive.js.map +1 -1
- package/dist/execution/request.js +57 -51
- package/dist/execution/request.js.map +2 -2
- package/dist/http/api-routes.d.ts +1 -1
- package/dist/http/api-routes.d.ts.map +1 -1
- package/dist/http/index.js +1 -1
- package/dist/index.d.ts +12 -10
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +101 -93
- package/dist/index.js.map +1 -1
- package/dist/lake-storage/errors.d.ts +15 -0
- package/dist/lake-storage/errors.d.ts.map +1 -1
- package/dist/lake-storage/index.d.ts +3 -2
- package/dist/lake-storage/index.d.ts.map +1 -1
- package/dist/lake-storage/index.js +16 -10
- package/dist/lake-storage/index.js.map +1 -1
- package/dist/lake-storage/maintenance.d.ts +88 -0
- package/dist/lake-storage/maintenance.d.ts.map +1 -0
- package/dist/lake-storage/merge.d.ts +3 -1
- package/dist/lake-storage/merge.d.ts.map +1 -1
- package/dist/lake-storage/source-ordering.d.ts +23 -0
- package/dist/lake-storage/source-ordering.d.ts.map +1 -1
- package/dist/lake-storage/types.d.ts +10 -0
- package/dist/lake-storage/types.d.ts.map +1 -1
- package/dist/maintenance/heartbeat.d.ts +5 -0
- package/dist/maintenance/heartbeat.d.ts.map +1 -0
- package/dist/maintenance/index.d.ts +4 -2
- package/dist/maintenance/index.d.ts.map +1 -1
- package/dist/maintenance/index.js +515 -0
- package/dist/maintenance/index.js.map +16 -0
- package/dist/maintenance/lake-retention-status.d.ts +36 -0
- package/dist/maintenance/lake-retention-status.d.ts.map +1 -0
- package/dist/maintenance/lake-retention.d.ts +84 -0
- package/dist/maintenance/lake-retention.d.ts.map +1 -0
- package/dist/maintenance/loop.d.ts +95 -0
- package/dist/maintenance/loop.d.ts.map +1 -0
- package/dist/maintenance/ontology-maintenance.d.ts +17 -16
- package/dist/maintenance/ontology-maintenance.d.ts.map +1 -1
- package/dist/maintenance/passes/cron-pass.d.ts +21 -0
- package/dist/maintenance/passes/cron-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/directory-pass.d.ts +12 -0
- package/dist/maintenance/passes/directory-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/ingest-pass.d.ts +26 -0
- package/dist/maintenance/passes/ingest-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/lake-change-feed.d.ts +38 -0
- package/dist/maintenance/passes/lake-change-feed.d.ts.map +1 -0
- package/dist/maintenance/passes/lake-retention-pass.d.ts +20 -0
- package/dist/maintenance/passes/lake-retention-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/ontology-pass.d.ts +8 -0
- package/dist/maintenance/passes/ontology-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/projections-pass.d.ts +26 -0
- package/dist/maintenance/passes/projections-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/recovery-pass.d.ts +6 -0
- package/dist/maintenance/passes/recovery-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/recovery-passes.d.ts +24 -0
- package/dist/maintenance/passes/recovery-passes.d.ts.map +1 -0
- package/dist/maintenance/passes/runs-pass.d.ts +6 -0
- package/dist/maintenance/passes/runs-pass.d.ts.map +1 -0
- package/dist/maintenance/passes/triggers-pass.d.ts +41 -0
- package/dist/maintenance/passes/triggers-pass.d.ts.map +1 -0
- package/dist/maintenance/status.d.ts +19 -0
- package/dist/maintenance/status.d.ts.map +1 -0
- package/dist/maintenance/types.d.ts +25 -24
- package/dist/maintenance/types.d.ts.map +1 -1
- package/dist/materialization/model.d.ts +11 -2
- package/dist/materialization/model.d.ts.map +1 -1
- package/dist/materializer/edits/artifact-refs.d.ts +33 -0
- package/dist/materializer/edits/artifact-refs.d.ts.map +1 -0
- package/dist/materializer/edits/commit.d.ts.map +1 -1
- package/dist/materializer/edits/operations.d.ts +7 -1
- package/dist/materializer/edits/operations.d.ts.map +1 -1
- package/dist/materializer/edits/plan.d.ts.map +1 -1
- package/dist/materializer/execution/work-records.d.ts +6 -0
- package/dist/materializer/execution/work-records.d.ts.map +1 -1
- package/dist/materializer/index.js +33 -30
- package/dist/materializer/index.js.map +1 -1
- package/dist/materializer/projections/replacement-plan.d.ts.map +1 -1
- package/dist/materializer/shared/normalize.d.ts.map +1 -1
- package/dist/materializer/telemetry/plan.d.ts.map +1 -1
- package/dist/models/catalog.d.ts +16 -0
- package/dist/models/catalog.d.ts.map +1 -1
- package/dist/models/definitions.d.ts +1 -1
- package/dist/models/definitions.d.ts.map +1 -1
- package/dist/models/execution/index.js +36 -33
- package/dist/models/execution/index.js.map +1 -1
- package/dist/models/execution/model-call-recorder.d.ts +1 -1
- package/dist/models/execution/model-call-recorder.d.ts.map +1 -1
- package/dist/models/execution/web-search.d.ts +7 -0
- package/dist/models/execution/web-search.d.ts.map +1 -0
- package/dist/models/index.d.ts +3 -1
- package/dist/models/index.d.ts.map +1 -1
- package/dist/models/index.js +5 -3
- package/dist/models/index.js.map +1 -1
- package/dist/models/language-model.d.ts +12 -0
- package/dist/models/language-model.d.ts.map +1 -1
- package/dist/models/web-search-model.d.ts +66 -0
- package/dist/models/web-search-model.d.ts.map +1 -0
- package/dist/objects/artifact-refs.d.ts +5 -0
- package/dist/objects/artifact-refs.d.ts.map +1 -0
- package/dist/objects/index.js +63 -58
- package/dist/objects/index.js.map +1 -1
- package/dist/objects/materializer-adapter.d.ts +4 -3
- package/dist/objects/materializer-adapter.d.ts.map +1 -1
- package/dist/objects/object/upsert-batch.d.ts.map +1 -1
- package/dist/objects/object/upsert.d.ts.map +1 -1
- package/dist/objects/query/executor.d.ts.map +1 -1
- package/dist/objects/query/index.d.ts +1 -0
- package/dist/objects/query/index.d.ts.map +1 -1
- package/dist/objects/query/index.js +35 -29
- package/dist/objects/query/index.js.map +1 -1
- package/dist/objects/query/ir.d.ts +3 -1
- package/dist/objects/query/ir.d.ts.map +1 -1
- package/dist/objects/query/scalar-values.d.ts.map +1 -1
- package/dist/objects/query/sort-ties.d.ts +11 -0
- package/dist/objects/query/sort-ties.d.ts.map +1 -0
- package/dist/objects/runtime-batch.d.ts +2 -0
- package/dist/objects/runtime-batch.d.ts.map +1 -1
- package/dist/ontology/artifact-ref.d.ts +36 -0
- package/dist/ontology/artifact-ref.d.ts.map +1 -0
- package/dist/ontology/docs-markdown.d.ts.map +1 -1
- package/dist/ontology/index.d.ts +3 -1
- package/dist/ontology/index.d.ts.map +1 -1
- package/dist/ontology/index.js +8 -5
- package/dist/ontology/index.js.map +1 -1
- package/dist/ontology/inference/index.d.ts +2 -0
- package/dist/ontology/inference/index.d.ts.map +1 -1
- package/dist/ontology/internal.js +7 -6
- package/dist/ontology/internal.js.map +1 -1
- package/dist/ontology/json-schema.d.ts.map +1 -1
- package/dist/ontology/primitives.d.ts.map +1 -1
- package/dist/ontology/reference-values.d.ts +10 -0
- package/dist/ontology/reference-values.d.ts.map +1 -0
- package/dist/ontology/refs.d.ts +6 -1
- package/dist/ontology/refs.d.ts.map +1 -1
- package/dist/ontology/registry.d.ts +9 -1
- package/dist/ontology/registry.d.ts.map +1 -1
- package/dist/ontology/types.d.ts +2 -1
- package/dist/ontology/types.d.ts.map +1 -1
- package/dist/ontology/user-ref.d.ts +16 -0
- package/dist/ontology/user-ref.d.ts.map +1 -1
- package/dist/ontology/validation/normalize.d.ts.map +1 -1
- package/dist/ontology/validation/properties.d.ts.map +1 -1
- package/dist/ontology/validation/schema.d.ts.map +1 -1
- package/dist/pending-tasks.d.ts +17 -0
- package/dist/pending-tasks.d.ts.map +1 -0
- package/dist/pipelines/index.js +40 -37
- package/dist/pipelines/index.js.map +1 -1
- package/dist/pipelines/run-dispatch.d.ts +6 -0
- package/dist/pipelines/run-dispatch.d.ts.map +1 -1
- package/dist/predicates/types.d.ts +4 -0
- package/dist/predicates/types.d.ts.map +1 -1
- package/dist/projections/builders.d.ts +13 -11
- package/dist/projections/builders.d.ts.map +1 -1
- package/dist/projections/internal.js +33 -30
- package/dist/projections/internal.js.map +1 -1
- package/dist/projections/types.d.ts +1 -1
- package/dist/projections/types.d.ts.map +1 -1
- package/dist/projections/validation.d.ts +2 -2
- package/dist/projections/validation.d.ts.map +1 -1
- package/dist/queues/in-memory.d.ts +6 -1
- package/dist/queues/in-memory.d.ts.map +1 -1
- package/dist/queues/index.d.ts +1 -1
- package/dist/queues/index.d.ts.map +1 -1
- package/dist/queues/index.js +1 -1
- package/dist/queues/types.d.ts +55 -2
- package/dist/queues/types.d.ts.map +1 -1
- package/dist/runtime/create.d.ts +4 -1
- package/dist/runtime/create.d.ts.map +1 -1
- package/dist/runtime/host.d.ts +22 -5
- package/dist/runtime/host.d.ts.map +1 -1
- package/dist/runtime/index.d.ts +0 -1
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/internal.d.ts +6 -0
- package/dist/runtime/internal.d.ts.map +1 -1
- package/dist/runtime/internal.js +57 -36
- package/dist/runtime/internal.js.map +1 -1
- package/dist/runtime/resolve-definitions.d.ts.map +1 -1
- package/dist/runtime/sixb.d.ts +6 -1
- package/dist/runtime/sixb.d.ts.map +1 -1
- package/dist/sandboxes/index.js +8 -7
- package/dist/sandboxes/index.js.map +1 -1
- package/dist/scheduler/index.d.ts +0 -2
- package/dist/scheduler/index.d.ts.map +1 -1
- package/dist/scheduler/index.js +3 -6
- package/dist/scheduler/index.js.map +1 -1
- package/dist/schedules/index.js +9 -11
- package/dist/schedules/index.js.map +1 -1
- package/dist/security/index.d.ts +1 -0
- package/dist/security/index.d.ts.map +1 -1
- package/dist/security/internal.js +1 -1
- package/dist/security/registry.d.ts +2 -0
- package/dist/security/registry.d.ts.map +1 -1
- package/dist/security/view-conditions.d.ts.map +1 -1
- package/dist/security/visibility-keys.d.ts +19 -0
- package/dist/security/visibility-keys.d.ts.map +1 -0
- package/dist/shared/backoff.d.ts +12 -0
- package/dist/shared/backoff.d.ts.map +1 -0
- package/dist/shared/duration.d.ts +3 -0
- package/dist/shared/duration.d.ts.map +1 -0
- package/dist/shared/params/artifact-refs.d.ts +19 -0
- package/dist/shared/params/artifact-refs.d.ts.map +1 -0
- package/dist/shares/guest-name.d.ts +8 -0
- package/dist/shares/guest-name.d.ts.map +1 -0
- package/dist/shares/internal.d.ts +1 -0
- package/dist/shares/internal.d.ts.map +1 -1
- package/dist/shares/internal.js +74 -33
- package/dist/shares/internal.js.map +3 -3
- package/dist/shares/session-protocol.d.ts +13 -0
- package/dist/shares/session-protocol.d.ts.map +1 -1
- package/dist/storage/action-runs/failure.js +2 -2
- package/dist/storage/agents/in-memory.d.ts +8 -2
- package/dist/storage/agents/in-memory.d.ts.map +1 -1
- package/dist/storage/agents/index.d.ts +1 -1
- package/dist/storage/agents/index.d.ts.map +1 -1
- package/dist/storage/agents/provider.d.ts +8 -2
- package/dist/storage/agents/provider.d.ts.map +1 -1
- package/dist/storage/agents/provider.js +12 -6
- package/dist/storage/agents/provider.js.map +1 -1
- package/dist/storage/agents/types.d.ts +42 -2
- package/dist/storage/agents/types.d.ts.map +1 -1
- package/dist/storage/ai-cost/provider.js +4 -4
- package/dist/storage/ai-limits/enforcement.js +4 -4
- package/dist/storage/ai-limits/provider.js +2 -2
- package/dist/storage/artifacts/errors.d.ts +9 -4
- package/dist/storage/artifacts/errors.d.ts.map +1 -1
- package/dist/storage/artifacts/in-memory.d.ts +27 -4
- package/dist/storage/artifacts/in-memory.d.ts.map +1 -1
- package/dist/storage/artifacts/index.d.ts +1 -1
- package/dist/storage/artifacts/index.d.ts.map +1 -1
- package/dist/storage/artifacts/record.d.ts +39 -2
- package/dist/storage/artifacts/record.d.ts.map +1 -1
- package/dist/storage/artifacts/types.d.ts +328 -39
- package/dist/storage/artifacts/types.d.ts.map +1 -1
- package/dist/storage/auth/in-memory/auth-storage.d.ts +2 -1
- package/dist/storage/auth/in-memory/auth-storage.d.ts.map +1 -1
- package/dist/storage/auth/in-memory/identities.d.ts +4 -0
- package/dist/storage/auth/in-memory/identities.d.ts.map +1 -1
- package/dist/storage/auth/in-memory/shared.d.ts +3 -1
- package/dist/storage/auth/in-memory/shared.d.ts.map +1 -1
- package/dist/storage/auth/in-memory/users.d.ts.map +1 -1
- package/dist/storage/auth/index.d.ts +1 -1
- package/dist/storage/auth/index.d.ts.map +1 -1
- package/dist/storage/auth/types.d.ts +39 -0
- package/dist/storage/auth/types.d.ts.map +1 -1
- package/dist/storage/connector-connections/in-memory.d.ts +1 -1
- package/dist/storage/connector-connections/in-memory.d.ts.map +1 -1
- package/dist/storage/connector-connections/index.d.ts +1 -1
- package/dist/storage/connector-connections/index.d.ts.map +1 -1
- package/dist/storage/connector-connections/provider/runs.d.ts.map +1 -1
- package/dist/storage/connector-connections/provider/shared.d.ts +12 -2
- package/dist/storage/connector-connections/provider/shared.d.ts.map +1 -1
- package/dist/storage/connector-connections/provider.d.ts +1 -0
- package/dist/storage/connector-connections/provider.d.ts.map +1 -1
- package/dist/storage/connector-connections/provider.js +23 -7
- package/dist/storage/connector-connections/provider.js.map +6 -6
- package/dist/storage/connector-connections/types.d.ts +1 -1
- package/dist/storage/connector-connections/types.d.ts.map +1 -1
- package/dist/storage/dataset-ingest/codec.d.ts +6 -0
- package/dist/storage/dataset-ingest/codec.d.ts.map +1 -0
- package/dist/storage/dataset-ingest/in-memory.d.ts +28 -0
- package/dist/storage/dataset-ingest/in-memory.d.ts.map +1 -0
- package/dist/storage/dataset-ingest/index.d.ts +4 -0
- package/dist/storage/dataset-ingest/index.d.ts.map +1 -0
- package/dist/storage/dataset-ingest/provider.d.ts +157 -0
- package/dist/storage/dataset-ingest/provider.d.ts.map +1 -0
- package/dist/storage/dataset-ingest/provider.js +17 -0
- package/dist/storage/dataset-ingest/provider.js.map +9 -0
- package/dist/storage/dataset-ingest/types.d.ts +188 -0
- package/dist/storage/dataset-ingest/types.d.ts.map +1 -0
- package/dist/storage/file-upload-sessions/provider.js +12 -11
- package/dist/storage/file-upload-sessions/provider.js.map +1 -1
- package/dist/storage/in-memory/index.d.ts +12 -0
- package/dist/storage/in-memory/index.d.ts.map +1 -1
- package/dist/storage/index.d.ts +20 -13
- package/dist/storage/index.d.ts.map +1 -1
- package/dist/storage/index.js +61 -51
- package/dist/storage/index.js.map +1 -1
- package/dist/storage/internal.d.ts +4 -1
- package/dist/storage/internal.d.ts.map +1 -1
- package/dist/storage/internal.js +83 -7
- package/dist/storage/internal.js.map +4 -3
- package/dist/storage/lake-retention-runs/in-memory.d.ts +11 -0
- package/dist/storage/lake-retention-runs/in-memory.d.ts.map +1 -0
- package/dist/storage/lake-retention-runs/index.d.ts +3 -0
- package/dist/storage/lake-retention-runs/index.d.ts.map +1 -0
- package/dist/storage/lake-retention-runs/types.d.ts +21 -0
- package/dist/storage/lake-retention-runs/types.d.ts.map +1 -0
- package/dist/storage/maintenance-heartbeats/in-memory.d.ts +11 -0
- package/dist/storage/maintenance-heartbeats/in-memory.d.ts.map +1 -0
- package/dist/storage/maintenance-heartbeats/index.d.ts +3 -0
- package/dist/storage/maintenance-heartbeats/index.d.ts.map +1 -0
- package/dist/storage/maintenance-heartbeats/record.d.ts +11 -0
- package/dist/storage/maintenance-heartbeats/record.d.ts.map +1 -0
- package/dist/storage/maintenance-heartbeats/types.d.ts +30 -0
- package/dist/storage/maintenance-heartbeats/types.d.ts.map +1 -0
- package/dist/storage/migrations/types.d.ts +6 -0
- package/dist/storage/migrations/types.d.ts.map +1 -1
- package/dist/storage/objects/in-memory/query.d.ts.map +1 -1
- package/dist/storage/objects/in-memory/storage.d.ts +15 -1
- package/dist/storage/objects/in-memory/storage.d.ts.map +1 -1
- package/dist/storage/objects/index.d.ts +1 -1
- package/dist/storage/objects/index.d.ts.map +1 -1
- package/dist/storage/objects/query-preparation.d.ts +13 -0
- package/dist/storage/objects/query-preparation.d.ts.map +1 -1
- package/dist/storage/objects/read-scope.d.ts.map +1 -1
- package/dist/storage/objects/types.d.ts +70 -1
- package/dist/storage/objects/types.d.ts.map +1 -1
- package/dist/storage/ontology/in-memory/materializations.d.ts.map +1 -1
- package/dist/storage/ontology/in-memory/replacement-plans.d.ts.map +1 -1
- package/dist/storage/ontology/index.d.ts +1 -1
- package/dist/storage/ontology/index.d.ts.map +1 -1
- package/dist/storage/ontology/materializations.d.ts +20 -0
- package/dist/storage/ontology/materializations.d.ts.map +1 -1
- package/dist/storage/ontology/provider-work.d.ts +7 -1
- package/dist/storage/ontology/provider-work.d.ts.map +1 -1
- package/dist/storage/ontology/provider.js +1 -1
- package/dist/storage/pipeline-runs/in-memory.d.ts +8 -2
- package/dist/storage/pipeline-runs/in-memory.d.ts.map +1 -1
- package/dist/storage/pipeline-runs/index.d.ts +1 -1
- package/dist/storage/pipeline-runs/index.d.ts.map +1 -1
- package/dist/storage/pipeline-runs/provider.js +1 -1
- package/dist/storage/pipeline-runs/transitions.d.ts +2 -2
- package/dist/storage/pipeline-runs/transitions.d.ts.map +1 -1
- package/dist/storage/pipeline-runs/types.d.ts +26 -6
- package/dist/storage/pipeline-runs/types.d.ts.map +1 -1
- package/dist/storage/projection-runs/errors.d.ts +6 -0
- package/dist/storage/projection-runs/errors.d.ts.map +1 -1
- package/dist/storage/projection-runs/in-memory.d.ts +5 -1
- package/dist/storage/projection-runs/in-memory.d.ts.map +1 -1
- package/dist/storage/projection-runs/index.d.ts +2 -2
- package/dist/storage/projection-runs/index.d.ts.map +1 -1
- package/dist/storage/projection-runs/lifecycle.d.ts +1 -0
- package/dist/storage/projection-runs/lifecycle.d.ts.map +1 -1
- package/dist/storage/projection-runs/provider.js +2 -2
- package/dist/storage/projection-runs/types.d.ts +16 -0
- package/dist/storage/projection-runs/types.d.ts.map +1 -1
- package/dist/storage/run-claim.d.ts +132 -0
- package/dist/storage/run-claim.d.ts.map +1 -0
- package/dist/storage/share-grants/provider.js +3 -3
- package/dist/storage/share-sessions/in-memory.d.ts +2 -1
- package/dist/storage/share-sessions/in-memory.d.ts.map +1 -1
- package/dist/storage/share-sessions/index.d.ts +1 -1
- package/dist/storage/share-sessions/index.d.ts.map +1 -1
- package/dist/storage/share-sessions/provider.d.ts +1 -1
- package/dist/storage/share-sessions/provider.d.ts.map +1 -1
- package/dist/storage/share-sessions/provider.js +4 -2
- package/dist/storage/share-sessions/provider.js.map +1 -1
- package/dist/storage/share-sessions/record.d.ts +2 -1
- package/dist/storage/share-sessions/record.d.ts.map +1 -1
- package/dist/storage/share-sessions/types.d.ts +17 -1
- package/dist/storage/share-sessions/types.d.ts.map +1 -1
- package/dist/storage/sync-runs/in-memory.d.ts +10 -2
- package/dist/storage/sync-runs/in-memory.d.ts.map +1 -1
- package/dist/storage/sync-runs/index.d.ts +1 -1
- package/dist/storage/sync-runs/index.d.ts.map +1 -1
- package/dist/storage/sync-runs/transitions.d.ts +2 -2
- package/dist/storage/sync-runs/transitions.d.ts.map +1 -1
- package/dist/storage/sync-runs/types.d.ts +29 -3
- package/dist/storage/sync-runs/types.d.ts.map +1 -1
- package/dist/storage/types.d.ts +12 -6
- package/dist/storage/types.d.ts.map +1 -1
- package/dist/storage/webhook-runs/in-memory.d.ts +2 -1
- package/dist/storage/webhook-runs/in-memory.d.ts.map +1 -1
- package/dist/storage/webhook-runs/index.d.ts +2 -2
- package/dist/storage/webhook-runs/index.d.ts.map +1 -1
- package/dist/storage/webhook-runs/types.d.ts +33 -2
- package/dist/storage/webhook-runs/types.d.ts.map +1 -1
- package/dist/storage/workflow-runs/in-memory.d.ts +6 -3
- package/dist/storage/workflow-runs/in-memory.d.ts.map +1 -1
- package/dist/storage/workflow-runs/index.d.ts +1 -1
- package/dist/storage/workflow-runs/index.d.ts.map +1 -1
- package/dist/storage/workflow-runs/provider.js +12 -11
- package/dist/storage/workflow-runs/provider.js.map +1 -1
- package/dist/storage/workflow-runs/types.d.ts +11 -28
- package/dist/storage/workflow-runs/types.d.ts.map +1 -1
- package/dist/syncs/index.js +41 -38
- package/dist/syncs/index.js.map +1 -1
- package/dist/syncs/run-dispatch.d.ts +2 -0
- package/dist/syncs/run-dispatch.d.ts.map +1 -1
- package/dist/testing/agent-storage-contract.d.ts.map +1 -1
- package/dist/testing/ai-limit-storage-contract.d.ts.map +1 -1
- package/dist/testing/ai-model-call-groups-contract.d.ts.map +1 -1
- package/dist/testing/ai-usage-storage-contract.d.ts.map +1 -1
- package/dist/testing/artifact-holders-contract.d.ts +15 -0
- package/dist/testing/artifact-holders-contract.d.ts.map +1 -0
- package/dist/testing/artifact-storage-contract.d.ts.map +1 -1
- package/dist/testing/auth-storage-contract.d.ts.map +1 -1
- package/dist/testing/broker-contract.d.ts.map +1 -1
- package/dist/testing/connector-connection-storage-contract.d.ts +1 -1
- package/dist/testing/connector-connection-storage-contract.d.ts.map +1 -1
- package/dist/testing/dataset-ingest-storage-contract.d.ts +11 -0
- package/dist/testing/dataset-ingest-storage-contract.d.ts.map +1 -0
- package/dist/testing/dataset-sequence-contract.d.ts +1 -1
- package/dist/testing/dataset-sequence-contract.d.ts.map +1 -1
- package/dist/testing/execution.d.ts.map +1 -1
- package/dist/testing/index.d.ts +8 -0
- package/dist/testing/index.d.ts.map +1 -1
- package/dist/testing/index.js +6497 -3090
- package/dist/testing/index.js.map +32 -23
- package/dist/testing/lake-retention-run-storage-contract.d.ts +9 -0
- package/dist/testing/lake-retention-run-storage-contract.d.ts.map +1 -0
- package/dist/testing/maintenance-heartbeat-storage-contract.d.ts +9 -0
- package/dist/testing/maintenance-heartbeat-storage-contract.d.ts.map +1 -0
- package/dist/testing/object-conditional-read-scope-contract.d.ts.map +1 -1
- package/dist/testing/object-query-contract.d.ts.map +1 -1
- package/dist/testing/pipeline-execution.d.ts.map +1 -1
- package/dist/testing/pipeline-run-read-contract.d.ts +13 -0
- package/dist/testing/pipeline-run-read-contract.d.ts.map +1 -0
- package/dist/testing/projection-run-storage-contract.d.ts.map +1 -1
- package/dist/testing/queues-contract.d.ts.map +1 -1
- package/dist/testing/run-claim-storage-contract.d.ts +12 -0
- package/dist/testing/run-claim-storage-contract.d.ts.map +1 -0
- package/dist/testing/run-claim.d.ts +30 -0
- package/dist/testing/run-claim.d.ts.map +1 -0
- package/dist/testing/run-recovery-contract.d.ts +49 -0
- package/dist/testing/run-recovery-contract.d.ts.map +1 -0
- package/dist/testing/share-session-storage-contract.d.ts.map +1 -1
- package/dist/testing/stored-artifacts.d.ts +10 -0
- package/dist/testing/stored-artifacts.d.ts.map +1 -0
- package/dist/testing/sync-execution.d.ts.map +1 -1
- package/dist/testing/webhook-execution.d.ts +1 -1
- package/dist/testing/webhook-execution.d.ts.map +1 -1
- package/dist/testing/webhook-run-storage-contract.d.ts.map +1 -1
- package/dist/users/execution.d.ts +18 -1
- package/dist/users/execution.d.ts.map +1 -1
- package/dist/users/index.d.ts +1 -1
- package/dist/users/index.d.ts.map +1 -1
- package/dist/webhooks/delivery-lease.d.ts +13 -0
- package/dist/webhooks/delivery-lease.d.ts.map +1 -0
- package/dist/webhooks/internal.d.ts +2 -0
- package/dist/webhooks/internal.d.ts.map +1 -1
- package/dist/webhooks/internal.js +72 -40
- package/dist/webhooks/internal.js.map +5 -4
- package/dist/webhooks/run-admission.d.ts.map +1 -1
- package/dist/workers/index.d.ts +5 -1
- package/dist/workers/index.d.ts.map +1 -1
- package/dist/workers/index.js +193 -58
- package/dist/workers/index.js.map +8 -7
- package/dist/workers/job-ids.d.ts +17 -0
- package/dist/workers/job-ids.d.ts.map +1 -0
- package/dist/workers/lost-projection-runs.d.ts +26 -0
- package/dist/workers/lost-projection-runs.d.ts.map +1 -0
- package/dist/workers/lost-runs.d.ts +51 -0
- package/dist/workers/lost-runs.d.ts.map +1 -0
- package/dist/workers/queue-delivery.d.ts.map +1 -1
- package/dist/workers/queue-worker.d.ts +1 -2
- package/dist/workers/queue-worker.d.ts.map +1 -1
- package/dist/workers/queued-run-dispatch.d.ts +90 -0
- package/dist/workers/queued-run-dispatch.d.ts.map +1 -0
- package/dist/workers/run-lease.d.ts +25 -0
- package/dist/workers/run-lease.d.ts.map +1 -0
- package/dist/workers/run-worker.d.ts +95 -0
- package/dist/workers/run-worker.d.ts.map +1 -0
- package/dist/workflows/index.js +68 -62
- package/dist/workflows/index.js.map +1 -1
- package/dist/workflows/request.d.ts.map +1 -1
- package/dist/workflows/run-dispatch.d.ts +6 -1
- package/dist/workflows/run-dispatch.d.ts.map +1 -1
- package/package.json +41 -3
- package/src/actions/request.ts +24 -7
- package/src/actions/run/executor.ts +9 -42
- package/src/actions/types/context.ts +8 -3
- package/src/agents/README.md +2 -1
- package/src/agents/cancel.ts +7 -1
- package/src/agents/execution.ts +10 -2
- package/src/agents/fork.ts +12 -4
- package/src/agents/index.ts +16 -2
- package/src/agents/request.ts +42 -31
- package/src/agents/run-artifacts.ts +290 -46
- package/src/agents/run-plan.ts +31 -0
- package/src/agents/run-session-http.ts +19 -12
- package/src/agents/run-session-serve.ts +18 -2
- package/src/agents/run-session.ts +39 -12
- package/src/agents/skills.ts +3 -0
- package/src/agents/step-limits.ts +6 -0
- package/src/agents/streams/protocol.ts +14 -14
- package/src/agents/tool-files.ts +11 -3
- package/src/agents/validation.ts +12 -0
- package/src/agents/web.ts +218 -0
- package/src/artifacts/access.ts +71 -28
- package/src/artifacts/canvas-display.ts +160 -0
- package/src/artifacts/canvas.ts +26 -1
- package/src/artifacts/comment-text.ts +32 -0
- package/src/artifacts/comments.ts +275 -0
- package/src/artifacts/errors.ts +6 -1
- package/src/artifacts/events.ts +58 -0
- package/src/artifacts/execution.ts +496 -53
- package/src/artifacts/frames/assets.ts +20 -1
- package/src/artifacts/frames/grants.ts +31 -10
- package/src/artifacts/frames/index.ts +2 -0
- package/src/artifacts/frames/kit.ts +8 -5
- package/src/artifacts/frames/protocol.ts +149 -0
- package/src/artifacts/frames/runtime.ts +317 -29
- package/src/artifacts/holders.ts +120 -0
- package/src/artifacts/ids.ts +8 -0
- package/src/artifacts/index.ts +28 -2
- package/src/artifacts/limits.ts +28 -4
- package/src/artifacts/live/board.ts +759 -0
- package/src/artifacts/live/diff.ts +297 -0
- package/src/artifacts/live/document.ts +354 -0
- package/src/artifacts/live/files.ts +82 -0
- package/src/artifacts/live/index.ts +50 -0
- package/src/artifacts/live/presence.ts +144 -0
- package/src/artifacts/live/protocol.ts +134 -0
- package/src/artifacts/live/server.ts +16 -0
- package/src/artifacts/live/state.ts +115 -0
- package/src/artifacts/outline.ts +12 -0
- package/src/artifacts/publish/index.ts +26 -1
- package/src/artifacts/publish/merge.ts +271 -0
- package/src/artifacts/publish/previews.ts +485 -0
- package/src/artifacts/publish/publish.ts +92 -39
- package/src/artifacts/publish/query-answers.ts +85 -0
- package/src/artifacts/publish/references.ts +10 -4
- package/src/artifacts/publish/validate/canvas.ts +133 -1
- package/src/artifacts/theme.ts +9 -1
- package/src/auth/directory.ts +166 -0
- package/src/auth/member-events.ts +10 -3
- package/src/auth/runtime.ts +108 -8
- package/src/auth/strategy.ts +3 -1
- package/src/auth/types.ts +44 -0
- package/src/authorization/decision.ts +6 -5
- package/src/authorization/event-visibility.ts +4 -0
- package/src/authorization/resolve.ts +9 -11
- package/src/authorization/types.ts +5 -5
- package/src/broker/in-memory.ts +33 -6
- package/src/broker/types.ts +4 -0
- package/src/connectors/builders.ts +34 -2
- package/src/connectors/connections/access.ts +83 -0
- package/src/connectors/connections/contracts.ts +6 -1
- package/src/connectors/connections/execution.ts +2 -2
- package/src/connectors/connections/runs.ts +93 -7
- package/src/connectors/connections/service.ts +208 -41
- package/src/connectors/connections/views.ts +11 -4
- package/src/connectors/execution.ts +27 -3
- package/src/connectors/index.ts +2 -0
- package/src/connectors/service.ts +12 -0
- package/src/connectors/types.ts +37 -2
- package/src/datasets/execution.ts +74 -37
- package/src/datasets/ingest-flush-batch.ts +289 -0
- package/src/datasets/ingest-flush-job.ts +112 -0
- package/src/datasets/ingest-flush.ts +377 -0
- package/src/datasets/produced-version.ts +55 -0
- package/src/datasets/write.ts +65 -11
- package/src/deploy/services.ts +1 -1
- package/src/deploy/types.ts +2 -3
- package/src/deploy/validation.ts +1 -0
- package/src/error-reporting/capability.ts +66 -0
- package/src/error-reporting/internal.ts +12 -0
- package/src/error-reporting/reporter.ts +11 -35
- package/src/error-reporting/reports.ts +167 -0
- package/src/error-reporting/types.ts +99 -0
- package/src/errors/catalog.ts +6 -0
- package/src/events/definitions.ts +14 -0
- package/src/events/execution.ts +77 -28
- package/src/events/index.ts +3 -0
- package/src/events/scope.ts +2 -0
- package/src/events/types/artifacts.ts +40 -0
- package/src/events/types/index.ts +3 -0
- package/src/events/types/users.ts +5 -2
- package/src/execution/authorized-object-reader.ts +34 -0
- package/src/execution/object-reader-clearance.ts +31 -0
- package/src/execution/object-reader-security.ts +37 -22
- package/src/http/api-routes.ts +105 -4
- package/src/index.ts +24 -4
- package/src/lake-storage/errors.ts +21 -0
- package/src/lake-storage/index.ts +9 -1
- package/src/lake-storage/maintenance.ts +93 -0
- package/src/lake-storage/merge.ts +3 -1
- package/src/lake-storage/source-ordering.ts +28 -2
- package/src/lake-storage/types.ts +14 -0
- package/src/maintenance/heartbeat.ts +14 -0
- package/src/maintenance/index.ts +5 -3
- package/src/maintenance/lake-retention-status.ts +81 -0
- package/src/maintenance/lake-retention.ts +347 -0
- package/src/maintenance/loop.ts +365 -0
- package/src/maintenance/ontology-maintenance.ts +76 -229
- package/src/maintenance/passes/cron-pass.ts +217 -0
- package/src/maintenance/passes/directory-pass.ts +22 -0
- package/src/maintenance/passes/ingest-pass.ts +94 -0
- package/src/maintenance/passes/lake-change-feed.ts +112 -0
- package/src/maintenance/passes/lake-retention-pass.ts +71 -0
- package/src/maintenance/passes/ontology-pass.ts +19 -0
- package/src/maintenance/passes/projections-pass.ts +238 -0
- package/src/maintenance/passes/recovery-pass.ts +17 -0
- package/src/maintenance/passes/recovery-passes.ts +39 -0
- package/src/maintenance/passes/runs-pass.ts +12 -0
- package/src/maintenance/passes/triggers-pass.ts +332 -0
- package/src/maintenance/status.ts +75 -0
- package/src/maintenance/types.ts +27 -25
- package/src/materialization/model.ts +33 -21
- package/src/materializer/README.md +13 -2
- package/src/materializer/edits/artifact-refs.ts +140 -0
- package/src/materializer/edits/commit.ts +20 -7
- package/src/materializer/edits/operations.ts +23 -7
- package/src/materializer/edits/plan.ts +2 -0
- package/src/materializer/execution/work-records.ts +61 -0
- package/src/materializer/projections/replacement-plan.ts +2 -0
- package/src/materializer/shared/normalize.ts +14 -0
- package/src/materializer/telemetry/plan.ts +2 -0
- package/src/models/catalog.ts +52 -3
- package/src/models/definitions.ts +2 -0
- package/src/models/execution/README.md +22 -2
- package/src/models/execution/model-call-recorder.ts +1 -1
- package/src/models/execution/web-search.ts +186 -0
- package/src/models/index.ts +12 -0
- package/src/models/language-model.ts +12 -0
- package/src/models/web-search-model.ts +152 -0
- package/src/objects/artifact-refs.ts +34 -0
- package/src/objects/materializer-adapter.ts +8 -3
- package/src/objects/object/upsert-batch.ts +7 -0
- package/src/objects/object/upsert.ts +11 -2
- package/src/objects/query/executor.ts +7 -3
- package/src/objects/query/index.ts +1 -0
- package/src/objects/query/ir.ts +2 -0
- package/src/objects/query/scalar-values.ts +5 -3
- package/src/objects/query/sort-ties.ts +16 -0
- package/src/objects/runtime-batch.ts +8 -1
- package/src/objects/vectors/README.md +4 -4
- package/src/ontology/artifact-ref.ts +83 -0
- package/src/ontology/docs-markdown.ts +17 -0
- package/src/ontology/index.ts +3 -1
- package/src/ontology/inference/index.ts +2 -0
- package/src/ontology/json-schema.ts +13 -0
- package/src/ontology/primitives.ts +14 -0
- package/src/ontology/reference-values.ts +62 -0
- package/src/ontology/refs.ts +7 -1
- package/src/ontology/registry.ts +26 -1
- package/src/ontology/types.ts +2 -0
- package/src/ontology/user-ref.ts +35 -45
- package/src/ontology/validation/normalize.ts +13 -0
- package/src/ontology/validation/properties.ts +9 -0
- package/src/ontology/validation/schema.ts +12 -0
- package/src/pending-tasks.ts +51 -0
- package/src/pipelines/run-dispatch.ts +120 -238
- package/src/predicates/types.ts +2 -1
- package/src/projections/builders.ts +28 -13
- package/src/projections/run-dispatch.ts +1 -1
- package/src/projections/types.ts +1 -1
- package/src/projections/validation.ts +22 -8
- package/src/queues/in-memory.ts +50 -3
- package/src/queues/index.ts +4 -0
- package/src/queues/types.ts +68 -1
- package/src/runtime/create.ts +7 -2
- package/src/runtime/host.ts +118 -13
- package/src/runtime/index.ts +0 -1
- package/src/runtime/internal.ts +13 -0
- package/src/runtime/ontology-mutations.ts +1 -1
- package/src/runtime/resolve-definitions.ts +4 -0
- package/src/runtime/sixb.ts +14 -5
- package/src/scheduler/index.ts +0 -2
- package/src/security/index.ts +1 -0
- package/src/security/registry.ts +2 -0
- package/src/security/view-conditions.ts +4 -3
- package/src/security/visibility-keys.ts +144 -0
- package/src/shared/backoff.ts +34 -0
- package/src/shared/duration.ts +15 -0
- package/src/shared/params/artifact-refs.ts +42 -0
- package/src/shares/compiler.ts +1 -1
- package/src/shares/guest-name.ts +20 -0
- package/src/shares/internal.ts +1 -0
- package/src/shares/session-protocol.ts +63 -0
- package/src/storage/agents/in-memory.ts +29 -2
- package/src/storage/agents/index.ts +2 -0
- package/src/storage/agents/provider.ts +57 -1
- package/src/storage/agents/types.ts +45 -2
- package/src/storage/artifacts/errors.ts +10 -2
- package/src/storage/artifacts/in-memory.ts +579 -96
- package/src/storage/artifacts/index.ts +22 -1
- package/src/storage/artifacts/record.ts +255 -11
- package/src/storage/artifacts/types.ts +343 -40
- package/src/storage/auth/in-memory/auth-storage.ts +42 -5
- package/src/storage/auth/in-memory/identities.ts +16 -0
- package/src/storage/auth/in-memory/shared.ts +15 -0
- package/src/storage/auth/in-memory/users.ts +17 -16
- package/src/storage/auth/index.ts +3 -0
- package/src/storage/auth/types.ts +38 -0
- package/src/storage/connector-connections/in-memory.ts +6 -3
- package/src/storage/connector-connections/index.ts +1 -0
- package/src/storage/connector-connections/provider/connections.ts +2 -2
- package/src/storage/connector-connections/provider/runs.ts +3 -0
- package/src/storage/connector-connections/provider/shared.ts +30 -0
- package/src/storage/connector-connections/provider.ts +4 -0
- package/src/storage/connector-connections/types.ts +1 -0
- package/src/storage/dataset-ingest/codec.ts +90 -0
- package/src/storage/dataset-ingest/in-memory.ts +277 -0
- package/src/storage/dataset-ingest/index.ts +16 -0
- package/src/storage/dataset-ingest/provider.ts +592 -0
- package/src/storage/dataset-ingest/types.ts +191 -0
- package/src/storage/in-memory/index.ts +33 -0
- package/src/storage/index.ts +69 -5
- package/src/storage/internal.ts +20 -0
- package/src/storage/lake-retention-runs/in-memory.ts +22 -0
- package/src/storage/lake-retention-runs/index.ts +2 -0
- package/src/storage/lake-retention-runs/types.ts +19 -0
- package/src/storage/maintenance-heartbeats/in-memory.ts +24 -0
- package/src/storage/maintenance-heartbeats/index.ts +7 -0
- package/src/storage/maintenance-heartbeats/record.ts +50 -0
- package/src/storage/maintenance-heartbeats/types.ts +30 -0
- package/src/storage/migrations/types.ts +6 -0
- package/src/storage/objects/in-memory/query.ts +6 -2
- package/src/storage/objects/in-memory/storage.ts +81 -0
- package/src/storage/objects/index.ts +2 -0
- package/src/storage/objects/query-preparation.ts +59 -1
- package/src/storage/objects/read-scope.ts +109 -2
- package/src/storage/objects/types.ts +59 -1
- package/src/storage/ontology/in-memory/materializations.ts +8 -0
- package/src/storage/ontology/in-memory/replacement-plans.ts +4 -1
- package/src/storage/ontology/index.ts +2 -0
- package/src/storage/ontology/materializations.ts +18 -0
- package/src/storage/ontology/provider-work.ts +39 -0
- package/src/storage/pipeline-runs/in-memory.ts +97 -24
- package/src/storage/pipeline-runs/index.ts +0 -1
- package/src/storage/pipeline-runs/provider.ts +1 -1
- package/src/storage/pipeline-runs/transitions.ts +7 -4
- package/src/storage/pipeline-runs/types.ts +33 -7
- package/src/storage/projection-runs/errors.ts +10 -0
- package/src/storage/projection-runs/in-memory.ts +56 -1
- package/src/storage/projection-runs/index.ts +2 -1
- package/src/storage/projection-runs/lifecycle.ts +9 -1
- package/src/storage/projection-runs/types.ts +20 -1
- package/src/storage/run-claim.ts +224 -0
- package/src/storage/share-sessions/in-memory.ts +21 -0
- package/src/storage/share-sessions/index.ts +1 -0
- package/src/storage/share-sessions/provider.ts +1 -0
- package/src/storage/share-sessions/record.ts +28 -0
- package/src/storage/share-sessions/types.ts +19 -1
- package/src/storage/sync-runs/in-memory.ts +109 -29
- package/src/storage/sync-runs/index.ts +1 -1
- package/src/storage/sync-runs/transitions.ts +7 -4
- package/src/storage/sync-runs/types.ts +36 -3
- package/src/storage/types.ts +15 -5
- package/src/storage/webhook-runs/in-memory.ts +26 -2
- package/src/storage/webhook-runs/index.ts +3 -1
- package/src/storage/webhook-runs/types.ts +44 -3
- package/src/storage/workflow-runs/in-memory.ts +50 -36
- package/src/storage/workflow-runs/index.ts +0 -2
- package/src/storage/workflow-runs/types.ts +18 -30
- package/src/syncs/run-dispatch.ts +118 -239
- package/src/testing/agent-storage-contract.ts +70 -0
- package/src/testing/ai-limit-storage-contract.ts +11 -1
- package/src/testing/ai-model-call-groups-contract.ts +2 -1
- package/src/testing/ai-usage-storage-contract.ts +15 -2
- package/src/testing/artifact-holders-contract.ts +392 -0
- package/src/testing/artifact-storage-contract.ts +1205 -151
- package/src/testing/auth-storage-contract.ts +228 -1
- package/src/testing/broker-contract.ts +56 -0
- package/src/testing/connector-connection-storage-contract.ts +117 -5
- package/src/testing/dataset-ingest-storage-contract.ts +480 -0
- package/src/testing/dataset-sequence-contract.ts +97 -12
- package/src/testing/execution.ts +23 -0
- package/src/testing/index.ts +31 -0
- package/src/testing/lake-retention-run-storage-contract.ts +75 -0
- package/src/testing/maintenance-heartbeat-storage-contract.ts +99 -0
- package/src/testing/object-conditional-read-scope-contract.ts +267 -5
- package/src/testing/object-query-contract.ts +168 -0
- package/src/testing/pipeline-execution.ts +3 -1
- package/src/testing/pipeline-run-read-contract.ts +123 -0
- package/src/testing/projection-run-storage-contract.ts +113 -0
- package/src/testing/queues-contract.ts +112 -0
- package/src/testing/run-claim-storage-contract.ts +736 -0
- package/src/testing/run-claim.ts +69 -0
- package/src/testing/run-recovery-contract.ts +176 -0
- package/src/testing/share-session-storage-contract.ts +43 -0
- package/src/testing/stored-artifacts.ts +43 -0
- package/src/testing/sync-execution.ts +3 -1
- package/src/testing/webhook-execution.ts +7 -2
- package/src/testing/webhook-run-storage-contract.ts +102 -5
- package/src/users/execution.ts +50 -2
- package/src/users/index.ts +1 -0
- package/src/webhooks/delivery-lease.ts +40 -0
- package/src/webhooks/internal.ts +2 -0
- package/src/webhooks/run-admission.ts +22 -9
- package/src/workers/README.md +169 -0
- package/src/workers/index.ts +9 -1
- package/src/workers/job-ids.ts +31 -0
- package/src/workers/lost-projection-runs.ts +114 -0
- package/src/workers/lost-runs.ts +397 -0
- package/src/workers/queue-delivery.ts +2 -14
- package/src/workers/queue-worker.ts +9 -17
- package/src/workers/queued-run-dispatch.ts +308 -0
- package/src/workers/run-lease.ts +46 -0
- package/src/workers/run-worker.ts +312 -0
- package/src/workers/worker.ts +4 -17
- package/src/workflows/request.ts +2 -0
- package/src/workflows/run-dispatch.ts +22 -4
- package/src/workflows/snapshot.ts +1 -0
- package/dist/chunk-2g0r46hy.js.map +0 -12
- package/dist/chunk-3fqxbn31.js +0 -107
- package/dist/chunk-3fqxbn31.js.map +0 -11
- package/dist/chunk-3x3bebz7.js.map +0 -49
- package/dist/chunk-5kyvrtjh.js.map +0 -12
- package/dist/chunk-5taem5aw.js.map +0 -10
- package/dist/chunk-65abf64x.js +0 -13
- package/dist/chunk-65abf64x.js.map +0 -10
- package/dist/chunk-9x8dybsb.js.map +0 -10
- package/dist/chunk-aqyjb86c.js +0 -587
- package/dist/chunk-aqyjb86c.js.map +0 -18
- package/dist/chunk-az47zep4.js +0 -41
- package/dist/chunk-az47zep4.js.map +0 -10
- package/dist/chunk-cb21tx14.js.map +0 -71
- package/dist/chunk-djs3hw9p.js.map +0 -20
- package/dist/chunk-e5wf5vz0.js.map +0 -10
- package/dist/chunk-e6xgz4h4.js.map +0 -21
- package/dist/chunk-e7v3trpz.js.map +0 -10
- package/dist/chunk-edx8xcsm.js.map +0 -13
- package/dist/chunk-epyfm23v.js +0 -299
- package/dist/chunk-epyfm23v.js.map +0 -11
- package/dist/chunk-fb3feg1e.js +0 -298
- package/dist/chunk-fb3feg1e.js.map +0 -12
- package/dist/chunk-fg1db9xx.js.map +0 -10
- package/dist/chunk-h05rg3bx.js +0 -314
- package/dist/chunk-h05rg3bx.js.map +0 -12
- package/dist/chunk-hz5d43gn.js.map +0 -10
- package/dist/chunk-jbw70d6t.js.map +0 -10
- package/dist/chunk-jftd33rc.js.map +0 -11
- package/dist/chunk-jk97v21j.js.map +0 -10
- package/dist/chunk-jspskey0.js.map +0 -10
- package/dist/chunk-kfee1h52.js.map +0 -13
- package/dist/chunk-ks87m383.js.map +0 -44
- package/dist/chunk-kwfhd1g0.js +0 -144
- package/dist/chunk-kwfhd1g0.js.map +0 -13
- package/dist/chunk-nz7815t3.js.map +0 -14
- package/dist/chunk-ratj7t3t.js.map +0 -45
- package/dist/chunk-s3we74h8.js.map +0 -12
- package/dist/chunk-scyq22td.js.map +0 -12
- package/dist/chunk-t9xyr7y9.js.map +0 -22
- package/dist/chunk-tvbmh7tj.js.map +0 -18
- package/dist/chunk-tvefbgvw.js.map +0 -11
- package/dist/chunk-w976a4me.js.map +0 -10
- package/dist/chunk-yw9pyg66.js +0 -143
- package/dist/chunk-yw9pyg66.js.map +0 -11
- package/dist/chunk-z8fx5cgb.js.map +0 -11
- package/dist/scheduler/runtime.d.ts +0 -40
- package/dist/scheduler/runtime.d.ts.map +0 -1
- package/dist/workers/unstarted-run.d.ts +0 -10
- package/dist/workers/unstarted-run.d.ts.map +0 -1
- package/src/scheduler/runtime.ts +0 -214
- package/src/workers/unstarted-run.ts +0 -18
- /package/dist/{chunk-2pk5hjj9.js.map → chunk-186k5yz3.js.map} +0 -0
- /package/dist/{chunk-nghc7eq0.js.map → chunk-3723kgba.js.map} +0 -0
- /package/dist/{chunk-ytzcxtpt.js.map → chunk-3ba89vm7.js.map} +0 -0
- /package/dist/{chunk-qsg8rw04.js.map → chunk-5qqmndhm.js.map} +0 -0
- /package/dist/{chunk-8wsjr52f.js.map → chunk-7qe46788.js.map} +0 -0
- /package/dist/{chunk-23s66j86.js.map → chunk-855w9nvw.js.map} +0 -0
- /package/dist/{chunk-qbrmpgvv.js.map → chunk-8tqnsx3q.js.map} +0 -0
- /package/dist/{chunk-s038wa5v.js.map → chunk-b9qfh2ya.js.map} +0 -0
- /package/dist/{chunk-7hd2ez3q.js.map → chunk-c4nrycdy.js.map} +0 -0
- /package/dist/{chunk-jjmggm9a.js.map → chunk-fe6r7yhg.js.map} +0 -0
- /package/dist/{chunk-165c9wm6.js.map → chunk-g2ph4873.js.map} +0 -0
- /package/dist/{chunk-jhbk10wf.js.map → chunk-q9nkpr8k.js.map} +0 -0
- /package/dist/{chunk-4zm1k3xj.js.map → chunk-r2psmn42.js.map} +0 -0
- /package/dist/{chunk-r1cxq7vv.js.map → chunk-rtdrm592.js.map} +0 -0
- /package/dist/{chunk-m3qe54bb.js.map → chunk-smnt672s.js.map} +0 -0
- /package/dist/{chunk-21q0j5f2.js.map → chunk-stmxh0hv.js.map} +0 -0
- /package/dist/{chunk-ff5xkv0p.js.map → chunk-tfzvjdms.js.map} +0 -0
- /package/dist/{chunk-6b61s40c.js.map → chunk-w3t94hm6.js.map} +0 -0
- /package/dist/{chunk-agn8d8ys.js.map → chunk-xtztwpkh.js.map} +0 -0
- /package/dist/{chunk-0g5nyx0k.js.map → chunk-zeykm8my.js.map} +0 -0
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
MaintenanceHeartbeatRecord,
|
|
3
|
+
MaintenanceLoopOwner,
|
|
4
|
+
MaintenancePassHealth,
|
|
5
|
+
} from "./types"
|
|
6
|
+
|
|
7
|
+
/** The stored form of `passes`: what `parseMaintenanceHeartbeatRow` reads back. */
|
|
8
|
+
export function serializeMaintenancePasses(passes: readonly MaintenancePassHealth[]): string {
|
|
9
|
+
return JSON.stringify(passes)
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* Rebuilds a heartbeat from a provider row with camelCase keys. `passes` may arrive parsed (jsonb)
|
|
14
|
+
* or as text (SQLite), and `beatAt` as `Date` or ISO text.
|
|
15
|
+
*/
|
|
16
|
+
export function parseMaintenanceHeartbeatRow(row: {
|
|
17
|
+
readonly [column: string]: unknown
|
|
18
|
+
}): MaintenanceHeartbeatRecord {
|
|
19
|
+
const passes = typeof row.passes === "string" ? JSON.parse(row.passes) : row.passes
|
|
20
|
+
if (!Array.isArray(passes)) throw corrupt(row.projectId, "passes is not a list")
|
|
21
|
+
|
|
22
|
+
return {
|
|
23
|
+
projectId: String(row.projectId),
|
|
24
|
+
owner: parseOwner(row.owner, row.projectId),
|
|
25
|
+
beatAt: new Date(row.beatAt as Date | string),
|
|
26
|
+
everyMs: Number(row.everyMs),
|
|
27
|
+
passes: passes.map((pass) => parsePass(pass, row.projectId)),
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
function parseOwner(value: unknown, projectId: unknown): MaintenanceLoopOwner {
|
|
32
|
+
if (value === "orchestrator" || value === "embedded") return value
|
|
33
|
+
throw corrupt(projectId, "owner is unknown")
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
function parsePass(value: unknown, projectId: unknown): MaintenancePassHealth {
|
|
37
|
+
if (typeof value !== "object" || value === null) throw corrupt(projectId, "a pass is no object")
|
|
38
|
+
|
|
39
|
+
const pass = value as Record<string, unknown>
|
|
40
|
+
return {
|
|
41
|
+
id: String(pass.id),
|
|
42
|
+
lastSucceededAt:
|
|
43
|
+
typeof pass.lastSucceededAt === "string" ? new Date(pass.lastSucceededAt) : null,
|
|
44
|
+
consecutiveFailures: Number(pass.consecutiveFailures),
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
function corrupt(projectId: unknown, reason: string): Error {
|
|
49
|
+
return new Error(`[Sixb] Stored heartbeat of project '${projectId}' is invalid: ${reason}.`)
|
|
50
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/** How one maintenance pass has fared since the process that runs it started. */
|
|
2
|
+
export interface MaintenancePassHealth {
|
|
3
|
+
readonly id: string
|
|
4
|
+
readonly lastSucceededAt: Date | null
|
|
5
|
+
readonly consecutiveFailures: number
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
/** Who runs a maintenance loop: the orchestrator, or a server embedded with no orchestrator. */
|
|
9
|
+
export type MaintenanceLoopOwner = "orchestrator" | "embedded"
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* The proof that a project's maintenance runs: one row per project and owner, which the loop
|
|
13
|
+
* rewrites as it goes. The API reads it from another process, so it is what tells a stopped loop
|
|
14
|
+
* from a quiet one. Each owner has its row, so one that runs cannot speak for one that stopped.
|
|
15
|
+
*/
|
|
16
|
+
export interface MaintenanceHeartbeatRecord {
|
|
17
|
+
readonly projectId: string
|
|
18
|
+
readonly owner: MaintenanceLoopOwner
|
|
19
|
+
readonly beatAt: Date
|
|
20
|
+
/** The longest the loop waits between two beats. A reader calls a beat stale from this. */
|
|
21
|
+
readonly everyMs: number
|
|
22
|
+
readonly passes: readonly MaintenancePassHealth[]
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export interface MaintenanceHeartbeatStorage {
|
|
26
|
+
/** Replaces this owner's heartbeat, passes included: a pass no longer run leaves the record. */
|
|
27
|
+
record(heartbeat: MaintenanceHeartbeatRecord): Promise<void>
|
|
28
|
+
/** Every owner's heartbeat for the project, in no particular order. */
|
|
29
|
+
list(input: { readonly projectId: string }): Promise<readonly MaintenanceHeartbeatRecord[]>
|
|
30
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { OntologyDefinitionCatalog } from "../../ontology/registry"
|
|
2
|
+
import type { SecurityDefinitionCatalog } from "../../security/registry"
|
|
2
3
|
import type { ObjectQueryPreparationResult } from "../objects/query-preparation"
|
|
3
4
|
import type { Storage } from "../types"
|
|
4
5
|
|
|
@@ -128,6 +129,11 @@ export interface MigrationCapableStorage extends Storage {
|
|
|
128
129
|
export interface StorageMigrationOptions {
|
|
129
130
|
readonly projectId: string
|
|
130
131
|
readonly ontology: OntologyDefinitionCatalog
|
|
132
|
+
/**
|
|
133
|
+
* The roles' view conditions, whose keys member reads filter on. Without them, what was prepared
|
|
134
|
+
* for them is left as it is.
|
|
135
|
+
*/
|
|
136
|
+
readonly security?: Pick<SecurityDefinitionCatalog, "listViewConditions">
|
|
131
137
|
}
|
|
132
138
|
|
|
133
139
|
export interface StorageMigrationResult {
|
|
@@ -2,6 +2,7 @@ import type { ObjectQuery, ObjectQuerySortField } from "../../../objects/query"
|
|
|
2
2
|
import { linkEndpointObjectTypeIds } from "../../../objects/query/link-endpoints"
|
|
3
3
|
import { matchesPredicate } from "../../../objects/query/matches-predicate"
|
|
4
4
|
import { compareQueryScalarValues } from "../../../objects/query/scalar-values"
|
|
5
|
+
import { sortTieDirection } from "../../../objects/query/sort-ties"
|
|
5
6
|
import { vectorSources } from "../../../objects/vectors/profile"
|
|
6
7
|
import type { LinkBatchKey } from "../keys"
|
|
7
8
|
import {
|
|
@@ -79,6 +80,7 @@ export const IN_MEMORY_OBJECT_QUERY_CAPABILITIES: ObjectQueryCapabilities = {
|
|
|
79
80
|
date: { equality: true, ordering: true },
|
|
80
81
|
timestamp: { equality: true, ordering: true },
|
|
81
82
|
userRef: { equality: true },
|
|
83
|
+
artifactRef: { equality: true },
|
|
82
84
|
},
|
|
83
85
|
limits: {
|
|
84
86
|
totalCount: true,
|
|
@@ -443,14 +445,16 @@ function sortEntries(
|
|
|
443
445
|
entries: readonly QueryEntry[],
|
|
444
446
|
fields: readonly ObjectQuerySortField[]
|
|
445
447
|
): QueryEntry[] {
|
|
448
|
+
const ties = sortTieDirection(fields)
|
|
446
449
|
return [...entries].sort((left, right) => {
|
|
447
450
|
for (const field of fields) {
|
|
448
451
|
const comparison = compareSortField(left, right, field)
|
|
449
452
|
if (comparison !== 0) return comparison
|
|
450
453
|
}
|
|
451
|
-
|
|
454
|
+
|
|
455
|
+
const tie =
|
|
452
456
|
left.order - right.order || rowIdentityKey(left.row).localeCompare(rowIdentityKey(right.row))
|
|
453
|
-
|
|
457
|
+
return ties === "desc" ? -tie : tie
|
|
454
458
|
})
|
|
455
459
|
}
|
|
456
460
|
|
|
@@ -2,6 +2,8 @@ import type { EffectiveLinkSnapshot, EffectiveObjectSnapshot } from "../../../ma
|
|
|
2
2
|
import { hasVectorProfile } from "../../../objects/vectors/query"
|
|
3
3
|
import { uniqueValueKey } from "../../../ontology/unique-values"
|
|
4
4
|
import type {
|
|
5
|
+
ArtifactHolder,
|
|
6
|
+
ExactArtifactHolderWrite,
|
|
5
7
|
ExactUniqueValueClaim,
|
|
6
8
|
ExactUniqueValueWrite,
|
|
7
9
|
UniqueValueRef,
|
|
@@ -56,6 +58,7 @@ export interface InMemoryObjectStorageSnapshot {
|
|
|
56
58
|
readonly links: Map<string, Map<string, ObjectLinkRow>>
|
|
57
59
|
readonly uniqueValues: Map<string, Map<string, string>>
|
|
58
60
|
readonly uniqueProperties: Map<string, InMemoryPreparedUniqueProperty>
|
|
61
|
+
readonly artifactHolders: Map<string, Map<string, ArtifactHolder>>
|
|
59
62
|
}
|
|
60
63
|
|
|
61
64
|
interface InMemoryPreparedUniqueProperty extends PreparedUniqueProperty {
|
|
@@ -114,6 +117,8 @@ interface InMemoryObjectMaterializerAdapter {
|
|
|
114
117
|
entries: readonly UniqueValueEntry[]
|
|
115
118
|
): void
|
|
116
119
|
markUniquePropertyPrepared(input: InMemoryPreparedUniqueProperty): void
|
|
120
|
+
deleteArtifactHolder(projectId: string, value: ExactArtifactHolderWrite): void
|
|
121
|
+
insertArtifactHolder(projectId: string, value: ExactArtifactHolderWrite): void
|
|
117
122
|
}
|
|
118
123
|
|
|
119
124
|
const materializerAdapters = new WeakMap<InMemoryObjectStorage, InMemoryObjectMaterializerAdapter>()
|
|
@@ -133,6 +138,8 @@ export class InMemoryObjectStorage implements ObjectStorage {
|
|
|
133
138
|
/** Holder primary ids by value key, for each unique property of a project. */
|
|
134
139
|
private readonly uniqueValues = new Map<string, Map<string, string>>()
|
|
135
140
|
private readonly uniqueProperties = new Map<string, InMemoryPreparedUniqueProperty>()
|
|
141
|
+
/** The properties holding each artifact of a project, by holder key. */
|
|
142
|
+
private readonly artifactHolders = new Map<string, Map<string, ArtifactHolder>>()
|
|
136
143
|
|
|
137
144
|
private vectorReader?: VectorReader
|
|
138
145
|
|
|
@@ -191,6 +198,20 @@ export class InMemoryObjectStorage implements ObjectStorage {
|
|
|
191
198
|
{ ...input }
|
|
192
199
|
)
|
|
193
200
|
},
|
|
201
|
+
deleteArtifactHolder: (projectId, value) => {
|
|
202
|
+
const key = artifactHoldersKey(projectId, value.artifactId)
|
|
203
|
+
const holders = this.artifactHolders.get(key)
|
|
204
|
+
holders?.delete(artifactHolderKey(value))
|
|
205
|
+
if (holders?.size === 0) this.artifactHolders.delete(key)
|
|
206
|
+
},
|
|
207
|
+
insertArtifactHolder: (projectId, value) => {
|
|
208
|
+
const key = artifactHoldersKey(projectId, value.artifactId)
|
|
209
|
+
const holders = this.artifactHolders.get(key) ?? new Map<string, ArtifactHolder>()
|
|
210
|
+
this.artifactHolders.set(key, holders)
|
|
211
|
+
|
|
212
|
+
const { objectTypeId, primaryId, propertyId } = value
|
|
213
|
+
holders.set(artifactHolderKey(value), { objectTypeId, primaryId, propertyId })
|
|
214
|
+
},
|
|
194
215
|
})
|
|
195
216
|
}
|
|
196
217
|
|
|
@@ -200,6 +221,7 @@ export class InMemoryObjectStorage implements ObjectStorage {
|
|
|
200
221
|
links: cloneLinkBuckets(this.links),
|
|
201
222
|
uniqueValues: cloneUniqueValues(this.uniqueValues),
|
|
202
223
|
uniqueProperties: new Map(this.uniqueProperties),
|
|
224
|
+
artifactHolders: cloneArtifactHolders(this.artifactHolders),
|
|
203
225
|
}
|
|
204
226
|
}
|
|
205
227
|
|
|
@@ -223,6 +245,11 @@ export class InMemoryObjectStorage implements ObjectStorage {
|
|
|
223
245
|
for (const [key, prepared] of snapshot.uniqueProperties) {
|
|
224
246
|
this.uniqueProperties.set(key, prepared)
|
|
225
247
|
}
|
|
248
|
+
|
|
249
|
+
this.artifactHolders.clear()
|
|
250
|
+
for (const [key, holders] of cloneArtifactHolders(snapshot.artifactHolders)) {
|
|
251
|
+
this.artifactHolders.set(key, holders)
|
|
252
|
+
}
|
|
226
253
|
}
|
|
227
254
|
|
|
228
255
|
/** The object holding a unique value, or undefined when none does. */
|
|
@@ -610,6 +637,32 @@ export class InMemoryObjectStorage implements ObjectStorage {
|
|
|
610
637
|
}
|
|
611
638
|
}
|
|
612
639
|
|
|
640
|
+
async listArtifactHolders(params: {
|
|
641
|
+
projectId: string
|
|
642
|
+
artifactId: string
|
|
643
|
+
after?: ArtifactHolder
|
|
644
|
+
limit: number
|
|
645
|
+
}): Promise<{ holders: readonly ArtifactHolder[]; next?: ArtifactHolder }> {
|
|
646
|
+
assertArtifactHolderPageLimit(params.limit)
|
|
647
|
+
|
|
648
|
+
const { after } = params
|
|
649
|
+
const holders = [
|
|
650
|
+
...(this.artifactHolders
|
|
651
|
+
.get(artifactHoldersKey(params.projectId, params.artifactId))
|
|
652
|
+
?.values() ?? []),
|
|
653
|
+
]
|
|
654
|
+
.filter((holder) => !after || compareArtifactHolders(holder, after) > 0)
|
|
655
|
+
.sort(compareArtifactHolders)
|
|
656
|
+
.slice(0, params.limit + 1)
|
|
657
|
+
|
|
658
|
+
const page = holders.slice(0, params.limit).map((holder) => ({ ...holder }))
|
|
659
|
+
const last = page.at(-1)
|
|
660
|
+
return {
|
|
661
|
+
holders: page,
|
|
662
|
+
...(holders.length > params.limit && last ? { next: { ...last } } : {}),
|
|
663
|
+
}
|
|
664
|
+
}
|
|
665
|
+
|
|
613
666
|
async list(params: {
|
|
614
667
|
projectId: string
|
|
615
668
|
objectTypeId?: string | readonly string[]
|
|
@@ -743,6 +796,34 @@ function uniquePropertyKey(projectId: string, objectTypeId: string, propertyId:
|
|
|
743
796
|
return JSON.stringify([projectId, objectTypeId, propertyId])
|
|
744
797
|
}
|
|
745
798
|
|
|
799
|
+
function artifactHoldersKey(projectId: string, artifactId: string): string {
|
|
800
|
+
return JSON.stringify([projectId, artifactId])
|
|
801
|
+
}
|
|
802
|
+
|
|
803
|
+
function artifactHolderKey(holder: ArtifactHolder): string {
|
|
804
|
+
return JSON.stringify([holder.objectTypeId, holder.primaryId, holder.propertyId])
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
function compareArtifactHolders(left: ArtifactHolder, right: ArtifactHolder): number {
|
|
808
|
+
return (
|
|
809
|
+
compareStrings(left.objectTypeId, right.objectTypeId) ||
|
|
810
|
+
compareStrings(left.primaryId, right.primaryId) ||
|
|
811
|
+
compareStrings(left.propertyId, right.propertyId)
|
|
812
|
+
)
|
|
813
|
+
}
|
|
814
|
+
|
|
815
|
+
function assertArtifactHolderPageLimit(limit: number): void {
|
|
816
|
+
if (!Number.isSafeInteger(limit) || limit <= 0) {
|
|
817
|
+
throw new Error("Artifact holder page limit must be a positive safe integer.")
|
|
818
|
+
}
|
|
819
|
+
}
|
|
820
|
+
|
|
821
|
+
function cloneArtifactHolders(
|
|
822
|
+
holders: Map<string, Map<string, ArtifactHolder>>
|
|
823
|
+
): Map<string, Map<string, ArtifactHolder>> {
|
|
824
|
+
return new Map([...holders].map(([key, rows]) => [key, new Map(rows)]))
|
|
825
|
+
}
|
|
826
|
+
|
|
746
827
|
function cloneUniqueValues(
|
|
747
828
|
values: Map<string, Map<string, string>>
|
|
748
829
|
): Map<string, Map<string, string>> {
|
|
@@ -50,10 +50,12 @@ export type {
|
|
|
50
50
|
ObjectReadRoot,
|
|
51
51
|
ObjectReadScopeFactory,
|
|
52
52
|
ObjectReadStorage,
|
|
53
|
+
ObjectReadVisibility,
|
|
53
54
|
ObjectRow,
|
|
54
55
|
ObjectRowLinks,
|
|
55
56
|
ObjectRowUsers,
|
|
56
57
|
ObjectStorage,
|
|
58
|
+
ObjectVisibilityKeys,
|
|
57
59
|
QueryObjectLinksInput,
|
|
58
60
|
QueryObjectLinksResult,
|
|
59
61
|
QueryObjectsInput,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { compareStrings } from "../../json"
|
|
1
2
|
import type { QueryScalarKind } from "../../objects/query/ir"
|
|
2
3
|
import { linkTargetObjectTypeIds } from "../../objects/query/link-endpoints"
|
|
3
4
|
import {
|
|
@@ -7,7 +8,10 @@ import {
|
|
|
7
8
|
} from "../../ontology/query-capabilities"
|
|
8
9
|
import type { OntologyDefinitionCatalog } from "../../ontology/registry"
|
|
9
10
|
import type { ObjectQueryIndexDefinition } from "../../ontology/types"
|
|
11
|
+
import type { SecurityDefinitionCatalog } from "../../security/registry"
|
|
12
|
+
import { viewConditionKeys } from "../../security/visibility-keys"
|
|
10
13
|
import type { Storage } from "../types"
|
|
14
|
+
import type { ObjectVisibilityKeys } from "./types"
|
|
11
15
|
|
|
12
16
|
export interface ObjectQueryPreparationPlan {
|
|
13
17
|
readonly projectId: string
|
|
@@ -26,6 +30,12 @@ export interface ObjectQueryPreparationPlan {
|
|
|
26
30
|
readonly linkId: string
|
|
27
31
|
readonly targetObjectTypeIds: readonly string[] | undefined
|
|
28
32
|
}[]
|
|
33
|
+
/**
|
|
34
|
+
* The keys of every view condition a role puts on the type or a supertype, each once: a
|
|
35
|
+
* member's reads of the type filter on them. Absent when preparation was not given the view
|
|
36
|
+
* conditions, and a provider then leaves what it prepared for them as it is.
|
|
37
|
+
*/
|
|
38
|
+
readonly visibility?: readonly ObjectVisibilityKeys[]
|
|
29
39
|
}[]
|
|
30
40
|
}
|
|
31
41
|
|
|
@@ -54,6 +64,11 @@ export function isQueryPreparationCapableStorage(
|
|
|
54
64
|
export async function prepareObjectQueries(input: {
|
|
55
65
|
projectId: string
|
|
56
66
|
ontology: OntologyDefinitionCatalog
|
|
67
|
+
/**
|
|
68
|
+
* The roles' view conditions, whose keys member reads filter on. Without them, what was prepared
|
|
69
|
+
* for them is left as it is.
|
|
70
|
+
*/
|
|
71
|
+
security?: Pick<SecurityDefinitionCatalog, "listViewConditions">
|
|
57
72
|
storage: Storage
|
|
58
73
|
}): Promise<ObjectQueryPreparationResult> {
|
|
59
74
|
if (!isQueryPreparationCapableStorage(input.storage)) {
|
|
@@ -61,6 +76,7 @@ export async function prepareObjectQueries(input: {
|
|
|
61
76
|
}
|
|
62
77
|
|
|
63
78
|
const values = input.ontology.getValueTypesById()
|
|
79
|
+
const visibility = viewConditionKeysByType(input.security, input.ontology)
|
|
64
80
|
const objectTypes = input.ontology.listObjectTypes().map((type) => ({
|
|
65
81
|
objectTypeId: type.id,
|
|
66
82
|
properties: type.properties
|
|
@@ -82,6 +98,48 @@ export async function prepareObjectQueries(input: {
|
|
|
82
98
|
linkId: link.id,
|
|
83
99
|
targetObjectTypeIds: linkTargetObjectTypeIds(link.targetObjectTypeId, input.ontology),
|
|
84
100
|
})),
|
|
101
|
+
...(visibility ? { visibility: visibility.get(type.id) ?? [] } : {}),
|
|
85
102
|
}))
|
|
86
|
-
|
|
103
|
+
const result = await input.storage.prepareObjectQueries({
|
|
104
|
+
projectId: input.projectId,
|
|
105
|
+
objectTypes,
|
|
106
|
+
})
|
|
107
|
+
|
|
108
|
+
const unindexed = (input.security?.listViewConditions() ?? [])
|
|
109
|
+
.filter((condition) => !viewConditionKeys(condition.predicate))
|
|
110
|
+
.map(
|
|
111
|
+
(condition) =>
|
|
112
|
+
`Role '${condition.roleId}': can.view(${condition.objectTypeId}).where(...) negates currentUser() or needs it twice at once, so members' reads check every object.`
|
|
113
|
+
)
|
|
114
|
+
return unindexed.length > 0 ? { ...result, warnings: [...result.warnings, ...unindexed] } : result
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/** Each concrete type's distinct condition keys, in a stable order. */
|
|
118
|
+
function viewConditionKeysByType(
|
|
119
|
+
security: Pick<SecurityDefinitionCatalog, "listViewConditions"> | undefined,
|
|
120
|
+
ontology: OntologyDefinitionCatalog
|
|
121
|
+
): ReadonlyMap<string, readonly ObjectVisibilityKeys[]> | undefined {
|
|
122
|
+
if (!security) return undefined
|
|
123
|
+
|
|
124
|
+
const keysByType = new Map<string, Map<string, ObjectVisibilityKeys>>()
|
|
125
|
+
for (const condition of security.listViewConditions()) {
|
|
126
|
+
const keys = viewConditionKeys(condition.predicate)
|
|
127
|
+
if (!keys) continue
|
|
128
|
+
|
|
129
|
+
for (const objectTypeId of [
|
|
130
|
+
condition.objectTypeId,
|
|
131
|
+
...ontology.listSubTypes(condition.objectTypeId),
|
|
132
|
+
]) {
|
|
133
|
+
const typeKeys = keysByType.get(objectTypeId) ?? new Map<string, ObjectVisibilityKeys>()
|
|
134
|
+
typeKeys.set(JSON.stringify(keys), keys)
|
|
135
|
+
keysByType.set(objectTypeId, typeKeys)
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
return new Map(
|
|
140
|
+
[...keysByType].map(([objectTypeId, keys]) => [
|
|
141
|
+
objectTypeId,
|
|
142
|
+
[...keys].sort(([left], [right]) => compareStrings(left, right)).map(([, value]) => value),
|
|
143
|
+
])
|
|
144
|
+
)
|
|
87
145
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { compareStrings, getInvalidJsonValueReason } from "../../json"
|
|
2
2
|
import type { ObjectQueryPredicate, QueryScalarKind } from "../../objects/query"
|
|
3
|
-
import { isCurrentUser } from "../../ontology/user-ref"
|
|
3
|
+
import { isCurrentUser, type UserRef } from "../../ontology/user-ref"
|
|
4
4
|
import type {
|
|
5
5
|
CompiledConditionalObjectReadScope,
|
|
6
6
|
CompiledObjectReadObjectSelection,
|
|
@@ -14,6 +14,8 @@ import type {
|
|
|
14
14
|
ObjectReadNode,
|
|
15
15
|
ObjectReadObjectSelection,
|
|
16
16
|
ObjectReadRoot,
|
|
17
|
+
ObjectReadVisibility,
|
|
18
|
+
ObjectVisibilityKeys,
|
|
17
19
|
SelectedObjectReadScope,
|
|
18
20
|
} from "./types"
|
|
19
21
|
|
|
@@ -520,6 +522,7 @@ const SCALAR_KINDS: ReadonlySet<string> = new Set<QueryScalarKind>([
|
|
|
520
522
|
"date",
|
|
521
523
|
"timestamp",
|
|
522
524
|
"userRef",
|
|
525
|
+
"artifactRef",
|
|
523
526
|
])
|
|
524
527
|
|
|
525
528
|
/**
|
|
@@ -560,7 +563,13 @@ export function compileConditionalObjectReadScope(
|
|
|
560
563
|
objectTypeIds.add(objectTypeId)
|
|
561
564
|
|
|
562
565
|
const predicate = capturePredicate(condition.predicate, `${path}.predicate`, 0, budget)
|
|
563
|
-
|
|
566
|
+
const visibility =
|
|
567
|
+
condition.visibility === undefined
|
|
568
|
+
? undefined
|
|
569
|
+
: captureVisibility(condition.visibility, `${path}.visibility`, budget)
|
|
570
|
+
conditions.push(
|
|
571
|
+
Object.freeze({ objectTypeId, predicate, ...(visibility ? { visibility } : {}) })
|
|
572
|
+
)
|
|
564
573
|
}
|
|
565
574
|
|
|
566
575
|
conditions.sort((left, right) => compareStrings(left.objectTypeId, right.objectTypeId))
|
|
@@ -571,6 +580,104 @@ export function compileConditionalObjectReadScope(
|
|
|
571
580
|
}) as CompiledConditionalObjectReadScope
|
|
572
581
|
}
|
|
573
582
|
|
|
583
|
+
/** The reader's keys, user and remainder: shaped as providers read them, every predicate bound. */
|
|
584
|
+
function captureVisibility(
|
|
585
|
+
value: unknown,
|
|
586
|
+
path: string,
|
|
587
|
+
budget: { nodes: number }
|
|
588
|
+
): ObjectReadVisibility {
|
|
589
|
+
if (!isRecord(value)) throw invalidScope(`${path} must hold keys`)
|
|
590
|
+
|
|
591
|
+
const source = captureArray(value.keys, `${path}.keys`)
|
|
592
|
+
if (source.length === 0) throw invalidScope(`${path}.keys must not be empty`)
|
|
593
|
+
|
|
594
|
+
const keys: ObjectVisibilityKeys[] = []
|
|
595
|
+
for (let index = 0; index < source.length; index += 1) {
|
|
596
|
+
keys.push(captureKeys(source.value[index], `${path}.keys[${index}]`, 0, budget))
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
let user: UserRef | undefined
|
|
600
|
+
if (value.user !== undefined) {
|
|
601
|
+
const ref = value.user
|
|
602
|
+
if (!isRecord(ref) || ref.type !== "user" || Object.keys(ref).length !== 2) {
|
|
603
|
+
throw invalidScope(`${path}.user must be a user reference`)
|
|
604
|
+
}
|
|
605
|
+
if (typeof ref.id !== "string" || ref.id.length === 0) {
|
|
606
|
+
throw invalidScope(`${path}.user.id must be a non-empty string`)
|
|
607
|
+
}
|
|
608
|
+
user = Object.freeze({ type: "user", id: ref.id })
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
const remainder =
|
|
612
|
+
value.remainder === undefined
|
|
613
|
+
? undefined
|
|
614
|
+
: capturePredicate(value.remainder, `${path}.remainder`, 0, budget)
|
|
615
|
+
|
|
616
|
+
return Object.freeze({
|
|
617
|
+
keys: Object.freeze(keys),
|
|
618
|
+
...(user ? { user } : {}),
|
|
619
|
+
...(remainder ? { remainder } : {}),
|
|
620
|
+
})
|
|
621
|
+
}
|
|
622
|
+
|
|
623
|
+
function captureKeys(
|
|
624
|
+
value: unknown,
|
|
625
|
+
path: string,
|
|
626
|
+
depth: number,
|
|
627
|
+
budget: { nodes: number }
|
|
628
|
+
): ObjectVisibilityKeys {
|
|
629
|
+
if (depth > CONDITIONAL_READ_SCOPE_LIMITS.maxPredicateDepth) {
|
|
630
|
+
throw invalidScope(
|
|
631
|
+
`${path} exceeds the maximum predicate depth of ${CONDITIONAL_READ_SCOPE_LIMITS.maxPredicateDepth}`
|
|
632
|
+
)
|
|
633
|
+
}
|
|
634
|
+
|
|
635
|
+
budget.nodes += 1
|
|
636
|
+
if (budget.nodes > CONDITIONAL_READ_SCOPE_LIMITS.maxPredicateNodes) {
|
|
637
|
+
throw invalidScope(
|
|
638
|
+
`scope exceeds the maximum of ${CONDITIONAL_READ_SCOPE_LIMITS.maxPredicateNodes} predicate nodes`
|
|
639
|
+
)
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
if (!isRecord(value)) throw invalidScope(`${path} must be visibility keys`)
|
|
643
|
+
|
|
644
|
+
switch (value.kind) {
|
|
645
|
+
case "everyone":
|
|
646
|
+
return Object.freeze({
|
|
647
|
+
kind: "everyone",
|
|
648
|
+
when: capturePredicate(value.when, `${path}.when`, depth + 1, budget),
|
|
649
|
+
})
|
|
650
|
+
|
|
651
|
+
case "user":
|
|
652
|
+
case "users":
|
|
653
|
+
return Object.freeze({
|
|
654
|
+
kind: value.kind,
|
|
655
|
+
propertyId: nonEmptyString(value.propertyId, `${path}.propertyId`),
|
|
656
|
+
})
|
|
657
|
+
|
|
658
|
+
case "union": {
|
|
659
|
+
const items = captureArray(value.items, `${path}.items`)
|
|
660
|
+
if (items.length === 0) throw invalidScope(`${path}.items must not be empty`)
|
|
661
|
+
|
|
662
|
+
const captured: ObjectVisibilityKeys[] = []
|
|
663
|
+
for (let index = 0; index < items.length; index += 1) {
|
|
664
|
+
captured.push(captureKeys(items.value[index], `${path}.items[${index}]`, depth + 1, budget))
|
|
665
|
+
}
|
|
666
|
+
return Object.freeze({ kind: "union", items: Object.freeze(captured) })
|
|
667
|
+
}
|
|
668
|
+
|
|
669
|
+
case "when":
|
|
670
|
+
return Object.freeze({
|
|
671
|
+
kind: "when",
|
|
672
|
+
when: capturePredicate(value.when, `${path}.when`, depth + 1, budget),
|
|
673
|
+
keys: captureKeys(value.keys, `${path}.keys`, depth + 1, budget),
|
|
674
|
+
})
|
|
675
|
+
|
|
676
|
+
default:
|
|
677
|
+
throw invalidScope(`${path}.kind must be a kind of visibility keys`)
|
|
678
|
+
}
|
|
679
|
+
}
|
|
680
|
+
|
|
574
681
|
function capturePredicate(
|
|
575
682
|
value: unknown,
|
|
576
683
|
path: string,
|
|
@@ -6,9 +6,10 @@ import type {
|
|
|
6
6
|
ObjectQuerySortField,
|
|
7
7
|
QueryScalarKind,
|
|
8
8
|
} from "../../objects/query"
|
|
9
|
+
import type { UserRef } from "../../ontology/user-ref"
|
|
9
10
|
import type { Redactions } from "../../security/types"
|
|
10
11
|
import type { UserProfile } from "../../users"
|
|
11
|
-
import type { UniqueValueRef } from "../ontology/materializations"
|
|
12
|
+
import type { ArtifactHolder, UniqueValueRef } from "../ontology/materializations"
|
|
12
13
|
import type { ObjectReadExecutionLimits } from "./execution-limits"
|
|
13
14
|
import type { LinkBatchKey, ObjectBatchKey } from "./keys"
|
|
14
15
|
|
|
@@ -203,8 +204,50 @@ export interface ObjectReadCondition {
|
|
|
203
204
|
* bound to the reader. Providers compile it with their own predicate compiler.
|
|
204
205
|
*/
|
|
205
206
|
readonly predicate: ObjectQueryPredicate
|
|
207
|
+
/**
|
|
208
|
+
* The same condition read from visibility keys, for a provider that indexes them. Absent when
|
|
209
|
+
* none of the reader's conditions on the type has keys.
|
|
210
|
+
*/
|
|
211
|
+
readonly visibility?: ObjectReadVisibility
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
/**
|
|
215
|
+
* `predicate` read from keys: it matches an object exactly when one of `keys` shows it to everyone
|
|
216
|
+
* or to `user`, or when `remainder` matches it.
|
|
217
|
+
*/
|
|
218
|
+
export interface ObjectReadVisibility {
|
|
219
|
+
/** One per condition of the reader's roles that has keys, the same for every reader. */
|
|
220
|
+
readonly keys: readonly ObjectVisibilityKeys[]
|
|
221
|
+
/** The user reading; without one, an object is only shown by keys for everyone. */
|
|
222
|
+
readonly user?: UserRef
|
|
223
|
+
/** The reader's other conditions, bound to its user: an object either matches is shown. */
|
|
224
|
+
readonly remainder?: ObjectQueryPredicate
|
|
206
225
|
}
|
|
207
226
|
|
|
227
|
+
/**
|
|
228
|
+
* Who a view condition shows an object to, read from the object alone: everyone holding the
|
|
229
|
+
* condition, or the users some of its properties name.
|
|
230
|
+
*
|
|
231
|
+
* `currentUser()` only appears where a condition compares user references, so a condition has
|
|
232
|
+
* keys unless it negates such a comparison, or needs two of them to hold at once. Unlike the
|
|
233
|
+
* condition bound to a reader, keys are the same for every reader, so a provider can index them
|
|
234
|
+
* once per condition. A reader sees an object when its keys show it to everyone or to the reader.
|
|
235
|
+
*/
|
|
236
|
+
export type ObjectVisibilityKeys =
|
|
237
|
+
/** Everyone, when `when` matches. `when` never reads `currentUser()`. */
|
|
238
|
+
| { readonly kind: "everyone"; readonly when: ObjectQueryPredicate }
|
|
239
|
+
/** The user a `ref.user()` property holds, as `eq(property, currentUser())` compares it. */
|
|
240
|
+
| { readonly kind: "user"; readonly propertyId: string }
|
|
241
|
+
/** Each user a list holds, as `contains(property, currentUser())` compares them. */
|
|
242
|
+
| { readonly kind: "users"; readonly propertyId: string }
|
|
243
|
+
| { readonly kind: "union"; readonly items: readonly ObjectVisibilityKeys[] }
|
|
244
|
+
/** `keys`, when `when` matches. `when` never reads `currentUser()`. */
|
|
245
|
+
| {
|
|
246
|
+
readonly kind: "when"
|
|
247
|
+
readonly when: ObjectQueryPredicate
|
|
248
|
+
readonly keys: ObjectVisibilityKeys
|
|
249
|
+
}
|
|
250
|
+
|
|
208
251
|
/**
|
|
209
252
|
* Detached and deeply immutable conditions, one per concrete type, ordered by type id.
|
|
210
253
|
*
|
|
@@ -451,4 +494,19 @@ export interface ObjectStorage extends ObjectReadStorage, ObjectReadScopeFactory
|
|
|
451
494
|
afterPrimaryId?: string
|
|
452
495
|
limit: number
|
|
453
496
|
}): Promise<{ objects: readonly ObjectRow[]; nextPrimaryId?: string }>
|
|
497
|
+
|
|
498
|
+
/**
|
|
499
|
+
* The object properties whose value holds this artifact, nested anywhere in it: a keyset page in
|
|
500
|
+
* `(objectTypeId, primaryId, propertyId)` order, by code point, after `after` when given. Every
|
|
501
|
+
* object write keeps them current in its own transaction, and a deleted object holds nothing.
|
|
502
|
+
*
|
|
503
|
+
* Unscoped like {@link listIncidentLinksBatch}: whoever reaches an artifact through the objects
|
|
504
|
+
* that hold it reads each of them through its own reader.
|
|
505
|
+
*/
|
|
506
|
+
listArtifactHolders(params: {
|
|
507
|
+
projectId: string
|
|
508
|
+
artifactId: string
|
|
509
|
+
after?: ArtifactHolder
|
|
510
|
+
limit: number
|
|
511
|
+
}): Promise<{ holders: readonly ArtifactHolder[]; next?: ArtifactHolder }>
|
|
454
512
|
}
|
|
@@ -549,6 +549,14 @@ export class InMemoryOntologyMaterializationStorage implements OntologyMateriali
|
|
|
549
549
|
write("unique.claim", () => {
|
|
550
550
|
getInMemoryObjectMaterializerAdapter(this.objects).claimUniqueValue(projectId, item)
|
|
551
551
|
})
|
|
552
|
+
for (const item of chunk.artifactHolders.deletes)
|
|
553
|
+
write("artifact-holder.delete", () => {
|
|
554
|
+
getInMemoryObjectMaterializerAdapter(this.objects).deleteArtifactHolder(projectId, item)
|
|
555
|
+
})
|
|
556
|
+
for (const item of chunk.artifactHolders.inserts)
|
|
557
|
+
write("artifact-holder.insert", () => {
|
|
558
|
+
getInMemoryObjectMaterializerAdapter(this.objects).insertArtifactHolder(projectId, item)
|
|
559
|
+
})
|
|
552
560
|
for (const item of chunk.timeseries.pointUpserts)
|
|
553
561
|
write("timeseries.point.upsert", () => {
|
|
554
562
|
this.assertPoint(item.expected, projectId)
|
|
@@ -140,9 +140,12 @@ export function touchPlanItem(touches: InMemoryCommitTouches, item: Materializat
|
|
|
140
140
|
case "link-slot-override-delete":
|
|
141
141
|
touches.scopes.add(linkScopeKey(item.value.ref.source, item.value.ref.linkId))
|
|
142
142
|
return
|
|
143
|
-
// A plan reads no unique value: its claims are checked when they apply.
|
|
143
|
+
// A plan reads no unique value: its claims are checked when they apply. Nor does it read
|
|
144
|
+
// which objects hold an artifact.
|
|
144
145
|
case "unique-value-release":
|
|
145
146
|
case "unique-value-claim":
|
|
147
|
+
case "artifact-holder-delete":
|
|
148
|
+
case "artifact-holder-insert":
|
|
146
149
|
return
|
|
147
150
|
}
|
|
148
151
|
}
|