@delali/narsil 0.3.1-next.112 → 0.3.1-next.113
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/dist/browser/{chunk-YRYBTRWB.mjs → chunk-3YPLBK4C.mjs} +2 -2
- package/dist/browser/{chunk-O5IKTA27.mjs → chunk-4FVSBSXY.mjs} +1 -1
- package/dist/browser/{chunk-UR5MNN53.mjs → chunk-DC2SZO4D.mjs} +7 -6
- package/dist/browser/{chunk-OVY4RPDS.mjs → chunk-YZPOBLAS.mjs} +35 -1
- package/dist/browser/{durability-wiring-CPEMDDK7.mjs → durability-wiring-2RG22WQJ.mjs} +3 -3
- package/dist/browser/{module-DYKR4INA.mjs → module-5EWHBKHZ.mjs} +102 -11
- package/dist/browser/{restore-queue-2H4QDQV4.mjs → restore-queue-WCFUB4NS.mjs} +1 -1
- package/dist/browser/{snapshot-ISZMBDCN.mjs → snapshot-BE3F2PNC.mjs} +6 -5
- package/dist/browser/{write-IABOLE4N.mjs → write-MV7K7OCU.mjs} +2 -2
- package/dist/{capabilities-ByaX8Arf.d.ts → capabilities-DOgB3pPf.d.ts} +2 -2
- package/dist/{chunk-ZXZ26WSO.mjs → chunk-22YPZVMG.mjs} +5 -1
- package/dist/{chunk-2IFU7SXG.mjs → chunk-27ZEY73B.mjs} +3 -3
- package/dist/{chunk-QI6JW4PM.mjs → chunk-4PFOOQFQ.mjs} +1 -1
- package/dist/{chunk-YIDSHBQS.mjs → chunk-4XWIW3F3.mjs} +29 -1
- package/dist/{chunk-V7ISFBFC.mjs → chunk-5QIRLJH4.mjs} +2 -2
- package/dist/{chunk-63HFWQEA.mjs → chunk-AOLD3LPV.mjs} +273 -102
- package/dist/{chunk-PT7VRWS7.mjs → chunk-CU4OB64V.mjs} +3 -2
- package/dist/{chunk-BVOUSX3U.mjs → chunk-DZXGNLK5.mjs} +3 -3
- package/dist/chunk-EBIHRL7B.mjs +21 -0
- package/dist/{chunk-R2MRGYU5.mjs → chunk-H2GNWBLB.mjs} +22 -2
- package/dist/{chunk-V7G627TA.mjs → chunk-HFJXEFFV.mjs} +13 -62
- package/dist/chunk-IWVEG5CX.mjs +67 -0
- package/dist/{chunk-VLRT47GU.mjs → chunk-JUAFWJON.mjs} +3 -3
- package/dist/{chunk-3COL24MT.mjs → chunk-LVNBY2TS.mjs} +1 -1
- package/dist/{chunk-IM76DLA7.mjs → chunk-OABTAUCW.mjs} +2 -2
- package/dist/{chunk-IBTKJIV7.mjs → chunk-OM5G2J6X.mjs} +1 -1
- package/dist/{chunk-3RRATITJ.mjs → chunk-PABYSTKO.mjs} +11 -8
- package/dist/chunk-PELHVTO7.mjs +24 -0
- package/dist/{chunk-7CI34JAP.mjs → chunk-QGVMEMCG.mjs} +4 -4
- package/dist/{chunk-6OXNHLNZ.mjs → chunk-RIIUZJQ3.mjs} +1 -1
- package/dist/{chunk-C7SLA6CM.mjs → chunk-W55X2BYN.mjs} +5 -1
- package/dist/{chunk-SOADQINJ.mjs → chunk-ZATRDAYU.mjs} +31 -3
- package/dist/{client-BdnzDFtO.d.ts → client-BGzLNt78.d.ts} +2 -2
- package/dist/client.d.ts +6 -6
- package/dist/{config-ujZESkJz.d.ts → config-CS5ADSrx.d.ts} +18 -2
- package/dist/{config-CSgvApt0.d.ts → config-CSYMTTm1.d.ts} +1 -1
- package/dist/{direct-executor-ZSTKRA6Z.mjs → direct-executor-R4HOSVPE.mjs} +5 -4
- package/dist/distribution.d.ts +5 -5
- package/dist/distribution.mjs +72 -35
- package/dist/{durability-wiring-EQTFL3B4.mjs → durability-wiring-XZI6355I.mjs} +13 -12
- package/dist/{engine-C_HSy3iz.d.ts → engine-CCBBGmMR.d.ts} +1 -1
- package/dist/{events-CJsXF1F9.d.ts → events-D8GPB1-H.d.ts} +5 -0
- package/dist/index.browser.mjs +1 -1
- package/dist/index.d.ts +5 -5
- package/dist/index.mjs +6 -5
- package/dist/{module-WP4VVGV2.mjs → module-WVKSJL74.mjs} +67 -7
- package/dist/persistence/durability/checkpoint-worker.mjs +10 -9
- package/dist/react.d.ts +6 -6
- package/dist/{restore-queue-WZTMTJP2.mjs → restore-queue-JAZAB5IQ.mjs} +1 -1
- package/dist/server.d.ts +8 -8
- package/dist/server.mjs +20 -62
- package/dist/{snapshot-EU6NNB2P.mjs → snapshot-PDUGHQ25.mjs} +14 -13
- package/dist/{tasks-CI3Fvkxw.d.ts → tasks-5_LCFEzF.d.ts} +1 -1
- package/dist/{thread-WGBCVJII.mjs → thread-S4SUCV4Y.mjs} +8 -5
- package/dist/vector/search-worker.mjs +2 -2
- package/dist/workers/entry.mjs +6 -6
- package/dist/{write-CKRWS3P5.mjs → write-KVJ7YJJ6.mjs} +7 -6
- package/package.json +7 -7
package/dist/server.mjs
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
|
-
import { DEFAULT_MAX_RETAINED_TASKS, loadUWebSockets, resolveCors, authorizerFor, createSharedGateBuffer, gateSlotOfWorker, createBodyBudgetBuffer, createRouteRunner, corsHeaderReader, createSharedBodyBudget, MAIN_THREAD_GATE_SLOT, createSharedRequestGate, registerServerRoutes, DEFAULT_MAX_CONCURRENT_TASKS, DEFAULT_MAX_TASK_PAGE_SIZE, DEFAULT_MAX_IMPORT_ERRORS, DEFAULT_MAX_FETCH_DOCUMENTS, DEFAULT_MAX_RESULT_WINDOW, DEFAULT_MAX_CONCURRENT_REQUESTS, DEFAULT_IMPORT_BATCH_SIZE, DEFAULT_MAX_LINE_BYTES, DEFAULT_MAX_RESTORE_BYTES, DEFAULT_MAX_IMPORT_BYTES, DEFAULT_MAX_BODY_BYTES, DEFAULT_MAX_RERANK_WINDOW, DEFAULT_MAX_BODY_BYTES_IN_FLIGHT_FRACTION, RUNNING_TASK_TTL_MS, DEFAULT_TASK_PAGE_SIZE, TERMINAL_TASK_TTL_MS, TASK_PROGRESS_WRITE_INTERVAL_MS, serializeNarsilError, createVersionHandler, acceptorOf, MAX_BODY_BYTES_IN_FLIGHT_FRACTION, createDocumentReadHandlers, sendError, respondError, respondJson, sendText, MAX_INDEX_TOUCH_INTERVAL_MS, INDEX_TOUCH_INTERVALS_PER_IDLE_TIMEOUT, closeEveryThreadAtExit, REQUEST_THREAD_CLOSE_AT_EXIT_MS, clearGateSlot, clearBodyBudgetSlot, createCloseAtExitWords, createDepartureWord, departureConfirmed, parseJson, validateCreateIndex, rejectInvalid, validateBatch, serializeBatchResult, parseWriteJson, validateDocumentBody, validateSuggest, validateQuery, refuseRegex, withServerRerankWindow, respondAnswer, parseTaskListQuery, parseJsonOptional, validateRebalance, badRequest, sendStream, SNAPSHOT_ARCHIVE_CONTENT_TYPE, DOCUMENT_EXPORT_CONTENT_TYPE, parseRefusalOf, IMPORT_FLUSHES_IN_FLIGHT, confirmDeparture,
|
|
2
|
-
export { ASYNC_IMPORT_CAPABILITY, DOCUMENT_EXPORT_CAPABILITY, INDEX_LIFECYCLE_CAPABILITY, REBUILD_ANALYSIS_CAPABILITY, SERVER_CAPABILITIES, SYNONYMS_CAPABILITY, TASK_CANCEL_CAPABILITY, TASK_FILTER_CAPABILITY, httpStatusForNarsilError } from './chunk-
|
|
1
|
+
import { DEFAULT_MAX_RETAINED_TASKS, loadUWebSockets, resolveCors, authorizerFor, createSharedGateBuffer, gateSlotOfWorker, createBodyBudgetBuffer, createRouteRunner, corsHeaderReader, createSharedBodyBudget, MAIN_THREAD_GATE_SLOT, createSharedRequestGate, registerServerRoutes, DEFAULT_MAX_CONCURRENT_TASKS, DEFAULT_MAX_TASK_PAGE_SIZE, DEFAULT_MAX_IMPORT_ERRORS, DEFAULT_MAX_FETCH_DOCUMENTS, DEFAULT_MAX_RESULT_WINDOW, DEFAULT_MAX_CONCURRENT_REQUESTS, DEFAULT_IMPORT_BATCH_SIZE, DEFAULT_MAX_LINE_BYTES, DEFAULT_MAX_RESTORE_BYTES, DEFAULT_MAX_IMPORT_BYTES, DEFAULT_MAX_BODY_BYTES, DEFAULT_MAX_RERANK_WINDOW, DEFAULT_MAX_BODY_BYTES_IN_FLIGHT_FRACTION, RUNNING_TASK_TTL_MS, DEFAULT_TASK_PAGE_SIZE, TERMINAL_TASK_TTL_MS, TASK_PROGRESS_WRITE_INTERVAL_MS, serializeNarsilError, createVersionHandler, acceptorOf, MAX_BODY_BYTES_IN_FLIGHT_FRACTION, createDocumentReadHandlers, sendError, respondError, respondJson, sendText, MAX_INDEX_TOUCH_INTERVAL_MS, INDEX_TOUCH_INTERVALS_PER_IDLE_TIMEOUT, closeEveryThreadAtExit, REQUEST_THREAD_CLOSE_AT_EXIT_MS, clearGateSlot, clearBodyBudgetSlot, createCloseAtExitWords, createDepartureWord, departureConfirmed, parseJson, validateCreateIndex, rejectInvalid, isRemoveOnlyBatch, validateBatch, serializeBatchResult, parseWriteJson, validateDocumentBody, validateSuggest, validateQuery, refuseRegex, withServerRerankWindow, respondAnswer, parseTaskListQuery, parseJsonOptional, validateRebalance, badRequest, sendStream, SNAPSHOT_ARCHIVE_CONTENT_TYPE, DOCUMENT_EXPORT_CONTENT_TYPE, parseRefusalOf, IMPORT_FLUSHES_IN_FLIGHT, confirmDeparture, SERVER_CAPABILITIES, toHttpError, RELAY_STREAM_CHUNKS_IN_FLIGHT, MIN_UNBOUNDED_SERVER_LIMIT, MIN_COUNTED_SERVER_LIMIT } from './chunk-AOLD3LPV.mjs';
|
|
2
|
+
export { ASYNC_IMPORT_CAPABILITY, DOCUMENT_EXPORT_CAPABILITY, INDEX_LIFECYCLE_CAPABILITY, REBUILD_ANALYSIS_CAPABILITY, SERVER_CAPABILITIES, SYNONYMS_CAPABILITY, TASK_CANCEL_CAPABILITY, TASK_FILTER_CAPABILITY, httpStatusForNarsilError } from './chunk-AOLD3LPV.mjs';
|
|
3
3
|
import { rerankOnHost } from './chunk-542TD4BL.mjs';
|
|
4
4
|
import { writeBlockLookupOf, indexReadsOf, isRecord, validateIndexName } from './chunk-LOBYK2FG.mjs';
|
|
5
|
-
import { readMemoryFigures } from './chunk-
|
|
5
|
+
import { readMemoryFigures } from './chunk-HFJXEFFV.mjs';
|
|
6
|
+
import './chunk-IWVEG5CX.mjs';
|
|
6
7
|
import './chunk-DJHHF2L5.mjs';
|
|
7
8
|
import './chunk-P36MUFEJ.mjs';
|
|
8
9
|
import { rerankWindowCapOf, engineCoreOf, providedDocId, resolveVectorText } from './chunk-N57XXGPG.mjs';
|
|
9
10
|
import { detectRuntime } from './chunk-AV4IJKD2.mjs';
|
|
10
11
|
import './chunk-FUUP45IS.mjs';
|
|
11
|
-
import './chunk-
|
|
12
|
+
import './chunk-ZATRDAYU.mjs';
|
|
13
|
+
import './chunk-EBIHRL7B.mjs';
|
|
12
14
|
import { MAX_RERANK_WINDOW } from './chunk-HJSN7UYG.mjs';
|
|
13
15
|
import './chunk-LXWDQLTW.mjs';
|
|
14
16
|
import './chunk-TGP5M5R7.mjs';
|
|
@@ -23,8 +25,8 @@ import './chunk-6ODIY6ZB.mjs';
|
|
|
23
25
|
import './chunk-7X5JST5L.mjs';
|
|
24
26
|
import './chunk-R6A773WK.mjs';
|
|
25
27
|
import './chunk-YTJCGKM4.mjs';
|
|
26
|
-
import { startIdleHeapCleanup } from './chunk-
|
|
27
|
-
import './chunk-
|
|
28
|
+
import { startIdleHeapCleanup } from './chunk-RIIUZJQ3.mjs';
|
|
29
|
+
import './chunk-22YPZVMG.mjs';
|
|
28
30
|
import './chunk-L5ORED7V.mjs';
|
|
29
31
|
import { NarsilError, ErrorCodes, ServerErrorCodes, isNarsilError } from './chunk-OBWUWZRA.mjs';
|
|
30
32
|
export { ClientErrorCodes, ErrorCodes, NarsilError, ServerErrorCodes, isNarsilError } from './chunk-OBWUWZRA.mjs';
|
|
@@ -408,62 +410,6 @@ function createDocumentExportHandlers(deps) {
|
|
|
408
410
|
return { exportDocuments, importExport };
|
|
409
411
|
}
|
|
410
412
|
|
|
411
|
-
// src/server/batch-scan.ts
|
|
412
|
-
var QUOTE = 34;
|
|
413
|
-
var BACKSLASH = 92;
|
|
414
|
-
var OPEN_OBJECT = 123;
|
|
415
|
-
var CLOSE_OBJECT = 125;
|
|
416
|
-
var OPEN_ARRAY = 91;
|
|
417
|
-
var CLOSE_ARRAY = 93;
|
|
418
|
-
var COLON = 58;
|
|
419
|
-
var REMOVE_BATCH_KEYS = /* @__PURE__ */ new Set(["action", "docIds", "options"]);
|
|
420
|
-
var REMOVE_ACTION = "delete";
|
|
421
|
-
function isWhitespace(byte) {
|
|
422
|
-
return byte === 32 || byte === 9 || byte === 10 || byte === 13;
|
|
423
|
-
}
|
|
424
|
-
function nextByteAt(raw, from) {
|
|
425
|
-
let at = from;
|
|
426
|
-
while (at < raw.length && isWhitespace(raw[at])) at++;
|
|
427
|
-
return at;
|
|
428
|
-
}
|
|
429
|
-
function plainStringOf(raw, open, close) {
|
|
430
|
-
const content = raw.subarray(open + 1, close);
|
|
431
|
-
if (content.includes(BACKSLASH)) return null;
|
|
432
|
-
return new TextDecoder().decode(content);
|
|
433
|
-
}
|
|
434
|
-
function isRemoveOnlyBatch(raw) {
|
|
435
|
-
const start = nextByteAt(raw, 0);
|
|
436
|
-
if (raw[start] !== OPEN_OBJECT) return false;
|
|
437
|
-
let depth = 0;
|
|
438
|
-
let action = null;
|
|
439
|
-
for (let at = start; at < raw.length; at++) {
|
|
440
|
-
const byte = raw[at];
|
|
441
|
-
if (byte === OPEN_OBJECT || byte === OPEN_ARRAY) depth++;
|
|
442
|
-
else if (byte === CLOSE_OBJECT || byte === CLOSE_ARRAY) depth--;
|
|
443
|
-
else if (byte === QUOTE) {
|
|
444
|
-
const close = closingQuoteOf(raw, at + 1);
|
|
445
|
-
if (close >= raw.length) return false;
|
|
446
|
-
const afterString = nextByteAt(raw, close + 1);
|
|
447
|
-
if (depth === 1 && raw[afterString] === COLON) {
|
|
448
|
-
const key = plainStringOf(raw, at, close);
|
|
449
|
-
if (key === null || !REMOVE_BATCH_KEYS.has(key)) return false;
|
|
450
|
-
if (key === "action") {
|
|
451
|
-
const value = nextByteAt(raw, afterString + 1);
|
|
452
|
-
const valueClose = raw[value] === QUOTE ? closingQuoteOf(raw, value + 1) : raw.length;
|
|
453
|
-
action = valueClose < raw.length ? plainStringOf(raw, value, valueClose) : null;
|
|
454
|
-
if (action === null) return false;
|
|
455
|
-
at = valueClose;
|
|
456
|
-
continue;
|
|
457
|
-
}
|
|
458
|
-
at = afterString;
|
|
459
|
-
continue;
|
|
460
|
-
}
|
|
461
|
-
at = close;
|
|
462
|
-
}
|
|
463
|
-
}
|
|
464
|
-
return action === REMOVE_ACTION;
|
|
465
|
-
}
|
|
466
|
-
|
|
467
413
|
// src/server/handlers/documents.ts
|
|
468
414
|
function createDocumentHandlers(deps) {
|
|
469
415
|
const { engine } = deps;
|
|
@@ -971,6 +917,17 @@ function prometheusText(metrics) {
|
|
|
971
917
|
])} ${figure.inSyncReplicas}`
|
|
972
918
|
)
|
|
973
919
|
),
|
|
920
|
+
...family(
|
|
921
|
+
"narsil_vector_rebuild_waiting_for_memory",
|
|
922
|
+
"gauge",
|
|
923
|
+
"A vector field whose rebuild waits for the node to have memory for a second graph, reported as 1.",
|
|
924
|
+
metrics.vectorRebuildsWaitingForMemory.map(
|
|
925
|
+
(figure) => `narsil_vector_rebuild_waiting_for_memory${labels([
|
|
926
|
+
["index", figure.indexName],
|
|
927
|
+
["field", figure.fieldName]
|
|
928
|
+
])} 1`
|
|
929
|
+
)
|
|
930
|
+
),
|
|
974
931
|
...family(
|
|
975
932
|
"narsil_coordinator_request_seconds",
|
|
976
933
|
"histogram",
|
|
@@ -1331,6 +1288,7 @@ async function answerRequest(handlers, request, port, streams) {
|
|
|
1331
1288
|
query: new URLSearchParams(request.query),
|
|
1332
1289
|
contentType: request.contentType,
|
|
1333
1290
|
rawBody: request.rawBody === null ? null : Buffer.from(request.rawBody.buffer, request.rawBody.byteOffset, request.rawBody.byteLength),
|
|
1291
|
+
bodyRefusal: request.bodyRefusal,
|
|
1334
1292
|
spooledBody: spooledBodyOf(request.spooledBody),
|
|
1335
1293
|
abort: captured.abort,
|
|
1336
1294
|
hookContext: request.hookContext
|
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
import { documentsOfPayloadV2 } from './chunk-
|
|
2
|
-
import { buildArchiveFromMemory, archiveStream, memoryCheckpointStore, readSnapshotArchive } from './chunk-
|
|
3
|
-
import './chunk-
|
|
4
|
-
import { indexMetadataOf, unpackIndexSnapshotEnvelope, loadSegmentedCheckpoint, writeMetadataEnvelope, readVectorFile, readGraphParts, deserializePayloadV1, SINGLE_NODE_PRIMARY_TERM } from './chunk-
|
|
1
|
+
import { documentsOfPayloadV2 } from './chunk-OM5G2J6X.mjs';
|
|
2
|
+
import { buildArchiveFromMemory, archiveStream, memoryCheckpointStore, readSnapshotArchive } from './chunk-QGVMEMCG.mjs';
|
|
3
|
+
import './chunk-CU4OB64V.mjs';
|
|
4
|
+
import { indexMetadataOf, unpackIndexSnapshotEnvelope, loadSegmentedCheckpoint, writeMetadataEnvelope, readVectorFile, readGraphParts, deserializePayloadV1, SINGLE_NODE_PRIMARY_TERM } from './chunk-JUAFWJON.mjs';
|
|
5
5
|
import { decodeVectorIndexParts, bytesToVectors } from './chunk-OCB7TMUQ.mjs';
|
|
6
|
-
import './chunk-
|
|
6
|
+
import './chunk-4XWIW3F3.mjs';
|
|
7
7
|
import './chunk-DJHHF2L5.mjs';
|
|
8
8
|
import './chunk-37CD3OKS.mjs';
|
|
9
|
-
import { manifestKey, encodeSegmentManifest, manifestFileRefs, readSegmentFile } from './chunk-
|
|
10
|
-
import './chunk-
|
|
9
|
+
import { manifestKey, encodeSegmentManifest, manifestFileRefs, readSegmentFile } from './chunk-27ZEY73B.mjs';
|
|
10
|
+
import './chunk-LVNBY2TS.mjs';
|
|
11
11
|
import './chunk-P36MUFEJ.mjs';
|
|
12
12
|
import './chunk-YH5OIL7B.mjs';
|
|
13
|
-
import { encodeIndexConfiguration, createByteReader, hasNrslMagic, HEADER_SIZE, readHeader, validateRequiredFieldsInSchema, validateEmbeddingConfig, decodeIndexConfiguration, prepareStoredSynonyms, insertDocumentVectors } from './chunk-
|
|
13
|
+
import { encodeIndexConfiguration, createByteReader, hasNrslMagic, HEADER_SIZE, readHeader, validateRequiredFieldsInSchema, validateEmbeddingConfig, decodeIndexConfiguration, prepareStoredSynonyms, insertDocumentVectors } from './chunk-PABYSTKO.mjs';
|
|
14
14
|
import { validatePatternValueLimit, requireSurfaceFormsForPartialFields } from './chunk-GLZI636G.mjs';
|
|
15
15
|
import { restoredConfigFields, restoredEmbedding, rejectSnapshot } from './chunk-N57XXGPG.mjs';
|
|
16
16
|
import './chunk-6PN3U6XW.mjs';
|
|
17
17
|
import './chunk-AV4IJKD2.mjs';
|
|
18
|
-
import { decodeEveryStoredDocument } from './chunk-
|
|
18
|
+
import { decodeEveryStoredDocument } from './chunk-5QIRLJH4.mjs';
|
|
19
19
|
import './chunk-5WEBVYOA.mjs';
|
|
20
20
|
import { getLanguage } from './chunk-FUUP45IS.mjs';
|
|
21
|
-
import { readHeapStatistics, readResidentMemory } from './chunk-
|
|
21
|
+
import { readHeapStatistics, readResidentMemory } from './chunk-ZATRDAYU.mjs';
|
|
22
|
+
import './chunk-EBIHRL7B.mjs';
|
|
22
23
|
import './chunk-HJSN7UYG.mjs';
|
|
23
24
|
import './chunk-LXWDQLTW.mjs';
|
|
24
25
|
import './chunk-TGP5M5R7.mjs';
|
|
@@ -41,10 +42,10 @@ import './chunk-7X5JST5L.mjs';
|
|
|
41
42
|
import './chunk-OFYKBKKV.mjs';
|
|
42
43
|
import './chunk-R6A773WK.mjs';
|
|
43
44
|
import './chunk-YTJCGKM4.mjs';
|
|
44
|
-
import { collectAndReturnPages } from './chunk-
|
|
45
|
+
import { collectAndReturnPages } from './chunk-RIIUZJQ3.mjs';
|
|
45
46
|
import './chunk-CQUMNIIG.mjs';
|
|
46
|
-
import { loadVectorCodeFor } from './chunk-
|
|
47
|
-
import './chunk-
|
|
47
|
+
import { loadVectorCodeFor } from './chunk-4PFOOQFQ.mjs';
|
|
48
|
+
import './chunk-22YPZVMG.mjs';
|
|
48
49
|
import './chunk-RFBLQLLZ.mjs';
|
|
49
50
|
import './chunk-L5ORED7V.mjs';
|
|
50
51
|
import { NarsilError, ErrorCodes } from './chunk-OBWUWZRA.mjs';
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import { loadUWebSockets, childAppOf, createRouteRunner, corsHeaderReader, createSharedBodyBudget, createSharedRequestGate, registerServerRoutes, closeWhenTheProcessExits, sendRelayed, createDocumentReadHandlers, respondJson, SERVER_CAPABILITIES, versionReport, statusLine, sendError, serverRoutes, parseJson, validateSuggest, rejectInvalid, respondError, validateQuery, refuseRegex, withServerRerankWindow, awaitDepartureConfirmation, departureConfirmation, REQUEST_THREAD_DEPARTURE_DRAIN_MS, departureConfirmed, encodeJson } from './chunk-
|
|
1
|
+
import { loadUWebSockets, childAppOf, createRouteRunner, corsHeaderReader, createSharedBodyBudget, createSharedRequestGate, registerServerRoutes, closeWhenTheProcessExits, sendRelayed, createDocumentReadHandlers, respondJson, SERVER_CAPABILITIES, versionReport, statusLine, sendError, serverRoutes, parseJson, validateSuggest, rejectInvalid, respondError, validateQuery, refuseRegex, withServerRerankWindow, awaitDepartureConfirmation, departureConfirmation, REQUEST_THREAD_DEPARTURE_DRAIN_MS, departureConfirmed, encodeJson } from './chunk-AOLD3LPV.mjs';
|
|
2
2
|
import { withRerankQueryText } from './chunk-KZ3NX2P7.mjs';
|
|
3
|
-
import './chunk-
|
|
3
|
+
import './chunk-HFJXEFFV.mjs';
|
|
4
|
+
import './chunk-IWVEG5CX.mjs';
|
|
4
5
|
import './chunk-DJHHF2L5.mjs';
|
|
5
6
|
import { executeListDocuments, executeSuggest, executePreflight, queryBindingOf, executeQuery } from './chunk-GLZI636G.mjs';
|
|
6
7
|
import { resolveProjection, projectionKeepsField, setNestedValue } from './chunk-5WEBVYOA.mjs';
|
|
7
|
-
import './chunk-
|
|
8
|
+
import './chunk-ZATRDAYU.mjs';
|
|
9
|
+
import './chunk-EBIHRL7B.mjs';
|
|
8
10
|
import './chunk-HJSN7UYG.mjs';
|
|
9
11
|
import './chunk-LXWDQLTW.mjs';
|
|
10
12
|
import './chunk-QSK35UC2.mjs';
|
|
@@ -22,8 +24,8 @@ import './chunk-X5CV2E2B.mjs';
|
|
|
22
24
|
import './chunk-OFYKBKKV.mjs';
|
|
23
25
|
import './chunk-R6A773WK.mjs';
|
|
24
26
|
import './chunk-YTJCGKM4.mjs';
|
|
25
|
-
import './chunk-
|
|
26
|
-
import './chunk-
|
|
27
|
+
import './chunk-RIIUZJQ3.mjs';
|
|
28
|
+
import './chunk-22YPZVMG.mjs';
|
|
27
29
|
import './chunk-L5ORED7V.mjs';
|
|
28
30
|
import { ServerErrorCodes, ErrorCodes, NarsilError, isNarsilError } from './chunk-OBWUWZRA.mjs';
|
|
29
31
|
|
|
@@ -335,6 +337,7 @@ function createRelayClient(port, touchIntervalMs) {
|
|
|
335
337
|
query: ctx.query.toString(),
|
|
336
338
|
contentType: ctx.contentType,
|
|
337
339
|
rawBody: body.bytes,
|
|
340
|
+
bodyRefusal: ctx.bodyRefusal,
|
|
338
341
|
spooledBody: ctx.spooledBody === null ? null : { path: ctx.spooledBody.path, bytes: ctx.spooledBody.bytes },
|
|
339
342
|
hookContext: ctx.hookContext
|
|
340
343
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { openSharedVectorField, createVectorStore } from '../chunk-
|
|
2
|
-
import { osqBitsOf, createHNSWIndex, createOsqQuantizer } from '../chunk-
|
|
1
|
+
import { openSharedVectorField, createVectorStore } from '../chunk-H2GNWBLB.mjs';
|
|
2
|
+
import { osqBitsOf, createHNSWIndex, createOsqQuantizer } from '../chunk-4XWIW3F3.mjs';
|
|
3
3
|
import '../chunk-DJHHF2L5.mjs';
|
|
4
4
|
import { osqRecordBytes } from '../chunk-37CD3OKS.mjs';
|
|
5
5
|
import '../chunk-KOKM4PQN.mjs';
|
package/dist/workers/entry.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { startIdleHeapCleanup } from '../chunk-
|
|
1
|
+
import { startIdleHeapCleanup } from '../chunk-RIIUZJQ3.mjs';
|
|
2
2
|
import { isValidWorkerAction } from '../chunk-CQUMNIIG.mjs';
|
|
3
|
-
import { loadVectorCode } from '../chunk-
|
|
4
|
-
import '../chunk-
|
|
3
|
+
import { loadVectorCode } from '../chunk-4PFOOQFQ.mjs';
|
|
4
|
+
import '../chunk-22YPZVMG.mjs';
|
|
5
5
|
import { threadSlotOfWorker } from '../chunk-RFBLQLLZ.mjs';
|
|
6
6
|
import '../chunk-L5ORED7V.mjs';
|
|
7
7
|
import { ErrorCodes, NarsilError, isNarsilError } from '../chunk-OBWUWZRA.mjs';
|
|
@@ -22,7 +22,7 @@ async function importBootstrapModule(moduleUrl) {
|
|
|
22
22
|
await import(moduleUrl);
|
|
23
23
|
}
|
|
24
24
|
async function stopServingRequests() {
|
|
25
|
-
const { closeRequestThread } = await import('../thread-
|
|
25
|
+
const { closeRequestThread } = await import('../thread-S4SUCV4Y.mjs');
|
|
26
26
|
closeRequestThread();
|
|
27
27
|
}
|
|
28
28
|
function holdsCopies(executor) {
|
|
@@ -53,7 +53,7 @@ function createActionHandler(executor) {
|
|
|
53
53
|
if (!holdsCopies(executor)) {
|
|
54
54
|
throw new NarsilError(ErrorCodes.CONFIG_INVALID, "This executor holds no copies to answer requests from");
|
|
55
55
|
}
|
|
56
|
-
const starting = import('../thread-
|
|
56
|
+
const starting = import('../thread-S4SUCV4Y.mjs').then(
|
|
57
57
|
({ serveRequests }) => serveRequests(executor, action.settings)
|
|
58
58
|
);
|
|
59
59
|
serving.start = starting.then(
|
|
@@ -106,7 +106,7 @@ async function setup() {
|
|
|
106
106
|
} catch {
|
|
107
107
|
parentPort = null;
|
|
108
108
|
}
|
|
109
|
-
const [{ createDirectExecutor }] = await Promise.all([import('../direct-executor-
|
|
109
|
+
const [{ createDirectExecutor }] = await Promise.all([import('../direct-executor-R4HOSVPE.mjs'), loadVectorCode()]);
|
|
110
110
|
const handleAction = createActionHandler(createDirectExecutor({ threadSlot }));
|
|
111
111
|
if (parentPort) {
|
|
112
112
|
const port = parentPort;
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { decodeVectorFilePayload, isDead, bytesToVectors } from './chunk-OCB7TMUQ.mjs';
|
|
2
2
|
import './chunk-37CD3OKS.mjs';
|
|
3
|
-
import { setNestedValue, KEYWORD_SEGMENT_ENVELOPE_VERSION, decodeKeywordSegment } from './chunk-
|
|
4
|
-
import { openChecksummedEnvelope, NUMBER_TAG, DATE_TAG, BYTES_TAG, encodeBase64, startsWithTagPrefix, OBJECT_TAG, MILLISECONDS_PER_SECOND, NANOSECONDS_PER_MILLISECOND, DOCUMENT_EXPORT_VERSION, DOCUMENT_EXPORT_FORMAT } from './chunk-
|
|
3
|
+
import { setNestedValue, KEYWORD_SEGMENT_ENVELOPE_VERSION, decodeKeywordSegment } from './chunk-LVNBY2TS.mjs';
|
|
4
|
+
import { openChecksummedEnvelope, NUMBER_TAG, DATE_TAG, BYTES_TAG, encodeBase64, startsWithTagPrefix, OBJECT_TAG, MILLISECONDS_PER_SECOND, NANOSECONDS_PER_MILLISECOND, DOCUMENT_EXPORT_VERSION, DOCUMENT_EXPORT_FORMAT } from './chunk-PABYSTKO.mjs';
|
|
5
5
|
import './chunk-GLZI636G.mjs';
|
|
6
6
|
import './chunk-N57XXGPG.mjs';
|
|
7
7
|
import './chunk-6PN3U6XW.mjs';
|
|
8
8
|
import './chunk-AV4IJKD2.mjs';
|
|
9
|
-
import { decodeStoredDocument } from './chunk-
|
|
9
|
+
import { decodeStoredDocument } from './chunk-5QIRLJH4.mjs';
|
|
10
10
|
import './chunk-5WEBVYOA.mjs';
|
|
11
11
|
import './chunk-FUUP45IS.mjs';
|
|
12
|
-
import './chunk-
|
|
12
|
+
import './chunk-ZATRDAYU.mjs';
|
|
13
|
+
import './chunk-EBIHRL7B.mjs';
|
|
13
14
|
import './chunk-HJSN7UYG.mjs';
|
|
14
15
|
import { EXPORT_CHUNK_BYTES } from './chunk-LXWDQLTW.mjs';
|
|
15
16
|
import './chunk-TGP5M5R7.mjs';
|
|
@@ -33,8 +34,8 @@ import './chunk-OFYKBKKV.mjs';
|
|
|
33
34
|
import './chunk-R6A773WK.mjs';
|
|
34
35
|
import './chunk-YTJCGKM4.mjs';
|
|
35
36
|
import './chunk-CQUMNIIG.mjs';
|
|
36
|
-
import './chunk-
|
|
37
|
-
import './chunk-
|
|
37
|
+
import './chunk-4PFOOQFQ.mjs';
|
|
38
|
+
import './chunk-22YPZVMG.mjs';
|
|
38
39
|
import './chunk-RFBLQLLZ.mjs';
|
|
39
40
|
import './chunk-L5ORED7V.mjs';
|
|
40
41
|
import { NarsilError, ErrorCodes } from './chunk-OBWUWZRA.mjs';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@delali/narsil",
|
|
3
|
-
"version": "0.3.1-next.
|
|
3
|
+
"version": "0.3.1-next.113",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Distributed search engine with full-text, vector, hybrid, and geosearch. One engine, embedded or on a server, with a cross-language .nrsl format.",
|
|
6
6
|
"author": "Delali (https://sondelali.com)",
|
|
@@ -269,11 +269,11 @@
|
|
|
269
269
|
}
|
|
270
270
|
},
|
|
271
271
|
"optionalDependencies": {
|
|
272
|
-
"@delali/narsil-native-darwin-arm64": "0.3.1-next.
|
|
273
|
-
"@delali/narsil-native-darwin-x64": "0.3.1-next.
|
|
274
|
-
"@delali/narsil-native-linux-arm64": "0.3.1-next.
|
|
275
|
-
"@delali/narsil-native-linux-x64": "0.3.1-next.
|
|
276
|
-
"@delali/narsil-native-win32-arm64": "0.3.1-next.
|
|
277
|
-
"@delali/narsil-native-win32-x64": "0.3.1-next.
|
|
272
|
+
"@delali/narsil-native-darwin-arm64": "0.3.1-next.113",
|
|
273
|
+
"@delali/narsil-native-darwin-x64": "0.3.1-next.113",
|
|
274
|
+
"@delali/narsil-native-linux-arm64": "0.3.1-next.113",
|
|
275
|
+
"@delali/narsil-native-linux-x64": "0.3.1-next.113",
|
|
276
|
+
"@delali/narsil-native-win32-arm64": "0.3.1-next.113",
|
|
277
|
+
"@delali/narsil-native-win32-x64": "0.3.1-next.113"
|
|
278
278
|
}
|
|
279
279
|
}
|