@delali/narsil 0.3.1-next.74 → 0.3.1-next.75

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 (44) hide show
  1. package/dist/{capabilities-CAMzmkAg.d.ts → capabilities-BHNksicw.d.ts} +16 -2
  2. package/dist/{chunk-Z3DQPOJQ.mjs → chunk-356UOTK2.mjs} +1 -1
  3. package/dist/chunk-7ODNRREZ.mjs +2050 -0
  4. package/dist/{chunk-T5ZWEWVD.mjs → chunk-AIUOAN7Y.mjs} +2 -2
  5. package/dist/{chunk-PO53FV4Q.mjs → chunk-AMGDG4ZJ.mjs} +1 -1
  6. package/dist/{chunk-LX4JERXI.mjs → chunk-BT62MUM5.mjs} +1 -1
  7. package/dist/{chunk-NOZUQM7J.mjs → chunk-BT6BI4GV.mjs} +41 -3
  8. package/dist/{chunk-LJYTW7GT.mjs → chunk-IBR6634K.mjs} +1 -1
  9. package/dist/{chunk-CUZOX6CN.mjs → chunk-LOARLB4F.mjs} +31 -27
  10. package/dist/{chunk-VKX2BPXD.mjs → chunk-NAMGDK45.mjs} +98 -19
  11. package/dist/{chunk-TVFLHM7M.mjs → chunk-PXDY5VRT.mjs} +3 -3
  12. package/dist/{chunk-I23G3IZC.mjs → chunk-UOJIV2NG.mjs} +1 -1
  13. package/dist/{chunk-3DDUNI6N.mjs → chunk-V3B24XR7.mjs} +7 -1
  14. package/dist/{chunk-CTOSGRM7.mjs → chunk-WL2GDSCV.mjs} +5 -5
  15. package/dist/{chunk-BVBIQQKG.mjs → chunk-YOVS4EV5.mjs} +16 -61
  16. package/dist/{client-C-I70ArH.d.ts → client-D4sXFS9f.d.ts} +2 -2
  17. package/dist/client.d.ts +6 -6
  18. package/dist/{config-C6Iw5rCX.d.ts → config-B-GRonqw.d.ts} +1 -1
  19. package/dist/{config-DJPH3IQB.d.ts → config-C1kbq1X2.d.ts} +1 -1
  20. package/dist/direct-executor-AVNWB73C.mjs +16 -0
  21. package/dist/distribution/coordinator/etcd.mjs +1 -1
  22. package/dist/distribution/coordinator/in-memory.mjs +1 -1
  23. package/dist/distribution.d.ts +5 -5
  24. package/dist/distribution.mjs +15 -15
  25. package/dist/{engine-B8eRPO7m.d.ts → engine-DcGSd5vh.d.ts} +1 -1
  26. package/dist/index.browser.mjs +72 -26
  27. package/dist/index.d.ts +5 -5
  28. package/dist/index.mjs +12 -13
  29. package/dist/invalidation/filesystem.mjs +1 -1
  30. package/dist/{memory-DJEwWoCi.d.ts → memory-M9kPmYP8.d.ts} +78 -24
  31. package/dist/partial-words.mjs +4 -4
  32. package/dist/pattern.mjs +2 -2
  33. package/dist/persistence/durability/checkpoint-worker.mjs +12 -13
  34. package/dist/react.d.ts +6 -6
  35. package/dist/server.d.ts +8 -8
  36. package/dist/server.mjs +34 -11
  37. package/dist/{tasks-BVmAKYBh.d.ts → tasks-A8se0J98.d.ts} +1 -1
  38. package/dist/{thread-W6DPKEF6.mjs → thread-BSIKT6ED.mjs} +14 -10
  39. package/dist/vector/search-worker.mjs +2 -2
  40. package/dist/workers/entry.mjs +3 -3
  41. package/package.json +8 -7
  42. package/dist/chunk-XW25X6AU.mjs +0 -614
  43. package/dist/chunk-ZKRV5M2P.mjs +0 -75
  44. package/dist/direct-executor-KFAGILJC.mjs +0 -17
@@ -1,5 +1,5 @@
1
- import { tokenizeOptions, getNestedValue, tokenizeIterator, fuzzyTermMatches } from './chunk-I23G3IZC.mjs';
2
- import { compareCodePoints } from './chunk-LJYTW7GT.mjs';
1
+ import { tokenizeOptions, getNestedValue, tokenizeIterator, fuzzyTermMatches } from './chunk-UOJIV2NG.mjs';
2
+ import { compareCodePoints } from './chunk-IBR6634K.mjs';
3
3
 
4
4
  // src/core/partition/suggestions.ts
5
5
  function verbatimOccurrences(state, token) {
@@ -1,7 +1,7 @@
1
1
  import { OSQ_STEPS, OSQ_GRID, OSQ_REFINE_ROUNDS, OSQ_REFINE_TOLERANCE, OSQ4_NARROW_DIMENSION_LIMIT, DEFAULT_OSQ4_NARROW_OVERSAMPLE, DEFAULT_OVERSAMPLE_BY_BITS, OSQ_QUERY_BITS, OSQ_LAMBDA } from './chunk-ZJ4CSAB2.mjs';
2
2
  import { nativeSearchCoreIsEnabled, loadNativeCore, stopUsingTheNativeSearchCore, noteFallback } from './chunk-2E35UM3G.mjs';
3
3
  import { COMPACTION_TOMBSTONE_RATIO, COMPACTION_ABSOLUTE_THRESHOLD, MAX_LAYER_CAP, PLACEMENT_ROOM_REQUESTS, INITIAL_LIST_CAPACITY, DEFAULT_EF_SEARCH, INITIAL_UPPER_SLOTS } from './chunk-KEHK2O6P.mjs';
4
- import { compareCodePoints } from './chunk-LJYTW7GT.mjs';
4
+ import { compareCodePoints } from './chunk-IBR6634K.mjs';
5
5
  import { NarsilError, ErrorCodes } from './chunk-I64LXKO3.mjs';
6
6
  import { readSync, closeSync, openSync } from 'fs';
7
7
 
@@ -1,4 +1,4 @@
1
- import { requireDocumentWithinSizeLimit, validateRequiredFields } from './chunk-Z3DQPOJQ.mjs';
1
+ import { requireDocumentWithinSizeLimit, validateRequiredFields } from './chunk-356UOTK2.mjs';
2
2
  import { ErrorCodes, NarsilError } from './chunk-I64LXKO3.mjs';
3
3
 
4
4
  // src/narsil/internals.ts
@@ -1,4 +1,4 @@
1
- import { MAX_SORT_FIELDS } from './chunk-3DDUNI6N.mjs';
1
+ import { MAX_FILTER_DEPTH, MAX_SORT_FIELDS } from './chunk-V3B24XR7.mjs';
2
2
  import { nativeSearchCoreIsEnabled, loadNativeCore } from './chunk-2E35UM3G.mjs';
3
3
  import { NarsilError, ServerErrorCodes, ErrorCodes } from './chunk-I64LXKO3.mjs';
4
4
  import { mkdtemp, open, rm } from 'fs/promises';
@@ -423,6 +423,43 @@ function serializeBatchResult(result) {
423
423
  };
424
424
  }
425
425
 
426
+ // src/server/regex-policy.ts
427
+ function isRecord(value) {
428
+ return value !== null && typeof value === "object" && !Array.isArray(value);
429
+ }
430
+ function regexFieldIn(expression, depth) {
431
+ if (!isRecord(expression) || depth > MAX_FILTER_DEPTH) return null;
432
+ if (isRecord(expression.fields)) {
433
+ for (const [fieldPath, filter] of Object.entries(expression.fields)) {
434
+ if (isRecord(filter) && Object.hasOwn(filter, "regex")) return fieldPath;
435
+ }
436
+ }
437
+ for (const nested of [expression.and, expression.or]) {
438
+ if (!Array.isArray(nested)) continue;
439
+ for (const child of nested) {
440
+ const found = regexFieldIn(child, depth + 1);
441
+ if (found !== null) return found;
442
+ }
443
+ }
444
+ return regexFieldIn(expression.not, depth + 1);
445
+ }
446
+ function refusedRegex(filters, allowRegex) {
447
+ if (allowRegex) return null;
448
+ const fieldPath = regexFieldIn(filters, 0);
449
+ if (fieldPath === null) return null;
450
+ return new NarsilError(
451
+ ErrorCodes.SEARCH_INVALID_FILTER,
452
+ `This server refuses every "regex" test, because its operator set the allowRegex server option to false. Test field "${fieldPath}" with "contains" or "wildcard"`,
453
+ { fieldPath, operator: "regex", option: "allowRegex" }
454
+ );
455
+ }
456
+ function refuseRegex(ctx, filters, allowRegex) {
457
+ const refused = refusedRegex(filters, allowRegex);
458
+ if (refused === null) return false;
459
+ respondError(ctx, refused);
460
+ return true;
461
+ }
462
+
426
463
  // src/server/validation.ts
