@askalf/deepdive 0.1.0 → 0.4.0
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 +177 -52
- package/dist/agent.d.ts +48 -2
- package/dist/agent.d.ts.map +1 -1
- package/dist/agent.js +178 -65
- package/dist/agent.js.map +1 -1
- package/dist/cache.d.ts +16 -0
- package/dist/cache.d.ts.map +1 -0
- package/dist/cache.js +62 -0
- package/dist/cache.js.map +1 -0
- package/dist/cli.d.ts +1 -0
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +164 -18
- package/dist/cli.js.map +1 -1
- package/dist/concurrency.d.ts +2 -0
- package/dist/concurrency.d.ts.map +1 -0
- package/dist/concurrency.js +38 -0
- package/dist/concurrency.js.map +1 -0
- package/dist/config.d.ts +20 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +64 -3
- package/dist/config.js.map +1 -1
- package/dist/doctor.d.ts +44 -0
- package/dist/doctor.d.ts.map +1 -0
- package/dist/doctor.js +533 -0
- package/dist/doctor.js.map +1 -0
- package/dist/index.d.ts +9 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -3
- package/dist/index.js.map +1 -1
- package/dist/llm-stream.d.ts +27 -0
- package/dist/llm-stream.d.ts.map +1 -0
- package/dist/llm-stream.js +173 -0
- package/dist/llm-stream.js.map +1 -0
- package/dist/llm.d.ts +10 -0
- package/dist/llm.d.ts.map +1 -1
- package/dist/llm.js +96 -20
- package/dist/llm.js.map +1 -1
- package/dist/plan.d.ts +7 -0
- package/dist/plan.d.ts.map +1 -1
- package/dist/plan.js +51 -0
- package/dist/plan.js.map +1 -1
- package/dist/retry.d.ts +18 -0
- package/dist/retry.d.ts.map +1 -0
- package/dist/retry.js +70 -0
- package/dist/retry.js.map +1 -0
- package/dist/robots.d.ts +26 -0
- package/dist/robots.d.ts.map +1 -0
- package/dist/robots.js +183 -0
- package/dist/robots.js.map +1 -0
- package/dist/search/duckduckgo.d.ts +2 -0
- package/dist/search/duckduckgo.d.ts.map +1 -1
- package/dist/search/duckduckgo.js +38 -13
- package/dist/search/duckduckgo.js.map +1 -1
- package/dist/search/exa.d.ts +17 -0
- package/dist/search/exa.d.ts.map +1 -0
- package/dist/search/exa.js +62 -0
- package/dist/search/exa.js.map +1 -0
- package/dist/search/searxng.d.ts.map +1 -1
- package/dist/search/searxng.js +2 -1
- package/dist/search/searxng.js.map +1 -1
- package/dist/search.d.ts.map +1 -1
- package/dist/search.js +9 -1
- package/dist/search.js.map +1 -1
- package/dist/synthesize.d.ts +1 -1
- package/dist/synthesize.d.ts.map +1 -1
- package/dist/synthesize.js +11 -2
- package/dist/synthesize.js.map +1 -1
- package/dist/url-util.d.ts +4 -0
- package/dist/url-util.d.ts.map +1 -0
- package/dist/url-util.js +24 -0
- package/dist/url-util.js.map +1 -0
- package/package.json +3 -2
package/dist/agent.js
CHANGED
|
@@ -1,99 +1,212 @@
|
|
|
1
|
-
// Main agent loop
|
|
1
|
+
// Main agent loop.
|
|
2
2
|
//
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
//
|
|
3
|
+
// Single-pass mode (default): plan → search → fetch → extract → synthesize.
|
|
4
|
+
// Deep mode (--deep[=N]): after the first synthesis, a critic LLM reviews the
|
|
5
|
+
// draft, proposes follow-up queries, and the loop runs another round. Up to
|
|
6
|
+
// `maxRounds` extra rounds, bounded by the source cap.
|
|
7
|
+
//
|
|
8
|
+
// Fetching is concurrent (configurable via browser.concurrency) and optionally
|
|
9
|
+
// backed by an on-disk cache (src/cache.ts) so re-running a question is cheap.
|
|
6
10
|
import { dedupeByUrl } from "./search.js";
|
|
7
|
-
import { planQueries } from "./plan.js";
|
|
11
|
+
import { planQueries, critique } from "./plan.js";
|
|
8
12
|
import { BrowserSession } from "./browser.js";
|
|
9
13
|
import { extractContent } from "./extract.js";
|
|
10
14
|
import { buildSourceTable, renderAnswerMarkdown } from "./citations.js";
|
|
11
15
|
import { synthesize } from "./synthesize.js";
|
|
16
|
+
import { runConcurrent } from "./concurrency.js";
|
|
17
|
+
import { canFetch, DEFAULT_USER_AGENT, } from "./robots.js";
|
|
12
18
|
export async function runAgent(question, config, signal) {
|
|
13
19
|
emit(config, { type: "plan.start", question });
|
|
14
20
|
const plan = await planQueries(question, config.llm, signal);
|
|
15
21
|
emit(config, { type: "plan.done", plan });
|
|
16
22
|
const seenUrls = new Set();
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
23
|
+
const allCandidates = [];
|
|
24
|
+
const allQueries = [];
|
|
25
|
+
const keptSources = [];
|
|
26
|
+
const rounds = [];
|
|
27
|
+
let browser = null;
|
|
28
|
+
let answer = "";
|
|
29
|
+
const makeBrowser = config.browserFactory ?? ((opts) => new BrowserSession(opts));
|
|
30
|
+
async function ensureBrowser() {
|
|
31
|
+
if (browser)
|
|
32
|
+
return browser;
|
|
33
|
+
browser = makeBrowser(config.browser);
|
|
34
|
+
await browser.start();
|
|
35
|
+
return browser;
|
|
29
36
|
}
|
|
30
|
-
const toFetch = candidates.slice(0, config.maxSources);
|
|
31
|
-
const browser = new BrowserSession(config.browser);
|
|
32
|
-
await browser.start();
|
|
33
|
-
const fetched = [];
|
|
34
37
|
try {
|
|
35
|
-
|
|
38
|
+
const maxRoundsTotal = 1 + Math.max(0, config.deepRounds);
|
|
39
|
+
let queriesForRound = plan.queries;
|
|
40
|
+
for (let round = 0; round < maxRoundsTotal; round++) {
|
|
36
41
|
if (signal?.aborted)
|
|
37
42
|
throw new Error("aborted");
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
43
|
+
if (queriesForRound.length === 0)
|
|
44
|
+
break;
|
|
45
|
+
emit(config, { type: "round.start", round, queries: queriesForRound });
|
|
46
|
+
allQueries.push(...queriesForRound);
|
|
47
|
+
const candidatesBefore = allCandidates.length;
|
|
48
|
+
for (const query of queriesForRound) {
|
|
49
|
+
if (signal?.aborted)
|
|
50
|
+
throw new Error("aborted");
|
|
51
|
+
emit(config, { type: "search.start", query });
|
|
52
|
+
const results = await config.search.search(query, config.resultsPerQuery, signal);
|
|
53
|
+
const fresh = dedupeByUrl(results).filter((r) => !seenUrls.has(r.url));
|
|
54
|
+
for (const r of fresh) {
|
|
55
|
+
seenUrls.add(r.url);
|
|
56
|
+
allCandidates.push({
|
|
57
|
+
url: r.url,
|
|
58
|
+
title: r.title,
|
|
59
|
+
snippet: r.snippet,
|
|
60
|
+
query,
|
|
61
|
+
});
|
|
62
|
+
}
|
|
63
|
+
emit(config, { type: "search.done", query, count: fresh.length });
|
|
64
|
+
}
|
|
65
|
+
const candidatesFoundThisRound = allCandidates.length - candidatesBefore;
|
|
66
|
+
const headroom = Math.max(0, config.maxSources - keptSources.length);
|
|
67
|
+
const toFetch = allCandidates
|
|
68
|
+
.slice(candidatesBefore)
|
|
69
|
+
.slice(0, Math.max(headroom, candidatesFoundThisRound));
|
|
70
|
+
const fetched = await fetchMany(toFetch, config, ensureBrowser, signal);
|
|
71
|
+
for (const f of fetched) {
|
|
72
|
+
if (keptSources.length >= config.maxSources)
|
|
73
|
+
break;
|
|
74
|
+
if (f.page.status >= 200 && f.page.status < 400 && f.words > 50) {
|
|
75
|
+
const sourceId = keptSources.length + 1;
|
|
76
|
+
const extracted = extractContent(f.page.text, f.page.title || f.candidate.title, config.maxWordsPerSource);
|
|
77
|
+
if (extracted.text.length === 0)
|
|
78
|
+
continue;
|
|
79
|
+
keptSources.push({
|
|
80
|
+
id: sourceId,
|
|
81
|
+
url: f.page.finalUrl || f.page.url,
|
|
82
|
+
title: f.page.title || f.candidate.title,
|
|
83
|
+
fetchedAt: f.page.fetchedAt,
|
|
84
|
+
content: extracted.text,
|
|
85
|
+
});
|
|
51
86
|
}
|
|
52
87
|
}
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
88
|
+
emit(config, {
|
|
89
|
+
type: "synthesize.start",
|
|
90
|
+
sourceCount: keptSources.length,
|
|
91
|
+
round,
|
|
92
|
+
});
|
|
93
|
+
const tokenSink = config.onSynthesizeToken
|
|
94
|
+
? (chunk) => config.onSynthesizeToken(chunk, round)
|
|
95
|
+
: undefined;
|
|
96
|
+
answer = await synthesize(question, keptSources, config.llm, signal, tokenSink);
|
|
97
|
+
emit(config, { type: "synthesize.done", round });
|
|
98
|
+
const roundTrace = {
|
|
99
|
+
round,
|
|
100
|
+
queries: queriesForRound,
|
|
101
|
+
candidatesFound: candidatesFoundThisRound,
|
|
102
|
+
fetched: fetched.length,
|
|
103
|
+
kept: keptSources.length,
|
|
104
|
+
};
|
|
105
|
+
const isLastPossibleRound = round === maxRoundsTotal - 1;
|
|
106
|
+
if (!isLastPossibleRound && keptSources.length < config.maxSources) {
|
|
107
|
+
emit(config, { type: "critique.start", round });
|
|
108
|
+
const crit = await critique(question, answer, allQueries, config.llm, signal);
|
|
109
|
+
emit(config, { type: "critique.done", round, critique: crit });
|
|
110
|
+
roundTrace.critique = crit;
|
|
111
|
+
rounds.push(roundTrace);
|
|
112
|
+
if (crit.done || crit.queries.length === 0)
|
|
113
|
+
break;
|
|
114
|
+
queriesForRound = crit.queries;
|
|
115
|
+
}
|
|
116
|
+
else {
|
|
117
|
+
rounds.push(roundTrace);
|
|
118
|
+
break;
|
|
61
119
|
}
|
|
62
120
|
}
|
|
63
121
|
}
|
|
64
122
|
finally {
|
|
65
|
-
|
|
123
|
+
if (browser)
|
|
124
|
+
await browser.close().catch(() => undefined);
|
|
66
125
|
}
|
|
67
|
-
const
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
fetchedAt: f.fetchedAt,
|
|
72
|
-
})));
|
|
73
|
-
for (let i = 0; i < fetched.length; i++) {
|
|
74
|
-
const f = fetched[i];
|
|
75
|
-
const row = sourceRows[i];
|
|
76
|
-
const ex = extractContent(f.text, f.title || f.origTitle, config.maxWordsPerSource);
|
|
77
|
-
if (ex.text.length > 0) {
|
|
78
|
-
extracted.push({ ...row, content: ex.text });
|
|
79
|
-
}
|
|
126
|
+
const sourceTable = buildSourceTable(keptSources.map((s) => ({ url: s.url, title: s.title, fetchedAt: s.fetchedAt })));
|
|
127
|
+
// Rebind ids to the final table order (keptSources already assigned ids).
|
|
128
|
+
for (let i = 0; i < keptSources.length; i++) {
|
|
129
|
+
keptSources[i].id = sourceTable[i].id;
|
|
80
130
|
}
|
|
81
|
-
|
|
82
|
-
const answer = await synthesize(question, extracted, config.llm, signal);
|
|
83
|
-
emit(config, { type: "synthesize.done" });
|
|
84
|
-
const markdown = renderAnswerMarkdown(question, answer, extracted);
|
|
131
|
+
const markdown = renderAnswerMarkdown(question, answer, keptSources);
|
|
85
132
|
return {
|
|
86
133
|
question,
|
|
87
134
|
plan,
|
|
88
|
-
sources:
|
|
135
|
+
sources: keptSources,
|
|
136
|
+
answer,
|
|
89
137
|
markdown,
|
|
138
|
+
rounds,
|
|
90
139
|
usage: {
|
|
91
|
-
queries:
|
|
92
|
-
fetched:
|
|
93
|
-
kept:
|
|
140
|
+
queries: allQueries.length,
|
|
141
|
+
fetched: rounds.reduce((sum, r) => sum + r.fetched, 0),
|
|
142
|
+
kept: keptSources.length,
|
|
143
|
+
rounds: rounds.length,
|
|
144
|
+
cacheHits: config.cache?.hits ?? 0,
|
|
94
145
|
},
|
|
95
146
|
};
|
|
96
147
|
}
|
|
148
|
+
async function fetchMany(candidates, config, ensureBrowser, signal) {
|
|
149
|
+
const results = await runConcurrent(candidates, config.concurrency, async (c) => fetchOne(c, config, ensureBrowser), signal);
|
|
150
|
+
return results.filter((r) => r !== null);
|
|
151
|
+
}
|
|
152
|
+
async function fetchOne(c, config, ensureBrowser) {
|
|
153
|
+
if (config.respectRobots !== false) {
|
|
154
|
+
const ua = config.robotsUserAgent ?? DEFAULT_USER_AGENT;
|
|
155
|
+
const result = await canFetch(c.url, {
|
|
156
|
+
userAgent: ua,
|
|
157
|
+
cache: config.robotsCache,
|
|
158
|
+
});
|
|
159
|
+
if (result === "deny") {
|
|
160
|
+
emit(config, { type: "fetch.skipped", url: c.url, reason: "robots" });
|
|
161
|
+
return null;
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
if (config.cache) {
|
|
165
|
+
const cached = await config.cache.get(c.url);
|
|
166
|
+
if (cached) {
|
|
167
|
+
const words = (cached.text.match(/\S+/g) ?? []).length;
|
|
168
|
+
emit(config, { type: "fetch.start", url: c.url, cached: true });
|
|
169
|
+
emit(config, {
|
|
170
|
+
type: "fetch.done",
|
|
171
|
+
url: c.url,
|
|
172
|
+
ok: cached.status >= 200 && cached.status < 400,
|
|
173
|
+
status: cached.status,
|
|
174
|
+
words,
|
|
175
|
+
cached: true,
|
|
176
|
+
});
|
|
177
|
+
return { candidate: c, page: cached, words, cached: true };
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
emit(config, { type: "fetch.start", url: c.url, cached: false });
|
|
181
|
+
try {
|
|
182
|
+
const browser = await ensureBrowser();
|
|
183
|
+
const page = await browser.fetch(c.url);
|
|
184
|
+
const words = (page.text.match(/\S+/g) ?? []).length;
|
|
185
|
+
if (config.cache && page.status >= 200 && page.status < 400) {
|
|
186
|
+
await config.cache.put(c.url, page).catch(() => undefined);
|
|
187
|
+
}
|
|
188
|
+
emit(config, {
|
|
189
|
+
type: "fetch.done",
|
|
190
|
+
url: c.url,
|
|
191
|
+
ok: page.status >= 200 && page.status < 400,
|
|
192
|
+
status: page.status,
|
|
193
|
+
words,
|
|
194
|
+
cached: false,
|
|
195
|
+
});
|
|
196
|
+
return { candidate: c, page, words, cached: false };
|
|
197
|
+
}
|
|
198
|
+
catch {
|
|
199
|
+
emit(config, {
|
|
200
|
+
type: "fetch.done",
|
|
201
|
+
url: c.url,
|
|
202
|
+
ok: false,
|
|
203
|
+
status: 0,
|
|
204
|
+
words: 0,
|
|
205
|
+
cached: false,
|
|
206
|
+
});
|
|
207
|
+
return null;
|
|
208
|
+
}
|
|
209
|
+
}
|
|
97
210
|
function emit(config, event) {
|
|
98
211
|
config.onEvent?.(event);
|
|
99
212
|
}
|
package/dist/agent.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent.js","sourceRoot":"","sources":["../src/agent.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"agent.js","sourceRoot":"","sources":["../src/agent.ts"],"names":[],"mappings":"AAAA,mBAAmB;AACnB,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,4EAA4E;AAC5E,uDAAuD;AACvD,EAAE;AACF,+EAA+E;AAC/E,+EAA+E;AAI/E,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,QAAQ,EAA4B,MAAM,WAAW,CAAC;AAC5E,OAAO,EAAE,cAAc,EAAyC,MAAM,cAAc,CAAC;AACrF,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,gBAAgB,EAAE,oBAAoB,EAAe,MAAM,gBAAgB,CAAC;AACrF,OAAO,EAAE,UAAU,EAA0B,MAAM,iBAAiB,CAAC;AAErE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EACL,QAAQ,EACR,kBAAkB,GAEnB,MAAM,aAAa,CAAC;AAmFrB,MAAM,CAAC,KAAK,UAAU,QAAQ,CAC5B,QAAgB,EAChB,MAAmB,EACnB,MAAoB;IAEpB,IAAI,CAAC,MAAM,EAAE,EAAE,IAAI,EAAE,YAAY,EAAE,QAAQ,EAAE,CAAC,CAAC;IAC/C,MAAM,IAAI,GAAG,MAAM,WAA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AC,SAAS,CAAC,CAAC;QAC7D,CAAC;QACD,IAAI,CAAC,MAAM,EAAE;YACX,IAAI,EAAE,YAAY;YAClB,GAAG,EAAE,CAAC,CAAC,GAAG;YACV,EAAE,EAAE,IAAI,CAAC,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC,MAAM,GAAG,GAAG;YAC3C,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,KAAK;YACL,MAAM,EAAE,KAAK;SACd,CAAC,CAAC;QACH,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC;IACtD,CAAC;IAAC,MAAM,CAAC;QACP,IAAI,CAAC,MAAM,EAAE;YACX,IAAI,EAAE,YAAY;YAClB,GAAG,EAAE,CAAC,CAAC,GAAG;YACV,EAAE,EAAE,KAAK;YACT,MAAM,EAAE,CAAC;YACT,KAAK,EAAE,CAAC;YACR,MAAM,EAAE,KAAK;SACd,CAAC,CAAC;QACH,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC;AAED,SAAS,IAAI,CAAC,MAAmB,EAAE,KAAiB;IAClD,MAAM,CAAC,OAAO,EAAE,CAAC,KAAK,CAAC,CAAC;AAC1B,CAAC"}
|
package/dist/cache.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { FetchedPage } from "./browser.js";
|
|
2
|
+
export interface CacheOptions {
|
|
3
|
+
dir: string;
|
|
4
|
+
ttlMs: number;
|
|
5
|
+
}
|
|
6
|
+
export interface PageCache {
|
|
7
|
+
readonly dir: string;
|
|
8
|
+
readonly ttlMs: number;
|
|
9
|
+
get(url: string): Promise<FetchedPage | null>;
|
|
10
|
+
put(url: string, page: FetchedPage): Promise<void>;
|
|
11
|
+
readonly hits: number;
|
|
12
|
+
readonly misses: number;
|
|
13
|
+
}
|
|
14
|
+
export declare function createCache(opts: CacheOptions): PageCache;
|
|
15
|
+
export declare function cacheKey(url: string): string;
|
|
16
|
+
//# sourceMappingURL=cache.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cache.d.ts","sourceRoot":"","sources":["../src/cache.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,MAAM,WAAW,YAAY;IAC3B,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,GAAG,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,GAAG,IAAI,CAAC,CAAC;IAC9C,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACnD,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB;AAED,wBAAgB,WAAW,CAAC,IAAI,EAAE,YAAY,GAAG,SAAS,CA+CzD;AAGD,wBAAgB,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAE5C"}
|
package/dist/cache.js
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
// Per-URL on-disk cache for fetched pages. Keyed by SHA-256(url). Stores
|
|
2
|
+
// the full FetchedPage JSON at <dir>/<hash>.json with mtime-based TTL.
|
|
3
|
+
//
|
|
4
|
+
// Why file-based: zero runtime deps, survives process restarts, inspectable,
|
|
5
|
+
// and good enough for a single-user local tool. The cache directory defaults
|
|
6
|
+
// to ~/.deepdive/cache/ but tests inject a tmpdir.
|
|
7
|
+
import { createHash } from "node:crypto";
|
|
8
|
+
import { promises as fs } from "node:fs";
|
|
9
|
+
import { join } from "node:path";
|
|
10
|
+
export function createCache(opts) {
|
|
11
|
+
const state = { hits: 0, misses: 0, mkdired: false };
|
|
12
|
+
async function ensureDir() {
|
|
13
|
+
if (state.mkdired)
|
|
14
|
+
return;
|
|
15
|
+
await fs.mkdir(opts.dir, { recursive: true });
|
|
16
|
+
state.mkdired = true;
|
|
17
|
+
}
|
|
18
|
+
return {
|
|
19
|
+
get dir() {
|
|
20
|
+
return opts.dir;
|
|
21
|
+
},
|
|
22
|
+
get ttlMs() {
|
|
23
|
+
return opts.ttlMs;
|
|
24
|
+
},
|
|
25
|
+
get hits() {
|
|
26
|
+
return state.hits;
|
|
27
|
+
},
|
|
28
|
+
get misses() {
|
|
29
|
+
return state.misses;
|
|
30
|
+
},
|
|
31
|
+
async get(url) {
|
|
32
|
+
const path = join(opts.dir, cacheKey(url) + ".json");
|
|
33
|
+
try {
|
|
34
|
+
const stat = await fs.stat(path);
|
|
35
|
+
if (Date.now() - stat.mtimeMs > opts.ttlMs) {
|
|
36
|
+
state.misses++;
|
|
37
|
+
return null;
|
|
38
|
+
}
|
|
39
|
+
const raw = await fs.readFile(path, "utf-8");
|
|
40
|
+
const page = JSON.parse(raw);
|
|
41
|
+
state.hits++;
|
|
42
|
+
return page;
|
|
43
|
+
}
|
|
44
|
+
catch {
|
|
45
|
+
state.misses++;
|
|
46
|
+
return null;
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
async put(url, page) {
|
|
50
|
+
await ensureDir();
|
|
51
|
+
const path = join(opts.dir, cacheKey(url) + ".json");
|
|
52
|
+
const tmp = path + ".tmp." + process.pid;
|
|
53
|
+
await fs.writeFile(tmp, JSON.stringify(page), "utf-8");
|
|
54
|
+
await fs.rename(tmp, path);
|
|
55
|
+
},
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
// Exported for unit tests.
|
|
59
|
+
export function cacheKey(url) {
|
|
60
|
+
return createHash("sha256").update(url).digest("hex").slice(0, 32);
|
|
61
|
+
}
|
|
62
|
+
//# sourceMappingURL=cache.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":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sources":["../src/cli.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";AAcA,OAAO,EAAiB,KAAK,QAAQ,EAAE,MAAM,aAAa,CAAC;AA0D3D,UAAU,UAAU;IAClB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,QAAQ,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;CACf;AAGD,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,UAAU,CAyGpD;AAoDD,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM,CAIrD"}
|