@typicalday/firegraph 0.15.0 → 0.16.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.
Files changed (57) hide show
  1. package/README.md +39 -17
  2. package/dist/{backend-CvImIwTY.d.cts → backend-CE3pM9-T.d.ts} +32 -2
  3. package/dist/{backend-BpYLdwCW.d.cts → backend-DNzv8KSR.d.cts} +33 -19
  4. package/dist/{backend-BpYLdwCW.d.ts → backend-DNzv8KSR.d.ts} +33 -19
  5. package/dist/{backend-YH5HtawN.d.ts → backend-EjFfw9yO.d.cts} +32 -2
  6. package/dist/backend.cjs.map +1 -1
  7. package/dist/backend.d.cts +2 -2
  8. package/dist/backend.d.ts +2 -2
  9. package/dist/backend.js +1 -1
  10. package/dist/{chunk-FODIMIWY.js → chunk-5JBNLH5W.js} +17 -6
  11. package/dist/chunk-5JBNLH5W.js.map +1 -0
  12. package/dist/{chunk-5HIRYV2S.js → chunk-6IO74NKD.js} +12 -10
  13. package/dist/{chunk-5HIRYV2S.js.map → chunk-6IO74NKD.js.map} +1 -1
  14. package/dist/{chunk-ULRDQ6HZ.js → chunk-NZVSLWNY.js} +6 -1
  15. package/dist/chunk-NZVSLWNY.js.map +1 -0
  16. package/dist/{chunk-N5HFDWQX.js → chunk-PWIO46RT.js} +1 -1
  17. package/dist/{chunk-N5HFDWQX.js.map → chunk-PWIO46RT.js.map} +1 -1
  18. package/dist/{client-B5o39X79.d.ts → client-CNAwJayO.d.ts} +1 -1
  19. package/dist/{client-BGHwxwPg.d.cts → client-CaXH5D5C.d.cts} +1 -1
  20. package/dist/cloudflare/index.cjs +11 -9
  21. package/dist/cloudflare/index.cjs.map +1 -1
  22. package/dist/cloudflare/index.d.cts +3 -3
  23. package/dist/cloudflare/index.d.ts +3 -3
  24. package/dist/cloudflare/index.js +3 -3
  25. package/dist/codegen/index.d.cts +1 -1
  26. package/dist/codegen/index.d.ts +1 -1
  27. package/dist/firestore-enterprise/index.cjs +11 -9
  28. package/dist/firestore-enterprise/index.cjs.map +1 -1
  29. package/dist/firestore-enterprise/index.d.cts +3 -3
  30. package/dist/firestore-enterprise/index.d.ts +3 -3
  31. package/dist/firestore-enterprise/index.js +2 -2
  32. package/dist/firestore-standard/index.cjs +11 -9
  33. package/dist/firestore-standard/index.cjs.map +1 -1
  34. package/dist/firestore-standard/index.d.cts +3 -3
  35. package/dist/firestore-standard/index.d.ts +3 -3
  36. package/dist/firestore-standard/index.js +2 -2
  37. package/dist/index.cjs +11 -9
  38. package/dist/index.cjs.map +1 -1
  39. package/dist/index.d.cts +4 -4
  40. package/dist/index.d.ts +4 -4
  41. package/dist/index.js +1 -1
  42. package/dist/{registry-tKTb5Kx1.d.ts → registry-By1i-zge.d.ts} +1 -1
  43. package/dist/{registry-BGh7Jqpb.d.cts → registry-CNToyEra.d.cts} +1 -1
  44. package/dist/sqlite/index.cjs +24 -12
  45. package/dist/sqlite/index.cjs.map +1 -1
  46. package/dist/sqlite/index.d.cts +4 -4
  47. package/dist/sqlite/index.d.ts +4 -4
  48. package/dist/sqlite/index.js +4 -4
  49. package/dist/sqlite/local.cjs +474 -47
  50. package/dist/sqlite/local.cjs.map +1 -1
  51. package/dist/sqlite/local.d.cts +31 -5
  52. package/dist/sqlite/local.d.ts +31 -5
  53. package/dist/sqlite/local.js +429 -4
  54. package/dist/sqlite/local.js.map +1 -1
  55. package/package.json +1 -1
  56. package/dist/chunk-FODIMIWY.js.map +0 -1
  57. package/dist/chunk-ULRDQ6HZ.js.map +0 -1
