@query-farm/vgi 0.52.0 → 0.52.1

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.
@@ -33,7 +33,15 @@ export declare function serializeBatch(batch: VgiBatch): Uint8Array;
33
33
  export declare function deserializeBatch(input: Uint8Array): VgiBatch;
34
34
  /** Flechette resolves all record batches and their dictionaries into one logical table. */
35
35
  export declare function deserializeBatches(bytes: Uint8Array): VgiBatch[];
36
- /** The input batches must share dictionaries; collection encoding builds them together. */
36
+ /**
37
+ * One multi-batch IPC stream. Each batch may carry its own dictionary values
38
+ * (batches built independently, e.g. an HTTP reply's metadata-only batch and
39
+ * its result batch): the flechette fork's `tablesToIPC` assigns dictionary ids
40
+ * by field position and writes a replacement dictionary before any batch whose
41
+ * dictionary differs. Needs @query-farm/flechette with that fix; earlier
42
+ * releases crashed on a leading zero-row batch and decoded later batches
43
+ * against the first batch's dictionary (see multi-batch-dictionaries.test.ts).
44
+ */
37
45
  export declare function serializeBatches(batches: VgiBatch[], schema: VgiSchema): Uint8Array;
38
46
  /** Build bounded batches together so their dictionary indices share one value table. */
39
47
  export declare function serializeCollectionRows(schema: VgiSchema, rows: Record<string, any>[], maxBatchRows: number): Uint8Array;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@query-farm/vgi",
3
- "version": "0.52.0",
3
+ "version": "0.52.1",
4
4
  "description": "TypeScript framework for extending DuckDB with user-defined functions via the Vector Gateway Interface (VGI) over Arrow IPC.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "author": "Query Farm LLC (https://query.farm)",
@@ -89,17 +89,17 @@
89
89
  },
90
90
  "dependencies": {
91
91
  "@noble/ciphers": "^2.3.0",
92
- "@query-farm/flechette": "^2.7.1",
92
+ "@query-farm/flechette": "^2.7.2",
93
93
  "jose": "^6.2.0"
94
94
  },
95
95
  "peerDependencies": {
96
96
  "@query-farm/apache-arrow": "^21.1.1",
97
- "@query-farm/vgi-rpc": "^0.30.0"
97
+ "@query-farm/vgi-rpc": "^0.30.1"
98
98
  },
99
99
  "devDependencies": {
100
100
  "@duckdb/node-api": "^1.5.5-r.4",
101
101
  "@query-farm/apache-arrow": "^21.1.1",
102
- "@query-farm/vgi-rpc": "^0.30.0",
102
+ "@query-farm/vgi-rpc": "^0.30.1",
103
103
  "@types/bun": "latest",
104
104
  "typescript": "^7.0.2"
105
105
  },
@@ -194,7 +194,15 @@ export function deserializeBatches(bytes: Uint8Array): VgiBatch[] {
194
194
  return [deserializeBatch(bytes)];
195
195
  }
196
196
 
197
- /** The input batches must share dictionaries; collection encoding builds them together. */
197
+ /**
198
+ * One multi-batch IPC stream. Each batch may carry its own dictionary values
199
+ * (batches built independently, e.g. an HTTP reply's metadata-only batch and
200
+ * its result batch): the flechette fork's `tablesToIPC` assigns dictionary ids
201
+ * by field position and writes a replacement dictionary before any batch whose
202
+ * dictionary differs. Needs @query-farm/flechette with that fix; earlier
203
+ * releases crashed on a leading zero-row batch and decoded later batches
204
+ * against the first batch's dictionary (see multi-batch-dictionaries.test.ts).
205
+ */
198
206
  export function serializeBatches(batches: VgiBatch[], schema: VgiSchema): Uint8Array {
199
207
  if (batches.length === 0) return serializeSchema(schema);
200
208
  return tablesToIPC(batches as any[], { format: "stream" }) as Uint8Array;