@sixb/pg 0.1.16 → 0.1.17

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 (92) hide show
  1. package/README.md +125 -0
  2. package/dist/index.d.ts +15 -2
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +3201 -1473
  5. package/dist/index.js.map +32 -25
  6. package/dist/migrations.d.ts.map +1 -1
  7. package/dist/objects/aggregate-admission.d.ts +10 -0
  8. package/dist/objects/aggregate-admission.d.ts.map +1 -0
  9. package/dist/objects/preparation-lock.d.ts +6 -0
  10. package/dist/objects/preparation-lock.d.ts.map +1 -0
  11. package/dist/objects/prepare-queries.d.ts +5 -0
  12. package/dist/objects/prepare-queries.d.ts.map +1 -0
  13. package/dist/objects/query-compiler.d.ts +19 -0
  14. package/dist/objects/query-compiler.d.ts.map +1 -1
  15. package/dist/objects/query-indexes.d.ts +43 -0
  16. package/dist/objects/query-indexes.d.ts.map +1 -0
  17. package/dist/objects/reader.d.ts +7 -1
  18. package/dist/objects/reader.d.ts.map +1 -1
  19. package/dist/objects/storage.d.ts +1 -1
  20. package/dist/objects/storage.d.ts.map +1 -1
  21. package/dist/objects/text-count-index.d.ts +24 -0
  22. package/dist/objects/text-count-index.d.ts.map +1 -0
  23. package/dist/ontology-storage/index.d.ts +2 -0
  24. package/dist/ontology-storage/index.d.ts.map +1 -1
  25. package/dist/ontology-storage/materialization-session.d.ts +18 -38
  26. package/dist/ontology-storage/materialization-session.d.ts.map +1 -1
  27. package/dist/ontology-storage/materialization-state.d.ts +3 -26
  28. package/dist/ontology-storage/materialization-state.d.ts.map +1 -1
  29. package/dist/ontology-storage/materialization-writer.d.ts +51 -9
  30. package/dist/ontology-storage/materialization-writer.d.ts.map +1 -1
  31. package/dist/ontology-storage/materializations.d.ts +5 -7
  32. package/dist/ontology-storage/materializations.d.ts.map +1 -1
  33. package/dist/ontology-storage/outbox.d.ts.map +1 -1
  34. package/dist/ontology-storage/replacement-plans.d.ts +36 -0
  35. package/dist/ontology-storage/replacement-plans.d.ts.map +1 -0
  36. package/dist/ontology-storage/shared.d.ts +11 -5
  37. package/dist/ontology-storage/shared.d.ts.map +1 -1
  38. package/dist/ontology-storage/source-cleanup.d.ts.map +1 -1
  39. package/dist/ontology-storage/source-roots.d.ts +14 -1
  40. package/dist/ontology-storage/source-roots.d.ts.map +1 -1
  41. package/dist/ontology-storage/sources.d.ts +1 -2
  42. package/dist/ontology-storage/sources.d.ts.map +1 -1
  43. package/dist/pg-ai-cost-storage.d.ts.map +1 -1
  44. package/dist/pg-ai-limit-storage.d.ts.map +1 -1
  45. package/dist/pg-ai-usage-storage.d.ts +2 -0
  46. package/dist/pg-ai-usage-storage.d.ts.map +1 -1
  47. package/dist/pg-execution-storage.d.ts +28 -0
  48. package/dist/pg-execution-storage.d.ts.map +1 -1
  49. package/dist/pg-file-download-grant-storage.d.ts +11 -0
  50. package/dist/pg-file-download-grant-storage.d.ts.map +1 -0
  51. package/dist/pg-projection-run-storage.d.ts.map +1 -1
  52. package/dist/pg-rules-storage.d.ts.map +1 -1
  53. package/dist/transactions.d.ts +6 -2
  54. package/dist/transactions.d.ts.map +1 -1
  55. package/package.json +3 -3
  56. package/src/index.ts +53 -3
  57. package/src/migrations/053-replacement-plans.sql +72 -0
  58. package/src/migrations/054-slim-ontology-outbox.sql +108 -0
  59. package/src/migrations/055-object-query-preparation.sql +11 -0
  60. package/src/migrations/056-commit-touches.sql +41 -0
  61. package/src/migrations/057-audio-transcription.sql +10 -0
  62. package/src/migrations/058-reranking-model-kind.sql +11 -0
  63. package/src/migrations/059-file-download-grants.sql +16 -0
  64. package/src/migrations/060-drained-source-versions.sql +11 -0
  65. package/src/migrations.ts +20 -0
  66. package/src/objects/aggregate-admission.ts +21 -0
  67. package/src/objects/preparation-lock.ts +15 -0
  68. package/src/objects/prepare-queries.ts +181 -0
  69. package/src/objects/query-compiler.ts +404 -114
  70. package/src/objects/query-indexes.ts +348 -0
  71. package/src/objects/reader.ts +140 -51
  72. package/src/objects/storage.ts +15 -3
  73. package/src/objects/text-count-index.ts +455 -0
  74. package/src/ontology-storage/index.ts +3 -0
  75. package/src/ontology-storage/materialization-session.ts +116 -275
  76. package/src/ontology-storage/materialization-state.ts +8 -259
  77. package/src/ontology-storage/materialization-writer.ts +618 -508
  78. package/src/ontology-storage/materializations.ts +106 -289
  79. package/src/ontology-storage/outbox.ts +46 -15
  80. package/src/ontology-storage/replacement-plans.ts +1110 -0
  81. package/src/ontology-storage/shared.ts +27 -15
  82. package/src/ontology-storage/source-cleanup.ts +22 -10
  83. package/src/ontology-storage/source-roots.ts +35 -8
  84. package/src/ontology-storage/sources.ts +0 -30
  85. package/src/pg-ai-cost-storage.ts +12 -0
  86. package/src/pg-ai-limit-storage.ts +13 -2
  87. package/src/pg-ai-usage-storage.ts +8 -0
  88. package/src/pg-execution-storage.ts +8 -3
  89. package/src/pg-file-download-grant-storage.ts +76 -0
  90. package/src/pg-projection-run-storage.ts +6 -1
  91. package/src/pg-rules-storage.ts +7 -3
  92. package/src/transactions.ts +10 -3