@@ -1,7 +1,7 @@
1
- import { W as WritableRecord, f as WriteMode, U as UpdatePayload, p as GraphRegistry, I as IndexSpec, Q as QueryFilter, r as QueryOptions, A as AggregateSpec, s as CascadeResult, F as FindEdgesParams, t as BulkOptions, u as BulkResult, b as BulkUpdatePatch, E as ExpandParams, S as StorageBackend, B as BackendCapabilities, o as GraphClient, n as DynamicGraphClient, v as StoredGraphRecord, T as TransactionBackend, a as BatchBackend, q as GraphReader, e as ExpandResult, G as GraphClientOptions, m as DynamicRegistryConfig } from '../backend-BpYLdwCW.cjs';
2
- export { w as AggregateExtension, x as AggregateField, y as AggregateOp, z as AggregateResult, C as Capability, d as DmlExtension, J as JoinExtension, g as createCapabilities, h as deleteField, j as intersectCapabilities } from '../backend-BpYLdwCW.cjs';
1
+ import { W as WritableRecord, f as WriteMode, U as UpdatePayload, p as GraphRegistry, I as IndexSpec, Q as QueryFilter, r as QueryOptions, A as AggregateSpec, s as CascadeResult, F as FindEdgesParams, t as BulkOptions, u as BulkResult, b as BulkUpdatePatch, E as ExpandParams, S as StorageBackend, B as BackendCapabilities, o as GraphClient, n as DynamicGraphClient, v as StoredGraphRecord, T as TransactionBackend, a as BatchBackend, q as GraphReader, e as ExpandResult, G as GraphClientOptions, m as DynamicRegistryConfig } from '../backend-DNzv8KSR.cjs';
2
+ export { w as AggregateExtension, x as AggregateField, y as AggregateOp, z as AggregateResult, C as Capability, d as DmlExtension, J as JoinExtension, g as createCapabilities, h as deleteField, j as intersectCapabilities } from '../backend-DNzv8KSR.cjs';
3
3
  import { DurableObject } from 'cloudflare:workers';
4
- export { M as META_EDGE_TYPE, a as META_NODE_TYPE, c as createMergedRegistry, b as createRegistry, g as generateId } from '../registry-BGh7Jqpb.cjs';
4
+ export { M as META_EDGE_TYPE, a as META_NODE_TYPE, c as createMergedRegistry, b as createRegistry, g as generateId } from '../registry-CNToyEra.cjs';
5
5
  export { C as CapabilityNotSupportedError } from '../errors-BRc3I_eH.cjs';
6
6
  import '@google-cloud/firestore';
7
7
 
@@ -1,7 +1,7 @@
1
- import { W as WritableRecord, f as WriteMode, U as UpdatePayload, p as GraphRegistry, I as IndexSpec, Q as QueryFilter, r as QueryOptions, A as AggregateSpec, s as CascadeResult, F as FindEdgesParams, t as BulkOptions, u as BulkResult, b as BulkUpdatePatch, E as ExpandParams, S as StorageBackend, B as BackendCapabilities, o as GraphClient, n as DynamicGraphClient, v as StoredGraphRecord, T as TransactionBackend, a as BatchBackend, q as GraphReader, e as ExpandResult, G as GraphClientOptions, m as DynamicRegistryConfig } from '../backend-BpYLdwCW.js';
2
- export { w as AggregateExtension, x as AggregateField, y as AggregateOp, z as AggregateResult, C as Capability, d as DmlExtension, J as JoinExtension, g as createCapabilities, h as deleteField, j as intersectCapabilities } from '../backend-BpYLdwCW.js';
1
+ import { W as WritableRecord, f as WriteMode, U as UpdatePayload, p as GraphRegistry, I as IndexSpec, Q as QueryFilter, r as QueryOptions, A as AggregateSpec, s as CascadeResult, F as FindEdgesParams, t as BulkOptions, u as BulkResult, b as BulkUpdatePatch, E as ExpandParams, S as StorageBackend, B as BackendCapabilities, o as GraphClient, n as DynamicGraphClient, v as StoredGraphRecord, T as TransactionBackend, a as BatchBackend, q as GraphReader, e as ExpandResult, G as GraphClientOptions, m as DynamicRegistryConfig } from '../backend-DNzv8KSR.js';
2
+ export { w as AggregateExtension, x as AggregateField, y as AggregateOp, z as AggregateResult, C as Capability, d as DmlExtension, J as JoinExtension, g as createCapabilities, h as deleteField, j as intersectCapabilities } from '../backend-DNzv8KSR.js';
3
3
  import { DurableObject } from 'cloudflare:workers';
4
- export { M as META_EDGE_TYPE, a as META_NODE_TYPE, c as createMergedRegistry, b as createRegistry, g as generateId } from '../registry-tKTb5Kx1.js';
4
+ export { M as META_EDGE_TYPE, a as META_NODE_TYPE, c as createMergedRegistry, b as createRegistry, g as generateId } from '../registry-By1i-zge.js';
5
5
  export { C as CapabilityNotSupportedError } from '../errors-BRc3I_eH.js';
6
6
  import '@google-cloud/firestore';
7
7
 
