@lancedb/lancedb 0.42.0-beta.2 → 0.42.0-beta.21
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/RUST_THIRD_PARTY_LICENSES.html +11637 -6176
- package/dist/arrow.js +3 -1
- package/dist/blob.d.ts +11 -0
- package/dist/blob.js +27 -0
- package/dist/cleanup.d.ts +31 -0
- package/dist/cleanup.js +80 -0
- package/dist/compaction.d.ts +23 -0
- package/dist/compaction.js +21 -0
- package/dist/connection.d.ts +2 -2
- package/dist/index.d.ts +13 -8
- package/dist/index.js +3 -2
- package/dist/indices.d.ts +44 -0
- package/dist/indices.js +42 -0
- package/dist/job.d.ts +117 -4
- package/dist/job.js +190 -12
- package/dist/merge.d.ts +17 -0
- package/dist/merge.js +7 -1
- package/dist/native.d.ts +296 -9
- package/dist/native.js +53 -52
- package/dist/prewarm.d.ts +40 -0
- package/dist/prewarm.js +37 -0
- package/dist/profiling.d.ts +44 -0
- package/dist/profiling.js +37 -0
- package/dist/query.d.ts +12 -2
- package/dist/query.js +55 -4
- package/dist/sql.d.ts +11 -0
- package/dist/sql.js +61 -0
- package/dist/table.d.ts +439 -12
- package/dist/table.js +461 -18
- package/package.json +9 -9
- package/pnpm-workspace.yaml +0 -7
package/dist/native.js
CHANGED
|
@@ -76,8 +76,8 @@ function requireNative() {
|
|
|
76
76
|
try {
|
|
77
77
|
const binding = require('@lancedb/lancedb-android-arm64');
|
|
78
78
|
const bindingPackageVersion = require('@lancedb/lancedb-android-arm64/package.json').version;
|
|
79
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
80
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
79
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
80
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
81
81
|
}
|
|
82
82
|
return binding;
|
|
83
83
|
}
|
|
@@ -95,8 +95,8 @@ function requireNative() {
|
|
|
95
95
|
try {
|
|
96
96
|
const binding = require('@lancedb/lancedb-android-arm-eabi');
|
|
97
97
|
const bindingPackageVersion = require('@lancedb/lancedb-android-arm-eabi/package.json').version;
|
|
98
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
99
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
98
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
99
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
100
100
|
}
|
|
101
101
|
return binding;
|
|
102
102
|
}
|
|
@@ -120,8 +120,8 @@ function requireNative() {
|
|
|
120
120
|
try {
|
|
121
121
|
const binding = require('@lancedb/lancedb-win32-x64-gnu');
|
|
122
122
|
const bindingPackageVersion = require('@lancedb/lancedb-win32-x64-gnu/package.json').version;
|
|
123
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
124
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
123
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
124
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
125
125
|
}
|
|
126
126
|
return binding;
|
|
127
127
|
}
|
|
@@ -139,8 +139,8 @@ function requireNative() {
|
|
|
139
139
|
try {
|
|
140
140
|
const binding = require('@lancedb/lancedb-win32-x64-msvc');
|
|
141
141
|
const bindingPackageVersion = require('@lancedb/lancedb-win32-x64-msvc/package.json').version;
|
|
142
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
143
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
142
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
143
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
144
144
|
}
|
|
145
145
|
return binding;
|
|
146
146
|
}
|
|
@@ -159,8 +159,8 @@ function requireNative() {
|
|
|
159
159
|
try {
|
|
160
160
|
const binding = require('@lancedb/lancedb-win32-ia32-msvc');
|
|
161
161
|
const bindingPackageVersion = require('@lancedb/lancedb-win32-ia32-msvc/package.json').version;
|
|
162
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
163
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
162
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
163
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
164
164
|
}
|
|
165
165
|
return binding;
|
|
166
166
|
}
|
|
@@ -178,8 +178,8 @@ function requireNative() {
|
|
|
178
178
|
try {
|
|
179
179
|
const binding = require('@lancedb/lancedb-win32-arm64-msvc');
|
|
180
180
|
const bindingPackageVersion = require('@lancedb/lancedb-win32-arm64-msvc/package.json').version;
|
|
181
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
182
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
181
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
182
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
183
183
|
}
|
|
184
184
|
return binding;
|
|
185
185
|
}
|
|
@@ -201,8 +201,8 @@ function requireNative() {
|
|
|
201
201
|
try {
|
|
202
202
|
const binding = require('@lancedb/lancedb-darwin-universal');
|
|
203
203
|
const bindingPackageVersion = require('@lancedb/lancedb-darwin-universal/package.json').version;
|
|
204
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
205
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
204
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
205
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
206
206
|
}
|
|
207
207
|
return binding;
|
|
208
208
|
}
|
|
@@ -219,8 +219,8 @@ function requireNative() {
|
|
|
219
219
|
try {
|
|
220
220
|
const binding = require('@lancedb/lancedb-darwin-x64');
|
|
221
221
|
const bindingPackageVersion = require('@lancedb/lancedb-darwin-x64/package.json').version;
|
|
222
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
223
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
222
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
223
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
224
224
|
}
|
|
225
225
|
return binding;
|
|
226
226
|
}
|
|
@@ -238,8 +238,8 @@ function requireNative() {
|
|
|
238
238
|
try {
|
|
239
239
|
const binding = require('@lancedb/lancedb-darwin-arm64');
|
|
240
240
|
const bindingPackageVersion = require('@lancedb/lancedb-darwin-arm64/package.json').version;
|
|
241
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
242
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
241
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
242
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
243
243
|
}
|
|
244
244
|
return binding;
|
|
245
245
|
}
|
|
@@ -262,8 +262,8 @@ function requireNative() {
|
|
|
262
262
|
try {
|
|
263
263
|
const binding = require('@lancedb/lancedb-freebsd-x64');
|
|
264
264
|
const bindingPackageVersion = require('@lancedb/lancedb-freebsd-x64/package.json').version;
|
|
265
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
266
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
265
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
266
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
267
267
|
}
|
|
268
268
|
return binding;
|
|
269
269
|
}
|
|
@@ -281,8 +281,8 @@ function requireNative() {
|
|
|
281
281
|
try {
|
|
282
282
|
const binding = require('@lancedb/lancedb-freebsd-arm64');
|
|
283
283
|
const bindingPackageVersion = require('@lancedb/lancedb-freebsd-arm64/package.json').version;
|
|
284
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
285
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
284
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
285
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
286
286
|
}
|
|
287
287
|
return binding;
|
|
288
288
|
}
|
|
@@ -306,8 +306,8 @@ function requireNative() {
|
|
|
306
306
|
try {
|
|
307
307
|
const binding = require('@lancedb/lancedb-linux-x64-musl');
|
|
308
308
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-x64-musl/package.json').version;
|
|
309
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
310
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
309
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
310
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
311
311
|
}
|
|
312
312
|
return binding;
|
|
313
313
|
}
|
|
@@ -325,8 +325,8 @@ function requireNative() {
|
|
|
325
325
|
try {
|
|
326
326
|
const binding = require('@lancedb/lancedb-linux-x64-gnu');
|
|
327
327
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-x64-gnu/package.json').version;
|
|
328
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
329
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
328
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
329
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
330
330
|
}
|
|
331
331
|
return binding;
|
|
332
332
|
}
|
|
@@ -346,8 +346,8 @@ function requireNative() {
|
|
|
346
346
|
try {
|
|
347
347
|
const binding = require('@lancedb/lancedb-linux-arm64-musl');
|
|
348
348
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-arm64-musl/package.json').version;
|
|
349
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
350
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
349
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
350
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
351
351
|
}
|
|
352
352
|
return binding;
|
|
353
353
|
}
|
|
@@ -365,8 +365,8 @@ function requireNative() {
|
|
|
365
365
|
try {
|
|
366
366
|
const binding = require('@lancedb/lancedb-linux-arm64-gnu');
|
|
367
367
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-arm64-gnu/package.json').version;
|
|
368
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
369
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
368
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
369
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
370
370
|
}
|
|
371
371
|
return binding;
|
|
372
372
|
}
|
|
@@ -386,8 +386,8 @@ function requireNative() {
|
|
|
386
386
|
try {
|
|
387
387
|
const binding = require('@lancedb/lancedb-linux-arm-musleabihf');
|
|
388
388
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-arm-musleabihf/package.json').version;
|
|
389
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
390
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
389
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
390
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
391
391
|
}
|
|
392
392
|
return binding;
|
|
393
393
|
}
|
|
@@ -405,8 +405,8 @@ function requireNative() {
|
|
|
405
405
|
try {
|
|
406
406
|
const binding = require('@lancedb/lancedb-linux-arm-gnueabihf');
|
|
407
407
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-arm-gnueabihf/package.json').version;
|
|
408
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
409
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
408
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
409
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
410
410
|
}
|
|
411
411
|
return binding;
|
|
412
412
|
}
|
|
@@ -426,8 +426,8 @@ function requireNative() {
|
|
|
426
426
|
try {
|
|
427
427
|
const binding = require('@lancedb/lancedb-linux-loong64-musl');
|
|
428
428
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-loong64-musl/package.json').version;
|
|
429
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
430
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
429
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
430
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
431
431
|
}
|
|
432
432
|
return binding;
|
|
433
433
|
}
|
|
@@ -445,8 +445,8 @@ function requireNative() {
|
|
|
445
445
|
try {
|
|
446
446
|
const binding = require('@lancedb/lancedb-linux-loong64-gnu');
|
|
447
447
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-loong64-gnu/package.json').version;
|
|
448
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
449
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
448
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
449
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
450
450
|
}
|
|
451
451
|
return binding;
|
|
452
452
|
}
|
|
@@ -466,8 +466,8 @@ function requireNative() {
|
|
|
466
466
|
try {
|
|
467
467
|
const binding = require('@lancedb/lancedb-linux-riscv64-musl');
|
|
468
468
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-riscv64-musl/package.json').version;
|
|
469
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
470
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
469
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
470
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
471
471
|
}
|
|
472
472
|
return binding;
|
|
473
473
|
}
|
|
@@ -485,8 +485,8 @@ function requireNative() {
|
|
|
485
485
|
try {
|
|
486
486
|
const binding = require('@lancedb/lancedb-linux-riscv64-gnu');
|
|
487
487
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-riscv64-gnu/package.json').version;
|
|
488
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
489
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
488
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
489
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
490
490
|
}
|
|
491
491
|
return binding;
|
|
492
492
|
}
|
|
@@ -505,8 +505,8 @@ function requireNative() {
|
|
|
505
505
|
try {
|
|
506
506
|
const binding = require('@lancedb/lancedb-linux-ppc64-gnu');
|
|
507
507
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-ppc64-gnu/package.json').version;
|
|
508
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
509
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
508
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
509
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
510
510
|
}
|
|
511
511
|
return binding;
|
|
512
512
|
}
|
|
@@ -524,8 +524,8 @@ function requireNative() {
|
|
|
524
524
|
try {
|
|
525
525
|
const binding = require('@lancedb/lancedb-linux-s390x-gnu');
|
|
526
526
|
const bindingPackageVersion = require('@lancedb/lancedb-linux-s390x-gnu/package.json').version;
|
|
527
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
528
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
527
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
528
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
529
529
|
}
|
|
530
530
|
return binding;
|
|
531
531
|
}
|
|
@@ -548,8 +548,8 @@ function requireNative() {
|
|
|
548
548
|
try {
|
|
549
549
|
const binding = require('@lancedb/lancedb-openharmony-arm64');
|
|
550
550
|
const bindingPackageVersion = require('@lancedb/lancedb-openharmony-arm64/package.json').version;
|
|
551
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
552
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
551
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
552
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
553
553
|
}
|
|
554
554
|
return binding;
|
|
555
555
|
}
|
|
@@ -567,8 +567,8 @@ function requireNative() {
|
|
|
567
567
|
try {
|
|
568
568
|
const binding = require('@lancedb/lancedb-openharmony-x64');
|
|
569
569
|
const bindingPackageVersion = require('@lancedb/lancedb-openharmony-x64/package.json').version;
|
|
570
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
571
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
570
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
571
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
572
572
|
}
|
|
573
573
|
return binding;
|
|
574
574
|
}
|
|
@@ -586,8 +586,8 @@ function requireNative() {
|
|
|
586
586
|
try {
|
|
587
587
|
const binding = require('@lancedb/lancedb-openharmony-arm');
|
|
588
588
|
const bindingPackageVersion = require('@lancedb/lancedb-openharmony-arm/package.json').version;
|
|
589
|
-
if (bindingPackageVersion !== '0.42.0-beta.
|
|
590
|
-
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.
|
|
589
|
+
if (bindingPackageVersion !== '0.42.0-beta.21' && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== '0') {
|
|
590
|
+
throw new Error(`Native binding package version mismatch, expected 0.42.0-beta.21 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
591
591
|
}
|
|
592
592
|
return binding;
|
|
593
593
|
}
|
|
@@ -684,6 +684,7 @@ module.exports.RrfReranker = nativeBinding.RrfReranker;
|
|
|
684
684
|
module.exports.RRFReranker = nativeBinding.RRFReranker;
|
|
685
685
|
module.exports.Session = nativeBinding.Session;
|
|
686
686
|
module.exports.Table = nativeBinding.Table;
|
|
687
|
+
module.exports.TableDelta = nativeBinding.TableDelta;
|
|
687
688
|
module.exports.TagContents = nativeBinding.TagContents;
|
|
688
689
|
module.exports.Tags = nativeBinding.Tags;
|
|
689
690
|
module.exports.TakeQuery = nativeBinding.TakeQuery;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/** Reported executor work for a pinned snapshot; unavailable measurements stay null. */
|
|
2
|
+
export interface PrewarmDataResult {
|
|
3
|
+
/** The source snapshot captured by submission. */
|
|
4
|
+
tableVersion: number;
|
|
5
|
+
/** Reported executors targeted, or null when unavailable. */
|
|
6
|
+
executorsTargeted: number | null;
|
|
7
|
+
/** Executors that finished successfully or partially, or null when unavailable. */
|
|
8
|
+
executorsCompleted: number | null;
|
|
9
|
+
/** Subset of completed executors reporting partial warming, or null when unavailable. */
|
|
10
|
+
executorsPartial: number | null;
|
|
11
|
+
/** Reported fragments selected, or null when unavailable. */
|
|
12
|
+
fragmentsSelected: number | null;
|
|
13
|
+
/** Reported ranges completed, or null when unavailable. */
|
|
14
|
+
rangesCompleted: number | null;
|
|
15
|
+
/** Reported bytes read, or null when unavailable. */
|
|
16
|
+
bytesRead: number | null;
|
|
17
|
+
}
|
|
18
|
+
/** @internal */
|
|
19
|
+
export declare function decodePrewarmDataResult(value: unknown): PrewarmDataResult;
|
|
20
|
+
/** Metadata-only snapshot preview; no warming job is submitted. */
|
|
21
|
+
export interface PrewarmDataPlan {
|
|
22
|
+
/** Snapshot used for this preview. A later submission plans its own snapshot. */
|
|
23
|
+
tableVersion: number;
|
|
24
|
+
/** Readable display text. Use pruning for structured facts. */
|
|
25
|
+
plan: string;
|
|
26
|
+
pruning: PrewarmPruningSummary;
|
|
27
|
+
}
|
|
28
|
+
/** Conservative metadata proof, rather than exact matching rows. */
|
|
29
|
+
export interface PrewarmPruningSummary {
|
|
30
|
+
/** Server-reported proof mode; future servers may add modes. */
|
|
31
|
+
mode: string;
|
|
32
|
+
inputFragments: number;
|
|
33
|
+
selectedFragments: number;
|
|
34
|
+
prunedFragments: number;
|
|
35
|
+
/** Candidate physical intervals, or null when unknown. */
|
|
36
|
+
selectedRowRanges: number | null;
|
|
37
|
+
fallbackReason: string | null;
|
|
38
|
+
}
|
|
39
|
+
/** @internal */
|
|
40
|
+
export declare function decodePrewarmDataPlan(value: unknown): PrewarmDataPlan;
|
package/dist/prewarm.js
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
// SPDX-FileCopyrightText: Copyright The LanceDB Authors
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.decodePrewarmDataResult = decodePrewarmDataResult;
|
|
6
|
+
exports.decodePrewarmDataPlan = decodePrewarmDataPlan;
|
|
7
|
+
/** @internal */
|
|
8
|
+
function decodePrewarmDataResult(value) {
|
|
9
|
+
// Rust validates the typed wire result before handing it to JavaScript.
|
|
10
|
+
const result = value;
|
|
11
|
+
return {
|
|
12
|
+
tableVersion: result.table_version,
|
|
13
|
+
executorsTargeted: result.executors_targeted ?? null,
|
|
14
|
+
executorsCompleted: result.executors_completed ?? null,
|
|
15
|
+
executorsPartial: result.executors_partial ?? null,
|
|
16
|
+
fragmentsSelected: result.fragments_selected ?? null,
|
|
17
|
+
rangesCompleted: result.ranges_completed ?? null,
|
|
18
|
+
bytesRead: result.bytes_read ?? null,
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
/** @internal */
|
|
22
|
+
function decodePrewarmDataPlan(value) {
|
|
23
|
+
// Rust validates the versioned response before handing it to JavaScript.
|
|
24
|
+
const result = value;
|
|
25
|
+
return {
|
|
26
|
+
tableVersion: result.table_version,
|
|
27
|
+
plan: result.plan,
|
|
28
|
+
pruning: {
|
|
29
|
+
mode: result.pruning.mode,
|
|
30
|
+
inputFragments: result.pruning.input_fragments,
|
|
31
|
+
selectedFragments: result.pruning.selected_fragments,
|
|
32
|
+
prunedFragments: result.pruning.pruned_fragments,
|
|
33
|
+
selectedRowRanges: result.pruning.selected_row_ranges ?? null,
|
|
34
|
+
fallbackReason: result.pruning.fallback_reason ?? null,
|
|
35
|
+
},
|
|
36
|
+
};
|
|
37
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/** Evidence collected from one Function worker's Python execution session. */
|
|
2
|
+
export type FunctionProfileKind = "cpu" | "gpu" | "memory";
|
|
3
|
+
/** A capture's lifecycle, independent of its parent refresh job. */
|
|
4
|
+
export type FunctionProfileStatus = "pending" | "capturing" | "complete" | "failed";
|
|
5
|
+
/** Options for requesting a Function worker capture. */
|
|
6
|
+
export interface FunctionProfileOptions {
|
|
7
|
+
/** CPU samples, retained Python allocations, or PyTorch CUDA activities. */
|
|
8
|
+
kind?: FunctionProfileKind;
|
|
9
|
+
/** 1–30 seconds for CPU/memory, default 10; 1–5 for GPU, default 5. */
|
|
10
|
+
durationSeconds?: number;
|
|
11
|
+
/** Python execution session within the worker; default zero. */
|
|
12
|
+
sessionSlot?: number;
|
|
13
|
+
}
|
|
14
|
+
/** Client-side controls while waiting for a Function worker capture. */
|
|
15
|
+
export interface FunctionProfileWaitOptions {
|
|
16
|
+
/** Maximum wait including HTTP requests and sleeps; defaults to 60,000 ms. */
|
|
17
|
+
timeoutMs?: number;
|
|
18
|
+
/** Delay between status requests; defaults to 2,000 ms and must be positive. */
|
|
19
|
+
pollIntervalMs?: number;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* A capture identity and status snapshot. Keep profileId for retained lookup
|
|
23
|
+
* after the Function refresh completes. Timestamp fields are epoch milliseconds.
|
|
24
|
+
*/
|
|
25
|
+
export interface FunctionProfile {
|
|
26
|
+
readonly profileId: string;
|
|
27
|
+
readonly jobId: string;
|
|
28
|
+
readonly workerId: string;
|
|
29
|
+
readonly executionEpoch: number;
|
|
30
|
+
readonly sessionSlot: number;
|
|
31
|
+
readonly kind: FunctionProfileKind;
|
|
32
|
+
readonly durationSeconds: number;
|
|
33
|
+
readonly status: FunctionProfileStatus;
|
|
34
|
+
readonly requestedAtMillis: number;
|
|
35
|
+
readonly deadlineAtMillis: number;
|
|
36
|
+
/** Upper retention bound; job scratch reclamation can remove artifacts sooner. */
|
|
37
|
+
readonly expiresAtMillis: number;
|
|
38
|
+
readonly completedAtMillis: number | null;
|
|
39
|
+
/** The server's capture failure reason; this is not a refresh job failure. */
|
|
40
|
+
readonly error: string | null;
|
|
41
|
+
readonly artifactId: string | null;
|
|
42
|
+
}
|
|
43
|
+
export declare function decodeFunctionProfile(value: string): FunctionProfile;
|
|
44
|
+
export declare function validateProfileOptions(options: object, names: string[]): void;
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
3
|
+
// SPDX-FileCopyrightText: Copyright The LanceDB Authors
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.decodeFunctionProfile = decodeFunctionProfile;
|
|
6
|
+
exports.validateProfileOptions = validateProfileOptions;
|
|
7
|
+
function decodeFunctionProfile(value) {
|
|
8
|
+
const data = JSON.parse(value);
|
|
9
|
+
return {
|
|
10
|
+
profileId: data.profile_id,
|
|
11
|
+
jobId: data.job_id,
|
|
12
|
+
workerId: data.worker_id,
|
|
13
|
+
executionEpoch: data.execution_epoch,
|
|
14
|
+
sessionSlot: data.session_slot,
|
|
15
|
+
kind: data.kind,
|
|
16
|
+
durationSeconds: data.duration_seconds,
|
|
17
|
+
status: data.status,
|
|
18
|
+
requestedAtMillis: data.requested_at_millis,
|
|
19
|
+
deadlineAtMillis: data.deadline_at_millis,
|
|
20
|
+
expiresAtMillis: data.expires_at_millis,
|
|
21
|
+
completedAtMillis: data.completed_at_millis,
|
|
22
|
+
error: data.error,
|
|
23
|
+
artifactId: data.artifact_id,
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
function validateProfileOptions(options, names) {
|
|
27
|
+
if (typeof options !== "object" ||
|
|
28
|
+
options === null ||
|
|
29
|
+
Array.isArray(options)) {
|
|
30
|
+
throw new TypeError("profiling expects an options object");
|
|
31
|
+
}
|
|
32
|
+
for (const key of Object.keys(options)) {
|
|
33
|
+
if (!names.includes(key)) {
|
|
34
|
+
throw new TypeError(`Unknown profiling option: ${key}`);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
package/dist/query.d.ts
CHANGED
|
@@ -32,6 +32,9 @@ export interface QueryExecutionOptions {
|
|
|
32
32
|
maxBatchLength?: number;
|
|
33
33
|
/**
|
|
34
34
|
* Timeout for query execution in milliseconds
|
|
35
|
+
*
|
|
36
|
+
* The timeout also covers reading the results, so consuming them slowly can
|
|
37
|
+
* exceed it.
|
|
35
38
|
*/
|
|
36
39
|
timeoutMs?: number;
|
|
37
40
|
/**
|
|
@@ -48,8 +51,10 @@ export interface QueryExecutionOptions {
|
|
|
48
51
|
* bytes. Blobs inside lists keep their descriptors. Arbitrary projection
|
|
49
52
|
* expressions are not materialized as bytes.
|
|
50
53
|
*
|
|
51
|
-
* The rows and
|
|
52
|
-
*
|
|
54
|
+
* The rows and bytes come from the same snapshot. Remote queries require
|
|
55
|
+
* authoritative query version and snapshot identity headers, verified again
|
|
56
|
+
* by the blob response. Older servers can still return `"descriptions"`.
|
|
57
|
+
* Local queries retry up to three times if the table changes while they run.
|
|
53
58
|
*
|
|
54
59
|
* @example
|
|
55
60
|
* ```ts
|
|
@@ -365,6 +370,11 @@ export declare class VectorQuery extends StandardQueryBase<NativeVectorQuery> {
|
|
|
365
370
|
/**
|
|
366
371
|
* Set the initial IVF search effort to a finite value in [0, 1].
|
|
367
372
|
*
|
|
373
|
+
* Efforts 0.1 and 0.25 target empirical mean partition-routing recall of
|
|
374
|
+
* 80% and 90% for L2, cosine and dot through k=100000. The probe budget
|
|
375
|
+
* adapts to the metric and k. Hamming and larger k remain uncalibrated;
|
|
376
|
+
* 100000 is not an API limit. Remote queries also require server support.
|
|
377
|
+
*
|
|
368
378
|
* The default, null, uses Auto (internally 0.5). Zero starts at the caller
|
|
369
379
|
* minimum; one searches all partitions within the caller maximum. Later
|
|
370
380
|
* probing may continue when too few candidates are found.
|
package/dist/query.js
CHANGED
|
@@ -7,6 +7,7 @@ exports.RecordBatchIterator = RecordBatchIterator;
|
|
|
7
7
|
exports.createAutoQuery = createAutoQuery;
|
|
8
8
|
exports.instanceOfFullTextQuery = instanceOfFullTextQuery;
|
|
9
9
|
const arrow_1 = require("./arrow");
|
|
10
|
+
const blob_1 = require("./blob");
|
|
10
11
|
const expr_1 = require("./expr");
|
|
11
12
|
const native_1 = require("./native");
|
|
12
13
|
async function* RecordBatchIterator(promisedInner) {
|
|
@@ -76,6 +77,30 @@ async function readBlobBytes(table, sources, snapshot, dropRowId) {
|
|
|
76
77
|
.map((field) => field.name)
|
|
77
78
|
.filter((name) => name !== "_rowid"));
|
|
78
79
|
}
|
|
80
|
+
// Discover descriptors from the executed query, not the live table's cached
|
|
81
|
+
// schema. Projection names are literal aliases; only source paths use dots.
|
|
82
|
+
function projectedBlobSources(schema, projection) {
|
|
83
|
+
const sources = [];
|
|
84
|
+
for (const field of schema.fields) {
|
|
85
|
+
const source = projection?.find(([output]) => output === field.name)?.[1] ?? field.name;
|
|
86
|
+
const visit = (child, path) => {
|
|
87
|
+
if ((0, blob_1.isBlobField)(child) || (0, blob_1.isBlobDescriptorField)(child)) {
|
|
88
|
+
sources.push({
|
|
89
|
+
output: field.name,
|
|
90
|
+
path,
|
|
91
|
+
source: [source, ...path].join("."),
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
else if (arrow_1.DataType.isStruct(child.type)) {
|
|
95
|
+
for (const nested of child.type.children) {
|
|
96
|
+
visit(nested, [...path, nested.name]);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
visit(field, []);
|
|
101
|
+
}
|
|
102
|
+
return sources;
|
|
103
|
+
}
|
|
79
104
|
function withBinaryColumns(table, replacements) {
|
|
80
105
|
if (replacements.size === 0) {
|
|
81
106
|
return table;
|
|
@@ -291,6 +316,27 @@ class QueryBase {
|
|
|
291
316
|
if (context === undefined) {
|
|
292
317
|
return this.collect(options, false);
|
|
293
318
|
}
|
|
319
|
+
if (!context.table.isNative()) {
|
|
320
|
+
// Request row IDs in the same query so newly added Blob columns can be
|
|
321
|
+
// fetched without rerunning the query against a different snapshot.
|
|
322
|
+
const addRowId = !context.withRowId;
|
|
323
|
+
const table = await this.collect(options, addRowId);
|
|
324
|
+
const sources = projectedBlobSources(table.schema, context.projection);
|
|
325
|
+
if (sources.length === 0) {
|
|
326
|
+
return addRowId
|
|
327
|
+
? table.select(table.schema.fields
|
|
328
|
+
.map((field) => field.name)
|
|
329
|
+
.filter((name) => name !== "_rowid"))
|
|
330
|
+
: table;
|
|
331
|
+
}
|
|
332
|
+
const version = table.schema.metadata.get("lancedb:query_version");
|
|
333
|
+
const identity = table.schema.metadata.get("lancedb:query_snapshot");
|
|
334
|
+
if (version === undefined || identity === undefined) {
|
|
335
|
+
throw new Error('blobMode "bytes" requires a trustworthy query snapshot: missing, invalid, or inconsistent x-lancedb-query-version or x-lancedb-query-snapshot. Upgrade every serving node, or use blobMode "descriptions".');
|
|
336
|
+
}
|
|
337
|
+
const snapshot = await context.table.querySnapshotWithIdentity(version, identity);
|
|
338
|
+
return readBlobBytes(table, sources, snapshot, addRowId);
|
|
339
|
+
}
|
|
294
340
|
for (let attempt = 1;; attempt++) {
|
|
295
341
|
// The snapshot pins the bytes. The query runs on the live table, so an
|
|
296
342
|
// unchanged version afterwards proves it read the snapshot's version.
|
|
@@ -316,10 +362,10 @@ class QueryBase {
|
|
|
316
362
|
for await (const batch of RecordBatchIterator(iterator)) {
|
|
317
363
|
batches.push(batch);
|
|
318
364
|
}
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
return new arrow_1.Table(batches);
|
|
365
|
+
// Read metadata from the executed stream, including empty results and
|
|
366
|
+
// query types whose individual batches do not carry the stream metadata.
|
|
367
|
+
const schema = (0, arrow_1.tableFromIPC)((await iterator).schema()).schema;
|
|
368
|
+
return new arrow_1.Table(schema, batches);
|
|
323
369
|
}
|
|
324
370
|
blobBytesContext(mode) {
|
|
325
371
|
if (mode === undefined || mode === "descriptions") {
|
|
@@ -599,6 +645,11 @@ class VectorQuery extends StandardQueryBase {
|
|
|
599
645
|
/**
|
|
600
646
|
* Set the initial IVF search effort to a finite value in [0, 1].
|
|
601
647
|
*
|
|
648
|
+
* Efforts 0.1 and 0.25 target empirical mean partition-routing recall of
|
|
649
|
+
* 80% and 90% for L2, cosine and dot through k=100000. The probe budget
|
|
650
|
+
* adapts to the metric and k. Hamming and larger k remain uncalibrated;
|
|
651
|
+
* 100000 is not an API limit. Remote queries also require server support.
|
|
652
|
+
*
|
|
602
653
|
* The default, null, uses Auto (internally 0.5). Zero starts at the caller
|
|
603
654
|
* minimum; one searches all partitions within the caller maximum. Later
|
|
604
655
|
* probing may continue when too few candidates are found.
|
package/dist/sql.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type RecordBatchLike, type TableLike } from "./arrow";
|
|
2
|
+
/** Scalar SQL values. Use a one-row Arrow table for explicit Arrow types. */
|
|
3
|
+
export type QueryParameterValue = string | number | bigint | boolean | Date | Uint8Array | null;
|
|
4
|
+
/** Values for `$1`/`$name` placeholders, sent separately from SQL text.
|
|
5
|
+
* Arrays bind by position; objects bind by name. Arrow columns bind both ways.
|
|
6
|
+
* Safe integers and bigint use Int64; fractional numbers use Float64.
|
|
7
|
+
* Arrow input preserves explicit types.
|
|
8
|
+
*/
|
|
9
|
+
export type QueryParameters = readonly QueryParameterValue[] | Readonly<Record<string, QueryParameterValue>> | TableLike | RecordBatchLike;
|
|
10
|
+
/** @internal */
|
|
11
|
+
export declare function toParameterBuffer(parameters: QueryParameters): Promise<Buffer>;
|