@remnic/core 9.3.660 → 9.3.661
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/access-cli.js +10 -10
- package/dist/access-http.d.ts +5 -5
- package/dist/access-http.js +10 -10
- package/dist/access-mcp.d.ts +5 -5
- package/dist/access-mcp.js +9 -9
- package/dist/{access-service-D_nbpexW.d.ts → access-service-D0SLB4MH.d.ts} +2 -2
- package/dist/access-service.d.ts +5 -5
- package/dist/access-service.js +8 -8
- package/dist/action-confidence.d.ts +1 -1
- package/dist/active-memory-bridge.d.ts +1 -1
- package/dist/active-recall.d.ts +1 -1
- package/dist/behavior-learner.d.ts +1 -1
- package/dist/behavior-signals.d.ts +1 -1
- package/dist/bootstrap.d.ts +3 -3
- package/dist/briefing.d.ts +1 -1
- package/dist/buffer-surprise-report.d.ts +1 -1
- package/dist/buffer.d.ts +1 -1
- package/dist/calibration.d.ts +1 -1
- package/dist/causal-behavior.d.ts +1 -1
- package/dist/causal-consolidation.d.ts +1 -1
- package/dist/{chunk-7PCZGNG2.js → chunk-34NSUPWS.js} +109 -24
- package/dist/chunk-34NSUPWS.js.map +1 -0
- package/dist/{chunk-FWIROLS6.js → chunk-44VFF3BB.js} +18 -16
- package/dist/chunk-44VFF3BB.js.map +1 -0
- package/dist/{chunk-2EVZ5EN6.js → chunk-4SYURHI6.js} +6 -6
- package/dist/{chunk-7H7J3ZWN.js → chunk-5G2DNO54.js} +2 -2
- package/dist/{chunk-OYXVENIS.js → chunk-7F7LC6HW.js} +3 -3
- package/dist/{chunk-256W7AXC.js → chunk-BP5O3GYD.js} +2 -2
- package/dist/{chunk-RP2U54GG.js → chunk-D44FQVCU.js} +2 -2
- package/dist/{chunk-R2EBP6CM.js → chunk-EMSC4P66.js} +5 -5
- package/dist/{chunk-6G5JEN55.js → chunk-FZC2WSDB.js} +2 -2
- package/dist/{chunk-UNLHHTKN.js → chunk-LFZUFZQR.js} +10 -2
- package/dist/chunk-LFZUFZQR.js.map +1 -0
- package/dist/{chunk-B57QYSWN.js → chunk-MHYRRV43.js} +109 -16
- package/dist/chunk-MHYRRV43.js.map +1 -0
- package/dist/{chunk-MO77TWPS.js → chunk-RQRKQJYM.js} +2 -2
- package/dist/{chunk-5PLUC5OB.js → chunk-WSQG37DV.js} +2 -2
- package/dist/{chunk-M3VYPE2H.js → chunk-YNQ6DFSV.js} +1 -1
- package/dist/chunk-YNQ6DFSV.js.map +1 -0
- package/dist/{chunk-GRYAECRV.js → chunk-ZJH723NM.js} +2 -2
- package/dist/{cli-aYxSuPvP.d.ts → cli-C6twwe84.d.ts} +3 -3
- package/dist/cli.d.ts +5 -5
- package/dist/cli.js +13 -13
- package/dist/compounding/engine.d.ts +1 -1
- package/dist/compounding/preference-consolidator.d.ts +1 -1
- package/dist/compression-optimizer.d.ts +1 -1
- package/dist/config.d.ts +1 -1
- package/dist/connectors/codex-materialize-runner.d.ts +1 -1
- package/dist/connectors/codex-materialize.d.ts +1 -1
- package/dist/connectors/index.d.ts +1 -1
- package/dist/consolidation-provenance-check.d.ts +1 -1
- package/dist/consolidation-undo.d.ts +1 -1
- package/dist/contradiction/index.d.ts +1 -1
- package/dist/conversation-index/backend.d.ts +1 -1
- package/dist/conversation-index/chunker.d.ts +1 -1
- package/dist/conversation-index/faiss-adapter.d.ts +1 -1
- package/dist/conversation-index/indexer.d.ts +1 -1
- package/dist/conversation-index/search.d.ts +1 -1
- package/dist/day-summary.d.ts +1 -1
- package/dist/delinearize.d.ts +1 -1
- package/dist/direct-answer-wiring.d.ts +1 -1
- package/dist/direct-answer.d.ts +1 -1
- package/dist/embedding-fallback.d.ts +1 -1
- package/dist/enrichment/index.d.ts +1 -1
- package/dist/entity-retrieval.d.ts +1 -1
- package/dist/entity-schema.d.ts +1 -1
- package/dist/explicit-capture.d.ts +3 -3
- package/dist/extraction-judge-telemetry.d.ts +1 -1
- package/dist/extraction-judge-training.d.ts +1 -1
- package/dist/extraction-judge.d.ts +1 -1
- package/dist/extraction.d.ts +1 -1
- package/dist/fallback-llm.d.ts +1 -1
- package/dist/identity-continuity.d.ts +1 -1
- package/dist/importance.d.ts +1 -1
- package/dist/index.d.ts +8 -8
- package/dist/index.js +15 -15
- package/dist/intent.d.ts +1 -1
- package/dist/lcm/engine.d.ts +1 -1
- package/dist/lcm/index.d.ts +1 -1
- package/dist/lcm/tools.d.ts +1 -1
- package/dist/lifecycle.d.ts +1 -1
- package/dist/live-connectors-runner.d.ts +1 -1
- package/dist/local-llm.d.ts +1 -1
- package/dist/maintenance/memory-governance.d.ts +1 -1
- package/dist/mcp-memory-inspector-app.d.ts +5 -5
- package/dist/memory-action-policy.d.ts +1 -1
- package/dist/memory-cache.d.ts +1 -1
- package/dist/memory-lifecycle-ledger-utils.d.ts +1 -1
- package/dist/memory-projection-store.d.ts +1 -1
- package/dist/memory-provenance.d.ts +1 -1
- package/dist/memory-worth-outcomes.d.ts +1 -1
- package/dist/models-json.d.ts +1 -1
- package/dist/namespaces/migrate.d.ts +1 -1
- package/dist/namespaces/migrate.js +8 -8
- package/dist/namespaces/principal.d.ts +1 -1
- package/dist/namespaces/search.d.ts +1 -1
- package/dist/namespaces/search.js +7 -7
- package/dist/namespaces/storage.d.ts +1 -1
- package/dist/native-knowledge.d.ts +1 -1
- package/dist/operator-toolkit.d.ts +1 -1
- package/dist/operator-toolkit.js +9 -9
- package/dist/{orchestrator-D1wcmPNj.d.ts → orchestrator-Cg1UkvmO.d.ts} +2 -2
- package/dist/orchestrator.d.ts +3 -3
- package/dist/orchestrator.js +9 -9
- package/dist/patterns-cli.d.ts +1 -1
- package/dist/policy-runtime.d.ts +1 -1
- package/dist/qmd-recall-cache.d.ts +1 -1
- package/dist/qmd.d.ts +17 -1
- package/dist/qmd.js +2 -2
- package/dist/recall-disclosure-escalation.d.ts +1 -1
- package/dist/recall-explain-renderer.d.ts +2 -1
- package/dist/recall-planner-llm.d.ts +1 -1
- package/dist/recall-state.d.ts +17 -1
- package/dist/recall-state.js +1 -1
- package/dist/recall-tag-filter.d.ts +1 -1
- package/dist/recall-xray-cli.d.ts +1 -1
- package/dist/recall-xray-renderer.d.ts +1 -1
- package/dist/recall-xray.d.ts +1 -1
- package/dist/resolve-auth-token.d.ts +1 -1
- package/dist/retrieval-agents.d.ts +1 -1
- package/dist/retrieval-tiers.d.ts +1 -1
- package/dist/routing/engine.d.ts +1 -1
- package/dist/routing/store.d.ts +1 -1
- package/dist/search/embed-helper.d.ts +1 -1
- package/dist/search/factory.d.ts +1 -1
- package/dist/search/factory.js +6 -6
- package/dist/search/index.d.ts +1 -1
- package/dist/search/index.js +6 -6
- package/dist/search/lancedb-backend.d.ts +1 -1
- package/dist/search/lancedb-backend.js +2 -2
- package/dist/search/meilisearch-backend.d.ts +1 -1
- package/dist/search/meilisearch-backend.js +2 -2
- package/dist/search/noop-backend.d.ts +1 -1
- package/dist/search/orama-backend.d.ts +1 -1
- package/dist/search/orama-backend.js +2 -2
- package/dist/search/port.d.ts +21 -2
- package/dist/search/port.js +1 -1
- package/dist/search/remote-backend.d.ts +1 -1
- package/dist/{semantic-consolidation-MWOdNtSE.d.ts → semantic-consolidation-BICZvQ3C.d.ts} +1 -1
- package/dist/semantic-consolidation.d.ts +2 -2
- package/dist/semantic-rule-verifier.d.ts +1 -1
- package/dist/session-observer-bands.d.ts +1 -1
- package/dist/session-observer-state.d.ts +1 -1
- package/dist/shared-context/manager.d.ts +1 -1
- package/dist/signal.d.ts +1 -1
- package/dist/storage.d.ts +1 -1
- package/dist/summarizer.d.ts +1 -1
- package/dist/summary-snapshot.d.ts +1 -1
- package/dist/temporal-supersession.d.ts +1 -1
- package/dist/temporal-validity.d.ts +1 -1
- package/dist/threading.d.ts +1 -1
- package/dist/tier-migration.d.ts +1 -1
- package/dist/tier-routing.d.ts +1 -1
- package/dist/topics.d.ts +1 -1
- package/dist/transcript.d.ts +1 -1
- package/dist/{types-CgcCpUrf.d.ts → types-D96bCB3C.d.ts} +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/utility-runtime.d.ts +1 -1
- package/package.json +1 -1
- package/src/namespaces/search.ts +16 -0
- package/src/orchestrator.ts +144 -3
- package/src/qmd.ts +131 -18
- package/src/recall-state.ts +47 -21
- package/src/search/port.ts +25 -0
- package/dist/chunk-7PCZGNG2.js.map +0 -1
- package/dist/chunk-B57QYSWN.js.map +0 -1
- package/dist/chunk-FWIROLS6.js.map +0 -1
- package/dist/chunk-M3VYPE2H.js.map +0 -1
- package/dist/chunk-UNLHHTKN.js.map +0 -1
- /package/dist/{chunk-2EVZ5EN6.js.map → chunk-4SYURHI6.js.map} +0 -0
- /package/dist/{chunk-7H7J3ZWN.js.map → chunk-5G2DNO54.js.map} +0 -0
- /package/dist/{chunk-OYXVENIS.js.map → chunk-7F7LC6HW.js.map} +0 -0
- /package/dist/{chunk-256W7AXC.js.map → chunk-BP5O3GYD.js.map} +0 -0
- /package/dist/{chunk-RP2U54GG.js.map → chunk-D44FQVCU.js.map} +0 -0
- /package/dist/{chunk-R2EBP6CM.js.map → chunk-EMSC4P66.js.map} +0 -0
- /package/dist/{chunk-6G5JEN55.js.map → chunk-FZC2WSDB.js.map} +0 -0
- /package/dist/{chunk-MO77TWPS.js.map → chunk-RQRKQJYM.js.map} +0 -0
- /package/dist/{chunk-5PLUC5OB.js.map → chunk-WSQG37DV.js.map} +0 -0
- /package/dist/{chunk-GRYAECRV.js.map → chunk-ZJH723NM.js.map} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
resolveEnsureCollectionArgs
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-YNQ6DFSV.js";
|
|
4
4
|
import {
|
|
5
5
|
launchProcess
|
|
6
6
|
} from "./chunk-O75CRYGF.js";
|
|
@@ -1421,7 +1421,10 @@ var QmdClient = class _QmdClient {
|
|
|
1421
1421
|
const trimmed = query.trim();
|
|
1422
1422
|
if (!trimmed) return [];
|
|
1423
1423
|
await this.maybeProbeDaemon();
|
|
1424
|
-
if (!this.isAvailable())
|
|
1424
|
+
if (!this.isAvailable()) {
|
|
1425
|
+
this.notifyDegradation(execution?.onDegradation, "backend_unavailable");
|
|
1426
|
+
return [];
|
|
1427
|
+
}
|
|
1425
1428
|
const col = collection ?? this.collection;
|
|
1426
1429
|
const n = maxResults ?? this.maxResults;
|
|
1427
1430
|
const searchOptions = this.resolveSearchOptions(options);
|
|
@@ -1450,22 +1453,40 @@ var QmdClient = class _QmdClient {
|
|
|
1450
1453
|
setCachedQmdSearch(cacheKey, results);
|
|
1451
1454
|
return results;
|
|
1452
1455
|
}
|
|
1453
|
-
log.
|
|
1456
|
+
log.warn("QMD daemon search timed out/failed; skipping subprocess (daemon-only mode)");
|
|
1457
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_timeout");
|
|
1454
1458
|
return [];
|
|
1455
1459
|
}
|
|
1456
1460
|
if (this.daemonSession?.isLoading()) {
|
|
1457
1461
|
log.debug("QMD search: daemon loading, skipping subprocess");
|
|
1462
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_loading");
|
|
1458
1463
|
return [];
|
|
1459
1464
|
}
|
|
1460
|
-
|
|
1461
|
-
|
|
1465
|
+
let subprocessDegraded = false;
|
|
1466
|
+
const subprocessResults = await this.searchViaSubprocess(
|
|
1467
|
+
trimmed,
|
|
1468
|
+
col,
|
|
1469
|
+
n,
|
|
1470
|
+
searchOptions,
|
|
1471
|
+
execution?.signal,
|
|
1472
|
+
(degradation) => {
|
|
1473
|
+
subprocessDegraded = true;
|
|
1474
|
+
this.notifyDegradation(execution?.onDegradation, degradation.code, degradation.detail);
|
|
1475
|
+
}
|
|
1476
|
+
);
|
|
1477
|
+
if (!subprocessDegraded) {
|
|
1478
|
+
setCachedQmdSearch(cacheKey, subprocessResults);
|
|
1479
|
+
}
|
|
1462
1480
|
return subprocessResults;
|
|
1463
1481
|
}
|
|
1464
1482
|
async searchGlobal(query, maxResults, execution) {
|
|
1465
1483
|
const trimmed = query.trim();
|
|
1466
1484
|
if (!trimmed) return [];
|
|
1467
1485
|
await this.maybeProbeDaemon();
|
|
1468
|
-
if (!this.isAvailable())
|
|
1486
|
+
if (!this.isAvailable()) {
|
|
1487
|
+
this.notifyDegradation(execution?.onDegradation, "backend_unavailable");
|
|
1488
|
+
return [];
|
|
1489
|
+
}
|
|
1469
1490
|
const n = maxResults ?? 6;
|
|
1470
1491
|
const searchOptions = this.resolveSearchOptions();
|
|
1471
1492
|
if (this.daemonAvailable) {
|
|
@@ -1484,14 +1505,22 @@ var QmdClient = class _QmdClient {
|
|
|
1484
1505
|
}
|
|
1485
1506
|
return results;
|
|
1486
1507
|
}
|
|
1487
|
-
log.
|
|
1508
|
+
log.warn("QMD daemon global search timed out/failed; skipping subprocess (daemon-only mode)");
|
|
1509
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_timeout");
|
|
1488
1510
|
return [];
|
|
1489
1511
|
}
|
|
1490
1512
|
if (this.daemonSession?.isLoading()) {
|
|
1491
1513
|
log.debug("QMD searchGlobal: daemon loading, skipping subprocess");
|
|
1514
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_loading");
|
|
1492
1515
|
return [];
|
|
1493
1516
|
}
|
|
1494
|
-
return this.searchGlobalViaSubprocess(
|
|
1517
|
+
return this.searchGlobalViaSubprocess(
|
|
1518
|
+
trimmed,
|
|
1519
|
+
n,
|
|
1520
|
+
searchOptions,
|
|
1521
|
+
execution?.signal,
|
|
1522
|
+
execution?.onDegradation
|
|
1523
|
+
);
|
|
1495
1524
|
}
|
|
1496
1525
|
/**
|
|
1497
1526
|
* BM25 keyword search (fast, ~0.3s). Uses `qmd search`.
|
|
@@ -1500,7 +1529,10 @@ var QmdClient = class _QmdClient {
|
|
|
1500
1529
|
const trimmed = query.trim();
|
|
1501
1530
|
if (!trimmed) return [];
|
|
1502
1531
|
await this.maybeProbeDaemon();
|
|
1503
|
-
if (!this.isAvailable())
|
|
1532
|
+
if (!this.isAvailable()) {
|
|
1533
|
+
this.notifyDegradation(execution?.onDegradation, "backend_unavailable");
|
|
1534
|
+
return [];
|
|
1535
|
+
}
|
|
1504
1536
|
const col = collection ?? this.collection;
|
|
1505
1537
|
const n = maxResults ?? this.maxResults;
|
|
1506
1538
|
if (this.daemonAvailable && this.daemonSession) {
|
|
@@ -1519,14 +1551,16 @@ var QmdClient = class _QmdClient {
|
|
|
1519
1551
|
}
|
|
1520
1552
|
return results;
|
|
1521
1553
|
}
|
|
1522
|
-
log.
|
|
1554
|
+
log.warn("QMD daemon bm25 timed out/failed; skipping subprocess (daemon-only mode)");
|
|
1555
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_timeout");
|
|
1523
1556
|
return [];
|
|
1524
1557
|
}
|
|
1525
1558
|
if (this.daemonSession?.isLoading()) {
|
|
1526
1559
|
log.debug("QMD bm25: daemon loading, skipping subprocess");
|
|
1560
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_loading");
|
|
1527
1561
|
return [];
|
|
1528
1562
|
}
|
|
1529
|
-
return this.bm25SearchViaSubprocess(trimmed, col, n, execution?.signal);
|
|
1563
|
+
return this.bm25SearchViaSubprocess(trimmed, col, n, execution?.signal, execution?.onDegradation);
|
|
1530
1564
|
}
|
|
1531
1565
|
/**
|
|
1532
1566
|
* Vector similarity search (~3-4s). Uses `qmd vsearch`.
|
|
@@ -1535,7 +1569,10 @@ var QmdClient = class _QmdClient {
|
|
|
1535
1569
|
const trimmed = query.trim();
|
|
1536
1570
|
if (!trimmed) return [];
|
|
1537
1571
|
await this.maybeProbeDaemon();
|
|
1538
|
-
if (!this.isAvailable())
|
|
1572
|
+
if (!this.isAvailable()) {
|
|
1573
|
+
this.notifyDegradation(execution?.onDegradation, "backend_unavailable");
|
|
1574
|
+
return [];
|
|
1575
|
+
}
|
|
1539
1576
|
const col = collection ?? this.collection;
|
|
1540
1577
|
const n = maxResults ?? this.maxResults;
|
|
1541
1578
|
if (this.daemonAvailable && this.daemonSession) {
|
|
@@ -1554,14 +1591,16 @@ var QmdClient = class _QmdClient {
|
|
|
1554
1591
|
}
|
|
1555
1592
|
return results;
|
|
1556
1593
|
}
|
|
1557
|
-
log.
|
|
1594
|
+
log.warn("QMD daemon vsearch timed out/failed; skipping subprocess (daemon-only mode)");
|
|
1595
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_timeout");
|
|
1558
1596
|
return [];
|
|
1559
1597
|
}
|
|
1560
1598
|
if (this.daemonSession?.isLoading()) {
|
|
1561
1599
|
log.debug("QMD vsearch: daemon loading, skipping subprocess");
|
|
1600
|
+
this.notifyDegradation(execution?.onDegradation, "daemon_loading");
|
|
1562
1601
|
return [];
|
|
1563
1602
|
}
|
|
1564
|
-
return this.vsearchViaSubprocess(trimmed, col, n, execution?.signal);
|
|
1603
|
+
return this.vsearchViaSubprocess(trimmed, col, n, execution?.signal, execution?.onDegradation);
|
|
1565
1604
|
}
|
|
1566
1605
|
/**
|
|
1567
1606
|
* Hybrid search: runs BM25 + vector in parallel, merges/dedupes by path
|
|
@@ -1721,10 +1760,48 @@ var QmdClient = class _QmdClient {
|
|
|
1721
1760
|
return null;
|
|
1722
1761
|
}
|
|
1723
1762
|
}
|
|
1724
|
-
|
|
1763
|
+
/**
|
|
1764
|
+
* Report a backend degradation to the caller's observer (#1536): an empty
|
|
1765
|
+
* result caused by unavailability/loading/timeout is otherwise
|
|
1766
|
+
* indistinguishable from "no matches" (CLAUDE.md rule 34). Observer
|
|
1767
|
+
* failures are swallowed — observability must never break search.
|
|
1768
|
+
*/
|
|
1769
|
+
notifyDegradation(onDegradation, code, detail) {
|
|
1770
|
+
if (!onDegradation) return;
|
|
1771
|
+
try {
|
|
1772
|
+
onDegradation({ backend: "qmd", code, ...detail !== void 0 ? { detail } : {} });
|
|
1773
|
+
} catch (err) {
|
|
1774
|
+
log.debug(`QMD degradation observer threw: ${err}`);
|
|
1775
|
+
}
|
|
1776
|
+
}
|
|
1777
|
+
/**
|
|
1778
|
+
* Condense an error into a degradation `detail` string that is safe to
|
|
1779
|
+
* serialize on LastRecallSnapshot and expose via last-recall MCP/HTTP
|
|
1780
|
+
* surfaces (cursor review on #1544): first line only, path-like tokens
|
|
1781
|
+
* redacted (absolute, home-rooted, and Windows drive paths can leak
|
|
1782
|
+
* usernames and filesystem layout), capped at 160 chars. The unredacted
|
|
1783
|
+
* error still reaches operators via the warn log at the failure site.
|
|
1784
|
+
*/
|
|
1785
|
+
degradationDetail(err, sensitive) {
|
|
1786
|
+
let message = String(err instanceof Error ? err.message : err);
|
|
1787
|
+
for (const value of sensitive ?? []) {
|
|
1788
|
+
if (typeof value !== "string" || value.length === 0) continue;
|
|
1789
|
+
message = message.split(value).join("<query>");
|
|
1790
|
+
for (const fragment of value.split("\n")) {
|
|
1791
|
+
const trimmed = fragment.trim();
|
|
1792
|
+
if (trimmed.length >= 4) {
|
|
1793
|
+
message = message.split(trimmed).join("<query>");
|
|
1794
|
+
}
|
|
1795
|
+
}
|
|
1796
|
+
}
|
|
1797
|
+
const firstLine = message.split("\n")[0] ?? "";
|
|
1798
|
+
const redacted = firstLine.replace(/(?:~|\/|[A-Za-z]:\\)[^\s'"`]+/g, "<path>");
|
|
1799
|
+
return redacted.length > 160 ? `${redacted.slice(0, 159)}\u2026` : redacted;
|
|
1800
|
+
}
|
|
1801
|
+
async searchViaSubprocess(query, collection, maxResults, options, signal, onDegradation) {
|
|
1725
1802
|
if (this.available === false) return [];
|
|
1726
1803
|
if (this.qmdSubprocessStrategy === "search") {
|
|
1727
|
-
return this.bm25SearchViaSubprocess(query, collection, maxResults, signal);
|
|
1804
|
+
return this.bm25SearchViaSubprocess(query, collection, maxResults, signal, onDegradation);
|
|
1728
1805
|
}
|
|
1729
1806
|
const startedAtMs = Date.now();
|
|
1730
1807
|
try {
|
|
@@ -1744,11 +1821,13 @@ var QmdClient = class _QmdClient {
|
|
|
1744
1821
|
if (isCallerCancellation(err, signal)) {
|
|
1745
1822
|
throw isAbortError(err) ? err : abortError("QMD subprocess search aborted");
|
|
1746
1823
|
}
|
|
1747
|
-
|
|
1824
|
+
const detail = this.degradationDetail(err, [query]);
|
|
1825
|
+
log.warn(`QMD subprocess search failed (returning empty): ${detail}`);
|
|
1826
|
+
this.notifyDegradation(onDegradation, "subprocess_error", detail);
|
|
1748
1827
|
return [];
|
|
1749
1828
|
}
|
|
1750
1829
|
}
|
|
1751
|
-
async bm25SearchViaSubprocess(query, collection, maxResults, signal) {
|
|
1830
|
+
async bm25SearchViaSubprocess(query, collection, maxResults, signal, onDegradation) {
|
|
1752
1831
|
if (this.available === false) return [];
|
|
1753
1832
|
const startedAtMs = Date.now();
|
|
1754
1833
|
try {
|
|
@@ -1762,11 +1841,13 @@ var QmdClient = class _QmdClient {
|
|
|
1762
1841
|
if (isCallerCancellation(err, signal)) {
|
|
1763
1842
|
throw isAbortError(err) ? err : abortError("QMD subprocess bm25 aborted");
|
|
1764
1843
|
}
|
|
1765
|
-
|
|
1844
|
+
const detail = this.degradationDetail(err, [query]);
|
|
1845
|
+
log.warn(`QMD bm25 subprocess search failed (returning empty): ${detail}`);
|
|
1846
|
+
this.notifyDegradation(onDegradation, "subprocess_error", detail);
|
|
1766
1847
|
return [];
|
|
1767
1848
|
}
|
|
1768
1849
|
}
|
|
1769
|
-
async vsearchViaSubprocess(query, collection, maxResults, signal) {
|
|
1850
|
+
async vsearchViaSubprocess(query, collection, maxResults, signal, onDegradation) {
|
|
1770
1851
|
if (this.available === false) return [];
|
|
1771
1852
|
const startedAtMs = Date.now();
|
|
1772
1853
|
try {
|
|
@@ -1781,11 +1862,13 @@ var QmdClient = class _QmdClient {
|
|
|
1781
1862
|
if (isCallerCancellation(err, signal)) {
|
|
1782
1863
|
throw isAbortError(err) ? err : abortError("QMD subprocess vsearch aborted");
|
|
1783
1864
|
}
|
|
1784
|
-
|
|
1865
|
+
const detail = this.degradationDetail(err, [query]);
|
|
1866
|
+
log.warn(`QMD vsearch subprocess failed (returning empty): ${detail}`);
|
|
1867
|
+
this.notifyDegradation(onDegradation, "subprocess_error", detail);
|
|
1785
1868
|
return [];
|
|
1786
1869
|
}
|
|
1787
1870
|
}
|
|
1788
|
-
async searchGlobalViaSubprocess(query, maxResults, options, signal) {
|
|
1871
|
+
async searchGlobalViaSubprocess(query, maxResults, options, signal, onDegradation) {
|
|
1789
1872
|
if (this.available === false) return [];
|
|
1790
1873
|
const startedAtMs = Date.now();
|
|
1791
1874
|
try {
|
|
@@ -1808,7 +1891,9 @@ var QmdClient = class _QmdClient {
|
|
|
1808
1891
|
if (isCallerCancellation(err, signal)) {
|
|
1809
1892
|
throw isAbortError(err) ? err : abortError("QMD subprocess global search aborted");
|
|
1810
1893
|
}
|
|
1811
|
-
|
|
1894
|
+
const detail = this.degradationDetail(err, [query]);
|
|
1895
|
+
log.warn(`QMD global subprocess search failed (returning empty): ${detail}`);
|
|
1896
|
+
this.notifyDegradation(onDegradation, "subprocess_error", detail);
|
|
1812
1897
|
return [];
|
|
1813
1898
|
}
|
|
1814
1899
|
}
|
|
@@ -2136,4 +2221,4 @@ export {
|
|
|
2136
2221
|
getQmdCommandName,
|
|
2137
2222
|
QmdClient
|
|
2138
2223
|
};
|
|
2139
|
-
//# sourceMappingURL=chunk-
|
|
2224
|
+
//# sourceMappingURL=chunk-34NSUPWS.js.map
|