@@ -16,12 +16,12 @@ import {
16
16
  decodeProjectedRow,
17
17
  rowTimestampToMillis,
18
18
  validateTableName
19
- } from "../chunk-ULRDQ6HZ.js";
19
+ } from "../chunk-NZVSLWNY.js";
20
20
  import "../chunk-2DHMNTV6.js";
21
21
  import {
22
22
  createCapabilities,
23
23
  intersectCapabilities
24
- } from "../chunk-N5HFDWQX.js";
24
+ } from "../chunk-PWIO46RT.js";
25
25
  import {
26
26
  META_EDGE_TYPE,
27
27
  META_NODE_TYPE,
@@ -30,7 +30,7 @@ import {
30
30
  createMergedRegistry,
31
31
  createRegistry,
32
32
  generateId
33
- } from "../chunk-5HIRYV2S.js";
33
+ } from "../chunk-6IO74NKD.js";
34
34
  import {
35
35
  NODE_RELATION,
36
36
  computeEdgeDocId,
@@ -1,4 +1,4 @@
1
- import { l as DiscoveryResult } from '../backend-BpYLdwCW.cjs';
1
+ import { l as DiscoveryResult } from '../backend-DNzv8KSR.cjs';
2
2
  import '@google-cloud/firestore';
3
3
 
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { l as DiscoveryResult } from '../backend-BpYLdwCW.js';
1
+ import { l as DiscoveryResult } from '../backend-DNzv8KSR.js';
2
2
  import '@google-cloud/firestore';
3
3
 
4
4
  /**
@@ -2048,7 +2048,7 @@ var GraphClientImpl = class _GraphClientImpl {
2048
2048
  async findNearest(params) {
2049
2049
  if (!this.backend.findNearest) {
2050
2050
  throw new FiregraphError(
2051
- "findNearest() is not supported by the current storage backend. Vector search requires a backend that declares `search.vector` (currently Firestore Standard and Enterprise). There is no client-side fallback because emulating ANN on top of the generic backend surface does not scale beyond toy datasets.",
2051
+ "findNearest() is not supported by the current storage backend. Vector search requires a backend that declares `search.vector` (currently Firestore Standard, Firestore Enterprise, and the local better-sqlite3 backend). There is no client-side fallback because emulating ANN on top of the generic backend surface does not scale beyond toy datasets.",
2052
2052
  "UNSUPPORTED_OPERATION"
2053
2053
  );
2054
2054
  }
@@ -2064,13 +2064,15 @@ var GraphClientImpl = class _GraphClientImpl {
2064
2064
  * Native full-text search (capability `search.fullText`).
2065
2065
  *
2066
2066
  * Returns the top-N records by relevance, ordered by the search
2067
- * index's score. Only Firestore Enterprise declares this capability
2068
- * today — the underlying Pipelines `search({ query: documentMatches(...) })`
2069
- * stage requires Enterprise's FTS index. Standard does not declare
2070
- * the cap (FTS is an Enterprise-only product feature, not a
2071
- * typed-API gap), and the SQLite-shaped backends have no native
2072
- * FTS index. Backends without `search.fullText` throw
2073
- * `UNSUPPORTED_OPERATION` from this wrapper.
2067
+ * index's score. Firestore Enterprise declares this capability (via
2068
+ * the Pipelines `search({ query: documentMatches(...) })` stage over
2069
+ * Enterprise's FTS index), as does the local better-sqlite3 backend
2070
+ * (`firegraph/sqlite-local`, via a trigger-synced FTS5 index ranked
2071
+ * by `bm25()`). Standard does not declare the cap (FTS is an
2072
+ * Enterprise-only product feature, not a typed-API gap); D1 and the
2073
+ * Cloudflare DO edition have no FTS trigger infrastructure. Backends
2074
+ * without `search.fullText` throw `UNSUPPORTED_OPERATION` from this
2075
+ * wrapper.
2074
2076
  *
2075
2077
  * Scan-protection mirrors `findNearest`: a search with no
2076
2078
  * identifying filters (`aType` / `axbType` / `bType`) walks every
@@ -2086,7 +2088,7 @@ var GraphClientImpl = class _GraphClientImpl {
2086
2088
  async fullTextSearch(params) {
2087
2089
  if (!this.backend.fullTextSearch) {
2088
2090
  throw new FiregraphError(
2089
- "fullTextSearch() is not supported by the current storage backend. Full-text search requires a backend that declares `search.fullText` (currently Firestore Enterprise only \u2014 FTS is an Enterprise product feature). There is no client-side fallback because emulating FTS over the generic backend surface would not scale beyond toy datasets.",
2091
+ "fullTextSearch() is not supported by the current storage backend. Full-text search requires a backend that declares `search.fullText` (currently Firestore Enterprise and the local better-sqlite3 backend). There is no client-side fallback because emulating FTS over the generic backend surface would not scale beyond toy datasets.",
2090
2092
  "UNSUPPORTED_OPERATION"
2091
2093
  );
2092
2094
  }