@facthouse/mcp 0.27.1 → 0.28.1
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/README.md +38 -27
- package/dist/cli/index.d.ts +5 -26
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +6 -781
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/init-backfill.d.ts +23 -4
- package/dist/cli/init-backfill.d.ts.map +1 -1
- package/dist/cli/init-backfill.js +33 -12
- package/dist/cli/init-backfill.js.map +1 -1
- package/dist/cli/init-knobs.d.ts +22 -11
- package/dist/cli/init-knobs.d.ts.map +1 -1
- package/dist/cli/init-knobs.js +69 -33
- package/dist/cli/init-knobs.js.map +1 -1
- package/dist/cli/init-wizard.d.ts +2 -0
- package/dist/cli/init-wizard.d.ts.map +1 -1
- package/dist/cli/init-wizard.js +7 -5
- package/dist/cli/init-wizard.js.map +1 -1
- package/dist/cli/init.d.ts +6 -1
- package/dist/cli/init.d.ts.map +1 -1
- package/dist/cli/init.js +31 -8
- package/dist/cli/init.js.map +1 -1
- package/dist/cli/query.js +4 -4
- package/dist/cli/run.d.ts +31 -0
- package/dist/cli/run.d.ts.map +1 -0
- package/dist/cli/run.js +787 -0
- package/dist/cli/run.js.map +1 -0
- package/dist/cli/settings.d.ts.map +1 -1
- package/dist/cli/settings.js +3 -3
- package/dist/cli/settings.js.map +1 -1
- package/dist/cli/web.d.ts.map +1 -1
- package/dist/cli/web.js +3 -8
- package/dist/cli/web.js.map +1 -1
- package/dist/identity.d.ts +7 -0
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +13 -0
- package/dist/identity.js.map +1 -1
- package/dist/index.d.ts +3 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -271
- package/dist/index.js.map +1 -1
- package/dist/intelligence/consolidate.d.ts +7 -1
- package/dist/intelligence/consolidate.d.ts.map +1 -1
- package/dist/intelligence/consolidate.js +19 -5
- package/dist/intelligence/consolidate.js.map +1 -1
- package/dist/server.d.ts +8 -0
- package/dist/server.d.ts.map +1 -0
- package/dist/server.js +274 -0
- package/dist/server.js.map +1 -0
- package/dist/suppress-sqlite-warning.d.ts +2 -0
- package/dist/suppress-sqlite-warning.d.ts.map +1 -0
- package/dist/suppress-sqlite-warning.js +29 -0
- package/dist/suppress-sqlite-warning.js.map +1 -0
- package/dist/tools/fact-manager.d.ts.map +1 -1
- package/dist/tools/fact-manager.js +6 -8
- package/dist/tools/fact-manager.js.map +1 -1
- package/dist/tools/resources.js +3 -3
- package/dist/tools/resources.js.map +1 -1
- package/dist/types/config.d.ts +5 -3
- package/dist/types/config.d.ts.map +1 -1
- package/dist/types/config.js +7 -1
- package/dist/types/config.js.map +1 -1
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -1,785 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* they print usage and exit 1. The vocabulary (copy, extract, integrate;
|
|
8
|
-
* consolidate; moments) is defined once in src/intelligence/steps.ts.
|
|
3
|
+
* Thin loader so `suppress-sqlite-warning` evaluates before `node:sqlite` is
|
|
4
|
+
* even translated. A static import of sqlite in this file (via the rest of
|
|
5
|
+
* the CLI graph) emits ExperimentalWarning during graph load, before any
|
|
6
|
+
* wrap of process.emitWarning can run.
|
|
9
7
|
*/
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import { existsSync } from "node:fs";
|
|
13
|
-
import path from "node:path";
|
|
14
|
-
import { recordEvent, extractContentFromHookPayload } from "./record.js";
|
|
15
|
-
import { initDataDir, mcpConfigSnippet, mcpServerName, mcpSnippetDataDir, providerStatusLines, embeddingStatusLines, appendCaptureRecipe, } from "./init.js";
|
|
16
|
-
import { collectInitAnswers, isInteractiveInit, bindInitIo, silentInitIo, defaultInitWizardDeps, } from "./init-wizard.js";
|
|
17
|
-
import { INIT_PROMPTS } from "./init-knobs.js";
|
|
18
|
-
import { offerInitBackfill, shouldOfferInitBackfill, } from "./init-backfill.js";
|
|
19
|
-
import { runSettings } from "./settings.js";
|
|
20
|
-
import { collectInitWebAnswers } from "./web.js";
|
|
21
|
-
import { CLI_NAME, PRODUCT_NAME, envIsSet, envValue, npmPackageSpec, } from "../identity.js";
|
|
22
|
-
import { dataDirFromEnvOrDefault, defaultDataDir, resolveUserPath } from "../paths.js";
|
|
23
|
-
import { runSearch, formatSearch, formatStats, formatPrune, formatConsolidate, getStats, } from "./query.js";
|
|
24
|
-
import { packageVersion } from "./package-version.js";
|
|
25
|
-
import { runInspect } from "./inspect.js";
|
|
26
|
-
import { prunableEvents, pruneEvents, vacuum } from "../db/prune.js";
|
|
27
|
-
import { applySqliteDiskBudget, getBoundDiskBudget } from "../db/disk-budget.js";
|
|
28
|
-
import { closeDatabase } from "../db/connection.js";
|
|
29
|
-
import { applySchema } from "../db/schema.js";
|
|
30
|
-
import { openStore, sqliteMemoryPath } from "../db/store.js";
|
|
31
|
-
import { consolidate } from "../intelligence/consolidate.js";
|
|
32
|
-
import { ALL_STEPS, NOTIFIABLE_MOMENTS, isNotifiableMoment, stepsFromFlags, } from "../intelligence/steps.js";
|
|
33
|
-
import { createIntelligenceProvider, resolveProviderType } from "../intelligence/provider.js";
|
|
34
|
-
import { createHeuristicProvider } from "../intelligence/heuristic.js";
|
|
35
|
-
import { probeHttpModels } from "../intelligence/http.js";
|
|
36
|
-
import { loadStoreVocabulary } from "../db/domains.js";
|
|
37
|
-
import { createEmbeddingProvider } from "../embedding/provider.js";
|
|
38
|
-
import { DEFAULT_CONFIG } from "../types/config.js";
|
|
39
|
-
import { CONFIG_FILENAME, loadConfig, loadShippedStoreConfig, configuredStorageProvider, ensureBitemporalSince, systemTimeWarning, } from "../config.js";
|
|
40
|
-
import { parseSystemTime } from "../db/facts.js";
|
|
41
|
-
import { notifyServer, isServerListening } from "../ipc/scheduler-ipc.js";
|
|
42
|
-
import { copySources } from "../sources/copy.js";
|
|
43
|
-
import { unexaminedEventCount } from "../db/extract-watermarks.js";
|
|
44
|
-
const SESSION_ROLES = ["user", "assistant", "system", "tool"];
|
|
45
|
-
const SESSION_EVENT_TYPES = ["message", "tool_call", "tool_result", "artifact"];
|
|
46
|
-
const SESSION_CONTENT_TYPES = ["text", "json", "image", "audio", "binary"];
|
|
47
|
-
function errorMessage(err) {
|
|
48
|
-
return err instanceof Error ? err.message : String(err);
|
|
49
|
-
}
|
|
50
|
-
function isSessionRole(value) {
|
|
51
|
-
return SESSION_ROLES.includes(value);
|
|
52
|
-
}
|
|
53
|
-
function isSessionEventType(value) {
|
|
54
|
-
return SESSION_EVENT_TYPES.includes(value);
|
|
55
|
-
}
|
|
56
|
-
function isSessionContentType(value) {
|
|
57
|
-
return SESSION_CONTENT_TYPES.includes(value);
|
|
58
|
-
}
|
|
59
|
-
function readStdin() {
|
|
60
|
-
return new Promise((resolve, reject) => {
|
|
61
|
-
const chunks = [];
|
|
62
|
-
process.stdin.on("data", (chunk) => chunks.push(typeof chunk === "string" ? Buffer.from(chunk) : chunk));
|
|
63
|
-
process.stdin.on("end", () => resolve(Buffer.concat(chunks).toString("utf-8")));
|
|
64
|
-
process.stdin.on("error", reject);
|
|
65
|
-
// Don't hang if stdin is a TTY with no data.
|
|
66
|
-
if (process.stdin.isTTY) {
|
|
67
|
-
resolve("");
|
|
68
|
-
}
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
async function main() {
|
|
72
|
-
const subcommand = process.argv[2];
|
|
73
|
-
// Recursion guard: any subprocess-based intelligence provider that
|
|
74
|
-
// re-invokes an MCP client should set FACTHOUSE_SUBPROCESS=1 (or the
|
|
75
|
-
// FACTHOUSE_SUBPROCESS compat alias) in the child's env. If a surviving
|
|
76
|
-
// hook then re-enters this CLI, we must not log events, signal the
|
|
77
|
-
// scheduler, or consolidate — each would feed back into an extraction loop.
|
|
78
|
-
// Exit silently with success.
|
|
79
|
-
//
|
|
80
|
-
// `init` is exempt: it only creates a directory, database, and config, so it
|
|
81
|
-
// cannot recurse. Skipping it here would make an explicit setup command exit
|
|
82
|
-
// 0 having silently done nothing — a confusing failure with no diagnostic.
|
|
83
|
-
if (envIsSet("SUBPROCESS", "1") && subcommand !== "init") {
|
|
84
|
-
process.exit(0);
|
|
85
|
-
}
|
|
86
|
-
if (subcommand === undefined ||
|
|
87
|
-
subcommand === "--help" ||
|
|
88
|
-
subcommand === "-h" ||
|
|
89
|
-
subcommand === "help") {
|
|
90
|
-
console.log(usageText());
|
|
91
|
-
process.exit(0);
|
|
92
|
-
}
|
|
93
|
-
if (subcommand === "init") {
|
|
94
|
-
await runInit();
|
|
95
|
-
}
|
|
96
|
-
else if (subcommand === "settings") {
|
|
97
|
-
await runSettingsCmd();
|
|
98
|
-
}
|
|
99
|
-
else if (subcommand === "record") {
|
|
100
|
-
await runRecord();
|
|
101
|
-
}
|
|
102
|
-
else if (subcommand === "notify") {
|
|
103
|
-
await runNotify();
|
|
104
|
-
}
|
|
105
|
-
else if (subcommand === "consolidate") {
|
|
106
|
-
await runConsolidate();
|
|
107
|
-
}
|
|
108
|
-
else if (subcommand === "search") {
|
|
109
|
-
await runSearchCmd();
|
|
110
|
-
}
|
|
111
|
-
else if (subcommand === "stats") {
|
|
112
|
-
await runStatsCmd();
|
|
113
|
-
}
|
|
114
|
-
else if (subcommand === "inspect") {
|
|
115
|
-
await runInspectCmd();
|
|
116
|
-
}
|
|
117
|
-
else if (subcommand === "prune") {
|
|
118
|
-
await runPruneCmd();
|
|
119
|
-
}
|
|
120
|
-
else {
|
|
121
|
-
console.error(usageText());
|
|
122
|
-
process.exit(1);
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
/** One usage block, grouped by job. Hidden aliases are not listed. */
|
|
126
|
-
function usageText() {
|
|
127
|
-
return [
|
|
128
|
-
`Usage: ${CLI_NAME} <command> [--data <dir>]`,
|
|
129
|
-
``,
|
|
130
|
-
`Set up`,
|
|
131
|
-
` init [dir] Create the store (--yes: no prompts; --web: local page)`,
|
|
132
|
-
` settings Change extra knobs on an existing store (--json, --web)`,
|
|
133
|
-
``,
|
|
134
|
-
`Feed`,
|
|
135
|
-
` record Record one session event (used by hooks; reads stdin)`,
|
|
136
|
-
` notify <moment> Tell the running MCP server a moment happened`,
|
|
137
|
-
` (${NOTIFIABLE_MOMENTS.join(", ")})`,
|
|
138
|
-
``,
|
|
139
|
-
`Consolidate`,
|
|
140
|
-
` consolidate Copy lines, extract facts, integrate them (spends model calls)`,
|
|
141
|
-
` -c --copy -e --extract -i --integrate run only these steps`,
|
|
142
|
-
` -a --all extract past the cap -l --limit N oldest N`,
|
|
143
|
-
``,
|
|
144
|
-
`Read`,
|
|
145
|
-
` search <q> Search integrated knowledge (--domain, --limit, --json)`,
|
|
146
|
-
` stats Counts, extract backlog, spend, whether a server is up`,
|
|
147
|
-
` inspect Sample D / I / K and write a local HTML graph`,
|
|
148
|
-
``,
|
|
149
|
-
`Housekeeping`,
|
|
150
|
-
` prune Reclaim raw events nothing can reach (dry run by default)`,
|
|
151
|
-
``,
|
|
152
|
-
`--data defaults to FACTHOUSE_DATA or ~/.facthouse.`,
|
|
153
|
-
].join("\n");
|
|
154
|
-
}
|
|
155
|
-
async function runInit() {
|
|
156
|
-
const { values, positionals } = parseArgs({
|
|
157
|
-
args: process.argv.slice(3),
|
|
158
|
-
options: {
|
|
159
|
-
data: { type: "string" },
|
|
160
|
-
force: { type: "boolean", default: false },
|
|
161
|
-
yes: { type: "boolean", default: false, short: "y" },
|
|
162
|
-
web: { type: "boolean", default: false },
|
|
163
|
-
},
|
|
164
|
-
allowPositionals: true,
|
|
165
|
-
strict: true,
|
|
166
|
-
});
|
|
167
|
-
// Accept `facthouse init ~/.facthouse` (positional) as well as --data, so
|
|
168
|
-
// the documented form and the flag used by every other subcommand both work.
|
|
169
|
-
const target = positionals[0] ??
|
|
170
|
-
values.data ??
|
|
171
|
-
dataDirFromEnvOrDefault();
|
|
172
|
-
// Normalise to an absolute, platform-native path so every path we print (and
|
|
173
|
-
// embed in the MCP snippet) is consistent regardless of how it was typed.
|
|
174
|
-
const dataDir = resolveUserPath(target);
|
|
175
|
-
const dataDirLocked = Boolean(positionals[0] ?? values.data) || Boolean(values.force);
|
|
176
|
-
const seed = {
|
|
177
|
-
dataDir,
|
|
178
|
-
dataDirLocked,
|
|
179
|
-
force: values.force,
|
|
180
|
-
};
|
|
181
|
-
const seedHasConfig = existsSync(path.join(seed.dataDir, CONFIG_FILENAME));
|
|
182
|
-
const ask = isInteractiveInit({
|
|
183
|
-
stdinIsTTY: Boolean(process.stdin.isTTY),
|
|
184
|
-
yes: Boolean(values.yes),
|
|
185
|
-
seed,
|
|
186
|
-
configExists: seedHasConfig,
|
|
187
|
-
});
|
|
188
|
-
const web = Boolean(values.web);
|
|
189
|
-
const yes = Boolean(values.yes);
|
|
190
|
-
let reportDir = seed.dataDir;
|
|
191
|
-
let result;
|
|
192
|
-
let wizard;
|
|
193
|
-
let rl;
|
|
194
|
-
const onSigint = () => {
|
|
195
|
-
rl?.close();
|
|
196
|
-
process.exit(130);
|
|
197
|
-
};
|
|
198
|
-
try {
|
|
199
|
-
// Always — env postgres refuses before prompts, even with no config.json.
|
|
200
|
-
loadShippedStoreConfig(seed.dataDir);
|
|
201
|
-
if (web && yes) {
|
|
202
|
-
console.error(INIT_PROMPTS.webYesRefuse);
|
|
203
|
-
process.exit(1);
|
|
204
|
-
}
|
|
205
|
-
if (web) {
|
|
206
|
-
wizard = await collectInitWebAnswers(seed, {
|
|
207
|
-
stdout: process.stderr,
|
|
208
|
-
processCwd: process.cwd(),
|
|
209
|
-
});
|
|
210
|
-
}
|
|
211
|
-
else if (!ask) {
|
|
212
|
-
wizard = await collectInitAnswers(silentInitIo(), seed);
|
|
213
|
-
}
|
|
214
|
-
else {
|
|
215
|
-
rl = createInterface({
|
|
216
|
-
input: process.stdin,
|
|
217
|
-
output: process.stdout,
|
|
218
|
-
terminal: true,
|
|
219
|
-
});
|
|
220
|
-
rl.on("SIGINT", onSigint);
|
|
221
|
-
wizard = await collectInitAnswers(bindInitIo(rl), seed, {
|
|
222
|
-
...defaultInitWizardDeps,
|
|
223
|
-
probeHttp: (baseUrl) => probeHttpModels(baseUrl),
|
|
224
|
-
});
|
|
225
|
-
}
|
|
226
|
-
reportDir = wizard.dataDir;
|
|
227
|
-
result = await initDataDir({
|
|
228
|
-
dataDir: wizard.dataDir,
|
|
229
|
-
force: values.force,
|
|
230
|
-
overlay: wizard.overlay,
|
|
231
|
-
});
|
|
232
|
-
}
|
|
233
|
-
catch (err) {
|
|
234
|
-
rl?.close();
|
|
235
|
-
console.error(`Failed to initialise ${reportDir}: ${errorMessage(err)}`);
|
|
236
|
-
process.exit(1);
|
|
237
|
-
}
|
|
238
|
-
const version = packageVersion();
|
|
239
|
-
const spec = npmPackageSpec(version);
|
|
240
|
-
const snippet = mcpConfigSnippet(spec, mcpSnippetDataDir(result.dataDir), 2, mcpServerName(result.dataDir));
|
|
241
|
-
const written = loadConfig(result.dataDir);
|
|
242
|
-
const embedLines = await embeddingStatusLines(written.embedding);
|
|
243
|
-
const captureLines = appendCaptureRecipe(written.sources, {
|
|
244
|
-
captureAskedAndEmpty: wizard.captureAskedAndEmpty,
|
|
245
|
-
captureSkippedCwd: wizard.captureSkippedCwd,
|
|
246
|
-
});
|
|
247
|
-
const lines = [
|
|
248
|
-
``,
|
|
249
|
-
`${PRODUCT_NAME} initialised.`,
|
|
250
|
-
``,
|
|
251
|
-
` Data directory ${result.dataDir}${result.createdDataDir ? " (created)" : ""}`,
|
|
252
|
-
` Database ${result.dialect === "postgres"
|
|
253
|
-
? `Postgres (schema v${result.schemaVersion})`
|
|
254
|
-
: `${result.dbPath} (schema v${result.schemaVersion})`}`,
|
|
255
|
-
` Config ${result.configPath}${result.wroteConfig
|
|
256
|
-
? " (written)"
|
|
257
|
-
: ` (${INIT_PROMPTS.existingConfig})`}`,
|
|
258
|
-
``,
|
|
259
|
-
`Add to your AI tool's MCP configuration:`,
|
|
260
|
-
``,
|
|
261
|
-
snippet,
|
|
262
|
-
``,
|
|
263
|
-
INIT_PROMPTS.mcpVsCli,
|
|
264
|
-
``,
|
|
265
|
-
`One data directory is one memory.`,
|
|
266
|
-
``,
|
|
267
|
-
...providerStatusLines(resolveProviderType(written.intelligence.provider)),
|
|
268
|
-
``,
|
|
269
|
-
...embedLines,
|
|
270
|
-
``,
|
|
271
|
-
];
|
|
272
|
-
console.log(lines.join("\n"));
|
|
273
|
-
// The copy offer runs before the outro, so the next-command line is not
|
|
274
|
-
// printed above the prompt that performs it.
|
|
275
|
-
if (rl) {
|
|
276
|
-
try {
|
|
277
|
-
if (shouldOfferInitBackfill({
|
|
278
|
-
ttyWalk: true,
|
|
279
|
-
wroteConfig: result.wroteConfig,
|
|
280
|
-
sources: written.sources,
|
|
281
|
-
})) {
|
|
282
|
-
const provider = resolveProviderType(written.intelligence.provider);
|
|
283
|
-
await offerInitBackfill(bindInitIo(rl), result.dataDir, {
|
|
284
|
-
providerIsHeuristic: provider === "heuristic",
|
|
285
|
-
copy: async (dir) => {
|
|
286
|
-
const cfg = loadConfig(dir);
|
|
287
|
-
return withDb(dir, (db) => copySources(db, cfg.sources));
|
|
288
|
-
},
|
|
289
|
-
unextracted: (dir) => withDb(dir, (db) => unexaminedEventCount(db)),
|
|
290
|
-
// The offer already copied; extract (capped) and integrate. The
|
|
291
|
-
// offer prints the counts itself, on the same channel as its prompts.
|
|
292
|
-
consolidate: async (dir) => {
|
|
293
|
-
const r = await consolidateStore(dir, { copy: false, extract: true, integrate: true }, { print: false });
|
|
294
|
-
return r
|
|
295
|
-
? { factsIntegrated: r.factsIntegrated, eventsRemaining: r.eventsRemaining }
|
|
296
|
-
: undefined;
|
|
297
|
-
},
|
|
298
|
-
});
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
finally {
|
|
302
|
-
rl.removeListener("SIGINT", onSigint);
|
|
303
|
-
rl.close();
|
|
304
|
-
}
|
|
305
|
-
}
|
|
306
|
-
const outro = [...captureLines, ``];
|
|
307
|
-
if (result.wroteConfig) {
|
|
308
|
-
const later = result.dataDir === defaultDataDir()
|
|
309
|
-
? `Later: ${CLI_NAME} settings (extra knobs; does not reset this file)`
|
|
310
|
-
: `Later: ${CLI_NAME} settings --data ${result.dataDir} (extra knobs; does not reset this file)`;
|
|
311
|
-
outro.push(later, ``);
|
|
312
|
-
}
|
|
313
|
-
console.log(outro.join("\n"));
|
|
314
|
-
}
|
|
315
|
-
async function runSettingsCmd() {
|
|
316
|
-
const { values, positionals } = parseArgs({
|
|
317
|
-
args: process.argv.slice(3),
|
|
318
|
-
options: {
|
|
319
|
-
data: { type: "string" },
|
|
320
|
-
json: { type: "boolean", default: false },
|
|
321
|
-
web: { type: "boolean", default: false },
|
|
322
|
-
},
|
|
323
|
-
allowPositionals: true,
|
|
324
|
-
strict: true,
|
|
325
|
-
});
|
|
326
|
-
const target = positionals[0] ??
|
|
327
|
-
values.data ??
|
|
328
|
-
dataDirFromEnvOrDefault();
|
|
329
|
-
const dataDir = resolveUserPath(target);
|
|
330
|
-
const json = Boolean(values.json);
|
|
331
|
-
const web = Boolean(values.web);
|
|
332
|
-
const ask = Boolean(process.stdin.isTTY) && !json && !web;
|
|
333
|
-
try {
|
|
334
|
-
let code;
|
|
335
|
-
if (!ask) {
|
|
336
|
-
code = await runSettings({
|
|
337
|
-
dataDir,
|
|
338
|
-
json,
|
|
339
|
-
web,
|
|
340
|
-
stdinIsTTY: Boolean(process.stdin.isTTY),
|
|
341
|
-
probeHttp: (baseUrl) => probeHttpModels(baseUrl),
|
|
342
|
-
});
|
|
343
|
-
}
|
|
344
|
-
else {
|
|
345
|
-
const rl = createInterface({
|
|
346
|
-
input: process.stdin,
|
|
347
|
-
output: process.stdout,
|
|
348
|
-
terminal: true,
|
|
349
|
-
});
|
|
350
|
-
const onSigint = () => {
|
|
351
|
-
rl.close();
|
|
352
|
-
process.exit(130);
|
|
353
|
-
};
|
|
354
|
-
rl.on("SIGINT", onSigint);
|
|
355
|
-
try {
|
|
356
|
-
code = await runSettings({
|
|
357
|
-
dataDir,
|
|
358
|
-
json,
|
|
359
|
-
web: false,
|
|
360
|
-
stdinIsTTY: true,
|
|
361
|
-
io: bindInitIo(rl),
|
|
362
|
-
probeHttp: (baseUrl) => probeHttpModels(baseUrl),
|
|
363
|
-
});
|
|
364
|
-
}
|
|
365
|
-
finally {
|
|
366
|
-
rl.removeListener("SIGINT", onSigint);
|
|
367
|
-
rl.close();
|
|
368
|
-
}
|
|
369
|
-
}
|
|
370
|
-
process.exit(code);
|
|
371
|
-
}
|
|
372
|
-
catch (err) {
|
|
373
|
-
console.error(`Failed to change settings in ${dataDir}: ${errorMessage(err)}`);
|
|
374
|
-
process.exit(1);
|
|
375
|
-
}
|
|
376
|
-
}
|
|
377
|
-
/**
|
|
378
|
-
* Open the database for a command, run `fn`, close.
|
|
379
|
-
* Exits with a clear message when the data dir was never initialised, rather
|
|
380
|
-
* than surfacing a raw SQLite error. Postgres stores have no memory.db;
|
|
381
|
-
* the URL is the database, checked by loadShippedStoreConfig / openStore.
|
|
382
|
-
*/
|
|
383
|
-
async function withDb(dataDir, fn) {
|
|
384
|
-
const config = loadShippedStoreConfig(dataDir);
|
|
385
|
-
if (configuredStorageProvider(config) === "sqlite" &&
|
|
386
|
-
!existsSync(sqliteMemoryPath(dataDir))) {
|
|
387
|
-
console.error(`No database at ${dataDir}. Run 'facthouse init ${dataDir}' first, ` +
|
|
388
|
-
`or point at another directory with --data.`);
|
|
389
|
-
process.exit(1);
|
|
390
|
-
}
|
|
391
|
-
const db = await openStore(dataDir, config);
|
|
392
|
-
try {
|
|
393
|
-
await applySchema(db);
|
|
394
|
-
return await fn(db);
|
|
395
|
-
}
|
|
396
|
-
finally {
|
|
397
|
-
await closeDatabase(db);
|
|
398
|
-
}
|
|
399
|
-
}
|
|
400
|
-
/**
|
|
401
|
-
* Async twin of `withDb`, for commands whose callback is already a Promise.
|
|
402
|
-
*/
|
|
403
|
-
async function withDbAsync(dataDir, fn) {
|
|
404
|
-
return withDb(dataDir, fn);
|
|
405
|
-
}
|
|
406
|
-
async function runSearchCmd() {
|
|
407
|
-
const { values, positionals } = parseArgs({
|
|
408
|
-
args: process.argv.slice(3),
|
|
409
|
-
options: {
|
|
410
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
411
|
-
domain: { type: "string" },
|
|
412
|
-
limit: { type: "string" },
|
|
413
|
-
"as-of-system": { type: "string" },
|
|
414
|
-
json: { type: "boolean", default: false },
|
|
415
|
-
},
|
|
416
|
-
allowPositionals: true,
|
|
417
|
-
strict: true,
|
|
418
|
-
});
|
|
419
|
-
const query = positionals.join(" ").trim();
|
|
420
|
-
if (!query) {
|
|
421
|
-
console.error(`Usage: facthouse search <query> [--domain <d>] [--limit <n>] [--as-of-system <t>] [--json]`);
|
|
422
|
-
process.exit(1);
|
|
423
|
-
}
|
|
424
|
-
const limit = values.limit ? Number(values.limit) : undefined;
|
|
425
|
-
if (limit !== undefined && (!Number.isFinite(limit) || limit < 1)) {
|
|
426
|
-
console.error(`Invalid --limit: ${values.limit}. Expected a positive number.`);
|
|
427
|
-
process.exit(1);
|
|
428
|
-
}
|
|
429
|
-
const dataDir = resolveUserPath(values.data);
|
|
430
|
-
const config = ensureBitemporalSince(dataDir, loadConfig(dataDir));
|
|
431
|
-
const rawAsOf = values["as-of-system"];
|
|
432
|
-
if (rawAsOf && config.temporal.mode !== "bitemporal") {
|
|
433
|
-
console.error(`as-of system time needs temporal.mode "bitemporal" in config.json. ` +
|
|
434
|
-
`The default simple mode does not record when the system retracted a belief.`);
|
|
435
|
-
process.exit(1);
|
|
436
|
-
}
|
|
437
|
-
let asOfSystemTime;
|
|
438
|
-
if (rawAsOf) {
|
|
439
|
-
try {
|
|
440
|
-
asOfSystemTime = parseSystemTime(rawAsOf);
|
|
441
|
-
}
|
|
442
|
-
catch (err) {
|
|
443
|
-
console.error(errorMessage(err));
|
|
444
|
-
process.exit(1);
|
|
445
|
-
}
|
|
446
|
-
}
|
|
447
|
-
// Semantic recall if this store configured it. Reported when configured but
|
|
448
|
-
// unusable, rather than silently searching keyword-only — from the command
|
|
449
|
-
// line there is a person to tell.
|
|
450
|
-
const embedding = createEmbeddingProvider(config.embedding, {
|
|
451
|
-
onUnavailable: (reason) => console.error(`[facthouse] ${reason}`),
|
|
452
|
-
});
|
|
453
|
-
const response = await withDbAsync(dataDir, (db) => runSearch(db, {
|
|
454
|
-
query,
|
|
455
|
-
domain: values.domain,
|
|
456
|
-
limit,
|
|
457
|
-
asOfSystemTime,
|
|
458
|
-
}, embedding, {
|
|
459
|
-
minSimilarityRatio: config.embedding?.min_similarity_ratio,
|
|
460
|
-
minSimilarity: config.embedding?.min_similarity ?? undefined,
|
|
461
|
-
ann: config.embedding?.ann,
|
|
462
|
-
annMaxBytes: config.embedding?.ann_max_bytes,
|
|
463
|
-
}, config.interlocutor));
|
|
464
|
-
if (asOfSystemTime) {
|
|
465
|
-
response.system_time_warning = systemTimeWarning(asOfSystemTime, config.temporal.bitemporal_since);
|
|
466
|
-
}
|
|
467
|
-
console.log(values.json ? JSON.stringify(response, null, 2) : formatSearch(response, query));
|
|
468
|
-
}
|
|
469
|
-
async function runStatsCmd() {
|
|
470
|
-
const { values } = parseArgs({
|
|
471
|
-
args: process.argv.slice(3),
|
|
472
|
-
options: {
|
|
473
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
474
|
-
json: { type: "boolean", default: false },
|
|
475
|
-
},
|
|
476
|
-
strict: true,
|
|
477
|
-
});
|
|
478
|
-
const dataDir = resolveUserPath(values.data);
|
|
479
|
-
const stats = await withDb(dataDir, (db) => getStats(db));
|
|
480
|
-
stats.listener = await isServerListening(dataDir);
|
|
481
|
-
const payload = { ...stats, package_version: packageVersion() };
|
|
482
|
-
console.log(values.json ? JSON.stringify(payload, null, 2) : formatStats(stats));
|
|
483
|
-
}
|
|
484
|
-
async function runInspectCmd() {
|
|
485
|
-
const { values } = parseArgs({
|
|
486
|
-
args: process.argv.slice(3),
|
|
487
|
-
options: {
|
|
488
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
489
|
-
layer: { type: "string" },
|
|
490
|
-
limit: { type: "string" },
|
|
491
|
-
json: { type: "boolean", default: false },
|
|
492
|
-
graph: { type: "boolean", default: false },
|
|
493
|
-
entity: { type: "string" },
|
|
494
|
-
output: { type: "string" },
|
|
495
|
-
all: { type: "boolean", default: false },
|
|
496
|
-
},
|
|
497
|
-
strict: true,
|
|
498
|
-
});
|
|
499
|
-
const dataDir = resolveUserPath(values.data);
|
|
500
|
-
const limitRaw = values.limit ? Number(values.limit) : undefined;
|
|
501
|
-
if (limitRaw !== undefined && (!Number.isFinite(limitRaw) || limitRaw < 1)) {
|
|
502
|
-
console.error("inspect --limit must be a positive number.");
|
|
503
|
-
process.exit(1);
|
|
504
|
-
}
|
|
505
|
-
try {
|
|
506
|
-
await withDb(dataDir, async (db) => {
|
|
507
|
-
const result = await runInspect(db, {
|
|
508
|
-
dataDir,
|
|
509
|
-
layer: values.layer,
|
|
510
|
-
limit: limitRaw,
|
|
511
|
-
json: Boolean(values.json),
|
|
512
|
-
graph: Boolean(values.graph),
|
|
513
|
-
entity: values.entity,
|
|
514
|
-
output: values.output,
|
|
515
|
-
all: Boolean(values.all),
|
|
516
|
-
packageVersion: packageVersion(),
|
|
517
|
-
});
|
|
518
|
-
if (result.stdout)
|
|
519
|
-
console.log(result.stdout);
|
|
520
|
-
if (result.path)
|
|
521
|
-
console.log(result.path);
|
|
522
|
-
});
|
|
523
|
-
}
|
|
524
|
-
catch (err) {
|
|
525
|
-
console.error(errorMessage(err));
|
|
526
|
-
process.exit(1);
|
|
527
|
-
}
|
|
528
|
-
}
|
|
529
|
-
/**
|
|
530
|
-
* Reclaim raw events that nothing can reach.
|
|
531
|
-
*
|
|
532
|
-
* Reports by default and deletes only when asked. Pruning is irreversible and
|
|
533
|
-
* this is a memory product: the difference between "here is what would go" and
|
|
534
|
-
* "it has gone" must be a deliberate keystroke, not a default.
|
|
535
|
-
*/
|
|
536
|
-
async function runPruneCmd() {
|
|
537
|
-
const { values } = parseArgs({
|
|
538
|
-
args: process.argv.slice(3),
|
|
539
|
-
options: {
|
|
540
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
541
|
-
apply: { type: "boolean", default: false },
|
|
542
|
-
vacuum: { type: "boolean", default: false },
|
|
543
|
-
json: { type: "boolean", default: false },
|
|
544
|
-
},
|
|
545
|
-
strict: true,
|
|
546
|
-
});
|
|
547
|
-
const dataDir = resolveUserPath(values.data);
|
|
548
|
-
const config = loadConfig(dataDir);
|
|
549
|
-
// Defers to the setting it protects rather than repeating its default, unless
|
|
550
|
-
// a store has deliberately overridden it.
|
|
551
|
-
const keep = config.retention?.prune_keep_per_session ??
|
|
552
|
-
config.extraction?.working_memory_size ??
|
|
553
|
-
DEFAULT_CONFIG.extraction.working_memory_size;
|
|
554
|
-
const apply = values.apply;
|
|
555
|
-
const result = await withDb(dataDir, async (db) => {
|
|
556
|
-
const stats = apply ? await pruneEvents(db, keep) : await prunableEvents(db, keep);
|
|
557
|
-
// Only after a successful delete — vacuuming a database nothing was removed
|
|
558
|
-
// from is a long rewrite for no reason.
|
|
559
|
-
if (apply && values.vacuum && stats.events > 0) {
|
|
560
|
-
await vacuum(db);
|
|
561
|
-
const cap = getBoundDiskBudget(db);
|
|
562
|
-
if (cap && db.dialect === "sqlite") {
|
|
563
|
-
await applySqliteDiskBudget(db, cap.bytes);
|
|
564
|
-
}
|
|
565
|
-
}
|
|
566
|
-
return stats;
|
|
567
|
-
});
|
|
568
|
-
if (values.json) {
|
|
569
|
-
console.log(JSON.stringify({ ...result, applied: apply }, null, 2));
|
|
570
|
-
return;
|
|
571
|
-
}
|
|
572
|
-
console.log(formatPrune(result, apply, keep, values.vacuum));
|
|
573
|
-
}
|
|
574
|
-
// ---------------------------------------------------------------------------
|
|
575
|
-
// consolidate — the one verb that spends model calls
|
|
576
|
-
// ---------------------------------------------------------------------------
|
|
577
|
-
async function runConsolidate() {
|
|
578
|
-
const { values } = parseArgs({
|
|
579
|
-
args: process.argv.slice(3),
|
|
580
|
-
options: {
|
|
581
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
582
|
-
copy: { type: "boolean", default: false, short: "c" },
|
|
583
|
-
extract: { type: "boolean", default: false, short: "e" },
|
|
584
|
-
integrate: { type: "boolean", default: false, short: "i" },
|
|
585
|
-
all: { type: "boolean", default: false, short: "a" },
|
|
586
|
-
limit: { type: "string", short: "l" },
|
|
587
|
-
json: { type: "boolean", default: false },
|
|
588
|
-
},
|
|
589
|
-
strict: true,
|
|
590
|
-
});
|
|
591
|
-
const dataDir = resolveUserPath(values.data);
|
|
592
|
-
// undefined → the default cap; null → no cap; a number → that many.
|
|
593
|
-
let extractLimit = undefined;
|
|
594
|
-
if (values.all)
|
|
595
|
-
extractLimit = null;
|
|
596
|
-
if (values.limit !== undefined) {
|
|
597
|
-
const n = Number(values.limit);
|
|
598
|
-
if (!Number.isInteger(n) || n < 1) {
|
|
599
|
-
console.error("--limit must be a whole number of at least 1");
|
|
600
|
-
process.exit(1);
|
|
601
|
-
}
|
|
602
|
-
extractLimit = n;
|
|
603
|
-
}
|
|
604
|
-
await consolidateStore(dataDir, stepsFromFlags(values), {
|
|
605
|
-
extractLimit,
|
|
606
|
-
json: Boolean(values.json),
|
|
607
|
-
});
|
|
608
|
-
}
|
|
609
|
-
/**
|
|
610
|
-
* Consolidate a store in this process with its configured provider. This is
|
|
611
|
-
* the manual path: no MCP server is involved. A `sampling` selection has no
|
|
612
|
-
* server to sample from and degrades to heuristic; `cli` spawns `claude -p`
|
|
613
|
-
* directly. The FACTHOUSE_SUBPROCESS guard at the top of main() prevents
|
|
614
|
-
* recursion when this runs inside a provider subprocess.
|
|
615
|
-
*/
|
|
616
|
-
async function consolidateStore(dataDir, steps, opts = {}) {
|
|
617
|
-
const config = ensureBitemporalSince(dataDir, loadConfig(dataDir));
|
|
618
|
-
if (!steps.extract && !steps.integrate) {
|
|
619
|
-
// Copy only: no model, no embeddings, no vocabulary. The heuristic
|
|
620
|
-
// provider is a placeholder consolidate() never calls on this path.
|
|
621
|
-
return consolidateInProcess(dataDir, createHeuristicProvider(), config, null, steps, opts);
|
|
622
|
-
}
|
|
623
|
-
if (steps.extract &&
|
|
624
|
-
resolveProviderType(config.intelligence.provider) === "heuristic") {
|
|
625
|
-
console.error("[facthouse] intelligence.provider is heuristic — it does not extract " +
|
|
626
|
-
"facts from transcripts. capture_fact still works.");
|
|
627
|
-
}
|
|
628
|
-
const vocabulary = await withDb(dataDir, (db) => loadStoreVocabulary(db, config.domains ?? []));
|
|
629
|
-
const provider = createIntelligenceProvider(config.intelligence, {
|
|
630
|
-
vocabulary,
|
|
631
|
-
});
|
|
632
|
-
// Embeddings are written here too, not only by the server. `facthouse
|
|
633
|
-
// consolidate` is the documented way to process a store by hand, and a store
|
|
634
|
-
// consolidated that way would otherwise never gain a vector.
|
|
635
|
-
const embedding = createEmbeddingProvider(config.embedding, {
|
|
636
|
-
onUnavailable: (reason) => console.error(`[facthouse] ${reason}`),
|
|
637
|
-
});
|
|
638
|
-
return consolidateInProcess(dataDir, provider, config, embedding, steps, opts);
|
|
639
|
-
}
|
|
640
|
-
/**
|
|
641
|
-
* Open the DB at dataDir, run consolidate() with the given provider and steps,
|
|
642
|
-
* report, then close. The copy step reads `config.sources` through the same
|
|
643
|
-
* copySources the server's heartbeat uses — one copy path.
|
|
644
|
-
*/
|
|
645
|
-
export async function consolidateInProcess(dataDir, provider, config = DEFAULT_CONFIG, embedding = null, steps = ALL_STEPS, opts = {}) {
|
|
646
|
-
const storeConfig = loadShippedStoreConfig(dataDir);
|
|
647
|
-
const db = await openStore(dataDir, storeConfig);
|
|
648
|
-
try {
|
|
649
|
-
await applySchema(db);
|
|
650
|
-
const result = await consolidate(db, provider, config, embedding, steps, {
|
|
651
|
-
trigger: "cli",
|
|
652
|
-
project: envValue("PROJECT") ?? null,
|
|
653
|
-
copy: () => copySources(db, config.sources),
|
|
654
|
-
extractLimit: opts.extractLimit,
|
|
655
|
-
});
|
|
656
|
-
if (result.skipped && result.skipReason) {
|
|
657
|
-
console.error(`[facthouse] ${result.skipReason}`);
|
|
658
|
-
}
|
|
659
|
-
if (result.extractionDegraded) {
|
|
660
|
-
if (result.prefixCommitted) {
|
|
661
|
-
console.error(`[facthouse] Extraction stopped after a failed call. Facts from earlier examined events were kept and the watermark advanced to ${result.examinedThrough}. Remaining events are still eligible. Re-run ${CLI_NAME} consolidate to continue.`);
|
|
662
|
-
}
|
|
663
|
-
else {
|
|
664
|
-
console.error(`[facthouse] Extraction could not run — events were not examined and the watermark was held. A zero factsIntegrated here is not a successful empty extract. Re-run ${CLI_NAME} consolidate when the CLI provider can run.`);
|
|
665
|
-
}
|
|
666
|
-
}
|
|
667
|
-
if (opts.print !== false &&
|
|
668
|
-
steps.extract &&
|
|
669
|
-
!result.extractionDegraded &&
|
|
670
|
-
result.eventsRemaining > 0) {
|
|
671
|
-
console.error(`[facthouse] ${result.eventsRemaining} event(s) still waiting to be extracted. ` +
|
|
672
|
-
`Run ${CLI_NAME} consolidate --all to take them all now, or --limit N for the oldest N.`);
|
|
673
|
-
}
|
|
674
|
-
if (opts.print !== false) {
|
|
675
|
-
console.log(opts.json ? JSON.stringify(result) : formatConsolidate(result));
|
|
676
|
-
}
|
|
677
|
-
return result;
|
|
678
|
-
}
|
|
679
|
-
catch (err) {
|
|
680
|
-
console.error(errorMessage(err));
|
|
681
|
-
process.exit(1);
|
|
682
|
-
}
|
|
683
|
-
finally {
|
|
684
|
-
await closeDatabase(db);
|
|
685
|
-
}
|
|
686
|
-
}
|
|
687
|
-
// ---------------------------------------------------------------------------
|
|
688
|
-
// notify — tell the running server a moment happened
|
|
689
|
-
// ---------------------------------------------------------------------------
|
|
690
|
-
/**
|
|
691
|
-
* The server decides what to run for a moment (the policy lives with the
|
|
692
|
-
* engine); this process only relays and exits, so a hook returns at once.
|
|
693
|
-
* No server listening is not an error: the next session start covers it.
|
|
694
|
-
*/
|
|
695
|
-
async function runNotify() {
|
|
696
|
-
const momentArg = process.argv[3];
|
|
697
|
-
const { values } = parseArgs({
|
|
698
|
-
args: process.argv.slice(4),
|
|
699
|
-
options: {
|
|
700
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
701
|
-
},
|
|
702
|
-
strict: true,
|
|
703
|
-
});
|
|
704
|
-
if (!momentArg || !isNotifiableMoment(momentArg)) {
|
|
705
|
-
console.error(`Usage: ${CLI_NAME} notify <moment> [--data <dir>]\n` +
|
|
706
|
-
`Moments: ${NOTIFIABLE_MOMENTS.join(", ")}`);
|
|
707
|
-
process.exit(1);
|
|
708
|
-
}
|
|
709
|
-
const dataDir = resolveUserPath(values.data);
|
|
710
|
-
await notifyMoment(dataDir, momentArg);
|
|
711
|
-
}
|
|
712
|
-
async function notifyMoment(dataDir, moment) {
|
|
713
|
-
const delivered = await notifyServer(dataDir, moment);
|
|
714
|
-
if (!delivered) {
|
|
715
|
-
console.error(`[facthouse] No MCP server is listening for this store, so there is nothing ` +
|
|
716
|
-
`to notify. Run ${CLI_NAME} consolidate to process pending events now.`);
|
|
717
|
-
}
|
|
718
|
-
console.log(JSON.stringify({ delivered, moment }));
|
|
719
|
-
}
|
|
720
|
-
async function runRecord() {
|
|
721
|
-
const { values } = parseArgs({
|
|
722
|
-
args: process.argv.slice(3),
|
|
723
|
-
options: {
|
|
724
|
-
role: { type: "string", default: "user" },
|
|
725
|
-
"event-type": { type: "string", default: "message" },
|
|
726
|
-
"content-type": { type: "string", default: "text" },
|
|
727
|
-
content: { type: "string" },
|
|
728
|
-
"session-id": { type: "string" },
|
|
729
|
-
speaker: { type: "string" },
|
|
730
|
-
data: { type: "string", default: dataDirFromEnvOrDefault() },
|
|
731
|
-
},
|
|
732
|
-
strict: true,
|
|
733
|
-
});
|
|
734
|
-
const role = values.role;
|
|
735
|
-
const eventType = values["event-type"];
|
|
736
|
-
const contentType = values["content-type"];
|
|
737
|
-
if (!isSessionRole(role)) {
|
|
738
|
-
console.error(`Invalid --role: ${role}. Must be one of: ${SESSION_ROLES.join(", ")}`);
|
|
739
|
-
process.exit(1);
|
|
740
|
-
}
|
|
741
|
-
if (!isSessionEventType(eventType)) {
|
|
742
|
-
console.error(`Invalid --event-type: ${eventType}. Must be one of: ${SESSION_EVENT_TYPES.join(", ")}`);
|
|
743
|
-
process.exit(1);
|
|
744
|
-
}
|
|
745
|
-
if (!isSessionContentType(contentType)) {
|
|
746
|
-
console.error(`Invalid --content-type: ${contentType}. Must be one of: ${SESSION_CONTENT_TYPES.join(", ")}`);
|
|
747
|
-
process.exit(1);
|
|
748
|
-
}
|
|
749
|
-
// Content from --content flag or stdin (for hooks).
|
|
750
|
-
let content = values.content;
|
|
751
|
-
let sessionId = values["session-id"];
|
|
752
|
-
if (!content) {
|
|
753
|
-
const stdin = await readStdin();
|
|
754
|
-
if (stdin.trim()) {
|
|
755
|
-
const extracted = extractContentFromHookPayload(stdin.trim());
|
|
756
|
-
content = extracted.content;
|
|
757
|
-
sessionId = sessionId ?? extracted.sessionId;
|
|
758
|
-
}
|
|
759
|
-
}
|
|
760
|
-
if (!content) {
|
|
761
|
-
console.error("No content provided. Use --content or pipe via stdin.");
|
|
762
|
-
process.exit(1);
|
|
763
|
-
}
|
|
764
|
-
try {
|
|
765
|
-
const event = await recordEvent({
|
|
766
|
-
role,
|
|
767
|
-
eventType,
|
|
768
|
-
content,
|
|
769
|
-
contentType,
|
|
770
|
-
sessionId,
|
|
771
|
-
speaker: values.speaker ?? null,
|
|
772
|
-
dataDir: resolveUserPath(values.data),
|
|
773
|
-
});
|
|
774
|
-
console.log(JSON.stringify({ event_id: event.id, sequence: event.sequence }));
|
|
775
|
-
}
|
|
776
|
-
catch (err) {
|
|
777
|
-
console.error(errorMessage(err));
|
|
778
|
-
process.exit(1);
|
|
779
|
-
}
|
|
780
|
-
}
|
|
781
|
-
main().catch((err) => {
|
|
782
|
-
console.error(errorMessage(err));
|
|
783
|
-
process.exit(1);
|
|
784
|
-
});
|
|
8
|
+
import "../suppress-sqlite-warning.js";
|
|
9
|
+
await import("./run.js");
|
|
785
10
|
//# sourceMappingURL=index.js.map
|