package/README.md CHANGED
@@ -77,6 +77,7 @@ Tested with pgvector 0.8.1; no approximate index is created.
77
77
 
78
78
  | Option | Default | Why you would set it |
79
79
  | --- | --- | --- |
80
+ | `maxConcurrentAggregates` | `1` | Root count/facet calculations admitted at once; keep below `max` to leave connections for pages. Increase for larger database CPUs after measuring. |
80
81
  | `max` | `10` | Pool size. Size it per role, not per project — an API replica and a worker each get their own pool. |
81
82
  | `statementTimeoutMillis` | unset | A single stalled query can otherwise pin its connection until the process restarts. Keep it generous or unset for workers that run long bulk writes. |
82
83
  | `idleInTransactionSessionTimeoutMillis` | unset | Aborts transactions left open and idle, releasing the connection. |
@@ -106,3 +107,127 @@ await storage.transaction(
106
107
  Nested transactions are rejected. A serialization conflict or deadlock surfaces as a
107
108
  `StorageTransactionError` with `code: "serialization_failure"`, which is the signal that the
108
109
  operation is safe to retry.
110
+
111
+ ## Preparing queries
112
+
113
+ Declare query capabilities on properties and recurring compound access patterns on the object type:
114
+
115
+ ```ts
116
+ const User = defineObjectType({
117
+ id: "User",
118
+ name: "User",
119
+ properties: [
120
+ prop("id", "string", { primary: true, required: true }),
121
+ prop("status", "string", { query: { searchable: true, filterable: true, facet: true } }),
122
+ prop("createdAt", "timestamp", { query: { searchable: true, sortable: true } }),
123
+ prop("searchText", "string", { query: { searchable: true, text: true } }),
124
+ ],
125
+ query: {
126
+ indexes: [
127
+ { kind: "sort", fields: [{ propertyId: "createdAt", direction: "desc" }] },
128
+ {
129
+ kind: "sort",
130
+ fields: [{ propertyId: "createdAt", direction: "desc" }],
131
+ filters: ["status"],
132
+ },
133
+ { kind: "text", propertyId: "searchText", filters: ["status"] },
134
+ ],
135
+ },
136
+ })
137
+ ```
138
+
139
+ Sixb prepares declared query structures automatically after schema migrations, before its
140
+ CLI development runtime or production services start. `bun sixb db migrate` performs both steps;
141
+ `bun sixb db prepare` remains available for explicit preparation. `--no-migrate` and
142
+ `SIXB_SKIP_MIGRATION=1` disable both steps for production services when a separate release step
143
+ has already run them. No index is built in a request handler.
144
+
145
+ Custom runtimes can opt into the same lifecycle with:
146
+
147
+ ```ts
148
+ await migrateStorage(storage, {
149
+ projectId: sixb.id,
150
+ ontology: sixb.definitions.ontology,
151
+ })
152
+ ```
153
+
154
+ Passing only `storage` retains schema-only migration. Providers without query preparation,
155
+ including SQLite and in-memory storage, continue normally; explicitly calling
156
+ `prepareObjectQueries` or `db prepare` on them reports the unsupported capability.
157
+
158
+ Each project database has one preparation record, enforced by a singleton key. PostgreSQL records
159
+ the completed declaration fingerprint there. Unchanged declarations need one small
160
+ read, without index DDL, statistics refreshes, or object-table locks. Concurrent
161
+ instances serialize changed preparation and recheck completion before doing work, including with
162
+ a single-connection pool. Completion is recorded only after every step succeeds; failures stop
163
+ startup and are surfaced. Indexes are additive across rolling releases.
164
+ A removed declaration does not remove its physical structures. The completion record assumes
165
+ framework-owned structures have not been manually dropped or changed.
166
+
167
+ **Allow maintenance time for the initial preparation.** To avoid doing it at service startup,
168
+ run `bun sixb db migrate` before starting the new release. Ordinary indexes build concurrently. A text
169
+ hint also adds STORED generated columns: the initial call rewrites the objects table under an
170
+ exclusive lock.
171
+ Provide all definitions together, allow temporary disk headroom, and measure projection throughput.
172
+ Preparation attempts to install `pg_trgm` in `public`; the database administrator must provide that
173
+ extension when the maintenance role cannot install it.
174
+
175
+ Preparation creates access paths for enabled filter, sort and text operations, incoming links,
176
+ and the explicitly declared combinations. Compound sort filters are string equality prefixes;
177
+ queries without those filters need an unfiltered index too. Primary identity predicates use the
178
+ existing primary key through the core query planner. Unsupported dedicated scalar indexes produce
179
+ warnings and keep the exact general query path.
180
+
181
+ Identical preparation is repeatable. Definitions are additive: removing an ontology hint does
182
+ not drop existing indexes or generated columns. Retire obsolete structures through explicit
183
+ PostgreSQL maintenance after coordinating application versions. An interrupted invalid index build
184
+ is reported with repair instructions. Low-level `ensureObjectQueryIndexes` and
185
+ `prepareObjectTextCounts` remain available for provider-specific maintenance and experiments;
186
+ application configuration should use ontology declarations.
187
+
188
+ ### Pages, search and totals
189
+
190
+ Use `list({ includeTotal: false })` for independently loaded pages. Existing cursor pagination
191
+ uses ordered index ranges, including deep pages. Incoming relationship pages can choose an ordered
192
+ endpoint scan after a bounded fanout probe; aggregates use their own execution plan.
193
+
194
+ Search remains literal, case-insensitive substring search, including `%`, `_` and `\` characters.
195
+ Trigrams accelerate selective terms; short or very common terms still require scanning. A text
196
+ hint provides a compact covering representation for broad exact counts and facets. Its normal path
197
+ covers text up to 1024 UTF-8 bytes and each filter up to 128 bytes; longer values remain valid and
198
+ are included through an exact overflow path. Sort indexes also separate oversized entries from
199
+ the bounded ordered index. No truncation changes results.
200
+
201
+ To load multiple facet counts and the matching total together:
202
+
203
+ ```ts
204
+ const { total, facets } = await sixb.objects(User).query()
205
+ .search("martin", { fields: [User.p.searchText] })
206
+ .facets([{ property: User.p.status, limit: 100 }])
207
+ ```
208
+
209
+ `total` counts all matching objects, including those without the facet property. Facet limits
210
+ truncate buckets, never the total. Explicit null is a bucket; missing properties are not. Do not
211
+ sum truncated buckets to infer the total, or treat an omitted bucket as necessarily zero.
212
+ This changes the earlier array-only `.facets()` result; SDK consumers now read `.facets` on the
213
+ returned object. The HTTP response adds `total` alongside its existing `facets` member.
214
+
215
+ Totals and facet buckets are calculated from current objects on each request. No aggregate
216
+ state tables, counter triggers or result caches participate in reads or writes. Compact text
217
+ indexes can reduce scan work, but broad exact counts still cost CPU on every request, including
218
+ repeated identical searches.
219
+
220
+ Root count/facet calculations queue before reserving a connection, including totals requested
221
+ with a page. `maxConcurrentAggregates` defaults to one per storage instance; use a pool of at least
222
+ two to leave capacity for independent page requests. Selected scopes and transaction-bound
223
+ readers preserve their own exact execution paths. Index maintenance still adds write work;
224
+ benchmark mixed reads and writes for your workload. Small projection deltas
225
+ rely on autovacuum for routine statistics maintenance; a first bulk publication or a substantial
226
+ replacement refreshes statistics synchronously.
227
+
228
+ The generic whole-document JSON GIN index is removed by migration 055: framework predicates use
229
+ property expressions, not whole-document containment. Applications running custom containment SQL
230
+ may choose their own suitable index.
231
+
232
+ See [the reproducible benchmark](benchmarks/README.md) for resources, synthetic data, SDK queries,
233
+ concurrent screens, relationship traversal and real projection measurements.
package/dist/index.d.ts CHANGED
@@ -1,11 +1,16 @@
1
1
  import type { MigrationCapableStorage, Storage, StorageMigrator, StorageTransactionOptions } from "@sixb/core";
2
- import { type AiCostStorage, type AiLimitStorage, type AiUsageStorage, type ObjectStorage } from "@sixb/core/storage";
2
+ import { type AiCostStorage, type AiLimitStorage, type AiUsageStorage, type ObjectQueryPreparationPlan, type ObjectQueryPreparationResult, type ObjectStorage, type QueryPreparationCapableStorage } from "@sixb/core/storage";
3
3
  import { PgAgentStorage } from "./agents";
4
4
  import { PgAuthStorage } from "./auth-storage";
5
5
  import { PgConnectorConnectionStorage } from "./connector-connection-storage";
6
+ import { type PgObjectQueryIndex } from "./objects/query-indexes";
7
+ export type { PgObjectQueryIndex, PgObjectQueryIndexScope } from "./objects/query-indexes";
8
+ import { type PgObjectTextCountIndex } from "./objects/text-count-index";
9
+ export type { PgObjectTextCountIndex } from "./objects/text-count-index";
6
10
  import { PgOntologyStorage } from "./ontology-storage";
7
11
  import { PgActionRunStorage } from "./pg-action-run-storage";
8
12
  import { PgExecutionStorage } from "./pg-execution-storage";
13
+ import { PgFileDownloadGrantStorage } from "./pg-file-download-grant-storage";
9
14
  import { PgFileUploadSessionStorage } from "./pg-file-upload-session-storage";
10
15
  import { PgPipelineRunStorage } from "./pg-pipeline-run-storage";
11
16
  import { PgProjectionRunStorage } from "./pg-projection-run-storage";
@@ -38,6 +43,8 @@ export interface PostgresStorageOptions {
38
43
  password?: string;
39
44
  /** Maximum number of connections in the pool. Defaults to 10. */
40
45
  max?: number;
46
+ /** Concurrent root count/facet calculations per instance; defaults to 1. */
47
+ maxConcurrentAggregates?: number;
41
48
  /** Idle connection timeout in milliseconds. Defaults to 30000. */
42
49
  idleTimeoutMillis?: number;
43
50
  /**
@@ -96,7 +103,7 @@ export interface PostgresStorageOptions {
96
103
  * })
97
104
  * ```
98
105
  */
99
- export declare class PostgresStorage implements MigrationCapableStorage {
106
+ export declare class PostgresStorage implements MigrationCapableStorage, QueryPreparationCapableStorage {
100
107
  readonly objects: ObjectStorage;
101
108
  readonly ontology: PgOntologyStorage;
102
109
  readonly auth: PgAuthStorage;
@@ -118,6 +125,7 @@ export declare class PostgresStorage implements MigrationCapableStorage {
118
125
  readonly shareGrants: PgShareGrantStorage;
119
126
  readonly shareSessions: PgShareSessionStorage;
120
127
  readonly fileUploadSessions: PgFileUploadSessionStorage;
128
+ readonly fileDownloadGrants: PgFileDownloadGrantStorage;
121
129
  readonly migrators: readonly StorageMigrator[];
122
130
  private readonly sql;
123
131
  private readonly schemaName;
@@ -126,6 +134,11 @@ export declare class PostgresStorage implements MigrationCapableStorage {
126
134
  constructor(options: PostgresStorageOptions);
127
135
  ping(): Promise<void>;
128
136
  transaction<T>(run: (tx: Storage) => Promise<T> | T, options?: StorageTransactionOptions): Promise<T>;
137
+ prepareObjectQueries(plan: ObjectQueryPreparationPlan): Promise<ObjectQueryPreparationResult>;
138
+ /** Build workload-specific indexes concurrently, after migrations, outside transactions. */
139
+ ensureObjectQueryIndexes(indexes: readonly PgObjectQueryIndex[]): Promise<readonly string[]>;
140
+ /** Offline maintenance: STORED columns rewrite the objects table before concurrent index builds. */
141
+ prepareObjectTextCounts(indexes: readonly PgObjectTextCountIndex[]): Promise<readonly string[]>;
129
142
  private assertRootOperationAvailable;
130
143
  /**
131
144
  * Close the connection pool. Should be called on shutdown.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACV,uBAAuB,EACvB,OAAO,EACP,eAAe,EACf,yBAAyB,EAC1B,MAAM,YAAY,CAAA;AAenB,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,aAAa,EAEnB,MAAM,oBAAoB,CAAA;AAC3B,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAA;AAC9C,OAAO,EAAE,4BAA4B,EAAE,MAAM,gCAAgC,CAAA;AAG7E,OAAO,EAAE,iBAAiB,EAAqC,MAAM,oBAAoB,CAAA;AACzF,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAK5D,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA;AAC3D,OAAO,EAAE,0BAA0B,EAAE,MAAM,kCAAkC,CAAA;AAC7E,OAAO,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAA;AAChE,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAA;AACpE,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA;AACnD,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBA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