claude-memory-layer 1.0.32 → 1.0.33
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/cli/index.js +1110 -72
- package/dist/cli/index.js.map +4 -4
- package/dist/core/index.js +414 -25
- package/dist/core/index.js.map +2 -2
- package/dist/hooks/post-tool-use.js +416 -27
- package/dist/hooks/post-tool-use.js.map +2 -2
- package/dist/hooks/semantic-daemon.js +416 -27
- package/dist/hooks/semantic-daemon.js.map +2 -2
- package/dist/hooks/session-end.js +416 -27
- package/dist/hooks/session-end.js.map +2 -2
- package/dist/hooks/session-start.js +416 -27
- package/dist/hooks/session-start.js.map +2 -2
- package/dist/hooks/stop.js +416 -27
- package/dist/hooks/stop.js.map +2 -2
- package/dist/hooks/user-prompt-submit.js +504 -34
- package/dist/hooks/user-prompt-submit.js.map +2 -2
- package/dist/index.js +416 -27
- package/dist/index.js.map +2 -2
- package/dist/mcp/index.js +407 -32
- package/dist/mcp/index.js.map +2 -2
- package/dist/server/api/index.js +850 -44
- package/dist/server/api/index.js.map +3 -3
- package/dist/server/index.js +1073 -64
- package/dist/server/index.js.map +3 -3
- package/dist/services/memory-service.js +416 -27
- package/dist/services/memory-service.js.map +2 -2
- package/dist/ui/assets/js/bootstrap.js +2 -0
- package/dist/ui/assets/js/overview.js +166 -3
- package/dist/ui/assets/js/state.js +3 -0
- package/dist/ui/index.html +20 -0
- package/dist/ui/style.css +193 -0
- package/package.json +5 -1
|
@@ -2247,10 +2247,15 @@ function sqliteClose(db) {
|
|
|
2247
2247
|
function toDateFromSQLite(value) {
|
|
2248
2248
|
if (value instanceof Date)
|
|
2249
2249
|
return value;
|
|
2250
|
-
if (typeof value === "string")
|
|
2251
|
-
return new Date(value);
|
|
2252
2250
|
if (typeof value === "number")
|
|
2253
2251
|
return new Date(value);
|
|
2252
|
+
if (typeof value === "string") {
|
|
2253
|
+
const trimmed = value.trim();
|
|
2254
|
+
if (/^\d{4}-\d{2}-\d{2}[ T]\d{2}:\d{2}:\d{2}(?:\.\d+)?$/.test(trimmed)) {
|
|
2255
|
+
return /* @__PURE__ */ new Date(trimmed.replace(" ", "T") + "Z");
|
|
2256
|
+
}
|
|
2257
|
+
return new Date(trimmed);
|
|
2258
|
+
}
|
|
2254
2259
|
return new Date(String(value));
|
|
2255
2260
|
}
|
|
2256
2261
|
function toSQLiteTimestamp(date) {
|
|
@@ -2316,6 +2321,13 @@ var MarkdownMirror2 = class {
|
|
|
2316
2321
|
};
|
|
2317
2322
|
|
|
2318
2323
|
// src/core/sqlite-event-store.ts
|
|
2324
|
+
function normalizeQueryRewriteKind(value) {
|
|
2325
|
+
const normalized = (value || "").trim().toLowerCase();
|
|
2326
|
+
if (normalized === "follow-up-context" || normalized === "intent-rewrite")
|
|
2327
|
+
return normalized;
|
|
2328
|
+
return "none";
|
|
2329
|
+
}
|
|
2330
|
+
var REWRITTEN_QUERY_REWRITE_KIND_SQL = `LOWER(TRIM(COALESCE(query_rewrite_kind, 'none'))) IN ('follow-up-context', 'intent-rewrite')`;
|
|
2319
2331
|
var SQLiteEventStore = class {
|
|
2320
2332
|
db;
|
|
2321
2333
|
initialized = false;
|
|
@@ -2576,6 +2588,8 @@ var SQLiteEventStore = class {
|
|
|
2576
2588
|
session_id TEXT,
|
|
2577
2589
|
project_hash TEXT,
|
|
2578
2590
|
query_text TEXT NOT NULL,
|
|
2591
|
+
raw_query_text TEXT,
|
|
2592
|
+
query_rewrite_kind TEXT,
|
|
2579
2593
|
strategy TEXT,
|
|
2580
2594
|
candidate_event_ids TEXT,
|
|
2581
2595
|
selected_event_ids TEXT,
|
|
@@ -2617,6 +2631,8 @@ var SQLiteEventStore = class {
|
|
|
2617
2631
|
CREATE INDEX IF NOT EXISTS idx_helpfulness_event ON memory_helpfulness(event_id);
|
|
2618
2632
|
CREATE INDEX IF NOT EXISTS idx_helpfulness_session ON memory_helpfulness(session_id);
|
|
2619
2633
|
CREATE INDEX IF NOT EXISTS idx_helpfulness_score ON memory_helpfulness(helpfulness_score DESC);
|
|
2634
|
+
CREATE INDEX IF NOT EXISTS idx_helpfulness_created_at ON memory_helpfulness(created_at);
|
|
2635
|
+
CREATE INDEX IF NOT EXISTS idx_helpfulness_measured_at ON memory_helpfulness(measured_at);
|
|
2620
2636
|
CREATE INDEX IF NOT EXISTS idx_retrieval_traces_created_at ON retrieval_traces(created_at DESC);
|
|
2621
2637
|
CREATE INDEX IF NOT EXISTS idx_retrieval_traces_project_hash ON retrieval_traces(project_hash);
|
|
2622
2638
|
CREATE INDEX IF NOT EXISTS idx_retrieval_traces_session_id ON retrieval_traces(session_id);
|
|
@@ -2650,6 +2666,18 @@ var SQLiteEventStore = class {
|
|
|
2650
2666
|
sqliteExec(this.db, `ALTER TABLE retrieval_traces ADD COLUMN candidate_details_json TEXT;`);
|
|
2651
2667
|
} catch {
|
|
2652
2668
|
}
|
|
2669
|
+
try {
|
|
2670
|
+
sqliteExec(this.db, `ALTER TABLE retrieval_traces ADD COLUMN raw_query_text TEXT;`);
|
|
2671
|
+
} catch {
|
|
2672
|
+
}
|
|
2673
|
+
try {
|
|
2674
|
+
sqliteExec(this.db, `ALTER TABLE retrieval_traces ADD COLUMN query_rewrite_kind TEXT;`);
|
|
2675
|
+
} catch {
|
|
2676
|
+
}
|
|
2677
|
+
try {
|
|
2678
|
+
sqliteExec(this.db, `CREATE INDEX IF NOT EXISTS idx_retrieval_traces_query_rewrite_kind ON retrieval_traces(query_rewrite_kind);`);
|
|
2679
|
+
} catch {
|
|
2680
|
+
}
|
|
2653
2681
|
const tableInfo = sqliteAll(this.db, "PRAGMA table_info(events)", []);
|
|
2654
2682
|
const columnNames = tableInfo.map((col) => col.name);
|
|
2655
2683
|
if (!columnNames.includes("access_count")) {
|
|
@@ -3435,8 +3463,11 @@ var SQLiteEventStore = class {
|
|
|
3435
3463
|
/**
|
|
3436
3464
|
* Get helpfulness statistics for dashboard
|
|
3437
3465
|
*/
|
|
3438
|
-
async getHelpfulnessStats() {
|
|
3466
|
+
async getHelpfulnessStats(since) {
|
|
3439
3467
|
await this.initialize();
|
|
3468
|
+
const sinceIso = since?.toISOString();
|
|
3469
|
+
const evaluatedWhere = sinceIso ? `WHERE measured_at IS NOT NULL AND datetime(created_at) >= datetime(?)` : `WHERE measured_at IS NOT NULL`;
|
|
3470
|
+
const totalWhere = sinceIso ? `WHERE datetime(created_at) >= datetime(?)` : ``;
|
|
3440
3471
|
const stats = sqliteGet(
|
|
3441
3472
|
this.db,
|
|
3442
3473
|
`SELECT
|
|
@@ -3446,11 +3477,13 @@ var SQLiteEventStore = class {
|
|
|
3446
3477
|
SUM(CASE WHEN helpfulness_score >= 0.4 AND helpfulness_score < 0.7 THEN 1 ELSE 0 END) as neutral,
|
|
3447
3478
|
SUM(CASE WHEN helpfulness_score < 0.4 THEN 1 ELSE 0 END) as unhelpful
|
|
3448
3479
|
FROM memory_helpfulness
|
|
3449
|
-
|
|
3480
|
+
${evaluatedWhere}`,
|
|
3481
|
+
sinceIso ? [sinceIso] : []
|
|
3450
3482
|
);
|
|
3451
3483
|
const totalRow = sqliteGet(
|
|
3452
3484
|
this.db,
|
|
3453
|
-
`SELECT COUNT(*) as total FROM memory_helpfulness
|
|
3485
|
+
`SELECT COUNT(*) as total FROM memory_helpfulness ${totalWhere}`,
|
|
3486
|
+
sinceIso ? [sinceIso] : []
|
|
3454
3487
|
);
|
|
3455
3488
|
return {
|
|
3456
3489
|
avgScore: Math.round((stats?.avg_score || 0) * 100) / 100,
|
|
@@ -3549,18 +3582,21 @@ var SQLiteEventStore = class {
|
|
|
3549
3582
|
async recordRetrievalTrace(input) {
|
|
3550
3583
|
await this.initialize();
|
|
3551
3584
|
const traceId = randomUUID5();
|
|
3585
|
+
const queryRewriteKind = normalizeQueryRewriteKind(input.queryRewriteKind);
|
|
3552
3586
|
sqliteRun(
|
|
3553
3587
|
this.db,
|
|
3554
3588
|
`INSERT INTO retrieval_traces (
|
|
3555
|
-
trace_id, session_id, project_hash, query_text, strategy,
|
|
3589
|
+
trace_id, session_id, project_hash, query_text, raw_query_text, query_rewrite_kind, strategy,
|
|
3556
3590
|
candidate_event_ids, selected_event_ids, candidate_details_json, selected_details_json,
|
|
3557
3591
|
candidate_count, selected_count, confidence, fallback_trace
|
|
3558
|
-
) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`,
|
|
3592
|
+
) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)`,
|
|
3559
3593
|
[
|
|
3560
3594
|
traceId,
|
|
3561
3595
|
input.sessionId || null,
|
|
3562
3596
|
input.projectHash || null,
|
|
3563
3597
|
input.queryText,
|
|
3598
|
+
input.rawQueryText || null,
|
|
3599
|
+
queryRewriteKind,
|
|
3564
3600
|
input.strategy || null,
|
|
3565
3601
|
JSON.stringify(input.candidateEventIds || []),
|
|
3566
3602
|
JSON.stringify(input.selectedEventIds || []),
|
|
@@ -3586,6 +3622,8 @@ var SQLiteEventStore = class {
|
|
|
3586
3622
|
sessionId: row.session_id || void 0,
|
|
3587
3623
|
projectHash: row.project_hash || void 0,
|
|
3588
3624
|
queryText: row.query_text,
|
|
3625
|
+
rawQueryText: row.raw_query_text || void 0,
|
|
3626
|
+
queryRewriteKind: normalizeQueryRewriteKind(row.query_rewrite_kind),
|
|
3589
3627
|
strategy: row.strategy || void 0,
|
|
3590
3628
|
candidateEventIds: row.candidate_event_ids ? JSON.parse(row.candidate_event_ids) : [],
|
|
3591
3629
|
selectedEventIds: row.selected_event_ids ? JSON.parse(row.selected_event_ids) : [],
|
|
@@ -3612,6 +3650,11 @@ var SQLiteEventStore = class {
|
|
|
3612
3650
|
COUNT(*) as total_queries,
|
|
3613
3651
|
AVG(candidate_count) as avg_candidate_count,
|
|
3614
3652
|
AVG(selected_count) as avg_selected_count,
|
|
3653
|
+
SUM(CASE WHEN ${REWRITTEN_QUERY_REWRITE_KIND_SQL} THEN 1 ELSE 0 END) as rewritten_queries,
|
|
3654
|
+
SUM(CASE WHEN ${REWRITTEN_QUERY_REWRITE_KIND_SQL} AND selected_count > 0 THEN 1 ELSE 0 END) as rewritten_queries_with_selection,
|
|
3655
|
+
SUM(CASE WHEN NOT (${REWRITTEN_QUERY_REWRITE_KIND_SQL}) AND selected_count > 0 THEN 1 ELSE 0 END) as raw_queries_with_selection,
|
|
3656
|
+
AVG(CASE WHEN ${REWRITTEN_QUERY_REWRITE_KIND_SQL} THEN selected_count END) as avg_selected_count_for_rewritten_queries,
|
|
3657
|
+
AVG(CASE WHEN NOT (${REWRITTEN_QUERY_REWRITE_KIND_SQL}) THEN selected_count END) as avg_selected_count_for_raw_queries,
|
|
3615
3658
|
CASE
|
|
3616
3659
|
WHEN SUM(candidate_count) > 0 THEN (SUM(selected_count) * 1.0 / SUM(candidate_count))
|
|
3617
3660
|
ELSE 0
|
|
@@ -3619,15 +3662,41 @@ var SQLiteEventStore = class {
|
|
|
3619
3662
|
FROM retrieval_traces`,
|
|
3620
3663
|
[]
|
|
3621
3664
|
);
|
|
3665
|
+
const totalQueries = Number(row?.total_queries || 0);
|
|
3666
|
+
const rewrittenQueries = Number(row?.rewritten_queries || 0);
|
|
3667
|
+
const rawQueries = Math.max(0, totalQueries - rewrittenQueries);
|
|
3668
|
+
const rewrittenQueriesWithSelection = Number(row?.rewritten_queries_with_selection || 0);
|
|
3669
|
+
const rawQueriesWithSelection = Number(row?.raw_queries_with_selection || 0);
|
|
3622
3670
|
return {
|
|
3623
|
-
totalQueries
|
|
3671
|
+
totalQueries,
|
|
3624
3672
|
avgCandidateCount: Number(row?.avg_candidate_count || 0),
|
|
3625
3673
|
avgSelectedCount: Number(row?.avg_selected_count || 0),
|
|
3626
|
-
selectionRate: Number(row?.selection_rate || 0)
|
|
3674
|
+
selectionRate: Number(row?.selection_rate || 0),
|
|
3675
|
+
rewrittenQueries,
|
|
3676
|
+
rewriteRate: totalQueries > 0 ? rewrittenQueries / totalQueries : 0,
|
|
3677
|
+
rewrittenQueriesWithSelection,
|
|
3678
|
+
rawQueriesWithSelection,
|
|
3679
|
+
rewrittenSelectionRate: rewrittenQueries > 0 ? rewrittenQueriesWithSelection / rewrittenQueries : 0,
|
|
3680
|
+
rawSelectionRate: rawQueries > 0 ? rawQueriesWithSelection / rawQueries : 0,
|
|
3681
|
+
avgSelectedCountForRewrittenQueries: Number(row?.avg_selected_count_for_rewritten_queries || 0),
|
|
3682
|
+
avgSelectedCountForRawQueries: Number(row?.avg_selected_count_for_raw_queries || 0)
|
|
3627
3683
|
};
|
|
3628
3684
|
} catch (err) {
|
|
3629
3685
|
if (err?.message?.includes("no such table")) {
|
|
3630
|
-
return {
|
|
3686
|
+
return {
|
|
3687
|
+
totalQueries: 0,
|
|
3688
|
+
avgCandidateCount: 0,
|
|
3689
|
+
avgSelectedCount: 0,
|
|
3690
|
+
selectionRate: 0,
|
|
3691
|
+
rewrittenQueries: 0,
|
|
3692
|
+
rewriteRate: 0,
|
|
3693
|
+
rewrittenQueriesWithSelection: 0,
|
|
3694
|
+
rawQueriesWithSelection: 0,
|
|
3695
|
+
rewrittenSelectionRate: 0,
|
|
3696
|
+
rawSelectionRate: 0,
|
|
3697
|
+
avgSelectedCountForRewrittenQueries: 0,
|
|
3698
|
+
avgSelectedCountForRawQueries: 0
|
|
3699
|
+
};
|
|
3631
3700
|
}
|
|
3632
3701
|
throw err;
|
|
3633
3702
|
}
|
|
@@ -4439,6 +4508,57 @@ var COMMAND_ARTIFACT_PATTERNS = [
|
|
|
4439
4508
|
/<local-command-stdout>[\s\S]*?<\/local-command-stdout>/i,
|
|
4440
4509
|
/<local-command-stderr>[\s\S]*?<\/local-command-stderr>/i
|
|
4441
4510
|
];
|
|
4511
|
+
var CONTINUATION_QUERY_PATTERNS = [
|
|
4512
|
+
/^\s*(?:continue|resume|next|what(?:'s| is)? next|next\s+(?:step|task|action)|recommended\s+(?:next\s+)?(?:step|task|action)|what should (?:we|i) do next)\??\s*$/i,
|
|
4513
|
+
/^\s*(?:응\s*)?(?:이어서(?:\s*진행(?:해줘)?)?|계속(?:\s*해줘)?|다음\s*(?:단계|작업|추천\s*작업|추천|할\s*일)?(?:은|는)?(?:\s*(?:뭐야|진행(?:해줘)?))?\??|남은\s*(?:추가(?:로)?\s*)?(?:(?:할\s*만한\s*)?(?:작업|일)|할\s*일)?(?:은|는)?\s*(?:있어|있나|있나요|뭐야)\??|추천\s*작업(?:은|는)?(?:\s*뭐야)?\??|진행해줘)\s*$/i
|
|
4514
|
+
];
|
|
4515
|
+
var SHORT_REPAIR_FOLLOW_UP_PATTERNS = [
|
|
4516
|
+
/^\s*(?:fix\s+(?:it|that)|repair\s+(?:it|that)|resolve\s+(?:it|that)|that\s+bug|same\s+issue)\s*$/i,
|
|
4517
|
+
/^\s*(?:그거|그것|이거|이것)?\s*(?:고쳐줘|수정해줘|해결해줘|처리해줘)\s*$/i
|
|
4518
|
+
];
|
|
4519
|
+
var CURRENT_STATE_QUERY_PATTERNS = [
|
|
4520
|
+
/\bcurrent\b.*\b(?:state|status|deployment|blocker|pr|pull request)\b/i,
|
|
4521
|
+
/\b(?:still|as current|current)\b.*\b(?:unresolved|open|pending|not completed)\b/i,
|
|
4522
|
+
/\b(?:old|obsolete|stale|resolved|already resolved)\b.*\b(?:current|still|unresolved|open|state|status)\b/i,
|
|
4523
|
+
/(?:현재|아직|이전|오래된|해결된).*(?:상태|미해결|열린|블로커|PR|풀리퀘스트)/i
|
|
4524
|
+
];
|
|
4525
|
+
var STALE_CONTENT_PATTERNS = [
|
|
4526
|
+
/\b(?:obsolete|superseded|outdated)\b/i,
|
|
4527
|
+
/\bstale\s+(?:operational\s+)?state\b/i,
|
|
4528
|
+
/\bstale\s+after\b/i,
|
|
4529
|
+
/\bno\s+longer\s+(?:valid|current|applies?)\b/i,
|
|
4530
|
+
/\bearlier\s+(?:pull request|pr)\b[\s\S]{0,160}\b(?:open|not completed|had not completed)\b/i,
|
|
4531
|
+
/\bshould\s+not\s+be\s+injected\s+as\s+current\s+context\b/i,
|
|
4532
|
+
/(?:오래된|더 이상 유효하지|현재 상태가 아님)/i
|
|
4533
|
+
];
|
|
4534
|
+
var CONTINUATION_EXPANSION = "current next step plan roadmap status validation replay rerank memory usefulness continuation";
|
|
4535
|
+
var REPAIR_FOLLOW_UP_EXPANSION = "review blocker fix pattern dashboard error state metrics bucket validation sanitize rerun unresolved";
|
|
4536
|
+
var RETRIEVAL_PRIVACY_DECISION_EXPANSION = "retrieval telemetry privacy public api dashboard dashboards rawQueryText queryText raw query text expose safe trace metadata trace id reason strategy rewrite kind aggregate count counts candidate selected public panel";
|
|
4537
|
+
var DECISION_RECALL_TERMS = /* @__PURE__ */ new Set([
|
|
4538
|
+
"decide",
|
|
4539
|
+
"decided",
|
|
4540
|
+
"decision",
|
|
4541
|
+
"agreed",
|
|
4542
|
+
"policy",
|
|
4543
|
+
"constraint"
|
|
4544
|
+
]);
|
|
4545
|
+
var RETRIEVAL_PRIVACY_SURFACE_TERMS = /* @__PURE__ */ new Set([
|
|
4546
|
+
"retrieval",
|
|
4547
|
+
"dashboard",
|
|
4548
|
+
"telemetry",
|
|
4549
|
+
"trace"
|
|
4550
|
+
]);
|
|
4551
|
+
var DECISION_TOPIC_WEAK_TERMS = /* @__PURE__ */ new Set([
|
|
4552
|
+
"api",
|
|
4553
|
+
"dashboard",
|
|
4554
|
+
"retrieval",
|
|
4555
|
+
"trace",
|
|
4556
|
+
"telemetry",
|
|
4557
|
+
"query",
|
|
4558
|
+
"raw",
|
|
4559
|
+
"count",
|
|
4560
|
+
"counts"
|
|
4561
|
+
]);
|
|
4442
4562
|
var GENERIC_TECHNICAL_TERMS = /* @__PURE__ */ new Set([
|
|
4443
4563
|
"api",
|
|
4444
4564
|
"cli",
|
|
@@ -4456,6 +4576,87 @@ var GENERIC_TECHNICAL_TERMS = /* @__PURE__ */ new Set([
|
|
|
4456
4576
|
"db",
|
|
4457
4577
|
"sql"
|
|
4458
4578
|
]);
|
|
4579
|
+
var LOW_INFORMATION_QUERY_TERMS = /* @__PURE__ */ new Set([
|
|
4580
|
+
"the",
|
|
4581
|
+
"and",
|
|
4582
|
+
"or",
|
|
4583
|
+
"for",
|
|
4584
|
+
"from",
|
|
4585
|
+
"with",
|
|
4586
|
+
"without",
|
|
4587
|
+
"about",
|
|
4588
|
+
"what",
|
|
4589
|
+
"when",
|
|
4590
|
+
"where",
|
|
4591
|
+
"which",
|
|
4592
|
+
"who",
|
|
4593
|
+
"why",
|
|
4594
|
+
"how",
|
|
4595
|
+
"did",
|
|
4596
|
+
"does",
|
|
4597
|
+
"do",
|
|
4598
|
+
"we",
|
|
4599
|
+
"i",
|
|
4600
|
+
"in",
|
|
4601
|
+
"to",
|
|
4602
|
+
"of",
|
|
4603
|
+
"on",
|
|
4604
|
+
"as",
|
|
4605
|
+
"be",
|
|
4606
|
+
"was",
|
|
4607
|
+
"were",
|
|
4608
|
+
"decide",
|
|
4609
|
+
"decided",
|
|
4610
|
+
"decision",
|
|
4611
|
+
"agreed",
|
|
4612
|
+
"policy",
|
|
4613
|
+
"constraint",
|
|
4614
|
+
"showing",
|
|
4615
|
+
"can",
|
|
4616
|
+
"you",
|
|
4617
|
+
"me",
|
|
4618
|
+
"show",
|
|
4619
|
+
"tell",
|
|
4620
|
+
"please",
|
|
4621
|
+
"should",
|
|
4622
|
+
"would",
|
|
4623
|
+
"could",
|
|
4624
|
+
"this",
|
|
4625
|
+
"that",
|
|
4626
|
+
"these",
|
|
4627
|
+
"those",
|
|
4628
|
+
"use",
|
|
4629
|
+
"using",
|
|
4630
|
+
"treat",
|
|
4631
|
+
"continue",
|
|
4632
|
+
"resume",
|
|
4633
|
+
"next",
|
|
4634
|
+
"step",
|
|
4635
|
+
"task",
|
|
4636
|
+
"action",
|
|
4637
|
+
"current",
|
|
4638
|
+
"state",
|
|
4639
|
+
"status",
|
|
4640
|
+
"old",
|
|
4641
|
+
"already",
|
|
4642
|
+
"still",
|
|
4643
|
+
"near",
|
|
4644
|
+
"today",
|
|
4645
|
+
"\uC751",
|
|
4646
|
+
"\uADF8\uAC70",
|
|
4647
|
+
"\uADF8\uAC83",
|
|
4648
|
+
"\uC774\uAC70",
|
|
4649
|
+
"\uC774\uAC83",
|
|
4650
|
+
"\uB2E4\uC74C",
|
|
4651
|
+
"\uB2E8\uACC4",
|
|
4652
|
+
"\uC9C4\uD589",
|
|
4653
|
+
"\uC9C4\uD589\uD574\uC918",
|
|
4654
|
+
"\uACC4\uC18D",
|
|
4655
|
+
"\uC774\uC5B4\uC11C",
|
|
4656
|
+
"\uACE0\uCCD0\uC918",
|
|
4657
|
+
"\uC218\uC815\uD574\uC918",
|
|
4658
|
+
"\uD574\uACB0\uD574\uC918"
|
|
4659
|
+
]);
|
|
4459
4660
|
function isCommandArtifactQuery(query) {
|
|
4460
4661
|
const trimmed = query.trim();
|
|
4461
4662
|
if (!trimmed)
|
|
@@ -4467,6 +4668,73 @@ function isCommandArtifactQuery(query) {
|
|
|
4467
4668
|
return true;
|
|
4468
4669
|
return COMMAND_ARTIFACT_PATTERNS.some((pattern) => pattern.test(trimmed));
|
|
4469
4670
|
}
|
|
4671
|
+
function isGenericContinuationQuery(query) {
|
|
4672
|
+
const trimmed = query.trim();
|
|
4673
|
+
if (!trimmed)
|
|
4674
|
+
return false;
|
|
4675
|
+
if (!CONTINUATION_QUERY_PATTERNS.some((pattern) => pattern.test(trimmed)))
|
|
4676
|
+
return false;
|
|
4677
|
+
if (extractTechnicalQueryTerms(trimmed).length > 0)
|
|
4678
|
+
return false;
|
|
4679
|
+
const tokens = trimmed.match(/[A-Za-z0-9가-힣#._/-]+/g) ?? [];
|
|
4680
|
+
if (tokens.length > 10)
|
|
4681
|
+
return false;
|
|
4682
|
+
return !/[A-Za-z0-9_-]+\.[A-Za-z0-9]+/.test(trimmed) && !/(?:^|\s)(?:feat|fix|chore|refactor|docs)\/[A-Za-z0-9._-]+/.test(trimmed) && !/[A-Za-z]:?[\\/]|\/Users\/|\.\/|\.\.\//.test(trimmed);
|
|
4683
|
+
}
|
|
4684
|
+
function isShortRepairFollowUpQuery(query) {
|
|
4685
|
+
const trimmed = query.trim();
|
|
4686
|
+
if (!trimmed)
|
|
4687
|
+
return false;
|
|
4688
|
+
if (extractTechnicalQueryTerms(trimmed).length > 0)
|
|
4689
|
+
return false;
|
|
4690
|
+
const tokens = trimmed.match(/[A-Za-z0-9가-힣#._/-]+/g) ?? [];
|
|
4691
|
+
if (tokens.length > 8)
|
|
4692
|
+
return false;
|
|
4693
|
+
return SHORT_REPAIR_FOLLOW_UP_PATTERNS.some((pattern) => pattern.test(trimmed));
|
|
4694
|
+
}
|
|
4695
|
+
function isCurrentStateQuery(query) {
|
|
4696
|
+
const trimmed = query.trim();
|
|
4697
|
+
if (!trimmed)
|
|
4698
|
+
return false;
|
|
4699
|
+
return CURRENT_STATE_QUERY_PATTERNS.some((pattern) => pattern.test(trimmed));
|
|
4700
|
+
}
|
|
4701
|
+
function isStaleOrSupersededContent(content) {
|
|
4702
|
+
const trimmed = content.trim();
|
|
4703
|
+
if (!trimmed)
|
|
4704
|
+
return false;
|
|
4705
|
+
return STALE_CONTENT_PATTERNS.some((pattern) => pattern.test(trimmed));
|
|
4706
|
+
}
|
|
4707
|
+
function buildRetrievalQualityQuery(query) {
|
|
4708
|
+
const trimmed = query.trim();
|
|
4709
|
+
if (!trimmed)
|
|
4710
|
+
return query;
|
|
4711
|
+
if (isRetrievalPrivacyDecisionQuery(trimmed)) {
|
|
4712
|
+
return `${trimmed} ${RETRIEVAL_PRIVACY_DECISION_EXPANSION}`;
|
|
4713
|
+
}
|
|
4714
|
+
if (isGenericContinuationQuery(trimmed)) {
|
|
4715
|
+
return `${trimmed} ${CONTINUATION_EXPANSION}`;
|
|
4716
|
+
}
|
|
4717
|
+
if (isShortRepairFollowUpQuery(trimmed)) {
|
|
4718
|
+
return `${trimmed} ${REPAIR_FOLLOW_UP_EXPANSION}`;
|
|
4719
|
+
}
|
|
4720
|
+
return query;
|
|
4721
|
+
}
|
|
4722
|
+
function isRetrievalPrivacyDecisionQuery(query) {
|
|
4723
|
+
const trimmed = query.trim();
|
|
4724
|
+
if (!trimmed)
|
|
4725
|
+
return false;
|
|
4726
|
+
const terms = new Set(tokenizeQualityText(trimmed));
|
|
4727
|
+
const hasDecisionSignal = hasAnyTerm(terms, DECISION_RECALL_TERMS) || /(?:결정|정책|원칙)/i.test(trimmed);
|
|
4728
|
+
if (!hasDecisionSignal)
|
|
4729
|
+
return false;
|
|
4730
|
+
const hasRawQuerySignal = terms.has("raw") && terms.has("query");
|
|
4731
|
+
const hasPrivacySignal = terms.has("privacy") || terms.has("expose") || terms.has("redacted");
|
|
4732
|
+
const hasRetrievalSurface = hasAnyTerm(terms, RETRIEVAL_PRIVACY_SURFACE_TERMS) || terms.has("api") && terms.has("query");
|
|
4733
|
+
const hasQuerySurface = terms.has("query") && (terms.has("dashboard") || terms.has("trace") || terms.has("telemetry") || terms.has("api"));
|
|
4734
|
+
const hasKoreanRetrievalSurface = /(?:검색|리트리벌|retrieval|대시보드|트레이스|텔레메트리|telemetry)/i.test(trimmed);
|
|
4735
|
+
const hasKoreanPrivacySurface = /(?:원문|쿼리|프라이버시|개인정보|노출|트레이스|메타데이터)/i.test(trimmed);
|
|
4736
|
+
return (hasRetrievalSurface || hasKoreanRetrievalSurface && hasKoreanPrivacySurface) && (hasRawQuerySignal || hasPrivacySignal || hasQuerySurface || hasKoreanPrivacySurface);
|
|
4737
|
+
}
|
|
4470
4738
|
function extractTechnicalQueryTerms(query) {
|
|
4471
4739
|
const matches = query.match(/[A-Za-z][A-Za-z0-9_.:-]{2,}/g) ?? [];
|
|
4472
4740
|
const terms = matches.filter((term) => {
|
|
@@ -4484,9 +4752,87 @@ function hasTechnicalTermOverlap(query, content) {
|
|
|
4484
4752
|
const normalizedContent = content.toLowerCase();
|
|
4485
4753
|
return terms.some((term) => normalizedContent.includes(term));
|
|
4486
4754
|
}
|
|
4755
|
+
function hasDiscriminativeTermOverlap(query, content) {
|
|
4756
|
+
const queryTerms = extractDiscriminativeQueryTerms(query);
|
|
4757
|
+
const contentTerms = new Set(tokenizeQualityText(content));
|
|
4758
|
+
if (isRetrievalPrivacyDecisionQuery(query) && hasRetrievalPrivacyDecisionContent(contentTerms)) {
|
|
4759
|
+
return true;
|
|
4760
|
+
}
|
|
4761
|
+
if (shouldRequireDecisionTopicOverlap(query)) {
|
|
4762
|
+
const topicTerms = queryTerms.filter((term) => !DECISION_TOPIC_WEAK_TERMS.has(term));
|
|
4763
|
+
if (topicTerms.length > 0) {
|
|
4764
|
+
return topicTerms.some((term) => contentTerms.has(term));
|
|
4765
|
+
}
|
|
4766
|
+
}
|
|
4767
|
+
if (queryTerms.length < 3)
|
|
4768
|
+
return true;
|
|
4769
|
+
const requiredHits = queryTerms.length >= 3 ? 2 : 1;
|
|
4770
|
+
let hits = 0;
|
|
4771
|
+
for (const term of queryTerms) {
|
|
4772
|
+
if (contentTerms.has(term))
|
|
4773
|
+
hits += 1;
|
|
4774
|
+
if (hits >= requiredHits)
|
|
4775
|
+
return true;
|
|
4776
|
+
}
|
|
4777
|
+
return false;
|
|
4778
|
+
}
|
|
4487
4779
|
function shouldApplyTechnicalGuard(query) {
|
|
4488
4780
|
return extractTechnicalQueryTerms(query).length > 0;
|
|
4489
4781
|
}
|
|
4782
|
+
function hasAnyTerm(terms, expectedTerms) {
|
|
4783
|
+
let found = false;
|
|
4784
|
+
expectedTerms.forEach((term) => {
|
|
4785
|
+
if (terms.has(term))
|
|
4786
|
+
found = true;
|
|
4787
|
+
});
|
|
4788
|
+
return found;
|
|
4789
|
+
}
|
|
4790
|
+
function shouldRequireDecisionTopicOverlap(query) {
|
|
4791
|
+
if (isRetrievalPrivacyDecisionQuery(query))
|
|
4792
|
+
return false;
|
|
4793
|
+
const trimmed = query.trim();
|
|
4794
|
+
if (!trimmed)
|
|
4795
|
+
return false;
|
|
4796
|
+
const terms = new Set(tokenizeQualityText(trimmed));
|
|
4797
|
+
return hasAnyTerm(terms, DECISION_RECALL_TERMS) || /(?:결정|정책|원칙)/i.test(trimmed);
|
|
4798
|
+
}
|
|
4799
|
+
function extractDiscriminativeQueryTerms(query) {
|
|
4800
|
+
const seen = /* @__PURE__ */ new Set();
|
|
4801
|
+
const terms = [];
|
|
4802
|
+
for (const token of tokenizeQualityText(query)) {
|
|
4803
|
+
if (LOW_INFORMATION_QUERY_TERMS.has(token))
|
|
4804
|
+
continue;
|
|
4805
|
+
if (GENERIC_TECHNICAL_TERMS.has(token))
|
|
4806
|
+
continue;
|
|
4807
|
+
if (seen.has(token))
|
|
4808
|
+
continue;
|
|
4809
|
+
seen.add(token);
|
|
4810
|
+
terms.push(token);
|
|
4811
|
+
}
|
|
4812
|
+
return terms;
|
|
4813
|
+
}
|
|
4814
|
+
function hasRetrievalPrivacyDecisionContent(contentTerms) {
|
|
4815
|
+
const hasDashboardTraceMetadata = contentTerms.has("dashboard") && (contentTerms.has("trace") || contentTerms.has("metadata")) && (contentTerms.has("safe") || contentTerms.has("strategy") || contentTerms.has("rewrite") || contentTerms.has("candidate") || contentTerms.has("selected") || contentTerms.has("count") || contentTerms.has("reason"));
|
|
4816
|
+
const hasRawQueryPrivacyPolicy = contentTerms.has("retrieval") && (contentTerms.has("privacy") || contentTerms.has("expose") || contentTerms.has("raw") && contentTerms.has("query") && (contentTerms.has("dashboard") || contentTerms.has("telemetry") || contentTerms.has("api") || contentTerms.has("public")));
|
|
4817
|
+
return hasDashboardTraceMetadata || hasRawQueryPrivacyPolicy;
|
|
4818
|
+
}
|
|
4819
|
+
function tokenizeQualityText(text) {
|
|
4820
|
+
return text.replace(/([a-z])([A-Z])/g, "$1 $2").toLowerCase().replace(/[^A-Za-z0-9가-힣\s_.:-]/g, " ").split(/\s+/).flatMap((token) => token.split(/(?=[._:-])|(?<=[._:-])/g)).map((token) => normalizeQualityToken(token.replace(/^[._:-]+|[._:-]+$/g, ""))).filter((token) => token.length >= 2);
|
|
4821
|
+
}
|
|
4822
|
+
function normalizeQualityToken(token) {
|
|
4823
|
+
if (token === "apis")
|
|
4824
|
+
return "api";
|
|
4825
|
+
if (token === "ids")
|
|
4826
|
+
return "id";
|
|
4827
|
+
if (LOW_INFORMATION_QUERY_TERMS.has(token) || GENERIC_TECHNICAL_TERMS.has(token))
|
|
4828
|
+
return token;
|
|
4829
|
+
if (token.length > 4 && token.endsWith("ies"))
|
|
4830
|
+
return `${token.slice(0, -3)}y`;
|
|
4831
|
+
if (token.length > 3 && token.endsWith("s") && !token.endsWith("ss") && !token.endsWith("us") && !token.endsWith("is")) {
|
|
4832
|
+
return token.slice(0, -1);
|
|
4833
|
+
}
|
|
4834
|
+
return token;
|
|
4835
|
+
}
|
|
4490
4836
|
|
|
4491
4837
|
// src/core/retriever.ts
|
|
4492
4838
|
var DEFAULT_OPTIONS = {
|
|
@@ -4539,6 +4885,7 @@ var Retriever = class {
|
|
|
4539
4885
|
const opts = { ...DEFAULT_OPTIONS, ...options };
|
|
4540
4886
|
const sessionFilter = opts.scope?.sessionId ?? opts.sessionId;
|
|
4541
4887
|
const fallbackTrace = [];
|
|
4888
|
+
const qualityQuery = buildRetrievalQualityQuery(query);
|
|
4542
4889
|
if (isCommandArtifactQuery(query)) {
|
|
4543
4890
|
fallbackTrace.push("guard:command-artifact-query");
|
|
4544
4891
|
const emptyMatch = this.matcher.matchSearchResults([], () => 0);
|
|
@@ -4555,6 +4902,7 @@ var Retriever = class {
|
|
|
4555
4902
|
const fallbackEnabled = (opts.strategy ?? "auto") === "auto";
|
|
4556
4903
|
const primaryStrategy = opts.strategy === "auto" ? "fast" : opts.strategy || "fast";
|
|
4557
4904
|
let current = await this.runStage(query, {
|
|
4905
|
+
qualityQuery,
|
|
4558
4906
|
strategy: primaryStrategy,
|
|
4559
4907
|
topK: opts.topK,
|
|
4560
4908
|
minScore: opts.minScore,
|
|
@@ -4572,6 +4920,7 @@ var Retriever = class {
|
|
|
4572
4920
|
fallbackTrace.push(`stage:primary:${primaryStrategy}`);
|
|
4573
4921
|
if (fallbackEnabled && this.shouldFallback(current.matchResult, current.results) && primaryStrategy !== "deep") {
|
|
4574
4922
|
current = await this.runStage(query, {
|
|
4923
|
+
qualityQuery,
|
|
4575
4924
|
strategy: "deep",
|
|
4576
4925
|
topK: opts.topK,
|
|
4577
4926
|
minScore: opts.minScore,
|
|
@@ -4589,6 +4938,7 @@ var Retriever = class {
|
|
|
4589
4938
|
}
|
|
4590
4939
|
if (fallbackEnabled && this.shouldFallback(current.matchResult, current.results)) {
|
|
4591
4940
|
current = await this.runStage(query, {
|
|
4941
|
+
qualityQuery,
|
|
4592
4942
|
strategy: "deep",
|
|
4593
4943
|
topK: opts.topK,
|
|
4594
4944
|
minScore: Math.max(0.5, opts.minScore - 0.15),
|
|
@@ -4605,11 +4955,21 @@ var Retriever = class {
|
|
|
4605
4955
|
fallbackTrace.push("fallback:scope-expanded");
|
|
4606
4956
|
}
|
|
4607
4957
|
if (fallbackEnabled && this.shouldFallback(current.matchResult, current.results)) {
|
|
4608
|
-
const summary = await this.buildSummaryFallback(
|
|
4958
|
+
const summary = await this.buildSummaryFallback(qualityQuery, opts.topK);
|
|
4959
|
+
const scopedSummary = await this.applyScopeFilters(summary, {
|
|
4960
|
+
scope: opts.scope,
|
|
4961
|
+
projectScopeMode: opts.projectScopeMode,
|
|
4962
|
+
projectHash: opts.projectHash,
|
|
4963
|
+
allowedProjectHashes: opts.allowedProjectHashes
|
|
4964
|
+
});
|
|
4965
|
+
const filteredSummary = this.applyQualityFilters(scopedSummary, {
|
|
4966
|
+
query,
|
|
4967
|
+
minScore: opts.minScore
|
|
4968
|
+
});
|
|
4609
4969
|
current = {
|
|
4610
|
-
results:
|
|
4611
|
-
candidateResults:
|
|
4612
|
-
matchResult: this.matcher.matchSearchResults(
|
|
4970
|
+
results: filteredSummary,
|
|
4971
|
+
candidateResults: filteredSummary,
|
|
4972
|
+
matchResult: this.matcher.matchSearchResults(filteredSummary, () => 0)
|
|
4613
4973
|
};
|
|
4614
4974
|
fallbackTrace.push("fallback:summary");
|
|
4615
4975
|
}
|
|
@@ -4634,7 +4994,10 @@ var Retriever = class {
|
|
|
4634
4994
|
semanticScore: r.semanticScore,
|
|
4635
4995
|
lexicalScore: r.lexicalScore,
|
|
4636
4996
|
recencyScore: r.recencyScore
|
|
4637
|
-
}))
|
|
4997
|
+
})),
|
|
4998
|
+
rawQueryText: current.queryRewriteKind ? query : void 0,
|
|
4999
|
+
effectiveQueryText: current.effectiveQueryText,
|
|
5000
|
+
queryRewriteKind: current.queryRewriteKind
|
|
4638
5001
|
};
|
|
4639
5002
|
}
|
|
4640
5003
|
async retrieveUnified(query, options = {}) {
|
|
@@ -4672,8 +5035,11 @@ var Retriever = class {
|
|
|
4672
5035
|
}
|
|
4673
5036
|
}
|
|
4674
5037
|
async runStage(query, input) {
|
|
4675
|
-
|
|
4676
|
-
let
|
|
5038
|
+
const searchQuery = input.qualityQuery ?? query;
|
|
5039
|
+
let rerankQuery = searchQuery;
|
|
5040
|
+
let effectiveQueryText;
|
|
5041
|
+
let queryRewriteKind;
|
|
5042
|
+
let initialResults = await this.searchByStrategy(searchQuery, {
|
|
4677
5043
|
strategy: input.strategy,
|
|
4678
5044
|
topK: input.topK,
|
|
4679
5045
|
minScore: input.minScore,
|
|
@@ -4681,9 +5047,12 @@ var Retriever = class {
|
|
|
4681
5047
|
});
|
|
4682
5048
|
if (input.intentRewrite && input.strategy === "deep" && this.queryRewriter) {
|
|
4683
5049
|
const rewritten = (await this.queryRewriter(query))?.trim();
|
|
4684
|
-
|
|
4685
|
-
|
|
4686
|
-
|
|
5050
|
+
const normalizedQuery = query.trim();
|
|
5051
|
+
if (rewritten && rewritten !== normalizedQuery) {
|
|
5052
|
+
effectiveQueryText = `${normalizedQuery} ${rewritten}`.trim();
|
|
5053
|
+
queryRewriteKind = "intent-rewrite";
|
|
5054
|
+
rerankQuery = buildRetrievalQualityQuery(effectiveQueryText);
|
|
5055
|
+
const rewrittenResults = await this.searchByStrategy(buildRetrievalQualityQuery(rewritten), {
|
|
4687
5056
|
strategy: "deep",
|
|
4688
5057
|
topK: input.topK,
|
|
4689
5058
|
minScore: Math.max(0.5, input.minScore - 0.1),
|
|
@@ -4710,10 +5079,14 @@ var Retriever = class {
|
|
|
4710
5079
|
});
|
|
4711
5080
|
const top = qualityFiltered.slice(0, input.topK);
|
|
4712
5081
|
const matchResult = this.matcher.matchSearchResults(top, () => 0);
|
|
4713
|
-
return { results: top, candidateResults: qualityFiltered, matchResult };
|
|
5082
|
+
return { results: top, candidateResults: qualityFiltered, matchResult, effectiveQueryText, queryRewriteKind };
|
|
4714
5083
|
}
|
|
4715
5084
|
applyQualityFilters(results, options) {
|
|
4716
5085
|
let filtered = [...results];
|
|
5086
|
+
if (isCurrentStateQuery(options.query)) {
|
|
5087
|
+
filtered = filtered.filter((result) => !isStaleOrSupersededContent(result.content));
|
|
5088
|
+
}
|
|
5089
|
+
filtered = filtered.filter((result) => hasDiscriminativeTermOverlap(options.query, result.content));
|
|
4717
5090
|
if (shouldApplyTechnicalGuard(options.query)) {
|
|
4718
5091
|
filtered = filtered.filter((result) => hasTechnicalTermOverlap(options.query, result.content));
|
|
4719
5092
|
}
|
|
@@ -5021,7 +5394,21 @@ _Context:_ ${sessionContext}`;
|
|
|
5021
5394
|
});
|
|
5022
5395
|
}
|
|
5023
5396
|
tokenize(text) {
|
|
5024
|
-
return text.toLowerCase().replace(/[^\p{L}\p{N}\s]/gu, " ").split(/\s+/).filter((t) => t.length >= 2).slice(0, 64);
|
|
5397
|
+
return text.replace(/([a-z])([A-Z])/g, "$1 $2").toLowerCase().replace(/[^\p{L}\p{N}\s]/gu, " ").split(/\s+/).map((token) => this.normalizeToken(token)).filter((t) => t.length >= 2).slice(0, 64);
|
|
5398
|
+
}
|
|
5399
|
+
normalizeToken(token) {
|
|
5400
|
+
if (token === "apis")
|
|
5401
|
+
return "api";
|
|
5402
|
+
if (token === "ids")
|
|
5403
|
+
return "id";
|
|
5404
|
+
if (token === "does")
|
|
5405
|
+
return token;
|
|
5406
|
+
if (token.length > 4 && token.endsWith("ies"))
|
|
5407
|
+
return `${token.slice(0, -3)}y`;
|
|
5408
|
+
if (token.length > 3 && token.endsWith("s") && !token.endsWith("ss") && !token.endsWith("us") && !token.endsWith("is") && !token.endsWith("ps")) {
|
|
5409
|
+
return token.slice(0, -1);
|
|
5410
|
+
}
|
|
5411
|
+
return token;
|
|
5025
5412
|
}
|
|
5026
5413
|
keywordOverlap(a, b) {
|
|
5027
5414
|
if (a.length === 0 || b.length === 0)
|
|
@@ -5084,9 +5471,9 @@ var RetrievalAnalyticsService = class {
|
|
|
5084
5471
|
await this.deps.initialize();
|
|
5085
5472
|
return this.deps.retrievalStore.getHelpfulMemories(limit);
|
|
5086
5473
|
}
|
|
5087
|
-
async getHelpfulnessStats() {
|
|
5474
|
+
async getHelpfulnessStats(since) {
|
|
5088
5475
|
await this.deps.initialize();
|
|
5089
|
-
return this.deps.retrievalStore.getHelpfulnessStats();
|
|
5476
|
+
return this.deps.retrievalStore.getHelpfulnessStats(since);
|
|
5090
5477
|
}
|
|
5091
5478
|
/**
|
|
5092
5479
|
* Extract topic keywords from event content (markdown headings and key terms).
|
|
@@ -5511,7 +5898,9 @@ var RetrievalOrchestrator = class {
|
|
|
5511
5898
|
await this.deps.traceStore.recordRetrievalTrace({
|
|
5512
5899
|
sessionId: options?.sessionId,
|
|
5513
5900
|
projectHash: projectHash || void 0,
|
|
5514
|
-
queryText: query,
|
|
5901
|
+
queryText: result.effectiveQueryText || query,
|
|
5902
|
+
rawQueryText: result.rawQueryText || (result.queryRewriteKind ? query : void 0),
|
|
5903
|
+
queryRewriteKind: result.queryRewriteKind || "none",
|
|
5515
5904
|
strategy: options?.strategy || "auto",
|
|
5516
5905
|
candidateEventIds,
|
|
5517
5906
|
selectedEventIds,
|
|
@@ -7501,8 +7890,8 @@ var MemoryService = class {
|
|
|
7501
7890
|
/**
|
|
7502
7891
|
* Get helpfulness statistics for dashboard
|
|
7503
7892
|
*/
|
|
7504
|
-
async getHelpfulnessStats() {
|
|
7505
|
-
return this.retrievalAnalyticsService.getHelpfulnessStats();
|
|
7893
|
+
async getHelpfulnessStats(since) {
|
|
7894
|
+
return this.retrievalAnalyticsService.getHelpfulnessStats(since);
|
|
7506
7895
|
}
|
|
7507
7896
|
/**
|
|
7508
7897
|
* Mark a consolidated memory as accessed
|