@graphrefly/graphrefly 0.34.0 → 0.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{cascading-DKIb6Pk8.d.cts → cascading-B25wxpRa.d.cts} +3 -3
- package/dist/{cascading-Bg0a4VSf.d.ts → cascading-BsJ4GbnS.d.ts} +3 -3
- package/dist/{chunk-TZLEMGAK.js → chunk-2Y3DKIZL.js} +2 -2
- package/dist/chunk-3OT7K33Q.js +1 -0
- package/dist/chunk-53XJ2S6D.js +1 -0
- package/dist/chunk-5CPPC75H.js +1 -0
- package/dist/chunk-5KPIYVCC.js +7 -0
- package/dist/{chunk-GAOX6OPT.js → chunk-5XZRCS2M.js} +1 -1
- package/dist/{chunk-C5DINHNP.js → chunk-6G5YD37E.js} +1 -1
- package/dist/{chunk-WBWBY6LI.js → chunk-6SVKZ7VI.js} +1 -1
- package/dist/chunk-A5HZZYRK.js +1 -0
- package/dist/chunk-BGEY3PXH.js +1 -0
- package/dist/chunk-CD4CB6S7.js +1 -0
- package/dist/chunk-CE72X3WO.js +1 -0
- package/dist/chunk-CUQFO6MT.js +1 -0
- package/dist/chunk-D5RFJOZ2.js +1 -0
- package/dist/{chunk-A3GDELMY.js → chunk-E5YSBQSF.js} +7 -7
- package/dist/{chunk-SFIM774L.js → chunk-EUE7ELFQ.js} +1 -1
- package/dist/chunk-F3IGTWCQ.js +1 -0
- package/dist/chunk-F672GV32.js +1 -0
- package/dist/{chunk-GCUYSIM4.js → chunk-GWOKTENT.js} +1 -1
- package/dist/{chunk-4NYSEUKV.js → chunk-J6TGRQUP.js} +1 -1
- package/dist/{chunk-4F564IPP.js → chunk-JJTF75VS.js} +1 -1
- package/dist/{chunk-BY4WKPKM.js → chunk-JUJEPZOI.js} +1 -1
- package/dist/{chunk-65WWQ5CB.js → chunk-M5UC63ZI.js} +5 -5
- package/dist/chunk-MQZWA3DF.js +1 -0
- package/dist/chunk-MYFR67PY.js +18 -0
- package/dist/{chunk-KN2UMFT6.js → chunk-PCD2MU7X.js} +1 -1
- package/dist/{chunk-YDWTVO4E.js → chunk-PIIUJIF7.js} +1 -1
- package/dist/chunk-PVUTRA5K.js +5 -0
- package/dist/chunk-Q7EUZ6NN.js +1 -0
- package/dist/chunk-RLMYS3XZ.js +1 -0
- package/dist/chunk-RRFOCAH6.js +1 -0
- package/dist/{chunk-Q46YJCQH.js → chunk-T6RPUERH.js} +1 -1
- package/dist/{chunk-IPNJDNE7.js → chunk-T7GWBGOO.js} +1 -1
- package/dist/{chunk-U2T2XWDA.js → chunk-U347KVM4.js} +1 -1
- package/dist/chunk-UAMWD4GG.js +1 -0
- package/dist/chunk-VN6RDSK2.js +1 -0
- package/dist/{chunk-CJMFZXIZ.js → chunk-W2ZU226Q.js} +1 -1
- package/dist/{chunk-UF746BQ4.js → chunk-XINLP35X.js} +1 -1
- package/dist/{chunk-TONEKQM3.js → chunk-XMDNNSMK.js} +1 -1
- package/dist/{chunk-INXDSJRC.js → chunk-YOUAVGHJ.js} +1 -1
- package/dist/chunk-YV2A2VWG.js +1 -0
- package/dist/{chunk-PBN426RU.js → chunk-ZGVA2SR5.js} +1 -1
- package/dist/compat/index.cjs +10 -10
- package/dist/compat/index.d.cts +17 -14
- package/dist/compat/index.d.ts +17 -14
- package/dist/compat/index.js +1 -1
- package/dist/compat/jotai/index.d.cts +2 -2
- package/dist/compat/jotai/index.d.ts +2 -2
- package/dist/compat/nanostores/index.d.cts +2 -2
- package/dist/compat/nanostores/index.d.ts +2 -2
- package/dist/compat/nestjs/index.cjs +12 -12
- package/dist/compat/nestjs/index.d.cts +9 -6
- package/dist/compat/nestjs/index.d.ts +9 -6
- package/dist/compat/nestjs/index.js +1 -1
- package/dist/compat/react/index.d.cts +2 -2
- package/dist/compat/react/index.d.ts +2 -2
- package/dist/compat/solid/index.d.cts +2 -2
- package/dist/compat/solid/index.d.ts +2 -2
- package/dist/compat/svelte/index.d.cts +2 -2
- package/dist/compat/svelte/index.d.ts +2 -2
- package/dist/compat/vue/index.d.cts +2 -2
- package/dist/compat/vue/index.d.ts +2 -2
- package/dist/compat/zustand/index.cjs +7 -7
- package/dist/compat/zustand/index.d.cts +5 -4
- package/dist/compat/zustand/index.d.ts +5 -4
- package/dist/compat/zustand/index.js +1 -1
- package/dist/{composite-BPDU_XV1.d.ts → composite-CT_mApQD.d.ts} +2 -2
- package/dist/{composite-CmvdhTJe.d.cts → composite-_XckYx2e.d.cts} +2 -2
- package/dist/{content-addressed-storage-DqIWCmZG.d.cts → content-addressed-storage-4-ST1tYk.d.cts} +5 -5
- package/dist/{content-addressed-storage-BUiREIuj.d.ts → content-addressed-storage-DuYMjV7o.d.ts} +5 -5
- package/dist/core/index.d.cts +4 -4
- package/dist/core/index.d.ts +4 -4
- package/dist/extra/browser.cjs +1 -1
- package/dist/extra/browser.d.cts +4 -3
- package/dist/extra/browser.d.ts +4 -3
- package/dist/extra/browser.js +1 -1
- package/dist/extra/index.cjs +19 -19
- package/dist/extra/index.d.cts +13 -12
- package/dist/extra/index.d.ts +13 -12
- package/dist/extra/index.js +1 -1
- package/dist/extra/node.cjs +2 -3
- package/dist/extra/node.d.cts +3 -3
- package/dist/extra/node.d.ts +3 -3
- package/dist/extra/node.js +2 -2
- package/dist/extra/operators.cjs +1 -1
- package/dist/extra/operators.d.cts +1 -1
- package/dist/extra/operators.d.ts +1 -1
- package/dist/extra/operators.js +1 -1
- package/dist/extra/reactive.cjs +1 -1
- package/dist/extra/reactive.d.cts +4 -3
- package/dist/extra/reactive.d.ts +4 -3
- package/dist/extra/reactive.js +1 -1
- package/dist/extra/sources.cjs +1 -1
- package/dist/extra/sources.d.cts +57 -2
- package/dist/extra/sources.d.ts +57 -2
- package/dist/extra/sources.js +1 -1
- package/dist/extra/storage-browser.cjs +1 -1
- package/dist/extra/storage-browser.d.cts +8 -42
- package/dist/extra/storage-browser.d.ts +8 -42
- package/dist/extra/storage-browser.js +1 -1
- package/dist/extra/storage-core.cjs +1 -1
- package/dist/extra/storage-core.d.cts +13 -83
- package/dist/extra/storage-core.d.ts +13 -83
- package/dist/extra/storage-core.js +1 -1
- package/dist/extra/storage-node.cjs +1 -2
- package/dist/extra/storage-node.d.cts +1 -59
- package/dist/extra/storage-node.d.ts +1 -59
- package/dist/extra/storage-node.js +0 -1
- package/dist/extra/storage-tiers-browser.cjs +1 -0
- package/dist/extra/storage-tiers-browser.d.cts +49 -0
- package/dist/extra/storage-tiers-browser.d.ts +49 -0
- package/dist/extra/storage-tiers-browser.js +1 -0
- package/dist/extra/storage-tiers-node.cjs +1 -0
- package/dist/extra/storage-tiers-node.d.cts +86 -0
- package/dist/extra/storage-tiers-node.d.ts +86 -0
- package/dist/extra/storage-tiers-node.js +1 -0
- package/dist/extra/storage-tiers.cjs +1 -0
- package/dist/extra/storage-tiers.d.cts +284 -0
- package/dist/extra/storage-tiers.d.ts +284 -0
- package/dist/extra/storage-tiers.js +1 -0
- package/dist/{fallback-mYSd8vQo.d.ts → fallback-DuEXfA4F.d.ts} +14 -14
- package/dist/{fallback-9YznPvPP.d.cts → fallback-axI2cXwt.d.cts} +14 -14
- package/dist/graph/index.cjs +3 -3
- package/dist/graph/index.d.cts +6 -5
- package/dist/graph/index.d.ts +6 -5
- package/dist/graph/index.js +1 -1
- package/dist/{graph-BROUZPG9.d.ts → graph-Cv-8x0ZI.d.ts} +28 -16
- package/dist/{graph-DaoydJ_u.d.cts → graph-kTltt95s.d.cts} +28 -16
- package/dist/imperative-audit-ahAE65a9.d.cts +28 -0
- package/dist/imperative-audit-ahAE65a9.d.ts +28 -0
- package/dist/{index-CI5fULSz.d.ts → index-8OxXae3g.d.ts} +1 -1
- package/dist/{index-CQ1gt4rn.d.cts → index-9xhIaM-w.d.cts} +1 -1
- package/dist/{index-DhWrMTI6.d.cts → index-B3D_z0Z6.d.cts} +1 -1
- package/dist/{index-Ccv_61jG.d.cts → index-B3Dfl5sS.d.cts} +110 -27
- package/dist/{index-Dia4yc2y.d.ts → index-B4s70vYf.d.ts} +4 -4
- package/dist/{index-Db21wuaD.d.ts → index-B5UR87KG.d.ts} +3 -3
- package/dist/{index-DuvQAU02.d.ts → index-BBdwz2BW.d.ts} +2 -2
- package/dist/{index-B5eS17Bz.d.ts → index-BEvsFlfH.d.ts} +47 -32
- package/dist/{index-BUtCR0k6.d.ts → index-BF-ssbJB.d.ts} +7 -7
- package/dist/{index-ClKm7CFB.d.cts → index-BFuVcqL8.d.cts} +1 -1
- package/dist/{index-BkfL5MXh.d.cts → index-BWH17rK_.d.cts} +3 -3
- package/dist/{index-CD7qmvSf.d.ts → index-BZ1V5GzX.d.ts} +3 -3
- package/dist/{index-BDEhWLF4.d.cts → index-BhkPzu-Z.d.cts} +4 -4
- package/dist/{index-CNxdDb2e.d.ts → index-Bilohojo.d.ts} +3 -3
- package/dist/{index-zA1uVtk0.d.ts → index-BiomL7AW.d.ts} +1 -1
- package/dist/{index-BWiX5foT.d.ts → index-BjWZARLy.d.ts} +1 -1
- package/dist/{index-IxinNgAH.d.cts → index-BkbawFkI.d.cts} +16 -15
- package/dist/{index-RJX4snyi.d.cts → index-BlRVj-7Q.d.cts} +21 -21
- package/dist/index-BpFwRAf9.d.cts +26 -0
- package/dist/{index-Ds3Rz9m9.d.cts → index-BsZlbHM5.d.cts} +3 -3
- package/dist/{index-BFHpNSsV.d.ts → index-BtY2QVDf.d.cts} +8 -7
- package/dist/{index-BsxqmV6u.d.ts → index-BuMzxRO2.d.ts} +2 -2
- package/dist/{index-C5uMGVJw.d.ts → index-BwYGLgmI.d.ts} +4 -4
- package/dist/{index-3L3RC3VJ.d.ts → index-C40wA8zt.d.ts} +7 -7
- package/dist/{index-Bi4ZP6Hc.d.ts → index-C9xF16gc.d.ts} +110 -27
- package/dist/index-CAIhFfws.d.ts +171 -0
- package/dist/{index-BRisOxlx.d.ts → index-CDvC1m5p.d.ts} +1 -1
- package/dist/index-CGKs5ixV.d.cts +287 -0
- package/dist/{index-ygRFoyrN.d.ts → index-CI_yjtua.d.ts} +2 -2
- package/dist/{index-DxEcY7Om.d.ts → index-CIcu6fIR.d.ts} +1 -1
- package/dist/{index-CQtnGFrZ.d.cts → index-CfOSES72.d.cts} +7 -7
- package/dist/{index-Bd2AjMQY.d.ts → index-Cot94_82.d.ts} +21 -21
- package/dist/{index-B1hFhK1K.d.cts → index-CpZKtdMw.d.cts} +1 -1
- package/dist/{index-BO6t0HjV.d.cts → index-CqSJ25A9.d.cts} +1 -1
- package/dist/{index-Jgl7ev9I.d.cts → index-CzC0G0C3.d.cts} +9 -9
- package/dist/{index-p0bkNfby.d.cts → index-D6JRP-1_.d.cts} +3 -3
- package/dist/{index-D23g00HE.d.cts → index-D7r_vd0b.d.cts} +4 -4
- package/dist/{index-Cp91Sxbo.d.cts → index-D8IyqHvT.d.cts} +3 -3
- package/dist/{index-iKsmdnq6.d.cts → index-D9qoEOj_.d.cts} +2 -2
- package/dist/index-DBmBtqAN.d.ts +461 -0
- package/dist/{index-nP13Qe6T.d.ts → index-DFe2Pk2u.d.ts} +1 -1
- package/dist/{index-Cn3taOmp.d.cts → index-DKp1CIbG.d.cts} +2 -2
- package/dist/{index-CoR-tOZA.d.cts → index-DSD6xnbT.d.ts} +8 -7
- package/dist/{index-DheNs40A.d.ts → index-DXSLMoma.d.ts} +2 -2
- package/dist/{index-ZIQaKIdY.d.cts → index-DXZsXxtU.d.cts} +47 -32
- package/dist/{index-BVTjuKeP.d.cts → index-D_QQ_dTD.d.cts} +1 -1
- package/dist/{index-ChZvMC4M.d.cts → index-DeyzuqAi.d.cts} +7 -7
- package/dist/{index-Chi9IiHJ.d.ts → index-DlccEIi3.d.ts} +3 -3
- package/dist/{index-DR3XqZlV.d.cts → index-DmtWMP0X.d.cts} +1 -1
- package/dist/{index-CbCNoogR.d.ts → index-Dp69u0ym.d.ts} +16 -15
- package/dist/{index-b4a6Sg0R.d.ts → index-DwNNufVa.d.ts} +4 -4
- package/dist/{index-D80nGRb9.d.ts → index-DzYTXMBz.d.ts} +3 -3
- package/dist/index-DzgS5uYi.d.ts +26 -0
- package/dist/{index-B-KCkW4M.d.cts → index-GaW6Welt.d.cts} +4 -4
- package/dist/{index-DupIl9wI.d.ts → index-JYtN9uqM.d.ts} +1 -1
- package/dist/{index-Ced0dphF.d.ts → index-KNAMYngu.d.ts} +9 -9
- package/dist/{index-BpjQanLs.d.cts → index-PluovH45.d.cts} +2 -2
- package/dist/index-Qq-G9B6g.d.cts +171 -0
- package/dist/{index-yJY9thRY.d.cts → index-XxSeddWP.d.cts} +2 -2
- package/dist/{index-C8_bnDBZ.d.cts → index-ZhKyR8co.d.cts} +3 -3
- package/dist/index-hXKhbfh-.d.ts +287 -0
- package/dist/index-zK_mN1D-.d.cts +461 -0
- package/dist/index.cjs +59 -59
- package/dist/index.d.cts +53 -49
- package/dist/index.d.ts +53 -49
- package/dist/index.js +1 -1
- package/dist/{meta-BdjSt8ky.d.cts → meta-BGO6C7K9.d.cts} +1 -1
- package/dist/{meta-CtDjj7cU.d.ts → meta-CC6EPdpK.d.ts} +1 -1
- package/dist/{node-8qx0kgYt.d.cts → node-fSc-hCv8.d.cts} +1 -1
- package/dist/{node-8qx0kgYt.d.ts → node-fSc-hCv8.d.ts} +1 -1
- package/dist/{observable-B6Ba-TTI.d.cts → observable-Cqty11jG.d.cts} +1 -1
- package/dist/{observable-DOniYM2B.d.ts → observable-EAV_rNfM.d.ts} +1 -1
- package/dist/patterns/ai/browser.cjs +5 -5
- package/dist/patterns/ai/browser.d.cts +4 -4
- package/dist/patterns/ai/browser.d.ts +4 -4
- package/dist/patterns/ai/browser.js +1 -1
- package/dist/patterns/ai/index.cjs +19 -19
- package/dist/patterns/ai/index.d.cts +19 -17
- package/dist/patterns/ai/index.d.ts +19 -17
- package/dist/patterns/ai/index.js +1 -1
- package/dist/patterns/ai/node.cjs +1 -2
- package/dist/patterns/ai/node.d.cts +9 -9
- package/dist/patterns/ai/node.d.ts +9 -9
- package/dist/patterns/ai/node.js +1 -1
- package/dist/patterns/audit/index.cjs +6 -6
- package/dist/patterns/audit/index.d.cts +7 -5
- package/dist/patterns/audit/index.d.ts +7 -5
- package/dist/patterns/audit/index.js +1 -1
- package/dist/patterns/cqrs/index.cjs +7 -7
- package/dist/patterns/cqrs/index.d.cts +7 -4
- package/dist/patterns/cqrs/index.d.ts +7 -4
- package/dist/patterns/cqrs/index.js +1 -1
- package/dist/patterns/demo-shell/index.cjs +8 -8
- package/dist/patterns/demo-shell/index.d.cts +6 -5
- package/dist/patterns/demo-shell/index.d.ts +6 -5
- package/dist/patterns/demo-shell/index.js +1 -1
- package/dist/patterns/domain-templates/index.cjs +5 -5
- package/dist/patterns/domain-templates/index.d.cts +5 -4
- package/dist/patterns/domain-templates/index.d.ts +5 -4
- package/dist/patterns/domain-templates/index.js +1 -1
- package/dist/patterns/graphspec/index.cjs +20 -20
- package/dist/patterns/graphspec/index.d.cts +6 -5
- package/dist/patterns/graphspec/index.d.ts +6 -5
- package/dist/patterns/graphspec/index.js +1 -1
- package/dist/patterns/guarded-execution/index.cjs +7 -7
- package/dist/patterns/guarded-execution/index.d.cts +8 -6
- package/dist/patterns/guarded-execution/index.d.ts +8 -6
- package/dist/patterns/guarded-execution/index.js +1 -1
- package/dist/patterns/harness/index.cjs +12 -12
- package/dist/patterns/harness/index.d.cts +13 -10
- package/dist/patterns/harness/index.d.ts +13 -10
- package/dist/patterns/harness/index.js +1 -1
- package/dist/patterns/job-queue/index.cjs +7 -7
- package/dist/patterns/job-queue/index.d.cts +8 -4
- package/dist/patterns/job-queue/index.d.ts +8 -4
- package/dist/patterns/job-queue/index.js +1 -1
- package/dist/patterns/lens/index.cjs +4 -4
- package/dist/patterns/lens/index.d.cts +7 -6
- package/dist/patterns/lens/index.d.ts +7 -6
- package/dist/patterns/lens/index.js +1 -1
- package/dist/patterns/memory/index.cjs +1 -1
- package/dist/patterns/memory/index.d.cts +5 -4
- package/dist/patterns/memory/index.d.ts +5 -4
- package/dist/patterns/memory/index.js +1 -1
- package/dist/patterns/messaging/index.cjs +7 -7
- package/dist/patterns/messaging/index.d.cts +6 -4
- package/dist/patterns/messaging/index.d.ts +6 -4
- package/dist/patterns/messaging/index.js +1 -1
- package/dist/patterns/orchestration/index.cjs +7 -7
- package/dist/patterns/orchestration/index.d.cts +8 -5
- package/dist/patterns/orchestration/index.d.ts +8 -5
- package/dist/patterns/orchestration/index.js +1 -1
- package/dist/patterns/process/index.cjs +1 -0
- package/dist/patterns/process/index.d.cts +10 -0
- package/dist/patterns/process/index.d.ts +10 -0
- package/dist/patterns/process/index.js +1 -0
- package/dist/patterns/reactive-layout/index.cjs +5 -5
- package/dist/patterns/reactive-layout/index.d.cts +6 -5
- package/dist/patterns/reactive-layout/index.d.ts +6 -5
- package/dist/patterns/reactive-layout/index.js +1 -1
- package/dist/patterns/reduction/index.cjs +1 -1
- package/dist/patterns/reduction/index.d.cts +5 -4
- package/dist/patterns/reduction/index.d.ts +5 -4
- package/dist/patterns/reduction/index.js +1 -1
- package/dist/patterns/refine-loop/index.cjs +8 -8
- package/dist/patterns/refine-loop/index.d.cts +7 -5
- package/dist/patterns/refine-loop/index.d.ts +7 -5
- package/dist/patterns/refine-loop/index.js +1 -1
- package/dist/patterns/resilient-pipeline/index.cjs +1 -1
- package/dist/patterns/resilient-pipeline/index.d.cts +7 -6
- package/dist/patterns/resilient-pipeline/index.d.ts +7 -6
- package/dist/patterns/resilient-pipeline/index.js +1 -1
- package/dist/patterns/surface/index.cjs +11 -11
- package/dist/patterns/surface/index.d.cts +7 -6
- package/dist/patterns/surface/index.d.ts +7 -6
- package/dist/patterns/surface/index.js +1 -1
- package/dist/pipeline-graph-B85HUrWg.d.cts +120 -0
- package/dist/pipeline-graph-HOTU4UG0.d.ts +120 -0
- package/dist/{reactive-layout-DBJ3Vz-m.d.ts → reactive-layout-Btv0-efV.d.ts} +2 -2
- package/dist/{reactive-layout-Dk9AOQb_.d.cts → reactive-layout-D9zqqaqK.d.cts} +2 -2
- package/dist/reactive-log-ByBb8g6A.d.ts +188 -0
- package/dist/reactive-log-CgbNqksB.d.cts +188 -0
- package/dist/{reactive-map-LjwjcFaW.d.ts → reactive-map-CHyeCf4D.d.ts} +1 -1
- package/dist/{reactive-map-Cm89Hk0c.d.cts → reactive-map-DmgeADH8.d.cts} +1 -1
- package/dist/{resilience-RjDIHZNZ.d.ts → resilience-BWP2c7Af.d.cts} +27 -45
- package/dist/{resilience-N_VtLf7W.d.cts → resilience-Bys63Cpd.d.ts} +27 -45
- package/dist/resilience-OBU472D2.js +1 -0
- package/dist/{sugar-CQkn_rxB.d.ts → sugar-D13E2M_z.d.ts} +1 -1
- package/dist/{sugar-DVEYhR7a.d.cts → sugar-DgaGJcI6.d.cts} +1 -1
- package/dist/{topology-tree-BB6oJxMz.d.cts → topology-tree-C50l9ARE.d.cts} +1 -1
- package/dist/{topology-tree-CAFOG5S5.d.ts → topology-tree-CJsT24DP.d.ts} +1 -1
- package/dist/{types-Cp_4coR_.d.cts → types-BMSGPlpO.d.cts} +1 -1
- package/dist/{types-B2LfBvNc.d.ts → types-CidcBDuk.d.ts} +1 -1
- package/package.json +41 -1
- package/dist/chunk-2JO6LXFT.js +0 -7
- package/dist/chunk-2LZ6DL45.js +0 -1
- package/dist/chunk-3JXNEPCD.js +0 -2
- package/dist/chunk-3Y4BXFFR.js +0 -1
- package/dist/chunk-55T3K37W.js +0 -1
- package/dist/chunk-6HQ6HVTF.js +0 -1
- package/dist/chunk-7Q2WPFQ7.js +0 -1
- package/dist/chunk-FKRPIRE6.js +0 -1
- package/dist/chunk-HTBOCKVD.js +0 -1
- package/dist/chunk-I6VIH3VA.js +0 -1
- package/dist/chunk-IB64M7VP.js +0 -1
- package/dist/chunk-IJFSR4NU.js +0 -1
- package/dist/chunk-LOF5HSD3.js +0 -18
- package/dist/chunk-T2TB37TW.js +0 -1
- package/dist/chunk-T7EQPKOP.js +0 -1
- package/dist/chunk-Y63GWRHO.js +0 -5
- package/dist/chunk-YUBV7EEE.js +0 -1
- package/dist/index-C2Dey3L-.d.cts +0 -152
- package/dist/index-ClJUZAOr.d.cts +0 -101
- package/dist/index-Cq7Uqgu4.d.ts +0 -192
- package/dist/index-Dtpr2FIB.d.ts +0 -101
- package/dist/index-HvJ90_tX.d.ts +0 -152
- package/dist/index-wcfc7W-f.d.cts +0 -192
- package/dist/reactive-log-CWC7jO4J.d.cts +0 -190
- package/dist/reactive-log-CqaBg8nf.d.ts +0 -190
- package/dist/resilience-7UZHSSGC.js +0 -1
- /package/dist/{chunk-L3KUKDZC.js → chunk-O32GJOUJ.js} +0 -0
|
@@ -0,0 +1,284 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Storage tier architecture (Audit 4 — locked 2026-04-24).
|
|
3
|
+
*
|
|
4
|
+
* Three-layer design:
|
|
5
|
+
*
|
|
6
|
+
* - **Layer 1 — {@link StorageBackend}:** generic bytes-level kv I/O. One
|
|
7
|
+
* `read(key) → Uint8Array | undefined`, `write(key, bytes)`, optional
|
|
8
|
+
* `delete(key)` / `list(prefix)`. No tier-level concerns (debounce, codec).
|
|
9
|
+
* - **Layer 2 — Tier specializations** layered over a backend, parametric over
|
|
10
|
+
* `T`: {@link SnapshotStorageTier} (one snapshot under one key) and
|
|
11
|
+
* {@link AppendLogStorageTier} (sequential entries, optional partition via
|
|
12
|
+
* `keyOf`). Both extend {@link BaseStorageTier} which carries
|
|
13
|
+
* `flush?` / `rollback?` for the wave-as-transaction model.
|
|
14
|
+
* - **Layer 3 — High-level wiring:** `Graph.attachSnapshotStorage(tiers)`,
|
|
15
|
+
* `reactiveLog.attachStorage(tiers)`, `cqrsGraph.attachEventStorage(tiers)`,
|
|
16
|
+
* `jobQueueGraph.attachEventStorage(tiers)`. These layers consume tier
|
|
17
|
+
* specializations directly — they don't see the backend.
|
|
18
|
+
*
|
|
19
|
+
* Browser-safe by default. {@link memoryBackend} + the in-memory factories
|
|
20
|
+
* live here; Node-only (`fileBackend` / `sqliteBackend`) lives in
|
|
21
|
+
* `extra/storage-node.ts`; browser-only (`indexedDbBackend`) lives in
|
|
22
|
+
* `extra/storage-browser.ts`.
|
|
23
|
+
*
|
|
24
|
+
* @module
|
|
25
|
+
*/
|
|
26
|
+
/**
|
|
27
|
+
* Bytes-level kv backend. One responsibility: read/write byte ranges under
|
|
28
|
+
* string keys. Tier specializations layer on top.
|
|
29
|
+
*
|
|
30
|
+
* @category extra
|
|
31
|
+
*/
|
|
32
|
+
interface StorageBackend {
|
|
33
|
+
/** Diagnostic name (e.g., `"memory"`, `"file:./checkpoints"`). */
|
|
34
|
+
readonly name: string;
|
|
35
|
+
/** Read raw bytes; returns `undefined` on miss. */
|
|
36
|
+
read(key: string): Uint8Array | undefined | Promise<Uint8Array | undefined>;
|
|
37
|
+
/** Write raw bytes. Sync backends return `void`; async return `Promise<void>`. */
|
|
38
|
+
write(key: string, bytes: Uint8Array): void | Promise<void>;
|
|
39
|
+
/** Optional delete-by-key. */
|
|
40
|
+
delete?(key: string): void | Promise<void>;
|
|
41
|
+
/** Optional enumeration; `prefix` filters keys. */
|
|
42
|
+
list?(prefix?: string): readonly string[] | Promise<readonly string[]>;
|
|
43
|
+
/** Optional drain hook — adapter authors implement when buffering writes. */
|
|
44
|
+
flush?(): Promise<void>;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Codec for tier serialization. Tiers call `encode(value) → bytes` before
|
|
48
|
+
* `backend.write` and `decode(bytes) → value` after `backend.read`.
|
|
49
|
+
*
|
|
50
|
+
* @category extra
|
|
51
|
+
*/
|
|
52
|
+
interface Codec<T = unknown> {
|
|
53
|
+
readonly name: string;
|
|
54
|
+
readonly version: number;
|
|
55
|
+
encode(value: T): Uint8Array;
|
|
56
|
+
decode(bytes: Uint8Array): T;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Default JSON codec — UTF-8 text, stable key order (via `stableJsonString`).
|
|
60
|
+
* Any value JSON-serializable is supported.
|
|
61
|
+
*
|
|
62
|
+
* @category extra
|
|
63
|
+
*/
|
|
64
|
+
declare const jsonCodec: Codec<unknown>;
|
|
65
|
+
/** Build a `Codec<T>` over the default JSON encoding. Pure typing helper. */
|
|
66
|
+
declare function jsonCodecFor<T>(): Codec<T>;
|
|
67
|
+
/**
|
|
68
|
+
* Common tier surface: name + cadence knobs + transaction lifecycle.
|
|
69
|
+
*
|
|
70
|
+
* Lifecycle hooks (`flush` / `rollback`) implement Audit 4's "one wave = one
|
|
71
|
+
* transaction" model. Framework integration:
|
|
72
|
+
* - After every wave (and on `batch()` close), framework iterates attached
|
|
73
|
+
* tiers and calls `tier.flush()` if exposed.
|
|
74
|
+
* - On wave-throw (per C.2 F rollback policy), framework calls
|
|
75
|
+
* `tier.rollback()` if exposed — pending writes discarded.
|
|
76
|
+
* - Cross-tier atomicity is best-effort. Each tier is its own transaction.
|
|
77
|
+
*
|
|
78
|
+
* @category extra
|
|
79
|
+
*/
|
|
80
|
+
interface BaseStorageTier {
|
|
81
|
+
readonly name: string;
|
|
82
|
+
/** Debounce window (ms). `0` = sync-through; >0 batches across waves. */
|
|
83
|
+
readonly debounceMs?: number;
|
|
84
|
+
/** Force flush every Nth write regardless of debounce. */
|
|
85
|
+
readonly compactEvery?: number;
|
|
86
|
+
/** Commit pending; framework calls at wave-close / debounce-fire. */
|
|
87
|
+
flush?(): Promise<void>;
|
|
88
|
+
/** Discard pending; framework calls on wave-throw. */
|
|
89
|
+
rollback?(): Promise<void>;
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Snapshot tier — writes a single record per `save(snapshot)` call.
|
|
93
|
+
*
|
|
94
|
+
* The tier maps the snapshot to a backend key via `keyOf(snapshot)` (default
|
|
95
|
+
* `() => name ?? "snapshot"`). For `Graph.attachSnapshotStorage`, the framework
|
|
96
|
+
* supplies a closure that pulls the graph name out of the record envelope.
|
|
97
|
+
*
|
|
98
|
+
* @category extra
|
|
99
|
+
*/
|
|
100
|
+
interface SnapshotStorageTier<T = unknown> extends BaseStorageTier {
|
|
101
|
+
save(snapshot: T): void | Promise<void>;
|
|
102
|
+
load?(): T | Promise<T | undefined> | undefined;
|
|
103
|
+
/** Skip-save policy — return `false` to skip persisting this snapshot. */
|
|
104
|
+
filter?: (snapshot: T) => boolean;
|
|
105
|
+
/** Extract the backend key per-snapshot; default `() => name ?? "snapshot"`. */
|
|
106
|
+
keyOf?: (snapshot: T) => string;
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* Append-log tier — bulk-friendly entry persistence with optional partitioning.
|
|
110
|
+
*
|
|
111
|
+
* Entries are appended to a logical stream; `keyOf?` partitions across backend
|
|
112
|
+
* keys (e.g., `(e) => `${e.type}::${e.aggregateId}`` for CQRS).
|
|
113
|
+
*
|
|
114
|
+
* @category extra
|
|
115
|
+
*/
|
|
116
|
+
interface AppendLogStorageTier<T = unknown> extends BaseStorageTier {
|
|
117
|
+
appendEntries(entries: readonly T[]): void | Promise<void>;
|
|
118
|
+
loadEntries?(opts?: {
|
|
119
|
+
cursor?: AppendCursor;
|
|
120
|
+
pageSize?: number;
|
|
121
|
+
keyFilter?: string;
|
|
122
|
+
}): AppendLoadResult<T> | Promise<AppendLoadResult<T>>;
|
|
123
|
+
/** Partition key per-entry (default `() => name ?? "append-log"`). */
|
|
124
|
+
keyOf?: (entry: T) => string;
|
|
125
|
+
}
|
|
126
|
+
/** Opaque cursor for windowed `loadEntries` pagination. */
|
|
127
|
+
type AppendCursor = Readonly<{
|
|
128
|
+
position: number;
|
|
129
|
+
tag?: string;
|
|
130
|
+
}> & {
|
|
131
|
+
readonly __brand: "AppendCursor";
|
|
132
|
+
};
|
|
133
|
+
type AppendLoadResult<T> = {
|
|
134
|
+
entries: readonly T[];
|
|
135
|
+
cursor: AppendCursor | undefined;
|
|
136
|
+
};
|
|
137
|
+
/**
|
|
138
|
+
* In-process bytes backend backed by `Map<string, Uint8Array>`. Useful for
|
|
139
|
+
* tests, hot tiers, and as a default for the convenience factories below.
|
|
140
|
+
*
|
|
141
|
+
* @category extra
|
|
142
|
+
*/
|
|
143
|
+
declare function memoryBackend(): StorageBackend;
|
|
144
|
+
type SnapshotStorageOptions<T> = {
|
|
145
|
+
name?: string;
|
|
146
|
+
codec?: Codec<T>;
|
|
147
|
+
debounceMs?: number;
|
|
148
|
+
compactEvery?: number;
|
|
149
|
+
filter?: (snapshot: T) => boolean;
|
|
150
|
+
keyOf?: (snapshot: T) => string;
|
|
151
|
+
};
|
|
152
|
+
/**
|
|
153
|
+
* Wrap a {@link StorageBackend} as a typed snapshot tier.
|
|
154
|
+
*
|
|
155
|
+
* Buffer model: `save(snapshot)` accumulates one pending snapshot in memory.
|
|
156
|
+
* `flush()` encodes via codec and writes to the backend under
|
|
157
|
+
* `keyOf(snapshot)` (default `name ?? "snapshot"`). `rollback()` discards
|
|
158
|
+
* the pending write.
|
|
159
|
+
*
|
|
160
|
+
* @category extra
|
|
161
|
+
*/
|
|
162
|
+
declare function snapshotStorage<T>(backend: StorageBackend, opts?: SnapshotStorageOptions<T>): SnapshotStorageTier<T>;
|
|
163
|
+
type AppendLogStorageOptions<T> = {
|
|
164
|
+
name?: string;
|
|
165
|
+
codec?: Codec<readonly T[]>;
|
|
166
|
+
keyOf?: (entry: T) => string;
|
|
167
|
+
debounceMs?: number;
|
|
168
|
+
compactEvery?: number;
|
|
169
|
+
};
|
|
170
|
+
/**
|
|
171
|
+
* Wrap a {@link StorageBackend} as a typed append-log tier.
|
|
172
|
+
*
|
|
173
|
+
* Buffer model: `appendEntries(entries)` accumulates per-key buckets in
|
|
174
|
+
* memory. `flush()` encodes each bucket as a JSON array via codec and writes
|
|
175
|
+
* under that bucket key. `rollback()` discards pending appends.
|
|
176
|
+
*
|
|
177
|
+
* Storage shape: each backend key holds a JSON array of all entries for that
|
|
178
|
+
* partition, growing on every flush. Adapters that need true append semantics
|
|
179
|
+
* (versus rewrite) should layer their own tier impl over the same backend.
|
|
180
|
+
*
|
|
181
|
+
* @category extra
|
|
182
|
+
*/
|
|
183
|
+
declare function appendLogStorage<T>(backend: StorageBackend, opts?: AppendLogStorageOptions<T>): AppendLogStorageTier<T>;
|
|
184
|
+
/**
|
|
185
|
+
* Key-value tier — typed records under arbitrary string keys with codec
|
|
186
|
+
* serialization at the storage-tier boundary. Use for content-addressed
|
|
187
|
+
* caches (replay), multi-record archives (snapshot index, AI memory), and
|
|
188
|
+
* fixture stores. Snapshot tier is "one record"; append-log is "sequential
|
|
189
|
+
* entries"; kv is "many records, addressable by key".
|
|
190
|
+
*
|
|
191
|
+
* @category extra
|
|
192
|
+
*/
|
|
193
|
+
interface KvStorageTier<T = unknown> extends BaseStorageTier {
|
|
194
|
+
load(key: string): T | undefined | Promise<T | undefined>;
|
|
195
|
+
save(key: string, value: T): void | Promise<void>;
|
|
196
|
+
delete?(key: string): void | Promise<void>;
|
|
197
|
+
list?(prefix?: string): readonly string[] | Promise<readonly string[]>;
|
|
198
|
+
/** Pre-save filter — return `false` to skip persisting this record. */
|
|
199
|
+
filter?: (key: string, value: T) => boolean;
|
|
200
|
+
}
|
|
201
|
+
type KvStorageOptions<T> = {
|
|
202
|
+
name?: string;
|
|
203
|
+
codec?: Codec<T>;
|
|
204
|
+
debounceMs?: number;
|
|
205
|
+
compactEvery?: number;
|
|
206
|
+
filter?: (key: string, value: T) => boolean;
|
|
207
|
+
};
|
|
208
|
+
/**
|
|
209
|
+
* Wrap a {@link StorageBackend} as a typed kv tier.
|
|
210
|
+
*
|
|
211
|
+
* Buffer model: `save(k, v)` encodes via codec and writes to the backend
|
|
212
|
+
* unless debounced. Pending writes are committed on `flush()` and discarded
|
|
213
|
+
* on `rollback()` — the wave-as-transaction model.
|
|
214
|
+
*
|
|
215
|
+
* @category extra
|
|
216
|
+
*/
|
|
217
|
+
declare function kvStorage<T>(backend: StorageBackend, opts?: KvStorageOptions<T>): KvStorageTier<T>;
|
|
218
|
+
/**
|
|
219
|
+
* In-memory snapshot tier — `snapshotStorage(memoryBackend(), opts)`.
|
|
220
|
+
*
|
|
221
|
+
* @category extra
|
|
222
|
+
*/
|
|
223
|
+
declare function memorySnapshot<T>(opts?: Omit<SnapshotStorageOptions<T>, "name"> & {
|
|
224
|
+
name?: string;
|
|
225
|
+
}): SnapshotStorageTier<T>;
|
|
226
|
+
/**
|
|
227
|
+
* In-memory append-log tier — `appendLogStorage(memoryBackend(), opts)`.
|
|
228
|
+
*
|
|
229
|
+
* @category extra
|
|
230
|
+
*/
|
|
231
|
+
declare function memoryAppendLog<T>(opts?: Omit<AppendLogStorageOptions<T>, "name"> & {
|
|
232
|
+
name?: string;
|
|
233
|
+
}): AppendLogStorageTier<T>;
|
|
234
|
+
/**
|
|
235
|
+
* In-memory kv tier — `kvStorage(memoryBackend(), opts)`.
|
|
236
|
+
*
|
|
237
|
+
* @category extra
|
|
238
|
+
*/
|
|
239
|
+
declare function memoryKv<T>(opts?: Omit<KvStorageOptions<T>, "name"> & {
|
|
240
|
+
name?: string;
|
|
241
|
+
}): KvStorageTier<T>;
|
|
242
|
+
/**
|
|
243
|
+
* Dict-backed kv tier — wraps a caller-owned plain object as a
|
|
244
|
+
* {@link StorageBackend} and returns a kv tier over it. Useful for
|
|
245
|
+
* embedding in a parent state shape or for tests that need access to the
|
|
246
|
+
* raw bytes.
|
|
247
|
+
*
|
|
248
|
+
* The dict stores raw encoded bytes as `Uint8Array`. Use `opts.name` to
|
|
249
|
+
* control the tier's diagnostic name (defaults to `"dict-kv"`).
|
|
250
|
+
*
|
|
251
|
+
* @example
|
|
252
|
+
* ```ts
|
|
253
|
+
* const store: Record<string, Uint8Array> = {};
|
|
254
|
+
* const tier = dictKv<MyRecord>(store);
|
|
255
|
+
* await tier.save("key1", myRecord);
|
|
256
|
+
* ```
|
|
257
|
+
*
|
|
258
|
+
* @category extra
|
|
259
|
+
*/
|
|
260
|
+
declare function dictKv<T>(storage: Record<string, Uint8Array>, opts?: Omit<KvStorageOptions<T>, "name"> & {
|
|
261
|
+
name?: string;
|
|
262
|
+
}): KvStorageTier<T>;
|
|
263
|
+
/**
|
|
264
|
+
* Dict-backed snapshot tier — wraps a caller-owned plain object as a
|
|
265
|
+
* {@link StorageBackend} and returns a snapshot tier over it. Useful for
|
|
266
|
+
* embedding checkpoints inside a parent state shape or for tests that need
|
|
267
|
+
* access to the raw bytes.
|
|
268
|
+
*
|
|
269
|
+
* The dict stores raw JSON bytes as `Uint8Array`. Use `opts.name` to control
|
|
270
|
+
* the storage key (defaults to `"snapshot"`).
|
|
271
|
+
*
|
|
272
|
+
* @example
|
|
273
|
+
* ```ts
|
|
274
|
+
* const store: Record<string, Uint8Array> = {};
|
|
275
|
+
* graph.attachSnapshotStorage([dictSnapshot(store, { name: graph.name })]);
|
|
276
|
+
* ```
|
|
277
|
+
*
|
|
278
|
+
* @category extra
|
|
279
|
+
*/
|
|
280
|
+
declare function dictSnapshot<T>(storage: Record<string, Uint8Array>, opts?: Omit<SnapshotStorageOptions<T>, "name"> & {
|
|
281
|
+
name?: string;
|
|
282
|
+
}): SnapshotStorageTier<T>;
|
|
283
|
+
|
|
284
|
+
export { type AppendCursor, type AppendLoadResult, type AppendLogStorageOptions, type AppendLogStorageTier, type BaseStorageTier, type Codec, type KvStorageOptions, type KvStorageTier, type SnapshotStorageOptions, type SnapshotStorageTier, type StorageBackend, appendLogStorage, dictKv, dictSnapshot, jsonCodec, jsonCodecFor, kvStorage, memoryAppendLog, memoryBackend, memoryKv, memorySnapshot, snapshotStorage };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a,b,c,d,e,f,g,h,i,j,k}from"../chunk-D5RFJOZ2.js";import"../chunk-CE72X3WO.js";import"../chunk-QYADASLV.js";export{e as appendLogStorage,j as dictKv,k as dictSnapshot,a as jsonCodec,b as jsonCodecFor,f as kvStorage,h as memoryAppendLog,c as memoryBackend,i as memoryKv,g as memorySnapshot,d as snapshotStorage};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { C as ChatMessage, a as LLMInvokeOptions, L as LLMAdapter, b as LLMResponse, S as StreamDelta } from './types-
|
|
3
|
-
import { d as canonicalJson$1 } from './content-addressed-storage-
|
|
1
|
+
import { KvStorageTier } from './extra/storage-tiers.js';
|
|
2
|
+
import { C as ChatMessage, a as LLMInvokeOptions, L as LLMAdapter, b as LLMResponse, S as StreamDelta } from './types-CidcBDuk.js';
|
|
3
|
+
import { d as canonicalJson$1 } from './content-addressed-storage-DuYMjV7o.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* `withReplayCache` — content-addressed response cache over `
|
|
6
|
+
* `withReplayCache` — content-addressed response cache over `KvStorageTier`.
|
|
7
7
|
*
|
|
8
8
|
* - Key: sha256 of canonicalized (messages + invoke options minus `signal`).
|
|
9
9
|
* - `"read-write"` (default): returns cached response if present; on miss,
|
|
@@ -15,8 +15,8 @@ import { d as canonicalJson$1 } from './content-addressed-storage-BUiREIuj.js';
|
|
|
15
15
|
* fallback adapters where any cache miss is a test failure or a signal to
|
|
16
16
|
* degrade.
|
|
17
17
|
*
|
|
18
|
-
* Reuses the library's existing `
|
|
19
|
-
*
|
|
18
|
+
* Reuses the library's existing `KvStorageTier` abstraction — any kv tier
|
|
19
|
+
* (memoryKv / fileKv / sqliteKv / indexedDbKv / custom).
|
|
20
20
|
*
|
|
21
21
|
* **Concurrent cache-miss dedup:** uses `singleFromAny` so two concurrent
|
|
22
22
|
* calls with the same key share one upstream request. Second caller sees the
|
|
@@ -53,7 +53,7 @@ interface ReplayCacheKeyContext {
|
|
|
53
53
|
readonly context: unknown;
|
|
54
54
|
}
|
|
55
55
|
interface WithReplayCacheOptions {
|
|
56
|
-
storage:
|
|
56
|
+
storage: KvStorageTier;
|
|
57
57
|
mode?: ReplayCacheMode;
|
|
58
58
|
/**
|
|
59
59
|
* Custom key function. Receives a {@link ReplayCacheKeyContext} with the
|
|
@@ -127,8 +127,8 @@ declare const canonicalJson: typeof canonicalJson$1;
|
|
|
127
127
|
* canonical hash for messages-keyed entries at init time. Ideal when you
|
|
128
128
|
* want full control in code (tests, small demos).
|
|
129
129
|
*
|
|
130
|
-
* 2. **`fixturesStorage:
|
|
131
|
-
* Pass a `
|
|
130
|
+
* 2. **`fixturesStorage: KvStorageTier`** — the escape hatch for any backend.
|
|
131
|
+
* Pass a `memoryKv()`, `indexedDbKv(...)`, `sqliteKv(...)`,
|
|
132
132
|
* `cascadingCache(...)`, or a custom tier. You own the layout — no
|
|
133
133
|
* auto-namespacing.
|
|
134
134
|
*
|
|
@@ -198,19 +198,19 @@ interface FallbackAdapterOptions {
|
|
|
198
198
|
* Inline hand-authored fixtures. Supports both hash-keyed (`{key, response, stream?}`)
|
|
199
199
|
* and messages-keyed (`{messages, invokeOpts?, response}`) shapes — the adapter
|
|
200
200
|
* computes the canonical hash for messages-keyed entries at init time. Held in
|
|
201
|
-
* an internal `
|
|
201
|
+
* an internal `memoryKv`. Mutually exclusive with `fixturesDir` and
|
|
202
202
|
* `fixturesStorage`.
|
|
203
203
|
*/
|
|
204
204
|
readonly fixtures?: readonly FallbackFixture[];
|
|
205
205
|
/**
|
|
206
|
-
* Bring-your-own `
|
|
207
|
-
* `
|
|
206
|
+
* Bring-your-own `KvStorageTier` (`memoryKv`, `sqliteKv`,
|
|
207
|
+
* `indexedDbKv`, `cascadingCache`, or a custom tier). You own the
|
|
208
208
|
* layout — no auto-namespacing. Mutually exclusive with `fixtures`.
|
|
209
209
|
*
|
|
210
210
|
* For filesystem directories, use the node subpath's `fallbackAdapter`
|
|
211
211
|
* with its `fixturesDir` option (auto-namespaced + validated).
|
|
212
212
|
*/
|
|
213
|
-
readonly fixturesStorage?:
|
|
213
|
+
readonly fixturesStorage?: KvStorageTier;
|
|
214
214
|
/**
|
|
215
215
|
* Called on fixture miss when `onMiss === "respond"`. If not provided and
|
|
216
216
|
* `onMiss === "respond"`, a canned "service unavailable" response is
|
|
@@ -226,7 +226,7 @@ interface FallbackAdapterOptions {
|
|
|
226
226
|
*/
|
|
227
227
|
readonly record?: {
|
|
228
228
|
readonly adapter: LLMAdapter;
|
|
229
|
-
readonly storage?:
|
|
229
|
+
readonly storage?: KvStorageTier;
|
|
230
230
|
};
|
|
231
231
|
/** Stream replay speed multiplier. See {@link withReplayCache}. Default `1`. */
|
|
232
232
|
readonly replaySpeed?: number;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { C as ChatMessage, a as LLMInvokeOptions, L as LLMAdapter, b as LLMResponse, S as StreamDelta } from './types-
|
|
3
|
-
import { d as canonicalJson$1 } from './content-addressed-storage-
|
|
1
|
+
import { KvStorageTier } from './extra/storage-tiers.cjs';
|
|
2
|
+
import { C as ChatMessage, a as LLMInvokeOptions, L as LLMAdapter, b as LLMResponse, S as StreamDelta } from './types-BMSGPlpO.cjs';
|
|
3
|
+
import { d as canonicalJson$1 } from './content-addressed-storage-4-ST1tYk.cjs';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* `withReplayCache` — content-addressed response cache over `
|
|
6
|
+
* `withReplayCache` — content-addressed response cache over `KvStorageTier`.
|
|
7
7
|
*
|
|
8
8
|
* - Key: sha256 of canonicalized (messages + invoke options minus `signal`).
|
|
9
9
|
* - `"read-write"` (default): returns cached response if present; on miss,
|
|
@@ -15,8 +15,8 @@ import { d as canonicalJson$1 } from './content-addressed-storage-DqIWCmZG.cjs';
|
|
|
15
15
|
* fallback adapters where any cache miss is a test failure or a signal to
|
|
16
16
|
* degrade.
|
|
17
17
|
*
|
|
18
|
-
* Reuses the library's existing `
|
|
19
|
-
*
|
|
18
|
+
* Reuses the library's existing `KvStorageTier` abstraction — any kv tier
|
|
19
|
+
* (memoryKv / fileKv / sqliteKv / indexedDbKv / custom).
|
|
20
20
|
*
|
|
21
21
|
* **Concurrent cache-miss dedup:** uses `singleFromAny` so two concurrent
|
|
22
22
|
* calls with the same key share one upstream request. Second caller sees the
|
|
@@ -53,7 +53,7 @@ interface ReplayCacheKeyContext {
|
|
|
53
53
|
readonly context: unknown;
|
|
54
54
|
}
|
|
55
55
|
interface WithReplayCacheOptions {
|
|
56
|
-
storage:
|
|
56
|
+
storage: KvStorageTier;
|
|
57
57
|
mode?: ReplayCacheMode;
|
|
58
58
|
/**
|
|
59
59
|
* Custom key function. Receives a {@link ReplayCacheKeyContext} with the
|
|
@@ -127,8 +127,8 @@ declare const canonicalJson: typeof canonicalJson$1;
|
|
|
127
127
|
* canonical hash for messages-keyed entries at init time. Ideal when you
|
|
128
128
|
* want full control in code (tests, small demos).
|
|
129
129
|
*
|
|
130
|
-
* 2. **`fixturesStorage:
|
|
131
|
-
* Pass a `
|
|
130
|
+
* 2. **`fixturesStorage: KvStorageTier`** — the escape hatch for any backend.
|
|
131
|
+
* Pass a `memoryKv()`, `indexedDbKv(...)`, `sqliteKv(...)`,
|
|
132
132
|
* `cascadingCache(...)`, or a custom tier. You own the layout — no
|
|
133
133
|
* auto-namespacing.
|
|
134
134
|
*
|
|
@@ -198,19 +198,19 @@ interface FallbackAdapterOptions {
|
|
|
198
198
|
* Inline hand-authored fixtures. Supports both hash-keyed (`{key, response, stream?}`)
|
|
199
199
|
* and messages-keyed (`{messages, invokeOpts?, response}`) shapes — the adapter
|
|
200
200
|
* computes the canonical hash for messages-keyed entries at init time. Held in
|
|
201
|
-
* an internal `
|
|
201
|
+
* an internal `memoryKv`. Mutually exclusive with `fixturesDir` and
|
|
202
202
|
* `fixturesStorage`.
|
|
203
203
|
*/
|
|
204
204
|
readonly fixtures?: readonly FallbackFixture[];
|
|
205
205
|
/**
|
|
206
|
-
* Bring-your-own `
|
|
207
|
-
* `
|
|
206
|
+
* Bring-your-own `KvStorageTier` (`memoryKv`, `sqliteKv`,
|
|
207
|
+
* `indexedDbKv`, `cascadingCache`, or a custom tier). You own the
|
|
208
208
|
* layout — no auto-namespacing. Mutually exclusive with `fixtures`.
|
|
209
209
|
*
|
|
210
210
|
* For filesystem directories, use the node subpath's `fallbackAdapter`
|
|
211
211
|
* with its `fixturesDir` option (auto-namespaced + validated).
|
|
212
212
|
*/
|
|
213
|
-
readonly fixturesStorage?:
|
|
213
|
+
readonly fixturesStorage?: KvStorageTier;
|
|
214
214
|
/**
|
|
215
215
|
* Called on fixture miss when `onMiss === "respond"`. If not provided and
|
|
216
216
|
* `onMiss === "respond"`, a canned "service unavailable" response is
|
|
@@ -226,7 +226,7 @@ interface FallbackAdapterOptions {
|
|
|
226
226
|
*/
|
|
227
227
|
readonly record?: {
|
|
228
228
|
readonly adapter: LLMAdapter;
|
|
229
|
-
readonly storage?:
|
|
229
|
+
readonly storage?: KvStorageTier;
|
|
230
230
|
};
|
|
231
231
|
/** Stream replay speed multiplier. See {@link withReplayCache}. Default `1`. */
|
|
232
232
|
readonly replaySpeed?: number;
|