427
464
  function isPlainObject(value) {
428
465
  return typeof value === "object" && value !== null && !Array.isArray(value);
@@ -616,7 +653,7 @@ function parseTaskListQuery(params, maxPageSize) {
616
653
 
617
654
  // src/server/handlers/document-reads.ts
618
655
  function createDocumentReadHandlers(deps) {
619
- const { engine, limits } = deps;
656
+ const { engine, limits, allowRegex } = deps;
620
657
  async function get(ctx) {
621
658
  try {
622
659
  const document = await engine.get(ctx.params[0], ctx.params[1]);
@@ -668,6 +705,7 @@ function createDocumentReadHandlers(deps) {
668
705
  rejectInvalid(ctx, failure);
669
706
  return;
670
707
  }
708
+ if (refuseRegex(ctx, params.filters, allowRegex)) return;
671
709
  try {
672
710
  respondJson(ctx, await engine.listDocuments(ctx.params[0], params));
673
711
  } catch (err) {
@@ -1155,4 +1193,4 @@ function childAppOf(app) {
1155
1193
  return candidate;
1156
1194
  }
1157
1195
 
1158
- export { ASYNC_IMPORT_CAPABILITY, DEFAULT_IMPORT_BATCH_SIZE, DEFAULT_MAX_BODY_BYTES, DEFAULT_MAX_CONCURRENT_REQUESTS, DEFAULT_MAX_CONCURRENT_TASKS, DEFAULT_MAX_FETCH_DOCUMENTS, DEFAULT_MAX_IMPORT_BYTES, DEFAULT_MAX_IMPORT_ERRORS, DEFAULT_MAX_LINE_BYTES, DEFAULT_MAX_RESTORE_BYTES, DEFAULT_MAX_RESULT_WINDOW, DEFAULT_MAX_RETAINED_TASKS, DEFAULT_MAX_TASK_PAGE_SIZE, DEFAULT_TASK_PAGE_SIZE, DOCUMENT_EXPORT_CAPABILITY, DOCUMENT_EXPORT_CONTENT_TYPE, IMPORT_FLUSHES_IN_FLIGHT, INDEX_LIFECYCLE_CAPABILITY, INDEX_TOUCH_INTERVALS_PER_IDLE_TIMEOUT, MAIN_THREAD_GATE_SLOT, MAX_INDEX_TOUCH_INTERVAL_MS, MIN_COUNTED_SERVER_LIMIT, MIN_UNBOUNDED_SERVER_LIMIT, REBUILD_ANALYSIS_CAPABILITY, RELAY_STREAM_CHUNKS_IN_FLIGHT, RUNNING_TASK_TTL_MS, SERVER_CAPABILITIES, SNAPSHOT_ARCHIVE_CONTENT_TYPE, TASK_CANCEL_CAPABILITY, TASK_FILTER_CAPABILITY, TASK_PROGRESS_WRITE_INTERVAL_MS, TERMINAL_TASK_TTL_MS, acceptorOf, authorizerFor, badRequest, childAppOf, clearGateSlot, corsHeaderReader, createDocumentReadHandlers, createRouteRunner, createSharedGateBuffer, createSharedRequestGate, createVersionHandler, gateSlotOfWorker, httpStatusForNarsilError, loadUWebSockets, parseJson, parseJsonOptional, parseTaskListQuery, registerServerRoutes, rejectInvalid, resolveCors, respondError, respondJson, sendError, sendRelayed, sendStream, serializeBatchResult, serializeNarsilError, serverRoutes, statusLine, toHttpError, validateBatch, validateCreateIndex, validateDocumentBody, validateQuery, validateRebalance, validateSuggest, versionReport };
1196
+ export { ASYNC_IMPORT_CAPABILITY, DEFAULT_IMPORT_BATCH_SIZE, DEFAULT_MAX_BODY_BYTES, DEFAULT_MAX_CONCURRENT_REQUESTS, DEFAULT_MAX_CONCURRENT_TASKS, DEFAULT_MAX_FETCH_DOCUMENTS, DEFAULT_MAX_IMPORT_BYTES, DEFAULT_MAX_IMPORT_ERRORS, DEFAULT_MAX_LINE_BYTES, DEFAULT_MAX_RESTORE_BYTES, DEFAULT_MAX_RESULT_WINDOW, DEFAULT_MAX_RETAINED_TASKS, DEFAULT_MAX_TASK_PAGE_SIZE, DEFAULT_TASK_PAGE_SIZE, DOCUMENT_EXPORT_CAPABILITY, DOCUMENT_EXPORT_CONTENT_TYPE, IMPORT_FLUSHES_IN_FLIGHT, INDEX_LIFECYCLE_CAPABILITY, INDEX_TOUCH_INTERVALS_PER_IDLE_TIMEOUT, MAIN_THREAD_GATE_SLOT, MAX_INDEX_TOUCH_INTERVAL_MS, MIN_COUNTED_SERVER_LIMIT, MIN_UNBOUNDED_SERVER_LIMIT, REBUILD_ANALYSIS_CAPABILITY, RELAY_STREAM_CHUNKS_IN_FLIGHT, RUNNING_TASK_TTL_MS, SERVER_CAPABILITIES, SNAPSHOT_ARCHIVE_CONTENT_TYPE, TASK_CANCEL_CAPABILITY, TASK_FILTER_CAPABILITY, TASK_PROGRESS_WRITE_INTERVAL_MS, TERMINAL_TASK_TTL_MS, acceptorOf, authorizerFor, badRequest, childAppOf, clearGateSlot, corsHeaderReader, createDocumentReadHandlers, createRouteRunner, createSharedGateBuffer, createSharedRequestGate, createVersionHandler, gateSlotOfWorker, httpStatusForNarsilError, loadUWebSockets, parseJson, parseJsonOptional, parseTaskListQuery, refuseRegex, registerServerRoutes, rejectInvalid, resolveCors, respondError, respondJson, sendError, sendRelayed, sendStream, serializeBatchResult, serializeNarsilError, serverRoutes, statusLine, toHttpError, validateBatch, validateCreateIndex, validateDocumentBody, validateQuery, validateRebalance, validateSuggest, versionReport };
@@ -290,4 +290,4 @@ function compareSortValues(aValues, bValues, directions) {
290
290
  return 0;
291
291
  }
292
292
 
293
- export { SORT_MODES, SORT_VALUE_MAX_CODE_POINTS, appendFoldedCodePoint, codePointCount, compareCodePoints, compareComparableKeys, compareComparableValues, compareSortValues, defaultSortMode, exceedsCodePoints, foldedCodePointCount, holdsUnpairedSurrogate, isSortMode, readSortField, sortModeOf, toComparableSortValue, toReducedSortValue, truncateSortString };
293
+ export { SORT_MODES, SORT_VALUE_MAX_CODE_POINTS, appendFoldedCodePoint, codePointCount, compareCodePoints, compareComparableKeys, compareComparableValues, compareSortValues, defaultSortMode, exceedsCodePoints, foldedCodePointCount, holdsUnpairedSurrogate, isSortMode, readSortField, singleFoldTable, sortModeOf, toComparableSortValue, toReducedSortValue, truncateSortString };
@@ -1,17 +1,17 @@
1
- import { validateWorkerConfig, validateIndexName, validatePatternValueLimit, requireSurfaceFormsForPartialFields, validateBM25Params, validatePartitionConfig, executeQuery, queryBindingOf, executePreflight, executeSuggest, executeListDocuments, validateDocId } from './chunk-CTOSGRM7.mjs';
1
+ import { validateWorkerConfig, validateIndexName, validatePatternValueLimit, requireSurfaceFormsForPartialFields, validateBM25Params, validatePartitionConfig, executeQuery, queryBindingOf, executePreflight, executeSuggest, executeListDocuments, validateDocId } from './chunk-WL2GDSCV.mjs';
2
2
  import { ReplicationMessageTypes } from './chunk-GCM3JFVA.mjs';
3
- import { WIRE_BATCH_BUDGET, resolveVectorText, bindEngineCore, restoredConfigFields, restoredEmbedding, collectRequiredFieldFailures, embedChunkDocuments, providedDocId, requireDocumentObject, admitInsert, asBatchInsertError, requireMatchingDocId, embedDocumentFields, assertDocumentCarriesMappedVectors, admitBufferedUpsert, createPendingAdmissions, recordPendingAdmission } from './chunk-LX4JERXI.mjs';
4
- import { NATIVE_CRC32_MIN_BYTES, generateId, decodeEveryStoredDocument, createSharedFrozenSegment, shareSegmentArrays, splitWorkerBudget, resolveWorkerCount, createDirectExecutor, createPartitionRouter, requirePatternSearchFor, requirePartialWordSearchFor, MAX_FILE_BYTES, resolveWorkerEntry, missingWorkerEntry, readHeapStatistics, nodeThreadId, CHECKSUM_YIELD_CHUNK_BYTES, createPartitionManager, buildSegmentPayload, resolvePartitionInsertOptions, createFrozenSegment, resolveRequestThreadCount, vectorsPerFile, vectorsToBytes, VECTOR_FILE_PAYLOAD_VERSION, deadBitsWhere, NO_LIVE_VECTOR_AT_POSITION, createPartitionIndex, selectionKeeps, decodeMapWithoutFields, isCompositePartition, segmentArraysOf, mergeSegmentContents, survivorDocumentsOf, partitionStateOf, VECTOR_FILE_MAX_VECTORS, deadBytesFor, resolveIndexAnalysis, mergeFrozenSegments, workerResourceLimits, decodeVectorIndexParts, bytesToVectors, freezeSegmentShared, DEFAULT_BACKPRESSURE_LIMIT, DEFAULT_REQUEST_TIMEOUT_MS, SHUTDOWN_TIMEOUT_MS, decodeVectorFilePayload, decodeVectorGraphPartPayload, assembleGraphParts, countDead, encodeSegmentState, CONSECUTIVE_TIMEOUTS_BEFORE_DEATH, VALID_HNSW_METRICS, spawnNodeWorker, decodeVectorGraphPayload, graphPartsOfEarlierPayload, decodeStoredDocument, isDead } from './chunk-BVBIQQKG.mjs';
5
- import { collectQueryTermStats, mergePartitionStats, oversampledFacetConfig, fnv1a, kWayMerge, mergeFacets, setNestedValue } from './chunk-VKX2BPXD.mjs';
3
+ import { WIRE_BATCH_BUDGET, resolveVectorText, bindEngineCore, restoredConfigFields, restoredEmbedding, collectRequiredFieldFailures, embedChunkDocuments, providedDocId, requireDocumentObject, admitInsert, asBatchInsertError, requireMatchingDocId, embedDocumentFields, assertDocumentCarriesMappedVectors, admitBufferedUpsert, createPendingAdmissions, recordPendingAdmission } from './chunk-BT62MUM5.mjs';
4
+ import { NATIVE_CRC32_MIN_BYTES, generateId, decodeEveryStoredDocument, createSharedFrozenSegment, shareSegmentArrays, splitWorkerBudget, resolveWorkerCount, createDirectExecutor, createPartitionRouter, requirePartialWordSearchFor, MAX_FILE_BYTES, resolveWorkerEntry, missingWorkerEntry, readHeapStatistics, nodeThreadId, CHECKSUM_YIELD_CHUNK_BYTES, createPartitionManager, buildSegmentPayload, resolvePartitionInsertOptions, createFrozenSegment, resolveRequestThreadCount, vectorsPerFile, vectorsToBytes, VECTOR_FILE_PAYLOAD_VERSION, deadBitsWhere, NO_LIVE_VECTOR_AT_POSITION, createPartitionIndex, selectionKeeps, decodeMapWithoutFields, isCompositePartition, segmentArraysOf, mergeSegmentContents, survivorDocumentsOf, partitionStateOf, VECTOR_FILE_MAX_VECTORS, deadBytesFor, resolveIndexAnalysis, mergeFrozenSegments, workerResourceLimits, decodeVectorIndexParts, bytesToVectors, freezeSegmentShared, DEFAULT_BACKPRESSURE_LIMIT, DEFAULT_REQUEST_TIMEOUT_MS, SHUTDOWN_TIMEOUT_MS, decodeVectorFilePayload, decodeVectorGraphPartPayload, assembleGraphParts, countDead, encodeSegmentState, CONSECUTIVE_TIMEOUTS_BEFORE_DEATH, VALID_HNSW_METRICS, spawnNodeWorker, decodeVectorGraphPayload, graphPartsOfEarlierPayload, decodeStoredDocument, isDead } from './chunk-YOVS4EV5.mjs';
5
+ import { requirePatternSearchFor, collectQueryTermStats, mergePartitionStats, oversampledFacetConfig, fnv1a, availablePatternSearch, kWayMerge, mergeFacets, PATTERN_HOST, setNestedValue } from './chunk-NAMGDK45.mjs';
6
6
  import { detectRuntime, getLanguage } from './chunk-4MQ5F4IL.mjs';
7
- import { MAX_INDEX_CONFIGURATION_BYTES, STATISTICS_BROADCAST_INTERVAL_MS, MAX_SWEEP_INTERVAL_MS, MIN_SWEEP_INTERVAL_MS, HEAP_PRESSURE_WARNING_FRACTION, MAX_EXPORT_LINE_BYTES, IMPORT_BATCH_DOCUMENTS, FOREIGN_STATS_TTL_MS, MAX_IMPORT_REFUSALS_REPORTED, BATCH_CHUNK_SIZE, MIN_DOCUMENTS_FOR_SEGMENTS, HEAP_PRESSURE_REARM_FRACTION, EXPORT_CHUNK_BYTES } from './chunk-3DDUNI6N.mjs';
8
- import { releaseLocksHeldBy } from './chunk-PO53FV4Q.mjs';
7
+ import { MAX_INDEX_CONFIGURATION_BYTES, STATISTICS_BROADCAST_INTERVAL_MS, MAX_SWEEP_INTERVAL_MS, MIN_SWEEP_INTERVAL_MS, HEAP_PRESSURE_WARNING_FRACTION, MAX_EXPORT_LINE_BYTES, IMPORT_BATCH_DOCUMENTS, FOREIGN_STATS_TTL_MS, MAX_IMPORT_REFUSALS_REPORTED, BATCH_CHUNK_SIZE, MIN_DOCUMENTS_FOR_SEGMENTS, HEAP_PRESSURE_REARM_FRACTION, EXPORT_CHUNK_BYTES } from './chunk-V3B24XR7.mjs';
8
+ import { releaseLocksHeldBy } from './chunk-AMGDG4ZJ.mjs';
9
9
  import { requireSearchBackendSettings } from './chunk-2E35UM3G.mjs';
10
- import { DEFAULT_PATTERN_WORK_CAP, MATCHER_STATE_BUDGET_BYTES, MATCHER_SIMULATION_BYTES_PER_POSITION, MATCHER_STATE_OVERHEAD_BYTES, PATTERN_TEST_OPERATORS, MATCHER_CODE_POINT_BYTES } from './chunk-ZKRV5M2P.mjs';
11
- import { getNestedValue, parseVectorDimension } from './chunk-I23G3IZC.mjs';
12
- import { extractVectorFieldsFromSchema, messagePackUpperBoundBytes, validateSchema, requireCreatableSchema, validateVectorPromotion, validateVectorStorage, raiseEarlierReleaseGraphSetting, flattenSchema, isSingleStringFieldType, requireValidFieldTypes, encodeDocument, VECTOR_PATTERN, schemaFieldsOf, MAX_DOCUMENT_NESTING_DEPTH, isQuantizationMode, isStorageMode, validateRequiredFields, requireDocumentWithinSizeLimit, validateDocument, validateDocumentStrict } from './chunk-Z3DQPOJQ.mjs';
10
+ import { DEFAULT_PATTERN_WORK_CAP, MATCHER_STATE_BUDGET_BYTES, PATTERN_TEST_OPERATORS, PATTERN_EXPRESSION_OPERATORS, MATCHER_CODE_POINT_BYTES, MATCHER_SIMULATION_BYTES_PER_POSITION, MATCHER_STATE_OVERHEAD_BYTES } from './chunk-7ODNRREZ.mjs';
11
+ import { getNestedValue, parseVectorDimension } from './chunk-UOJIV2NG.mjs';
12
+ import { extractVectorFieldsFromSchema, messagePackUpperBoundBytes, validateSchema, requireCreatableSchema, validateVectorPromotion, validateVectorStorage, raiseEarlierReleaseGraphSetting, flattenSchema, isSingleStringFieldType, requireValidFieldTypes, encodeDocument, VECTOR_PATTERN, schemaFieldsOf, MAX_DOCUMENT_NESTING_DEPTH, isQuantizationMode, isStorageMode, validateRequiredFields, requireDocumentWithinSizeLimit, validateDocument, validateDocumentStrict } from './chunk-356UOTK2.mjs';
13
13
  import { MIN_M } from './chunk-KEHK2O6P.mjs';
14
- import { compareCodePoints, foldedCodePointCount, codePointCount } from './chunk-LJYTW7GT.mjs';
14
+ import { compareCodePoints, foldedCodePointCount, codePointCount } from './chunk-IBR6634K.mjs';
15
15
  import { createRequestId, isValidWorkerResponse, threadSlotOfWorker } from './chunk-POWOTUKJ.mjs';
16
16
  import { ErrorCodes, NarsilError } from './chunk-I64LXKO3.mjs';
17
17
  import { encode, decode } from '@msgpack/msgpack';
@@ -10228,57 +10228,61 @@ var POSITIONS_PER_WORD = 32;
10228
10228
  function positionWords(positions) {
10229
10229
  return Math.max(1, Math.ceil(positions / POSITIONS_PER_WORD));
10230
10230
  }
10231
- function automatonBytes(positions) {
10232
- return 2 * positionWords(positions) * Uint32Array.BYTES_PER_ELEMENT + positions * MATCHER_CODE_POINT_BYTES;
10233
- }
10234
10231
  function smallestMatcherBytes(positions) {
10235
- return automatonBytes(positions) + positions * MATCHER_SIMULATION_BYTES_PER_POSITION + MATCHER_STATE_OVERHEAD_BYTES + positions * Uint32Array.BYTES_PER_ELEMENT;
10232
+ return 2 * positionWords(positions) * Uint32Array.BYTES_PER_ELEMENT + positions * MATCHER_CODE_POINT_BYTES + positions * MATCHER_SIMULATION_BYTES_PER_POSITION + MATCHER_STATE_OVERHEAD_BYTES + positions * Uint32Array.BYTES_PER_ELEMENT;
10236
10233
  }
10237
- function widestPatternSplit(positions) {
10238
- return Math.max(1, Math.floor(MATCHER_STATE_BUDGET_BYTES / smallestMatcherBytes(positions)));
10234
+ function widestPatternSplit(footprintBytes) {
10235
+ return Math.max(1, Math.floor(MATCHER_STATE_BUDGET_BYTES / Math.max(1, footprintBytes)));
10239
10236
  }
10240
10237
 
10241
10238
  // src/core/pattern-index/query-positions.ts
10242
10239
  function isRecord4(value) {
10243
10240
  return value !== null && typeof value === "object" && !Array.isArray(value);
10244
10241
  }
10245
- function textPositions(text, caseFold) {
10246
- if (typeof text !== "string") return 0;
10247
- return caseFold ? foldedCodePointCount(text) : codePointCount(text);
10242
+ function literalFootprint(text, caseFold) {
10243
+ if (typeof text !== "string") return null;
10244
+ return smallestMatcherBytes(caseFold ? foldedCodePointCount(text) : codePointCount(text));
10248
10245
  }
10249
10246
  function larger(left, right) {
10250
10247
  if (left === null) return right;
10251
10248
  if (right === null) return left;
10252
10249
  return Math.max(left, right);
10253
10250
  }
10254
- function largestTestOf(filter) {
10251
+ function largestTestOf(filter, module) {
10255
10252
  const caseFold = filter.caseFold === true;
10256
10253
  let largest = null;
10257
10254
  for (const operator of PATTERN_TEST_OPERATORS) {
10258
10255
  const operand = filter[operator];
10259
10256
  if (operand === void 0) continue;
10260
10257
  const texts = Array.isArray(operand) ? operand : [operand];
10261
- for (const text of texts) largest = larger(largest, textPositions(text, caseFold));
10258
+ for (const text of texts) largest = larger(largest, literalFootprint(text, caseFold));
10259
+ }
10260
+ for (const operator of PATTERN_EXPRESSION_OPERATORS) {
10261
+ const pattern = filter[operator];
10262
+ if (typeof pattern !== "string") continue;
10263
+ largest = larger(largest, module.expressionFootprint(operator, pattern, caseFold, PATTERN_HOST));
10262
10264
  }
10263
10265
  return largest;
10264
10266
  }
10265
- function largestIn(expression, patternFields) {
10267
+ function largestIn(expression, patternFields, module) {
10266
10268
  let largest = null;
10267
10269
  if (isRecord4(expression.fields)) {
10268
10270
  for (const [fieldPath, filter] of Object.entries(expression.fields)) {
10269
- if (patternFields.has(fieldPath) && isRecord4(filter)) largest = larger(largest, largestTestOf(filter));
10271
+ if (patternFields.has(fieldPath) && isRecord4(filter)) largest = larger(largest, largestTestOf(filter, module));
10270
10272
  }
10271
10273
  }
10272
10274
  const nested = [...expression.and ?? [], ...expression.or ?? []];
10273
10275
  if (expression.not !== void 0) nested.push(expression.not);
10274
- for (const child of nested) largest = larger(largest, largestIn(child, patternFields));
10276
+ for (const child of nested) largest = larger(largest, largestIn(child, patternFields, module));
10275
10277
  return largest;
10276
10278
  }
10277
- function largestPatternTest(expression, schema) {
10279
+ function largestPatternFootprint(expression, schema) {
10278
10280
  if (expression === void 0) return null;
10281
+ const module = availablePatternSearch();
10282
+ if (module === null) return null;
10279
10283
  const patternFields = /* @__PURE__ */ new Set();
10280
10284
  for (const { path, pattern } of schemaFieldsOf(schema)) if (pattern) patternFields.add(path);
10281
- return patternFields.size === 0 ? null : largestIn(expression, patternFields);
10285
+ return patternFields.size === 0 ? null : largestIn(expression, patternFields, module);
10282
10286
  }
10283
10287
 
10284
10288
  // src/engine/orchestration/search.ts
@@ -10345,7 +10349,7 @@ function isWorkCapError(err) {
10345
10349
  function patternSplitWidth(state, indexName, params) {
10346
10350
  const schema = state.indexRegistry.get(indexName)?.config.schema;
10347
10351
  if (schema === void 0) return Number.POSITIVE_INFINITY;
10348
- const largest = largestPatternTest(params.filters, schema);
10352
+ const largest = largestPatternFootprint(params.filters, schema);
10349
10353
  if (largest === null) return Number.POSITIVE_INFINITY;
10350
10354
  if (typeof SharedArrayBuffer !== "function") return 1;
10351
10355
  return widestPatternSplit(largest);
@@ -1,10 +1,47 @@
1
- import { MAX_SORT_FIELDS, MAX_SORT_FIELD_NAME_LENGTH, MAX_CURSOR_LENGTH, MAX_CURSOR_ANCHOR_CODE_POINTS, RESULT_WINDOW, DEFAULT_FUZZY_PREFIX_LENGTH, DEFAULT_PAGE_SIZE, PREFIX_MAX_EXPANSIONS, PARTIAL_WORD_MIN_CODE_POINTS, PARTIAL_WORDS_ADDED_PER_QUERY } from './chunk-3DDUNI6N.mjs';
2
- import { DEFAULT_PATTERN_WORK_CAP, PATTERN_TEST_OPERATORS, bitsetIsEmpty, MAX_PATTERN_TEXT_CODE_POINTS, MAX_PATTERN_POSITIONS, createBitSet, bitsetSet, PATTERN_WORK_FLUSH_UNITS, MATCHER_STATE_BUDGET_BYTES } from './chunk-ZKRV5M2P.mjs';
3
- import { getFlatSchema, tokenize, getFieldValueByInternalId, getFieldValueForDoc, fuzzyTermMatches } from './chunk-I23G3IZC.mjs';
4
- import { MAX_LATITUDE_DEGREES, MAX_LONGITUDE_DEGREES, MIN_POLYGON_POINTS, flattenSchema, parsedTypeOf, isStringValuedBase, withSortableOption, isGeopointOrVectorType, EARTH_RADIUS_METERS, RADIUS_BOX_MARGIN_RATIO, RADIUS_BOX_MARGIN_RADIANS, FULL_TURN_DEGREES, ANTIMERIDIAN_SPAN_DEGREES, PROTOTYPE_POLLUTION_KEYS, DEG_TO_RAD, LOCATION_CODE_BITS_PER_AXIS, isLatitude, isLongitude, isWordIndexedFieldType, partialFieldsOf, MAX_COVERING_CELLS } from './chunk-Z3DQPOJQ.mjs';
5
- import { compareCodePoints, sortModeOf, defaultSortMode, SORT_VALUE_MAX_CODE_POINTS, toReducedSortValue, readSortField, compareComparableKeys, toComparableSortValue, exceedsCodePoints, holdsUnpairedSurrogate, isSortMode, SORT_MODES, compareSortValues, foldedCodePointCount, codePointCount } from './chunk-LJYTW7GT.mjs';
1
+ import { MAX_SORT_FIELDS, MAX_SORT_FIELD_NAME_LENGTH, MAX_CURSOR_LENGTH, MAX_CURSOR_ANCHOR_CODE_POINTS, RESULT_WINDOW, DEFAULT_FUZZY_PREFIX_LENGTH, MAX_FILTER_DEPTH, DEFAULT_PAGE_SIZE, MAX_FILTER_ARRAY_SIZE, GEO_UNIT_METRES, MAX_FILTER_TESTS, PREFIX_MAX_EXPANSIONS, PARTIAL_WORD_MIN_CODE_POINTS, PARTIAL_WORDS_ADDED_PER_QUERY } from './chunk-V3B24XR7.mjs';
2
+ import { DEFAULT_PATTERN_WORK_CAP, patternSearchModule, PATTERN_TEST_OPERATORS, bitsetIsEmpty, PATTERN_EXPRESSION_OPERATORS, MAX_PATTERN_POSITIONS, createBitSet, bitsetSet, MAX_PATTERN_TEXT_CODE_POINTS, PATTERN_WORK_FLUSH_UNITS, MATCHER_STATE_BUDGET_BYTES } from './chunk-7ODNRREZ.mjs';
3
+ import { getFlatSchema, tokenize, getFieldValueByInternalId, getFieldValueForDoc, fuzzyTermMatches } from './chunk-UOJIV2NG.mjs';
4
+ import { schemaFieldsOf, MAX_LATITUDE_DEGREES, MAX_LONGITUDE_DEGREES, MIN_POLYGON_POINTS, flattenSchema, parsedTypeOf, isStringValuedBase, withSortableOption, isGeopointOrVectorType, EARTH_RADIUS_METERS, RADIUS_BOX_MARGIN_RATIO, RADIUS_BOX_MARGIN_RADIANS, FULL_TURN_DEGREES, ANTIMERIDIAN_SPAN_DEGREES, PROTOTYPE_POLLUTION_KEYS, DEG_TO_RAD, LOCATION_CODE_BITS_PER_AXIS, isLatitude, isLongitude, isWordIndexedFieldType, partialFieldsOf, MAX_COVERING_CELLS } from './chunk-356UOTK2.mjs';
5
+ import { appendFoldedCodePoint, compareCodePoints, sortModeOf, defaultSortMode, SORT_VALUE_MAX_CODE_POINTS, toReducedSortValue, readSortField, compareComparableKeys, toComparableSortValue, exceedsCodePoints, singleFoldTable, holdsUnpairedSurrogate, isSortMode, SORT_MODES, compareSortValues, foldedCodePointCount, codePointCount } from './chunk-IBR6634K.mjs';
6
6
  import { NarsilError, ErrorCodes } from './chunk-I64LXKO3.mjs';
7
7
 
8
+ // src/core/pattern-index/platform.ts
9
+ function platformPatternSearch() {
10
+ return patternSearchModule;
11
+ }
12
+
13
+ // src/core/pattern-index/registry.ts
14
+ var registered = null;
15
+ function isPatternSearchModule(value) {
16
+ return value !== null && typeof value === "object" && value.name === "pattern" && "createIndex" in value && typeof value.createIndex === "function" && "readArrays" in value && typeof value.readArrays === "function" && "mergeArrays" in value && typeof value.mergeArrays === "function" && "matchInto" in value && typeof value.matchInto === "function" && "checkExpression" in value && typeof value.checkExpression === "function" && "expressionFootprint" in value && typeof value.expressionFootprint === "function";
17
+ }
18
+ function registerPatternSearch(module) {
19
+ if (!isPatternSearchModule(module)) {
20
+ throw new NarsilError(
21
+ ErrorCodes.CONFIG_INVALID,
22
+ 'registerPatternSearch takes the patternSearch object that "@delali/narsil/pattern" exports'
23
+ );
24
+ }
25
+ registered = module;
26
+ }
27
+ function availablePatternSearch() {
28
+ return registered ?? platformPatternSearch();
29
+ }
30
+ function requirePatternSearchFor(schema) {
31
+ for (const { path, pattern } of schemaFieldsOf(schema)) {
32
+ if (pattern) requirePatternSearch(path);
33
+ }
34
+ }
35
+ function requirePatternSearch(fieldPath) {
36
+ const module = availablePatternSearch();
37
+ if (module !== null) return module;
38
+ throw new NarsilError(
39
+ ErrorCodes.CONFIG_INVALID,
40
+ `Field "${fieldPath}" is a pattern field, but this bundle contains no pattern search code. Add import { patternSearch } from '@delali/narsil/pattern', then call registerPatternSearch(patternSearch) before you create or load the index`,
41
+ { field: fieldPath }
42
+ );
43
+ }
44
+
8
45
  // src/core/pattern-index/work-meter.ts
9
46
  var COUNTER_BYTES = 8;
10
47
  function capExceeded(cap) {
@@ -529,12 +566,6 @@ function decodeCursorText(encoded) {
529
566
  return new TextDecoder().decode(bytes);
530
567
  }
531
568
 
532
- // src/filters/constants.ts
533
- var MAX_FILTER_DEPTH = 30;
534
- var MAX_FILTER_TESTS = 1024;
535
- var MAX_FILTER_ARRAY_SIZE = 65536;
536
- var GEO_UNIT_METRES = { km: 1e3, mi: 1609.344, m: 1 };
537
-
538
569
  // src/filters/operands/checks.ts
539
570
  function operandKindOf(type) {
540
571
  if (type === void 0) return void 0;
@@ -955,6 +986,34 @@ function requireSizeOperands(fieldPath, filter, type) {
955
986
  }
956
987
  }
957
988
 
989
+ // src/core/pattern-index/host.ts
990
+ var NO_SOURCES = [];
991
+ var foldSources = null;
992
+ function sourcesByFold() {
993
+ if (foldSources !== null) return foldSources;
994
+ const sources = /* @__PURE__ */ new Map();
995
+ const add = (source, folded) => {
996
+ const known = sources.get(folded);
997
+ if (known === void 0) sources.set(folded, [source]);
998
+ else known.push(source);
999
+ };
1000
+ for (const [source, folded] of singleFoldTable()) add(source, folded);
1001
+ foldSources = sources;
1002
+ return sources;
1003
+ }
1004
+ function singleFoldSources(folded) {
1005
+ return sourcesByFold().get(folded) ?? NO_SOURCES;
1006
+ }
1007
+ var PATTERN_HOST = { appendFoldedCodePoint, singleFoldSources };
1008
+ function patternIndexOf(indexes, fieldPath) {
1009
+ let index = indexes.get(fieldPath);
1010
+ if (index === void 0) {
1011
+ index = requirePatternSearch(fieldPath).createIndex(PATTERN_HOST);
1012
+ indexes.set(fieldPath, index);
1013
+ }
1014
+ return index;
1015
+ }
1016
+
958
1017
  // src/filters/operands/pattern.ts
959
1018
  function requirePatternField(fieldPath, operator, type) {
960
1019
  if (parsedTypeOf(type)?.pattern === true) return;
@@ -965,14 +1024,16 @@ function requirePatternField(fieldPath, operator, type) {
965
1024
  operator
966
1025
  );
967
1026
  }
1027
+ function requireTextLength(fieldPath, operator, text) {
1028
+ if (!exceedsCodePoints(text, MAX_PATTERN_TEXT_CODE_POINTS)) return;
1029
+ invalid(
1030
+ `The text of "${operator}" on pattern field "${fieldPath}" holds more than ${MAX_PATTERN_TEXT_CODE_POINTS} code points`,
1031
+ fieldPath,
1032
+ operator
1033
+ );
1034
+ }
968
1035
  function requirePatternText(fieldPath, operator, text, caseFold) {
969
- if (exceedsCodePoints(text, MAX_PATTERN_TEXT_CODE_POINTS)) {
970
- invalid(
971
- `The text of "${operator}" on pattern field "${fieldPath}" holds more than ${MAX_PATTERN_TEXT_CODE_POINTS} code points`,
972
- fieldPath,
973
- operator
974
- );
975
- }
1036
+ requireTextLength(fieldPath, operator, text);
976
1037
  if (caseFold && foldedCodePointCount(text) > MAX_PATTERN_POSITIONS) {
977
1038
  invalid(
978
1039
  `The text of "${operator}" on pattern field "${fieldPath}" has a case fold of more than ${MAX_PATTERN_POSITIONS} code points, while a pattern holds at most ${MAX_PATTERN_POSITIONS} positions`,
@@ -982,6 +1043,23 @@ function requirePatternText(fieldPath, operator, text, caseFold) {
982
1043
  }
983
1044
  }
984
1045
  var ELEMENT_OPERATORS2 = ["matchesAny", "containsAll"];
1046
+ function requireExpressions(fieldPath, filter, type) {
1047
+ for (const operator of PATTERN_EXPRESSION_OPERATORS) {
1048
+ const pattern = filter[operator];
1049
+ if (pattern === void 0) continue;
1050
+ if (typeof pattern !== "string")
1051
+ invalid(`"${operator}" on field "${fieldPath}" must be a string`, fieldPath, operator);
1052
+ requirePatternField(fieldPath, operator, type);
1053
+ requireTextLength(fieldPath, operator, pattern);
1054
+ requirePatternSearch(fieldPath).checkExpression(
1055
+ operator,
1056
+ pattern,
1057
+ filter.caseFold === true,
1058
+ fieldPath,
1059
+ PATTERN_HOST
1060
+ );
1061
+ }
1062
+ }
985
1063
  function requirePatternOperands(fieldPath, filter, type) {
986
1064
  if (filter.contains !== void 0) {
987
1065
  if (typeof filter.contains !== "string") {
@@ -995,6 +1073,7 @@ function requirePatternOperands(fieldPath, filter, type) {
995
1073
  }
996
1074
  requirePatternField(fieldPath, "caseFold", type);
997
1075
  }
1076
+ requireExpressions(fieldPath, filter, type);
998
1077
  if (parsedTypeOf(type)?.pattern !== true) return;
999
1078
  const caseFold = filter.caseFold === true;
1000
1079
  for (const operator of PATTERN_TEST_OPERATORS) {
@@ -2078,4 +2157,4 @@ function setNestedValue(obj, path, value) {
2078
2157
  current[segments[segments.length - 1]] = value;
2079
2158
  }
2080
2159
 
2081
- export { GEO_UNIT_METRES, MAX_FILTER_ARRAY_SIZE, MAX_FILTER_DEPTH, MAX_FILTER_TESTS, applyPagination, applyProjection, applySorting, clampRowCount, cloneProjected, collectQueryTermStats, computeFacets, countsWithoutScores, coveringRanges, createPatternWorkMeter, decodePageCursor, encodePageCursor, everyValueFacetConfig, fanOutMatchCount, fanOutQuery, filterTestCount, fnv1a, fnv1aBytes, fnv1aUint32s, fulltextMatches, joinPatternWorkMeter, kWayMerge, locationCode, mergeFacets, mergePartitionStats, normalizeSort, oversampledFacetConfig, oversampledShardSize, partitionsIn, polygonBoxes, polygonContainment, projectionKeepsField, pruneStatsToQueryTerms, radiusBoxes, readSortValues, requireMatchingCursor, requireSortableFields, requireValidFilter, requireValidOperands, requireWithinResultWindow, resolveProjection, sanitizeGlobalStats, setNestedValue, sortModesOf, sortSignatureEntry, sortSignatureOf, undeclaredFieldOnStrictIndex, undeclaredFilterField };
2160
+ export { PATTERN_HOST, applyPagination, applyProjection, applySorting, availablePatternSearch, clampRowCount, cloneProjected, collectQueryTermStats, computeFacets, countsWithoutScores, coveringRanges, createPatternWorkMeter, decodePageCursor, encodePageCursor, everyValueFacetConfig, fanOutMatchCount, fanOutQuery, filterTestCount, fnv1a, fnv1aBytes, fnv1aUint32s, fulltextMatches, joinPatternWorkMeter, kWayMerge, locationCode, mergeFacets, mergePartitionStats, normalizeSort, oversampledFacetConfig, oversampledShardSize, partitionsIn, patternIndexOf, polygonBoxes, polygonContainment, projectionKeepsField, pruneStatsToQueryTerms, radiusBoxes, readSortValues, registerPatternSearch, requireMatchingCursor, requirePatternSearch, requirePatternSearchFor, requireSortableFields, requireValidFilter, requireValidOperands, requireWithinResultWindow, resolveProjection, sanitizeGlobalStats, setNestedValue, sortModesOf, sortSignatureEntry, sortSignatureOf, undeclaredFieldOnStrictIndex, undeclaredFilterField };
@@ -1,7 +1,7 @@
1
- import { readSharedConfigFields, restoredEmbedding, restoredPartitionConfig, MAX_PARTITION_COUNT, MAX_REPLICATION_FACTOR } from './chunk-LX4JERXI.mjs';
1
+ import { readSharedConfigFields, restoredEmbedding, restoredPartitionConfig, MAX_PARTITION_COUNT, MAX_REPLICATION_FACTOR } from './chunk-BT62MUM5.mjs';
2
2
  import { getLanguage } from './chunk-4MQ5F4IL.mjs';
3
- import { MAX_INDEX_NAME_LENGTH, INDEX_NAME_PATTERN } from './chunk-3DDUNI6N.mjs';
4
- import { compareCodePoints } from './chunk-LJYTW7GT.mjs';
3
+ import { MAX_INDEX_NAME_LENGTH, INDEX_NAME_PATTERN } from './chunk-V3B24XR7.mjs';
4
+ import { compareCodePoints } from './chunk-IBR6634K.mjs';
5
5
  import { NarsilError, ErrorCodes } from './chunk-I64LXKO3.mjs';
6
6
  import { encode, decode } from '@msgpack/msgpack';
7
7
 
@@ -1,4 +1,4 @@
1
- import { isWordIndexedBase, flattenSchema } from './chunk-Z3DQPOJQ.mjs';
1
+ import { isWordIndexedBase, flattenSchema } from './chunk-356UOTK2.mjs';
2
2
  import { createNarsilError, ErrorCodes } from './chunk-I64LXKO3.mjs';
3
3
 
4
4
  // src/core/tokenizer/constants.ts
@@ -1,3 +1,9 @@
1
+ // src/filters/constants.ts
2
+ var MAX_FILTER_DEPTH = 30;
3
+ var MAX_FILTER_TESTS = 1024;
4
+ var MAX_FILTER_ARRAY_SIZE = 65536;
5
+ var GEO_UNIT_METRES = { km: 1e3, mi: 1609.344, m: 1 };
6
+
1
7
  // src/search/constants.ts
2
8
  var RESULT_WINDOW = 1e4;
3
9
  var DEFAULT_PAGE_SIZE = 10;
@@ -45,4 +51,4 @@ var SUGGEST_OVERSAMPLE_FACTOR = 1.5;
45
51
  var SUGGEST_OVERSAMPLE_PADDING = 10;
46
52
  var MAX_SUGGEST_SCATTER_LIMIT = Math.ceil(MAX_SUGGEST_LIMIT * SUGGEST_OVERSAMPLE_FACTOR) + SUGGEST_OVERSAMPLE_PADDING;
47
53
 
48
- export { ABSOLUTE_WINDOWS_PATH_PATTERN, BATCH_CHUNK_SIZE, DEFAULT_FUZZY_PREFIX_LENGTH, DEFAULT_LIMIT, DEFAULT_LINEAR_ALPHA, DEFAULT_MAX_PER_GROUP, DEFAULT_OFFSET, DEFAULT_PAGE_SIZE, DEFAULT_RANK_CONSTANT, DEFAULT_SUGGEST_LIMIT, EXPORT_CHUNK_BYTES, FOREIGN_STATS_TTL_MS, HEAP_PRESSURE_REARM_FRACTION, HEAP_PRESSURE_WARNING_FRACTION, IMPORT_BATCH_DOCUMENTS, INDEX_NAME_PATTERN, MAX_CURSOR_ANCHOR_CODE_POINTS, MAX_CURSOR_LENGTH, MAX_DOC_ID_LENGTH, MAX_EXPORT_LINE_BYTES, MAX_IMPORT_REFUSALS_REPORTED, MAX_INDEX_CONFIGURATION_BYTES, MAX_INDEX_NAME_LENGTH, MAX_LINEAR_ALPHA, MAX_PREFIX_LENGTH, MAX_SORT_FIELDS, MAX_SORT_FIELD_NAME_LENGTH, MAX_SUGGEST_LIMIT, MAX_SUGGEST_SCATTER_LIMIT, MAX_SWEEP_INTERVAL_MS, MAX_TOLERANCE, MIN_DOCUMENTS_FOR_SEGMENTS, MIN_LINEAR_ALPHA, MIN_RANK_CONSTANT, MIN_SWEEP_INTERVAL_MS, MODULE_URL_SCHEME_PATTERN, PARTIAL_WORDS_ADDED_PER_QUERY, PARTIAL_WORD_MIN_CODE_POINTS, PREFIX_MAX_EXPANSIONS, RESULT_WINDOW, STATISTICS_BROADCAST_INTERVAL_MS, SUGGEST_OVERSAMPLE_FACTOR, SUGGEST_OVERSAMPLE_PADDING };
54
+ export { ABSOLUTE_WINDOWS_PATH_PATTERN, BATCH_CHUNK_SIZE, DEFAULT_FUZZY_PREFIX_LENGTH, DEFAULT_LIMIT, DEFAULT_LINEAR_ALPHA, DEFAULT_MAX_PER_GROUP, DEFAULT_OFFSET, DEFAULT_PAGE_SIZE, DEFAULT_RANK_CONSTANT, DEFAULT_SUGGEST_LIMIT, EXPORT_CHUNK_BYTES, FOREIGN_STATS_TTL_MS, GEO_UNIT_METRES, HEAP_PRESSURE_REARM_FRACTION, HEAP_PRESSURE_WARNING_FRACTION, IMPORT_BATCH_DOCUMENTS, INDEX_NAME_PATTERN, MAX_CURSOR_ANCHOR_CODE_POINTS, MAX_CURSOR_LENGTH, MAX_DOC_ID_LENGTH, MAX_EXPORT_LINE_BYTES, MAX_FILTER_ARRAY_SIZE, MAX_FILTER_DEPTH, MAX_FILTER_TESTS, MAX_IMPORT_REFUSALS_REPORTED, MAX_INDEX_CONFIGURATION_BYTES, MAX_INDEX_NAME_LENGTH, MAX_LINEAR_ALPHA, MAX_PREFIX_LENGTH, MAX_SORT_FIELDS, MAX_SORT_FIELD_NAME_LENGTH, MAX_SUGGEST_LIMIT, MAX_SUGGEST_SCATTER_LIMIT, MAX_SWEEP_INTERVAL_MS, MAX_TOLERANCE, MIN_DOCUMENTS_FOR_SEGMENTS, MIN_LINEAR_ALPHA, MIN_RANK_CONSTANT, MIN_SWEEP_INTERVAL_MS, MODULE_URL_SCHEME_PATTERN, PARTIAL_WORDS_ADDED_PER_QUERY, PARTIAL_WORD_MIN_CODE_POINTS, PREFIX_MAX_EXPANSIONS, RESULT_WINDOW, STATISTICS_BROADCAST_INTERVAL_MS, SUGGEST_OVERSAMPLE_FACTOR, SUGGEST_OVERSAMPLE_PADDING };
@@ -1,9 +1,9 @@
1
- import { clampRowCount, sortSignatureOf, requireSortableFields, decodePageCursor, requireMatchingCursor, resolveProjection, encodePageCursor, requireWithinResultWindow, normalizeSort, fanOutQuery, sortModesOf, applySorting, applyPagination, projectionKeepsField, countsWithoutScores, fanOutMatchCount, fnv1aBytes, requireValidFilter, createPatternWorkMeter, everyValueFacetConfig, fulltextMatches, mergeFacets, pruneStatsToQueryTerms, partitionsIn, undeclaredFieldOnStrictIndex } from './chunk-VKX2BPXD.mjs';
2
- import { MAX_INDEX_NAME_LENGTH, INDEX_NAME_PATTERN, MAX_DOC_ID_LENGTH, DEFAULT_LIMIT, DEFAULT_MAX_PER_GROUP, DEFAULT_SUGGEST_LIMIT, MAX_SUGGEST_LIMIT, MAX_SUGGEST_SCATTER_LIMIT, ABSOLUTE_WINDOWS_PATH_PATTERN, MODULE_URL_SCHEME_PATTERN, DEFAULT_LINEAR_ALPHA, MIN_LINEAR_ALPHA, MAX_LINEAR_ALPHA, DEFAULT_RANK_CONSTANT, MIN_RANK_CONSTANT, DEFAULT_OFFSET, DEFAULT_FUZZY_PREFIX_LENGTH, RESULT_WINDOW, PARTIAL_WORD_MIN_CODE_POINTS, PARTIAL_WORDS_ADDED_PER_QUERY, MAX_TOLERANCE, MAX_PREFIX_LENGTH } from './chunk-3DDUNI6N.mjs';
1
+ import { clampRowCount, sortSignatureOf, requireSortableFields, decodePageCursor, requireMatchingCursor, resolveProjection, encodePageCursor, requireWithinResultWindow, normalizeSort, fanOutQuery, sortModesOf, applySorting, applyPagination, projectionKeepsField, countsWithoutScores, fanOutMatchCount, fnv1aBytes, requireValidFilter, createPatternWorkMeter, everyValueFacetConfig, fulltextMatches, mergeFacets, pruneStatsToQueryTerms, partitionsIn, undeclaredFieldOnStrictIndex } from './chunk-NAMGDK45.mjs';
2
+ import { MAX_INDEX_NAME_LENGTH, INDEX_NAME_PATTERN, MAX_DOC_ID_LENGTH, DEFAULT_LIMIT, DEFAULT_MAX_PER_GROUP, DEFAULT_SUGGEST_LIMIT, MAX_SUGGEST_LIMIT, MAX_SUGGEST_SCATTER_LIMIT, ABSOLUTE_WINDOWS_PATH_PATTERN, MODULE_URL_SCHEME_PATTERN, DEFAULT_LINEAR_ALPHA, MIN_LINEAR_ALPHA, MAX_LINEAR_ALPHA, DEFAULT_RANK_CONSTANT, MIN_RANK_CONSTANT, DEFAULT_OFFSET, DEFAULT_FUZZY_PREFIX_LENGTH, RESULT_WINDOW, PARTIAL_WORD_MIN_CODE_POINTS, PARTIAL_WORDS_ADDED_PER_QUERY, MAX_TOLERANCE, MAX_PREFIX_LENGTH } from './chunk-V3B24XR7.mjs';
3
3
  import { MIN_OVERSAMPLE } from './chunk-ZJ4CSAB2.mjs';
4
- import { tokenize, fuzzyTermMatches } from './chunk-I23G3IZC.mjs';
5
- import { partialFieldsOf, MIN_PATTERN_VALUE_LIMIT, MAX_PATTERN_VALUE_LIMIT, flattenSchema, isWordIndexedFieldType, isGeopointOrVectorType } from './chunk-Z3DQPOJQ.mjs';
6
- import { holdsUnpairedSurrogate, compareCodePoints, compareComparableKeys, codePointCount } from './chunk-LJYTW7GT.mjs';
4
+ import { tokenize, fuzzyTermMatches } from './chunk-UOJIV2NG.mjs';
5
+ import { partialFieldsOf, MIN_PATTERN_VALUE_LIMIT, MAX_PATTERN_VALUE_LIMIT, flattenSchema, isWordIndexedFieldType, isGeopointOrVectorType } from './chunk-356UOTK2.mjs';
6
+ import { holdsUnpairedSurrogate, compareCodePoints, compareComparableKeys, codePointCount } from './chunk-IBR6634K.mjs';
7
7
  import { NarsilError, ErrorCodes } from './chunk-I64LXKO3.mjs';
8
8
 
9
9
  // src/search/cursor-binding.ts
@@ -1,15 +1,14 @@
1
- import { joinPatternWorkMeter, countsWithoutScores, fanOutMatchCount, fanOutQuery, sanitizeGlobalStats, computeFacets, cloneProjected, projectionKeepsField, setNestedValue, fnv1a, everyValueFacetConfig, mergeFacets, undeclaredFilterField, requireValidOperands, kWayMerge, polygonContainment, polygonBoxes, radiusBoxes, locationCode, coveringRanges, GEO_UNIT_METRES } from './chunk-VKX2BPXD.mjs';
1
+ import { requirePatternSearchFor, patternIndexOf, joinPatternWorkMeter, countsWithoutScores, fanOutMatchCount, fanOutQuery, sanitizeGlobalStats, computeFacets, cloneProjected, projectionKeepsField, setNestedValue, fnv1a, requirePatternSearch, PATTERN_HOST, everyValueFacetConfig, mergeFacets, undeclaredFilterField, requireValidOperands, kWayMerge, polygonContainment, polygonBoxes, radiusBoxes, locationCode, coveringRanges } from './chunk-NAMGDK45.mjs';
2
2
  import { getLanguage, detectRuntime } from './chunk-4MQ5F4IL.mjs';
3
- import { MAX_DOC_ID_LENGTH } from './chunk-3DDUNI6N.mjs';
4
- import { SCRATCH_SLOTS_PER_THREAD_POOL, osqRecordBytes, openSharedVectorField, osqBitsOf, createVectorStore, DISK_STORAGE_BLOCK_BYTES, createOsqQuantizer, magnitude, createHNSWIndex, nativeStoreScratchBytes, createOrdinalFilter, isTombstoned, addToOrdinalFilter, ordinalFilterValues, nativeScoresOf, toScore, removeFromOrdinalFilter, euclideanDistance, dotProduct, cosineSimilarityWithMagnitudes, ordinalFilterHas, STORE_CALIBRATION_GENERATION, entryForOrd, toDistance, sharedMemoryAvailable, requireWholeNeighbourLists, topLayerInParts, GRAPH_BUILD_CHUNKS_IN_FLIGHT_PER_WORKER, GRAPH_BUILD_DISPATCH_CHUNK, releaseLocksHeldBy, VECTOR_SEARCH_TIMEOUT_MS, VECTOR_SEARCH_LOAD_TIMEOUT_MS, VECTOR_INSERT_TIMEOUT_MS, VECTOR_SCRATCH_SLOTS } from './chunk-PO53FV4Q.mjs';
3
+ import { MAX_DOC_ID_LENGTH, GEO_UNIT_METRES } from './chunk-V3B24XR7.mjs';
4
+ import { SCRATCH_SLOTS_PER_THREAD_POOL, osqRecordBytes, openSharedVectorField, osqBitsOf, createVectorStore, DISK_STORAGE_BLOCK_BYTES, createOsqQuantizer, magnitude, createHNSWIndex, nativeStoreScratchBytes, createOrdinalFilter, isTombstoned, addToOrdinalFilter, ordinalFilterValues, nativeScoresOf, toScore, removeFromOrdinalFilter, euclideanDistance, dotProduct, cosineSimilarityWithMagnitudes, ordinalFilterHas, STORE_CALIBRATION_GENERATION, entryForOrd, toDistance, sharedMemoryAvailable, requireWholeNeighbourLists, topLayerInParts, GRAPH_BUILD_CHUNKS_IN_FLIGHT_PER_WORKER, GRAPH_BUILD_DISPATCH_CHUNK, releaseLocksHeldBy, VECTOR_SEARCH_TIMEOUT_MS, VECTOR_SEARCH_LOAD_TIMEOUT_MS, VECTOR_INSERT_TIMEOUT_MS, VECTOR_SCRATCH_SLOTS } from './chunk-AMGDG4ZJ.mjs';
5
5
  import { noteFallback } from './chunk-2E35UM3G.mjs';
6
- import { GrowableUint32, patternSearchModule } from './chunk-XW25X6AU.mjs';
7
- import { bitsetHas, createBitSet, bitsetSet, bitsetOrInto, bitsetAndNotInto, bitsetAndInto, PATTERN_RUN_CODE_POINTS, bitsetFromSet, bitsetIsEmpty, bitsetAnd, bitsetNot } from './chunk-ZKRV5M2P.mjs';
8
- import { encodePartialSpellings, countSpelling, expandTermPrefix, suggestDisplayTerms, spellingCountsOf, codePointOrder, encodeStringBlob, partialWordSearchModule, partitionDocumentFrequency } from './chunk-T5ZWEWVD.mjs';
9
- import { tokenizeOptions, getNestedValue, visitTokens, textFieldsChanged, fuzzyPrefixOf, boundedLevenshtein, getFlatSchema, tokenize, getOrCreateFieldNameIndex, tokenizeIterator, getFieldValueByInternalId } from './chunk-I23G3IZC.mjs';
10
- import { schemaFieldsOf, partialFieldsOf, isWordIndexedBase, validateDocument, validateDocumentStrict, encodeDocument, extractVectorFieldsFromSchema, parsedTypeOf, isListBase, VINCENTY_CONVERGENCE_THRESHOLD, EARTH_RADIUS_METERS, VINCENTY_MAX_ITERATIONS, DEG_TO_RAD } from './chunk-Z3DQPOJQ.mjs';
6
+ import { GrowableUint32, bitsetHas, createBitSet, bitsetSet, bitsetOrInto, bitsetAndNotInto, bitsetAndInto, PATTERN_RUN_CODE_POINTS, bitsetFromSet, bitsetIsEmpty, bitsetAnd, bitsetNot } from './chunk-7ODNRREZ.mjs';
7
+ import { encodePartialSpellings, countSpelling, expandTermPrefix, suggestDisplayTerms, spellingCountsOf, codePointOrder, encodeStringBlob, partialWordSearchModule, partitionDocumentFrequency } from './chunk-AIUOAN7Y.mjs';
8
+ import { tokenizeOptions, getNestedValue, visitTokens, textFieldsChanged, fuzzyPrefixOf, boundedLevenshtein, getFlatSchema, tokenize, getOrCreateFieldNameIndex, tokenizeIterator, getFieldValueByInternalId } from './chunk-UOJIV2NG.mjs';
9
+ import { partialFieldsOf, schemaFieldsOf, isWordIndexedBase, validateDocument, validateDocumentStrict, encodeDocument, extractVectorFieldsFromSchema, parsedTypeOf, isListBase, VINCENTY_CONVERGENCE_THRESHOLD, EARTH_RADIUS_METERS, VINCENTY_MAX_ITERATIONS, DEG_TO_RAD } from './chunk-356UOTK2.mjs';
11
10
  import { MAX_M, EARLIER_RELEASE_MIN_M, MIN_M } from './chunk-KEHK2O6P.mjs';
12
- import { compareCodePoints, appendFoldedCodePoint, toReducedSortValue, readSortField, defaultSortMode, compareComparableValues, truncateSortString, SORT_VALUE_MAX_CODE_POINTS } from './chunk-LJYTW7GT.mjs';
11
+ import { compareCodePoints, toReducedSortValue, readSortField, defaultSortMode, compareComparableValues, truncateSortString, SORT_VALUE_MAX_CODE_POINTS } from './chunk-IBR6634K.mjs';
13
12
  import { NarsilError, ErrorCodes } from './chunk-I64LXKO3.mjs';
14
13
  import { totalmem } from 'os';
15
14
  import { getHeapStatistics } from 'v8';
@@ -944,54 +943,6 @@ function createSurfaceRegistry() {
944
943
  };
945
944
  }
946
945
 
947
- // src/core/pattern-index/platform.ts
948
- function platformPatternSearch() {
949
- return patternSearchModule;
950
- }
951
-
952
- // src/core/pattern-index/registry.ts
953
- var registered = null;
954
- function isPatternSearchModule(value) {
955
- return value !== null && typeof value === "object" && value.name === "pattern" && "createIndex" in value && typeof value.createIndex === "function" && "readArrays" in value && typeof value.readArrays === "function" && "mergeArrays" in value && typeof value.mergeArrays === "function" && "matchInto" in value && typeof value.matchInto === "function";
956
- }
957
- function registerPatternSearch(module) {
958
- if (!isPatternSearchModule(module)) {
959
- throw new NarsilError(
960
- ErrorCodes.CONFIG_INVALID,
961
- 'registerPatternSearch takes the patternSearch object that "@delali/narsil/pattern" exports'
962
- );
963
- }
964
- registered = module;
965
- }
966
- function availablePatternSearch() {
967
- return registered ?? platformPatternSearch();
968
- }
969
- function requirePatternSearchFor(schema) {
970
- for (const { path, pattern } of schemaFieldsOf(schema)) {
971
- if (pattern) requirePatternSearch(path);
972
- }
973
- }
974
- function requirePatternSearch(fieldPath) {
975
- const module = availablePatternSearch();
976
- if (module !== null) return module;
977
- throw new NarsilError(
978
- ErrorCodes.CONFIG_INVALID,
979
- `Field "${fieldPath}" is a pattern field, but this bundle contains no pattern search code. Add import { patternSearch } from '@delali/narsil/pattern', then call registerPatternSearch(patternSearch) before you create or load the index`,
980
- { field: fieldPath }
981
- );
982
- }
983
-
984
- // src/core/pattern-index/host.ts
985
- var PATTERN_HOST = { appendFoldedCodePoint };
986
- function patternIndexOf(indexes, fieldPath) {
987
- let index = indexes.get(fieldPath);
988
- if (index === void 0) {
989
- index = requirePatternSearch(fieldPath).createIndex(PATTERN_HOST);
990
- indexes.set(fieldPath, index);
991
- }
992
- return index;
993
- }
994
-
995
946
  // src/geo/haversine.ts
996
947
  function haversineDistance(lat1, lon1, lat2, lon2) {
997
948
  const phi1 = lat1 * DEG_TO_RAD;
@@ -2035,6 +1986,8 @@ function evaluatePatternTests(fieldPath, filter, context, bitsets) {
2035
1986
  if (typeof filter.startsWith === "string") bitsets.push(matching("startsWith", [filter.startsWith]));
2036
1987
  if (typeof filter.endsWith === "string") bitsets.push(matching("endsWith", [filter.endsWith]));
2037
1988
  if (typeof filter.contains === "string") bitsets.push(matching("contains", [filter.contains]));
1989
+ if (typeof filter.wildcard === "string") bitsets.push(matching("wildcard", [filter.wildcard]));
1990
+ if (typeof filter.regex === "string") bitsets.push(matching("regex", [filter.regex]));
2038
1991
  }
2039
1992
 
2040
1993
  // src/filters/field-tests.ts
@@ -2239,6 +2192,8 @@ var FIELD_FILTER_OPERATORS = [
2239
2192
  "startsWith",
2240
2193
  "endsWith",
2241
2194
  "contains",
2195
+ "wildcard",
2196
+ "regex",
2242
2197
  "caseFold",
2243
2198
  "containsAll",
2244
2199
  "matchesAny",
@@ -3525,7 +3480,7 @@ function platformPartialWordSearch() {
3525
3480
  }
3526
3481
 
3527
3482
  // src/core/partition/partial-words/registry.ts
3528
- var registered2 = null;
3483
+ var registered = null;
3529
3484
  function isPartialWordSearchModule(value) {
3530
3485
  return value !== null && typeof value === "object" && value.name === "partialWords" && "createGrowingSlot" in value && typeof value.createGrowingSlot === "function" && "createFrozenSlot" in value && typeof value.createFrozenSlot === "function" && "buildTable" in value && typeof value.buildTable === "function" && "expand" in value && typeof value.expand === "function";
3531
3486
  }
@@ -3536,10 +3491,10 @@ function registerPartialWordSearch(module) {
3536
3491
  'Pass registerPartialWordSearch the partialWordSearch object that "@delali/narsil/partial-words" exports'
3537
3492
  );
3538
3493
  }
3539
- registered2 = module;
3494
+ registered = module;
3540
3495
  }
3541
3496
  function availablePartialWordSearch() {
3542
- return registered2 ?? platformPartialWordSearch();
3497
+ return registered ?? platformPartialWordSearch();
3543
3498
  }
3544
3499
  function requirePartialWordSearchFor(schema) {
3545
3500
  const fields = partialFieldsOf(schema);
@@ -11179,4 +11134,4 @@ function createDirectExecutor(options) {
11179
11134
  };
11180
11135
  }
11181
11136
 
11182
- export { CHECKSUM_YIELD_CHUNK_BYTES, CONSECUTIVE_TIMEOUTS_BEFORE_DEATH, DEFAULT_BACKPRESSURE_LIMIT, DEFAULT_REQUEST_TIMEOUT_MS, FIELD_FILTER_OPERATORS, FILTER_EXPRESSION_KEYS, MAX_FILE_BYTES, NATIVE_CRC32_MIN_BYTES, NO_LIVE_VECTOR_AT_POSITION, SHUTDOWN_TIMEOUT_MS, VALID_HNSW_METRICS, VECTOR_FILE_MAX_VECTORS, VECTOR_FILE_PAYLOAD_VERSION, assembleGraphParts, buildSegmentPayload, bytesToVectors, countDead, createDirectExecutor, createFrozenSegment, createPartitionIndex, createPartitionManager, createPartitionRouter, createSharedFrozenSegment, deadBitsWhere, deadBytesFor, decodeEveryStoredDocument, decodeMapWithoutFields, decodeStoredDocument, decodeVectorFilePayload, decodeVectorGraphPartPayload, decodeVectorGraphPayload, decodeVectorIndexParts, encodeSegmentState, freezeSegmentShared, generateId, getStopWords, getTokenizer, graphPartsOfEarlierPayload, hasStopWords, hasTokenizer, isCompositePartition, isDead, mergeFrozenSegments, mergeSegmentContents, missingWorkerEntry, nodeThreadId, partitionStateOf, readHeapStatistics, registerPartialWordSearch, registerPatternSearch, registerStopWords, registerTokenizer, requirePartialWordSearchFor, requirePatternSearchFor, resolveIndexAnalysis, resolvePartitionInsertOptions, resolveRequestThreadCount, resolveWorkerCount, resolveWorkerEntry, segmentArraysOf, selectionKeeps, shareSegmentArrays, spawnNodeWorker, splitWorkerBudget, survivorDocumentsOf, vectorsPerFile, vectorsToBytes, workerResourceLimits };
11137
+ export { CHECKSUM_YIELD_CHUNK_BYTES, CONSECUTIVE_TIMEOUTS_BEFORE_DEATH, DEFAULT_BACKPRESSURE_LIMIT, DEFAULT_REQUEST_TIMEOUT_MS, FIELD_FILTER_OPERATORS, FILTER_EXPRESSION_KEYS, MAX_FILE_BYTES, NATIVE_CRC32_MIN_BYTES, NO_LIVE_VECTOR_AT_POSITION, SHUTDOWN_TIMEOUT_MS, VALID_HNSW_METRICS, VECTOR_FILE_MAX_VECTORS, VECTOR_FILE_PAYLOAD_VERSION, assembleGraphParts, buildSegmentPayload, bytesToVectors, countDead, createDirectExecutor, createFrozenSegment, createPartitionIndex, createPartitionManager, createPartitionRouter, createSharedFrozenSegment, deadBitsWhere, deadBytesFor, decodeEveryStoredDocument, decodeMapWithoutFields, decodeStoredDocument, decodeVectorFilePayload, decodeVectorGraphPartPayload, decodeVectorGraphPayload, decodeVectorIndexParts, encodeSegmentState, freezeSegmentShared, generateId, getStopWords, getTokenizer, graphPartsOfEarlierPayload, hasStopWords, hasTokenizer, isCompositePartition, isDead, mergeFrozenSegments, mergeSegmentContents, missingWorkerEntry, nodeThreadId, partitionStateOf, readHeapStatistics, registerPartialWordSearch, registerStopWords, registerTokenizer, requirePartialWordSearchFor, resolveIndexAnalysis, resolvePartitionInsertOptions, resolveRequestThreadCount, resolveWorkerCount, resolveWorkerEntry, segmentArraysOf, selectionKeeps, shareSegmentArrays, spawnNodeWorker, splitWorkerBudget, survivorDocumentsOf, vectorsPerFile, vectorsToBytes, workerResourceLimits };
@@ -1,6 +1,6 @@
1
1
  import { P as PartitionConfig, A as AnyDocument, a as InsertOptions, W as WriteOptions } from './schema-DgyDijhf.js';
2
- import { V as VectorMaintenanceResult, B as BatchResult, L as ListParams, h as ListResult, I as IndexInfo, g as IndexStats, P as PartitionStatsResult, Q as QueryParams, e as QueryResult, j as PreflightResult, k as SuggestParams, l as SuggestResult } from './memory-DJEwWoCi.js';
3
- import { e as TaskRecord, M as MemoryStatsResponse, b as ImportResult, H as HttpIndexConfig, c as TaskListQuery, T as TaskListPage } from './tasks-BVmAKYBh.js';
2
+ import { V as VectorMaintenanceResult, B as BatchResult, L as ListParams, h as ListResult, I as IndexInfo, g as IndexStats, P as PartitionStatsResult, Q as QueryParams, e as QueryResult, j as PreflightResult, k as SuggestParams, l as SuggestResult } from './memory-M9kPmYP8.js';
3
+ import { e as TaskRecord, M as MemoryStatsResponse, b as ImportResult, H as HttpIndexConfig, c as TaskListQuery, T as TaskListPage } from './tasks-A8se0J98.js';
4
4
 
5
5
  /**
6
6
  * This is the `fetch` implementation the client sends every request through.
package/dist/client.d.ts CHANGED
@@ -1,10 +1,10 @@
1
- export { C as ClientErrorCode, a as ClientErrorCodes, E as ErrorCode, b as ErrorCodes, N as NarsilError, c as NarsilErrorCode, S as ServerErrorCode, d as ServerErrorCodes, i as isNarsilError } from './memory-DJEwWoCi.js';
2
- export { A as ASYNC_IMPORT_CAPABILITY, D as DOCUMENT_EXPORT_CAPABILITY, E as ErrorEnvelope, I as INDEX_LIFECYCLE_CAPABILITY, R as REBUILD_ANALYSIS_CAPABILITY, S as SERVER_CAPABILITIES, T as TASK_CANCEL_CAPABILITY, a as TASK_FILTER_CAPABILITY } from './capabilities-CAMzmkAg.js';
3
- export { C as CapabilitiesResponse, a as CreateIndexEmbedding, H as HttpIndexConfig, I as ImportError, b as ImportResult, M as MemoryStatsResponse, T as TaskListPage, c as TaskListQuery, d as TaskProgress, e as TaskRecord, f as TaskStatus, g as TaskType } from './tasks-BVmAKYBh.js';
4
- export { A as AdminOperations, B as BulkOperations, D as DocumentOperations, F as FetchFunction, I as ImportSource, a as IndexOperations, N as NarsilClient, b as NarsilClientOptions, P as PutResult, R as RequestOptions, S as SearchOperations, c as ServerOperations, d as ServerVersion, T as TaskOperations, W as WaitForTaskOptions, e as createNarsilClient } from './client-C-I70ArH.js';
1
+ export { C as ClientErrorCode, a as ClientErrorCodes, E as ErrorCode, b as ErrorCodes, N as NarsilError, c as NarsilErrorCode, S as ServerErrorCode, d as ServerErrorCodes, i as isNarsilError } from './memory-M9kPmYP8.js';
2
+ export { A as ASYNC_IMPORT_CAPABILITY, D as DOCUMENT_EXPORT_CAPABILITY, E as ErrorEnvelope, I as INDEX_LIFECYCLE_CAPABILITY, R as REBUILD_ANALYSIS_CAPABILITY, S as SERVER_CAPABILITIES, T as TASK_CANCEL_CAPABILITY, a as TASK_FILTER_CAPABILITY } from './capabilities-BHNksicw.js';
3
+ export { C as CapabilitiesResponse, a as CreateIndexEmbedding, H as HttpIndexConfig, I as ImportError, b as ImportResult, M as MemoryStatsResponse, T as TaskListPage, c as TaskListQuery, d as TaskProgress, e as TaskRecord, f as TaskStatus, g as TaskType } from './tasks-A8se0J98.js';
4
+ export { A as AdminOperations, B as BulkOperations, D as DocumentOperations, F as FetchFunction, I as ImportSource, a as IndexOperations, N as NarsilClient, b as NarsilClientOptions, P as PutResult, R as RequestOptions, S as SearchOperations, c as ServerOperations, d as ServerVersion, T as TaskOperations, W as WaitForTaskOptions, e as createNarsilClient } from './client-D4sXFS9f.js';
5
5
  import './schema-DgyDijhf.js';
6
6
  import './adapters-79OIa4xm.js';
7
- import './config-C6Iw5rCX.js';
8
- import './config-DJPH3IQB.js';
7
+ import './config-B-GRonqw.js';
8
+ import './config-C1kbq1X2.js';
9
9
  import './types-ChrVy4lH.js';
10
10
  import './types-Cb9kiY5P.js';