matryoshka-rlm 0.2.36 → 0.2.39
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/engine/nucleus-engine.d.ts.map +1 -1
- package/dist/engine/nucleus-engine.js +27 -3
- package/dist/engine/nucleus-engine.js.map +1 -1
- package/dist/fsm/rlm-states.d.ts.map +1 -1
- package/dist/fsm/rlm-states.js +25 -1
- package/dist/fsm/rlm-states.js.map +1 -1
- package/dist/logic/lc-linter.d.ts +37 -0
- package/dist/logic/lc-linter.d.ts.map +1 -0
- package/dist/logic/lc-linter.js +296 -0
- package/dist/logic/lc-linter.js.map +1 -0
- package/dist/persistence/session-db.d.ts +28 -37
- package/dist/persistence/session-db.d.ts.map +1 -1
- package/dist/persistence/session-db.js +194 -97
- package/dist/persistence/session-db.js.map +1 -1
- package/package.json +3 -3
|
@@ -0,0 +1,296 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Scan `input` and produce a per-character classification of which positions
|
|
3
|
+
* are "inside a string literal." This is the single source of truth for
|
|
4
|
+
* "should this `(` count?" — every paren/bracket-counting pass consults it.
|
|
5
|
+
*
|
|
6
|
+
* The scanner mirrors `lc-parser.ts`'s lexer: `"` toggles string mode, `\`
|
|
7
|
+
* escapes the next character. We do not interpret escape sequences here;
|
|
8
|
+
* we only need to know which positions are inside string mode.
|
|
9
|
+
*
|
|
10
|
+
* Returns `null` if the string is unterminated (`"` opened but never closed)
|
|
11
|
+
* — at that point structural counting is unreliable and we bail.
|
|
12
|
+
*/
|
|
13
|
+
function classifyStringPositions(input) {
|
|
14
|
+
const inString = new Array(input.length).fill(false);
|
|
15
|
+
let active = false;
|
|
16
|
+
let escaped = false;
|
|
17
|
+
for (let i = 0; i < input.length; i++) {
|
|
18
|
+
const ch = input[i];
|
|
19
|
+
if (active)
|
|
20
|
+
inString[i] = true;
|
|
21
|
+
if (escaped) {
|
|
22
|
+
escaped = false;
|
|
23
|
+
continue;
|
|
24
|
+
}
|
|
25
|
+
if (ch === "\\") {
|
|
26
|
+
escaped = true;
|
|
27
|
+
continue;
|
|
28
|
+
}
|
|
29
|
+
if (ch === '"') {
|
|
30
|
+
// The closing quote is part of the string for our purposes — but its
|
|
31
|
+
// index after toggling matters less than balancing the state.
|
|
32
|
+
active = !active;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
if (active)
|
|
36
|
+
return null; // unterminated
|
|
37
|
+
return inString;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Trim "obvious" prose around an S-expression: anything before the first `(`
|
|
41
|
+
* and anything after the position where the outermost expression closes.
|
|
42
|
+
*
|
|
43
|
+
* Refuses to strip a side that contains any Nucleus syntax character —
|
|
44
|
+
* `(`, `[`, `]`, `"`, `⊗`. Without this guard we'd silently delete real
|
|
45
|
+
* intent: an unbalanced constraint prefix like `[type=string ⊗ (expr)`
|
|
46
|
+
* would lose its constraint, or a chained `(expr1)(expr2)` would lose
|
|
47
|
+
* the second expression. Per the project rule (correctness > token cost),
|
|
48
|
+
* we'd rather fall through to LLM retry than mangle the query.
|
|
49
|
+
*/
|
|
50
|
+
function stripSurroundingProse(input, inString) {
|
|
51
|
+
// Characters that, if found in the candidate prose region, mean the
|
|
52
|
+
// region is *not* mere prose — could be an unclosed constraint, a
|
|
53
|
+
// stray string literal, or another expression. Refuse to strip.
|
|
54
|
+
const NUCLEUS_SYNTAX_CHARS = /[()[\]"⊗]/;
|
|
55
|
+
// Locate the first non-string `(`.
|
|
56
|
+
let firstOpen = -1;
|
|
57
|
+
for (let i = 0; i < input.length; i++) {
|
|
58
|
+
if (!inString[i] && input[i] === "(") {
|
|
59
|
+
firstOpen = i;
|
|
60
|
+
break;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
if (firstOpen === -1) {
|
|
64
|
+
return { stripped: input, changed: false, leading: false, trailing: false };
|
|
65
|
+
}
|
|
66
|
+
// Walk from firstOpen, tracking depth. The outermost expression closes
|
|
67
|
+
// the first time depth returns to zero. If depth never returns to zero,
|
|
68
|
+
// there is no outermost-end to trim against; defer to the balancer.
|
|
69
|
+
let depth = 0;
|
|
70
|
+
let outerClose = -1;
|
|
71
|
+
for (let i = firstOpen; i < input.length; i++) {
|
|
72
|
+
if (inString[i])
|
|
73
|
+
continue;
|
|
74
|
+
const ch = input[i];
|
|
75
|
+
if (ch === "(")
|
|
76
|
+
depth++;
|
|
77
|
+
else if (ch === ")") {
|
|
78
|
+
depth--;
|
|
79
|
+
if (depth === 0) {
|
|
80
|
+
outerClose = i;
|
|
81
|
+
break;
|
|
82
|
+
}
|
|
83
|
+
if (depth < 0) {
|
|
84
|
+
// Stray ')' before the outer expression even opened — abandon
|
|
85
|
+
// prose-stripping; balancer will deal with it.
|
|
86
|
+
return { stripped: input, changed: false, leading: false, trailing: false };
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
const leadingText = firstOpen > 0 ? input.slice(0, firstOpen) : "";
|
|
91
|
+
const leadingHasProse = leadingText.trim().length > 0;
|
|
92
|
+
const leadingSafe = leadingHasProse && !NUCLEUS_SYNTAX_CHARS.test(leadingText);
|
|
93
|
+
// If the leading region has prose but also contains Nucleus syntax,
|
|
94
|
+
// it's not safely strippable — bail entirely so neither side is
|
|
95
|
+
// touched (we don't want to half-repair into an even more confusing
|
|
96
|
+
// shape for the caller).
|
|
97
|
+
if (leadingHasProse && !leadingSafe) {
|
|
98
|
+
return { stripped: input, changed: false, leading: false, trailing: false };
|
|
99
|
+
}
|
|
100
|
+
const leading = leadingSafe;
|
|
101
|
+
if (outerClose === -1) {
|
|
102
|
+
// Unclosed outermost expression — only strip leading prose. Trailing
|
|
103
|
+
// prose (if any) is ambiguous: we don't know where the expr "should"
|
|
104
|
+
// end.
|
|
105
|
+
if (!leading) {
|
|
106
|
+
return { stripped: input, changed: false, leading: false, trailing: false };
|
|
107
|
+
}
|
|
108
|
+
return {
|
|
109
|
+
stripped: input.slice(firstOpen),
|
|
110
|
+
changed: true,
|
|
111
|
+
leading: true,
|
|
112
|
+
trailing: false,
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
const trailingText = outerClose < input.length - 1 ? input.slice(outerClose + 1) : "";
|
|
116
|
+
const trailingHasProse = trailingText.trim().length > 0;
|
|
117
|
+
const trailingSafe = trailingHasProse && !NUCLEUS_SYNTAX_CHARS.test(trailingText);
|
|
118
|
+
if (trailingHasProse && !trailingSafe) {
|
|
119
|
+
// Trailing region looks like another expression / quoted text — don't
|
|
120
|
+
// silently drop it.
|
|
121
|
+
return { stripped: input, changed: false, leading: false, trailing: false };
|
|
122
|
+
}
|
|
123
|
+
const trailing = trailingSafe;
|
|
124
|
+
if (!leading && !trailing) {
|
|
125
|
+
return { stripped: input, changed: false, leading: false, trailing: false };
|
|
126
|
+
}
|
|
127
|
+
return {
|
|
128
|
+
stripped: input.slice(firstOpen, outerClose + 1),
|
|
129
|
+
changed: true,
|
|
130
|
+
leading,
|
|
131
|
+
trailing,
|
|
132
|
+
};
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* Count net paren/bracket imbalance (ignoring positions inside strings).
|
|
136
|
+
* Positive = unclosed (need more closers). Negative = surplus closers.
|
|
137
|
+
* Returns null if at any point a closer appears with no matching opener
|
|
138
|
+
* AND the surplus is not just trailing — i.e. a mid-expression stray
|
|
139
|
+
* closer, which we don't try to fix.
|
|
140
|
+
*/
|
|
141
|
+
function bracketBalance(input, inString) {
|
|
142
|
+
let parens = 0;
|
|
143
|
+
let brackets = 0;
|
|
144
|
+
let trailingExtraParens = 0;
|
|
145
|
+
let trailingExtraBrackets = 0;
|
|
146
|
+
for (let i = 0; i < input.length; i++) {
|
|
147
|
+
if (inString[i])
|
|
148
|
+
continue;
|
|
149
|
+
const ch = input[i];
|
|
150
|
+
if (ch === "(")
|
|
151
|
+
parens++;
|
|
152
|
+
else if (ch === ")") {
|
|
153
|
+
parens--;
|
|
154
|
+
if (parens < 0) {
|
|
155
|
+
// Could be a trailing extra ')' — defer judgment until we know
|
|
156
|
+
// whether anything non-whitespace, non-closer follows.
|
|
157
|
+
// Stash the position; if everything afterward is just `)`/`]`/space,
|
|
158
|
+
// we'll treat it as a trailing surplus.
|
|
159
|
+
const rest = input.slice(i);
|
|
160
|
+
if (/^[\s)\]]*$/.test(rest)) {
|
|
161
|
+
// Count the trailing surplus closers.
|
|
162
|
+
for (const c of rest) {
|
|
163
|
+
if (c === ")")
|
|
164
|
+
trailingExtraParens++;
|
|
165
|
+
else if (c === "]")
|
|
166
|
+
trailingExtraBrackets++;
|
|
167
|
+
}
|
|
168
|
+
return {
|
|
169
|
+
parens: 0,
|
|
170
|
+
brackets,
|
|
171
|
+
trailingExtraParens,
|
|
172
|
+
trailingExtraBrackets,
|
|
173
|
+
};
|
|
174
|
+
}
|
|
175
|
+
// Mid-expression stray ')' — unrepairable here.
|
|
176
|
+
return null;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
else if (ch === "[")
|
|
180
|
+
brackets++;
|
|
181
|
+
else if (ch === "]") {
|
|
182
|
+
brackets--;
|
|
183
|
+
if (brackets < 0) {
|
|
184
|
+
const rest = input.slice(i);
|
|
185
|
+
if (/^[\s)\]]*$/.test(rest)) {
|
|
186
|
+
for (const c of rest) {
|
|
187
|
+
if (c === ")")
|
|
188
|
+
trailingExtraParens++;
|
|
189
|
+
else if (c === "]")
|
|
190
|
+
trailingExtraBrackets++;
|
|
191
|
+
}
|
|
192
|
+
return {
|
|
193
|
+
parens,
|
|
194
|
+
brackets: 0,
|
|
195
|
+
trailingExtraParens,
|
|
196
|
+
trailingExtraBrackets,
|
|
197
|
+
};
|
|
198
|
+
}
|
|
199
|
+
return null;
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
return { parens, brackets, trailingExtraParens, trailingExtraBrackets };
|
|
204
|
+
}
|
|
205
|
+
/**
|
|
206
|
+
* Main entry. See module-level doc for scope of repairs.
|
|
207
|
+
*/
|
|
208
|
+
export function lintAndRepair(input) {
|
|
209
|
+
if (!input || input.trim().length === 0) {
|
|
210
|
+
return { repaired: null, repairs: [] };
|
|
211
|
+
}
|
|
212
|
+
const inStringInitial = classifyStringPositions(input);
|
|
213
|
+
if (inStringInitial === null) {
|
|
214
|
+
// Unterminated string literal — bail. We won't guess where it ends.
|
|
215
|
+
return { repaired: null, repairs: [] };
|
|
216
|
+
}
|
|
217
|
+
const repairs = [];
|
|
218
|
+
const stripped = stripSurroundingProse(input, inStringInitial);
|
|
219
|
+
let current = stripped.stripped;
|
|
220
|
+
if (stripped.changed) {
|
|
221
|
+
if (stripped.leading)
|
|
222
|
+
repairs.push("stripped leading prose before first '('");
|
|
223
|
+
if (stripped.trailing)
|
|
224
|
+
repairs.push("stripped trailing prose after outermost ')'");
|
|
225
|
+
}
|
|
226
|
+
// Re-classify on the (possibly trimmed) text.
|
|
227
|
+
const inString = classifyStringPositions(current);
|
|
228
|
+
if (inString === null) {
|
|
229
|
+
return { repaired: null, repairs: [] };
|
|
230
|
+
}
|
|
231
|
+
const balance = bracketBalance(current, inString);
|
|
232
|
+
if (balance === null) {
|
|
233
|
+
// Stray mid-expression closer — don't guess.
|
|
234
|
+
return { repaired: null, repairs: [] };
|
|
235
|
+
}
|
|
236
|
+
// Strip trailing surplus closers.
|
|
237
|
+
if (balance.trailingExtraParens > 0 || balance.trailingExtraBrackets > 0) {
|
|
238
|
+
// Walk back from the end, removing whitespace and extra `)`/`]`
|
|
239
|
+
// until we've removed exactly the surplus count.
|
|
240
|
+
let parensToRemove = balance.trailingExtraParens;
|
|
241
|
+
let bracketsToRemove = balance.trailingExtraBrackets;
|
|
242
|
+
let end = current.length;
|
|
243
|
+
while (end > 0 && (parensToRemove > 0 || bracketsToRemove > 0)) {
|
|
244
|
+
const c = current[end - 1];
|
|
245
|
+
if (/\s/.test(c)) {
|
|
246
|
+
end--;
|
|
247
|
+
continue;
|
|
248
|
+
}
|
|
249
|
+
if (c === ")" && parensToRemove > 0) {
|
|
250
|
+
parensToRemove--;
|
|
251
|
+
end--;
|
|
252
|
+
continue;
|
|
253
|
+
}
|
|
254
|
+
if (c === "]" && bracketsToRemove > 0) {
|
|
255
|
+
bracketsToRemove--;
|
|
256
|
+
end--;
|
|
257
|
+
continue;
|
|
258
|
+
}
|
|
259
|
+
break;
|
|
260
|
+
}
|
|
261
|
+
current = current.slice(0, end);
|
|
262
|
+
const parts = [];
|
|
263
|
+
if (balance.trailingExtraParens > 0) {
|
|
264
|
+
parts.push(`${balance.trailingExtraParens} extra ')'`);
|
|
265
|
+
}
|
|
266
|
+
if (balance.trailingExtraBrackets > 0) {
|
|
267
|
+
parts.push(`${balance.trailingExtraBrackets} extra ']'`);
|
|
268
|
+
}
|
|
269
|
+
repairs.push(`stripped trailing ${parts.join(" + ")}`);
|
|
270
|
+
}
|
|
271
|
+
// Append missing closers to balance the expression.
|
|
272
|
+
if (balance.parens > 0 || balance.brackets > 0) {
|
|
273
|
+
// Brackets nest inside parens here; we don't know the original
|
|
274
|
+
// interleaving, so close in a stable order: brackets first, then
|
|
275
|
+
// parens. This matches the common case `[constraint] ⊗ (expr` where
|
|
276
|
+
// a missing `)` is at the very end.
|
|
277
|
+
if (balance.brackets > 0) {
|
|
278
|
+
current += "]".repeat(balance.brackets);
|
|
279
|
+
repairs.push(`appended ${balance.brackets} missing ']' to balance brackets`);
|
|
280
|
+
}
|
|
281
|
+
if (balance.parens > 0) {
|
|
282
|
+
current += ")".repeat(balance.parens);
|
|
283
|
+
repairs.push(`appended ${balance.parens} missing ')' to balance parens`);
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
if (current === input) {
|
|
287
|
+
return { repaired: null, repairs: [] };
|
|
288
|
+
}
|
|
289
|
+
if (repairs.length === 0) {
|
|
290
|
+
// Defensive: text changed via whitespace normalization but we
|
|
291
|
+
// didn't record a repair — don't claim a fix.
|
|
292
|
+
return { repaired: null, repairs: [] };
|
|
293
|
+
}
|
|
294
|
+
return { repaired: current, repairs };
|
|
295
|
+
}
|
|
296
|
+
//# sourceMappingURL=lc-linter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lc-linter.js","sourceRoot":"","sources":["../../src/logic/lc-linter.ts"],"names":[],"mappings":"AAiCA;;;;;;;;;;;GAWG;AACH,SAAS,uBAAuB,CAAC,KAAa;IAC5C,MAAM,QAAQ,GAAc,IAAI,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAChE,IAAI,MAAM,GAAG,KAAK,CAAC;IACnB,IAAI,OAAO,GAAG,KAAK,CAAC;IACpB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,KAAK,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QACtC,MAAM,EAAE,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC;QACpB,IAAI,MAAM;YAAE,QAAQ,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC;QAC/B,IAAI,OAAO,EAAE,CAAC;YACZ,OAAO,GAAG,KAAK,CAAC;YAChB,SAAS;QACX,CAAC;QACD,IAAI,EAAE,KAAK,IAAI,EAAE,CAAC;YAChB,OAAO,GAAG,IAAI,CAAC;YACf,SAAS;QACX,CAAC;QACD,IAAI,EAAE,KAAK,GAAG,EAAE,CAAC;YACf,qEAAqE;YACrE,8DAA8D;YAC9D,MAAM,GAAG,CAAC,MAAM,CAAC;QACnB,CAAC;IACH,CAAC;IACD,IAAI,MAAM;QAAE,OAAO,IAAI,CAAC,CAAC,eAAe;IACxC,OAAO,QAAQ,CAAC;AAClB,CAAC;AAED;;;;;;;;;;GAUG;AACH,SAAS,qBAAqB,CAC5B,KAAa,EACb,QAAmB;IAEnB,oEAAoE;IACpE,kEAAkE;IAClE,gEAAgE;IAChE,MAAM,oBAAoB,GAAG,WAAW,CAAC;IACzC,mCAAmC;IACnC,IAAI,SAAS,GAAG,CAAC,CAAC,CAAC;IACnB,KAAK,IAAI,CAAC,GAAG,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*
|
|
4
4
|
* Provides:
|
|
5
|
-
* -
|
|
5
|
+
* - FTS4 full-text search for document lines
|
|
6
6
|
* - Handle storage for result sets
|
|
7
7
|
* - Checkpoint persistence for session resume
|
|
8
8
|
* - Symbol storage for tree-sitter extracted symbols
|
|
9
|
+
*
|
|
10
|
+
* Uses sql.js (WASM-based SQLite, zero native dependencies) instead of
|
|
11
|
+
* better-sqlite3 to avoid the deprecated prebuild-install dependency.
|
|
9
12
|
*/
|
|
10
13
|
import type { Symbol, SymbolKind } from "../treesitter/types.js";
|
|
11
14
|
export interface DocumentLine {
|
|
@@ -41,28 +44,39 @@ export declare class SessionDB {
|
|
|
41
44
|
private lastLoadStatus;
|
|
42
45
|
/** Tracks usage count per slug base for collision disambiguation */
|
|
43
46
|
private slugCounts;
|
|
47
|
+
private bm25Lines;
|
|
48
|
+
private bm25Index;
|
|
44
49
|
constructor();
|
|
45
50
|
private initSchema;
|
|
46
51
|
/**
|
|
47
52
|
* Check if database is open
|
|
48
53
|
*/
|
|
49
54
|
isOpen(): boolean;
|
|
55
|
+
/** Number of cached prepared statements (for tests / observability). */
|
|
56
|
+
preparedStatementCount(): number;
|
|
50
57
|
/**
|
|
51
58
|
* Get list of tables in database
|
|
52
59
|
*/
|
|
53
60
|
getTables(): string[];
|
|
54
61
|
/**
|
|
55
|
-
* Check if
|
|
62
|
+
* Check if the FTS virtual table exists.
|
|
63
|
+
*
|
|
64
|
+
* Note: under sql.js the table is FTS4, not FTS5 (sql.js doesn't ship FTS5).
|
|
65
|
+
* The name is kept for backwards-compatibility with existing callers.
|
|
56
66
|
*/
|
|
67
|
+
hasFTSTable(): boolean;
|
|
68
|
+
/** @deprecated Use hasFTSTable() — kept for backwards compatibility. */
|
|
57
69
|
hasFTS5(): boolean;
|
|
58
70
|
/**
|
|
59
|
-
* Load document content into the database
|
|
71
|
+
* Load document content into the database.
|
|
72
|
+
*
|
|
73
|
+
* FTS4 external-content tables need a manual index rebuild after the
|
|
74
|
+
* content table is modified, unlike FTS5 triggers. We run the rebuild
|
|
75
|
+
* inside the same atomic transaction so readers never see a stale index.
|
|
60
76
|
*/
|
|
61
77
|
loadDocument(content: string): number;
|
|
62
78
|
/**
|
|
63
79
|
* Truncation metadata from the most recent loadDocument() call.
|
|
64
|
-
* Callers can use this to warn the user when a downstream query
|
|
65
|
-
* may be operating on incomplete data.
|
|
66
80
|
*/
|
|
67
81
|
getLastLoadStatus(): LoadStatus;
|
|
68
82
|
/**
|
|
@@ -74,50 +88,36 @@ export declare class SessionDB {
|
|
|
74
88
|
*/
|
|
75
89
|
getLineCount(): number;
|
|
76
90
|
/**
|
|
77
|
-
* Search document using
|
|
91
|
+
* Search document using FTS (sanitizes user input)
|
|
78
92
|
*/
|
|
79
93
|
search(query: string): DocumentLine[];
|
|
80
94
|
/**
|
|
81
|
-
* Search with a raw
|
|
95
|
+
* Search with a raw FTS query (for trusted internal callers only)
|
|
82
96
|
* WARNING: Do not pass user input directly to this method
|
|
83
97
|
*/
|
|
84
98
|
searchRaw(query: string): DocumentLine[];
|
|
85
99
|
/**
|
|
86
|
-
* Search with
|
|
100
|
+
* Search with BM25 relevance ranking.
|
|
101
|
+
*
|
|
102
|
+
* sql.js bundles FTS3/4 but not FTS5, and FTS4's matchinfo() doesn't give
|
|
103
|
+
* us a real ranker out of the box. We score in JS using the BM25 index
|
|
104
|
+
* that's lazily built from the line cache populated by loadDocument().
|
|
87
105
|
*/
|
|
88
106
|
searchByRelevance(query: string): DocumentLine[];
|
|
89
107
|
/**
|
|
90
108
|
* Generate a unique handle name for a slug.
|
|
91
|
-
*
|
|
92
|
-
* Increments the per-slug counter and checks the candidate name against
|
|
93
|
-
* existing handles in SQLite. If a cross-slug collision is detected
|
|
94
|
-
* (e.g. slug "grep_error" count=2 produces "$grep_error_2" which was
|
|
95
|
-
* already taken by slug "grep_error_2" count=1), keeps incrementing
|
|
96
|
-
* until a free name is found.
|
|
97
109
|
*/
|
|
98
110
|
private nextUniqueHandle;
|
|
99
111
|
/**
|
|
100
112
|
* Create a handle for storing data array.
|
|
101
|
-
*
|
|
102
|
-
* @param data The array payload to store.
|
|
103
|
-
* @param command Optional Nucleus command string used to derive a
|
|
104
|
-
* descriptive handle name (e.g. `(grep "ERROR")` → `$grep_error`).
|
|
105
|
-
* Falls back to `$res`, `$res_2`, … when omitted.
|
|
106
113
|
*/
|
|
107
114
|
createHandle(data: unknown[], command?: string): string;
|
|
108
115
|
/**
|
|
109
116
|
* Create a memo handle for storing arbitrary context.
|
|
110
|
-
* Uses $memo prefix and "memo" type to distinguish from query result handles.
|
|
111
|
-
*
|
|
112
|
-
* @param data The array payload to store.
|
|
113
|
-
* @param label Optional label used to derive a descriptive handle name
|
|
114
|
-
* (e.g., "auth architecture" → `$memo_auth_architecture`).
|
|
115
|
-
* Falls back to `$memo`, `$memo_2`, … when omitted.
|
|
116
117
|
*/
|
|
117
118
|
createMemoHandle(data: unknown[], label?: string): string;
|
|
118
119
|
/**
|
|
119
120
|
* Delete all non-memo handles (query result handles)
|
|
120
|
-
* Preserves memo handles across document reloads
|
|
121
121
|
*/
|
|
122
122
|
clearQueryHandles(): void;
|
|
123
123
|
/**
|
|
@@ -125,7 +125,7 @@ export declare class SessionDB {
|
|
|
125
125
|
*/
|
|
126
126
|
getHandleMetadata(handle: string): HandleMetadata | null;
|
|
127
127
|
/**
|
|
128
|
-
* Get a slice of data stored in a handle
|
|
128
|
+
* Get a slice of data stored in a handle
|
|
129
129
|
*/
|
|
130
130
|
getHandleDataSlice(handle: string, limit: number, offset?: number): unknown[];
|
|
131
131
|
/**
|
|
@@ -142,15 +142,6 @@ export declare class SessionDB {
|
|
|
142
142
|
handleCount(): number;
|
|
143
143
|
/**
|
|
144
144
|
* Get the total byte size of a handle's stored JSON rows.
|
|
145
|
-
*
|
|
146
|
-
* Sums `length(data)` over the handle_data rows in a single SQL query,
|
|
147
|
-
* so callers can estimate token costs without re-serializing the whole
|
|
148
|
-
* array on the JS side. The data is already JSON-stringified in SQLite
|
|
149
|
-
* (see `createHandle`), so this is the authoritative serialized size
|
|
150
|
-
* minus the JSON array brackets and commas that would wrap it — close
|
|
151
|
-
* enough for a token-cost estimate.
|
|
152
|
-
*
|
|
153
|
-
* Returns 0 for unknown handles.
|
|
154
145
|
*/
|
|
155
146
|
getHandleDataByteSize(handle: string): number;
|
|
156
147
|
/**
|
|
@@ -166,7 +157,7 @@ export declare class SessionDB {
|
|
|
166
157
|
*/
|
|
167
158
|
saveCheckpoint(turn: number, bindings: Map<string, string>): void;
|
|
168
159
|
/**
|
|
169
|
-
* Get a checkpoint
|
|
160
|
+
* Get a checkpoint timestamp
|
|
170
161
|
*/
|
|
171
162
|
getCheckpointTimestamp(turn: number): number | null;
|
|
172
163
|
getCheckpoint(turn: number): Map<string, string> | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-db.d.ts","sourceRoot":"","sources":["../../src/persistence/session-db.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"session-db.d.ts","sourceRoot":"","sources":["../../src/persistence/session-db.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAGH,OAAO,KAAK,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAuKjE,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,cAAc;IAC7B,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,aAAa,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAuCtD;AAED,MAAM,WAAW,UAAU;IACzB,SAAS,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,WAAW,EAA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