@apmantza/greedysearch-pi 1.5.0 → 1.6.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/CHANGELOG.md +19 -0
- package/README.md +44 -30
- package/index.ts +23 -19
- package/package.json +1 -1
- package/search.mjs +35 -12
- package/skills/greedy-search/SKILL.md +35 -26
- package/.pi-lens/cache/jscpd.json +0 -112
- package/.pi-lens/cache/jscpd.meta.json +0 -3
- package/.pi-lens/cache/knip.json +0 -111
- package/.pi-lens/cache/knip.meta.json +0 -4
- package/.pi-lens/fix-plan.md +0 -13
- package/.pi-lens/fix-session.json +0 -11
- package/.pi-lens/metrics-history.json +0 -182
- package/.pi-lens/reports/fix-plan.tsv +0 -38
- package/.pi-lens/turn-state.json +0 -6
- package/test.mjs +0 -308
- package/test.sh +0 -298
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## v1.6.0 (2026-03-29)
|
|
4
|
+
|
|
5
|
+
### Breaking Changes (Backward Compatible)
|
|
6
|
+
- **Merged deep_research into greedy_search** — new `depth` parameter with three levels:
|
|
7
|
+
- `fast`: single engine (~15-30s)
|
|
8
|
+
- `standard`: 3 engines + synthesis (~30-90s, default for `engine: "all"`)
|
|
9
|
+
- `deep`: 3 engines + source fetching + synthesis + confidence (~60-180s)
|
|
10
|
+
- **Simpler mental model** — one tool with clear speed/quality tradeoffs instead of separate tools with overlapping flags
|
|
11
|
+
- **Deprecated flags still work** — `--synthesize` maps to `depth: "standard"`, `--deep-research` maps to `depth: "deep"`
|
|
12
|
+
- **deep_research tool aliased** — still works, calls `greedy_search` with `depth: "deep"`
|
|
13
|
+
|
|
14
|
+
### Documentation
|
|
15
|
+
- Updated README with new `depth` parameter and examples
|
|
16
|
+
- Updated skill documentation (SKILL.md) to reflect simplified API
|
|
17
|
+
|
|
18
|
+
## v1.5.1 (2026-03-29)
|
|
19
|
+
|
|
20
|
+
- **Fixed npm package** — added `.pi-lens/` and test files to `.npmignore` to reduce package size
|
|
21
|
+
|
|
3
22
|
## v1.5.0 (2026-03-29)
|
|
4
23
|
|
|
5
24
|
### Features
|
package/README.md
CHANGED
|
@@ -24,10 +24,10 @@ pi install git:github.com/apmantza/GreedySearch-pi
|
|
|
24
24
|
|
|
25
25
|
## Quick Start
|
|
26
26
|
|
|
27
|
-
Once installed, Pi gains a `greedy_search` tool
|
|
27
|
+
Once installed, Pi gains a `greedy_search` tool with three depth levels.
|
|
28
28
|
|
|
29
29
|
```
|
|
30
|
-
greedy_search({ query: "What's new in React 19?",
|
|
30
|
+
greedy_search({ query: "What's new in React 19?", depth: "standard" })
|
|
31
31
|
```
|
|
32
32
|
|
|
33
33
|
## Parameters
|
|
@@ -35,19 +35,27 @@ greedy_search({ query: "What's new in React 19?", engine: "all" })
|
|
|
35
35
|
| Parameter | Type | Default | Description |
|
|
36
36
|
|-----------|------|---------|-------------|
|
|
37
37
|
| `query` | string | required | The search question |
|
|
38
|
-
| `engine` | string | `"all"` |
|
|
39
|
-
| `
|
|
38
|
+
| `engine` | string | `"all"` | `all`, `perplexity`, `bing`, `google`, `gemini` |
|
|
39
|
+
| `depth` | string | `"standard"` | `fast` (1 engine), `standard` (3 engines + synthesis), `deep` (3 + fetch + synthesis + confidence) |
|
|
40
40
|
| `fullAnswer` | boolean | `false` | Return complete answer (~3000+ chars) vs truncated preview (~300 chars) |
|
|
41
41
|
|
|
42
|
-
##
|
|
42
|
+
## Depth Levels
|
|
43
43
|
|
|
44
|
-
|
|
|
45
|
-
|
|
46
|
-
| `
|
|
47
|
-
| `
|
|
48
|
-
| `
|
|
49
|
-
|
|
50
|
-
|
|
44
|
+
| Depth | Engines | Synthesis | Source Fetch | Time | Best For |
|
|
45
|
+
|-------|---------|-----------|--------------|------|----------|
|
|
46
|
+
| `fast` | 1 | — | — | 15-30s | Quick lookup, single perspective |
|
|
47
|
+
| `standard` | 3 | ✅ | — | 30-90s | Default — balanced speed/quality |
|
|
48
|
+
| `deep` | 3 | ✅ | ✅ (top 5) | 60-180s | Research that matters — architecture decisions |
|
|
49
|
+
|
|
50
|
+
## Engines (for fast mode)
|
|
51
|
+
|
|
52
|
+
| Engine | Alias | Best for |
|
|
53
|
+
|--------|-------|----------|
|
|
54
|
+
| `all` | — | All 3 engines — but for fast single-engine, pick one below |
|
|
55
|
+
| `perplexity` | `p` | Technical Q&A, code explanations, documentation |
|
|
56
|
+
| `bing` | `b` | Recent news, Microsoft ecosystem |
|
|
57
|
+
| `google` | `g` | Broad coverage, multiple perspectives |
|
|
58
|
+
| `gemini` | `gem` | Google's AI with different training data |
|
|
51
59
|
|
|
52
60
|
## Streaming Progress
|
|
53
61
|
|
|
@@ -60,24 +68,21 @@ When using `engine: "all"`, the tool streams progress as each engine completes:
|
|
|
60
68
|
**Searching...** ✅ perplexity done · ✅ bing done · ✅ google done
|
|
61
69
|
```
|
|
62
70
|
|
|
63
|
-
##
|
|
71
|
+
## Deep Research Mode
|
|
64
72
|
|
|
65
|
-
For
|
|
73
|
+
For research that matters — architecture decisions, library comparisons — use `depth: "deep"`:
|
|
66
74
|
|
|
67
75
|
```
|
|
68
|
-
greedy_search({ query: "best auth patterns for SaaS in 2026",
|
|
76
|
+
greedy_search({ query: "best auth patterns for SaaS in 2026", depth: "deep" })
|
|
69
77
|
```
|
|
70
78
|
|
|
71
|
-
|
|
79
|
+
Deep mode: 3 engines + source fetching (top 5) + synthesis + confidence scores. ~60-180s but returns grounded synthesis with fetched evidence.
|
|
72
80
|
|
|
73
|
-
**
|
|
74
|
-
-
|
|
75
|
-
-
|
|
76
|
-
- Token efficiency matters (one answer vs three)
|
|
81
|
+
**Standard vs Deep:**
|
|
82
|
+
- `standard` (default): 3 engines + synthesis. Good for most research.
|
|
83
|
+
- `deep`: Same + fetches source content for grounded answers. Use when the answer really matters.
|
|
77
84
|
|
|
78
|
-
**
|
|
79
|
-
- You want to see where engines disagree
|
|
80
|
-
- Speed matters
|
|
85
|
+
**Legacy:** `deep_research` tool still works — aliases to `greedy_search` with `depth: "deep"`.
|
|
81
86
|
|
|
82
87
|
## Full vs Short Answers
|
|
83
88
|
|
|
@@ -89,28 +94,28 @@ greedy_search({ query: "explain the React compiler", engine: "perplexity", fullA
|
|
|
89
94
|
|
|
90
95
|
## Examples
|
|
91
96
|
|
|
92
|
-
**Quick
|
|
97
|
+
**Quick lookup (fast):**
|
|
93
98
|
|
|
94
99
|
```
|
|
95
|
-
greedy_search({ query: "How to use async await in Python", engine: "perplexity" })
|
|
100
|
+
greedy_search({ query: "How to use async await in Python", depth: "fast", engine: "perplexity" })
|
|
96
101
|
```
|
|
97
102
|
|
|
98
|
-
**Compare tools (
|
|
103
|
+
**Compare tools (standard):**
|
|
99
104
|
|
|
100
105
|
```
|
|
101
|
-
greedy_search({ query: "Prisma vs Drizzle in 2026",
|
|
106
|
+
greedy_search({ query: "Prisma vs Drizzle in 2026", depth: "standard" })
|
|
102
107
|
```
|
|
103
108
|
|
|
104
|
-
**
|
|
109
|
+
**Deep research (architecture decision):**
|
|
105
110
|
|
|
106
111
|
```
|
|
107
|
-
greedy_search({ query: "Best practices for monorepo structure",
|
|
112
|
+
greedy_search({ query: "Best practices for monorepo structure", depth: "deep" })
|
|
108
113
|
```
|
|
109
114
|
|
|
110
115
|
**Debug an error:**
|
|
111
116
|
|
|
112
117
|
```
|
|
113
|
-
greedy_search({ query: "Error: Cannot find module 'react-dom/client' Next.js 15",
|
|
118
|
+
greedy_search({ query: "Error: Cannot find module 'react-dom/client' Next.js 15", depth: "standard" })
|
|
114
119
|
```
|
|
115
120
|
|
|
116
121
|
## Requirements
|
|
@@ -200,6 +205,15 @@ Sources are now extracted by regex-parsing Markdown links (`[title](url)`) from
|
|
|
200
205
|
|
|
201
206
|
## Changelog
|
|
202
207
|
|
|
208
|
+
### v1.6.0 (2026-03-29)
|
|
209
|
+
- **Merged deep_research into greedy_search** — new `depth` parameter: `fast` (1 engine), `standard` (3 engines + synthesis), `deep` (3 engines + fetch + synthesis + confidence)
|
|
210
|
+
- **Simpler API** — one tool with clear speed/quality tradeoffs instead of separate tools with overlapping flags
|
|
211
|
+
- **Backward compatible** — `deep_research` still works as alias, `--synthesize` and `--deep-research` flags still function
|
|
212
|
+
- **Updated documentation** — README and skill docs now use `depth` parameter throughout
|
|
213
|
+
|
|
214
|
+
### v1.5.1 (2026-03-29)
|
|
215
|
+
- Fixed npm package — added `.pi-lens/` and test files to `.npmignore`
|
|
216
|
+
|
|
203
217
|
### v1.5.0 (2026-03-29)
|
|
204
218
|
|
|
205
219
|
- **Code extraction fixed** — `coding_task` now uses clipboard interception to preserve markdown code blocks (was losing them via DOM scraping)
|
package/index.ts
CHANGED
|
@@ -456,12 +456,13 @@ export default function greedySearchExtension(pi: ExtensionAPI) {
|
|
|
456
456
|
default: "all",
|
|
457
457
|
},
|
|
458
458
|
),
|
|
459
|
-
|
|
460
|
-
Type.
|
|
459
|
+
depth: Type.Union(
|
|
460
|
+
[Type.Literal("fast"), Type.Literal("standard"), Type.Literal("deep")],
|
|
461
|
+
{
|
|
461
462
|
description:
|
|
462
|
-
|
|
463
|
-
default:
|
|
464
|
-
}
|
|
463
|
+
"Search depth: fast (single engine, ~15-30s), standard (3 engines + synthesis, ~30-90s), deep (3 engines + source fetching + synthesis + confidence, ~60-180s). Default: standard.",
|
|
464
|
+
default: "standard",
|
|
465
|
+
},
|
|
465
466
|
),
|
|
466
467
|
fullAnswer: Type.Optional(
|
|
467
468
|
Type.Boolean({
|
|
@@ -475,12 +476,12 @@ export default function greedySearchExtension(pi: ExtensionAPI) {
|
|
|
475
476
|
const {
|
|
476
477
|
query,
|
|
477
478
|
engine = "all",
|
|
478
|
-
|
|
479
|
+
depth = "standard",
|
|
479
480
|
fullAnswer = false,
|
|
480
481
|
} = params as {
|
|
481
482
|
query: string;
|
|
482
483
|
engine: string;
|
|
483
|
-
|
|
484
|
+
depth?: "fast" | "standard" | "deep";
|
|
484
485
|
fullAnswer?: boolean;
|
|
485
486
|
};
|
|
486
487
|
|
|
@@ -498,7 +499,11 @@ export default function greedySearchExtension(pi: ExtensionAPI) {
|
|
|
498
499
|
|
|
499
500
|
const flags: string[] = [];
|
|
500
501
|
if (fullAnswer) flags.push("--full");
|
|
501
|
-
|
|
502
|
+
// Map depth to CLI flags
|
|
503
|
+
if (depth === "deep") flags.push("--deep");
|
|
504
|
+
else if (depth === "standard" && engine === "all")
|
|
505
|
+
flags.push("--synthesize");
|
|
506
|
+
// For "fast" depth with "all" engine, we run 3 engines but no synthesis (just pick first result)
|
|
502
507
|
|
|
503
508
|
// Track progress for "all" engine mode
|
|
504
509
|
const completed = new Set<string>();
|
|
@@ -510,7 +515,8 @@ export default function greedySearchExtension(pi: ExtensionAPI) {
|
|
|
510
515
|
if (completed.has(e)) parts.push(`✅ ${e} done`);
|
|
511
516
|
else parts.push(`⏳ ${e}`);
|
|
512
517
|
}
|
|
513
|
-
if (
|
|
518
|
+
if (depth !== "fast" && completed.size >= 3)
|
|
519
|
+
parts.push("🔄 synthesizing");
|
|
514
520
|
|
|
515
521
|
onUpdate?.({
|
|
516
522
|
content: [
|
|
@@ -544,17 +550,15 @@ export default function greedySearchExtension(pi: ExtensionAPI) {
|
|
|
544
550
|
});
|
|
545
551
|
|
|
546
552
|
// ─── deep_research ─────────────────────────────────────────────────────────
|
|
553
|
+
// DEPRECATED: Use greedy_search with depth: "deep" instead.
|
|
554
|
+
// Kept for backward compatibility — aliases to greedy_search.
|
|
547
555
|
pi.registerTool({
|
|
548
556
|
name: "deep_research",
|
|
549
|
-
label: "Deep Research",
|
|
557
|
+
label: "Deep Research (legacy)",
|
|
550
558
|
description:
|
|
551
|
-
"
|
|
552
|
-
"
|
|
553
|
-
|
|
554
|
-
"and synthesizes via Gemini. Returns a structured research document with confidence scores. " +
|
|
555
|
-
"Use for architecture decisions, library comparisons, best practices, or any research where the answer matters.",
|
|
556
|
-
promptSnippet:
|
|
557
|
-
"Deep multi-engine research with source deduplication and synthesis",
|
|
559
|
+
"DEPRECATED — Use greedy_search with depth: 'deep' instead. " +
|
|
560
|
+
"Comprehensive multi-engine research with source fetching and synthesis.",
|
|
561
|
+
promptSnippet: "Deep multi-engine research (legacy alias to greedy_search)",
|
|
558
562
|
parameters: Type.Object({
|
|
559
563
|
query: Type.String({ description: "The research question" }),
|
|
560
564
|
}),
|
|
@@ -590,11 +594,11 @@ export default function greedySearchExtension(pi: ExtensionAPI) {
|
|
|
590
594
|
};
|
|
591
595
|
|
|
592
596
|
try {
|
|
593
|
-
//
|
|
597
|
+
// Delegate to greedy_search with depth: "deep"
|
|
594
598
|
const data = await runSearch(
|
|
595
599
|
"all",
|
|
596
600
|
query,
|
|
597
|
-
["--deep
|
|
601
|
+
["--deep"],
|
|
598
602
|
signal,
|
|
599
603
|
onProgress,
|
|
600
604
|
);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@apmantza/greedysearch-pi",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "Pi extension: multi-engine AI search (Perplexity, Bing Copilot, Google AI) via browser automation — NO API KEYS needed. Extracts answers with sources, optional Gemini synthesis. Grounded AI answers from real browser interactions.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"keywords": [
|
package/search.mjs
CHANGED
|
@@ -1070,12 +1070,30 @@ async function main() {
|
|
|
1070
1070
|
|
|
1071
1071
|
await ensureChrome();
|
|
1072
1072
|
|
|
1073
|
-
|
|
1073
|
+
// Parse --depth or fall back to deprecated flags
|
|
1074
|
+
const depthIdx = args.indexOf("--depth");
|
|
1075
|
+
let depth = "fast"; // default for single engine
|
|
1076
|
+
if (depthIdx !== -1 && args[depthIdx + 1]) {
|
|
1077
|
+
depth = args[depthIdx + 1];
|
|
1078
|
+
} else if (args.includes("--deep-research")) {
|
|
1079
|
+
depth = "deep";
|
|
1080
|
+
} else if (args.includes("--synthesize")) {
|
|
1081
|
+
depth = "standard";
|
|
1082
|
+
}
|
|
1083
|
+
// For "all" engine, default to standard if not specified
|
|
1084
|
+
const engineArg = args.find((a) => !a.startsWith("--"))?.toLowerCase();
|
|
1085
|
+
if (
|
|
1086
|
+
engineArg === "all" &&
|
|
1087
|
+
depthIdx === -1 &&
|
|
1088
|
+
!args.includes("--deep-research") &&
|
|
1089
|
+
!args.includes("--synthesize")
|
|
1090
|
+
) {
|
|
1091
|
+
depth = "standard";
|
|
1092
|
+
}
|
|
1093
|
+
|
|
1094
|
+
const full = args.includes("--full") || depth === "deep";
|
|
1074
1095
|
const short = !full;
|
|
1075
1096
|
const fetchSource = args.includes("--fetch-top-source");
|
|
1076
|
-
const synthesize =
|
|
1077
|
-
args.includes("--synthesize") || args.includes("--deep-research");
|
|
1078
|
-
const deepResearch = args.includes("--deep-research");
|
|
1079
1097
|
const inline = args.includes("--inline");
|
|
1080
1098
|
const outIdx = args.indexOf("--out");
|
|
1081
1099
|
const outFile = outIdx !== -1 ? args[outIdx + 1] : null;
|
|
@@ -1087,7 +1105,8 @@ async function main() {
|
|
|
1087
1105
|
a !== "--synthesize" &&
|
|
1088
1106
|
a !== "--deep-research" &&
|
|
1089
1107
|
a !== "--inline" &&
|
|
1090
|
-
a !== "--
|
|
1108
|
+
a !== "--depth" &&
|
|
1109
|
+
(depthIdx === -1 || i !== depthIdx + 1) &&
|
|
1091
1110
|
(outIdx === -1 || i !== outIdx + 1),
|
|
1092
1111
|
);
|
|
1093
1112
|
const engine = rest[0].toLowerCase();
|
|
@@ -1137,7 +1156,7 @@ async function main() {
|
|
|
1137
1156
|
// Build a canonical source registry across all engines
|
|
1138
1157
|
out._sources = buildSourceRegistry(out);
|
|
1139
1158
|
|
|
1140
|
-
if (
|
|
1159
|
+
if (depth === "deep") {
|
|
1141
1160
|
process.stderr.write("PROGRESS:deep-research:start\n");
|
|
1142
1161
|
const fetchedSources =
|
|
1143
1162
|
out._sources.length > 0
|
|
@@ -1153,8 +1172,8 @@ async function main() {
|
|
|
1153
1172
|
);
|
|
1154
1173
|
}
|
|
1155
1174
|
|
|
1156
|
-
// Synthesize with Gemini
|
|
1157
|
-
if (
|
|
1175
|
+
// Synthesize with Gemini for standard and deep modes
|
|
1176
|
+
if (depth !== "fast") {
|
|
1158
1177
|
process.stderr.write("PROGRESS:synthesis:start\n");
|
|
1159
1178
|
process.stderr.write(
|
|
1160
1179
|
"[greedysearch] Synthesizing results with Gemini...\n",
|
|
@@ -1165,7 +1184,7 @@ async function main() {
|
|
|
1165
1184
|
tabs.push(geminiTab); // ensure cleanup in finally block
|
|
1166
1185
|
await activateTab(geminiTab);
|
|
1167
1186
|
const synthesis = await synthesizeWithGemini(query, out, {
|
|
1168
|
-
grounded:
|
|
1187
|
+
grounded: depth === "deep",
|
|
1169
1188
|
tabPrefix: geminiTab,
|
|
1170
1189
|
});
|
|
1171
1190
|
out._synthesis = {
|
|
@@ -1187,9 +1206,13 @@ async function main() {
|
|
|
1187
1206
|
out._topSource = await fetchTopSource(top.canonicalUrl || top.url);
|
|
1188
1207
|
}
|
|
1189
1208
|
|
|
1190
|
-
if (
|
|
1209
|
+
if (depth === "deep") out._confidence = buildConfidence(out);
|
|
1191
1210
|
|
|
1192
|
-
writeOutput(out, outFile, {
|
|
1211
|
+
writeOutput(out, outFile, {
|
|
1212
|
+
inline,
|
|
1213
|
+
synthesize: depth !== "fast",
|
|
1214
|
+
query,
|
|
1215
|
+
});
|
|
1193
1216
|
return;
|
|
1194
1217
|
} finally {
|
|
1195
1218
|
await closeTabs(tabs);
|
|
@@ -1209,7 +1232,7 @@ async function main() {
|
|
|
1209
1232
|
if (fetchSource && result.sources?.length > 0) {
|
|
1210
1233
|
result.topSource = await fetchTopSource(result.sources[0].url);
|
|
1211
1234
|
}
|
|
1212
|
-
writeOutput(result, outFile, { inline, synthesize, query });
|
|
1235
|
+
writeOutput(result, outFile, { inline, synthesize: false, query });
|
|
1213
1236
|
} catch (e) {
|
|
1214
1237
|
process.stderr.write(`Error: ${e.message}\n`);
|
|
1215
1238
|
process.exit(1);
|
|
@@ -1,48 +1,57 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: greedy-search
|
|
3
|
-
description: Multi-engine AI web search — greedy_search
|
|
3
|
+
description: Multi-engine AI web search — greedy_search with three depth levels (fast/standard/deep). Use for high-quality research where training data may be stale or single-engine results are insufficient. NO API KEYS needed.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# GreedySearch Tools
|
|
7
7
|
|
|
8
8
|
| Tool | Speed | Use For |
|
|
9
9
|
|------|-------|---------|
|
|
10
|
-
| `greedy_search` | 15-
|
|
11
|
-
| `deep_research` | 60-120s | Architecture decisions, source-backed research |
|
|
10
|
+
| `greedy_search` | 15-180s | Multi-engine search with depth levels |
|
|
12
11
|
| `coding_task` | 60-180s | Debug, review, plan modes for hard problems |
|
|
13
12
|
|
|
14
13
|
## greedy_search
|
|
15
14
|
|
|
16
|
-
Multi-engine AI search (Perplexity, Bing, Google).
|
|
15
|
+
Multi-engine AI search (Perplexity, Bing, Google) with three depth levels.
|
|
17
16
|
|
|
18
|
-
```greedy_search({ query: "React 19 changes",
|
|
17
|
+
```greedy_search({ query: "React 19 changes", depth: "standard" })```
|
|
19
18
|
|
|
20
19
|
| Parameter | Type | Default | Description |
|
|
21
20
|
|-----------|------|---------|-------------|
|
|
22
21
|
| `query` | string | required | Search question |
|
|
23
22
|
| `engine` | string | `"all"` | `all`, `perplexity`, `bing`, `google`, `gemini` |
|
|
24
|
-
| `
|
|
23
|
+
| `depth` | string | `"standard"` | `fast`, `standard`, `deep` — see below |
|
|
25
24
|
| `fullAnswer` | boolean | `false` | Complete vs ~300 char summary |
|
|
26
25
|
|
|
27
|
-
|
|
28
|
-
**vs web_search:** Slower but higher quality — 3 engines cross-verify.
|
|
26
|
+
### Depth Levels
|
|
29
27
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
- `gemini`: 15-30s, different training data
|
|
28
|
+
| Depth | Engines | Synthesis | Source Fetch | Time | Use When |
|
|
29
|
+
|-------|---------|-----------|--------------|------|----------|
|
|
30
|
+
| `fast` | 1 | ❌ | ❌ | 15-30s | Quick lookup, single perspective |
|
|
31
|
+
| `standard` | 3 | ✅ | ❌ | 30-90s | Default — balanced speed/quality |
|
|
32
|
+
| `deep` | 3 | ✅ | ✅ (top 5) | 60-180s | Research that matters — architecture decisions |
|
|
36
33
|
|
|
37
|
-
|
|
34
|
+
**Standard** (default): Runs 3 engines, deduplicates sources, synthesizes via Gemini.
|
|
35
|
+
**Deep**: Same + fetches content from top sources for grounded synthesis + confidence scores.
|
|
38
36
|
|
|
39
|
-
|
|
37
|
+
### Engine Selection (for fast mode)
|
|
40
38
|
|
|
41
|
-
```
|
|
39
|
+
```greedy_search({ query: "...", engine: "perplexity", depth: "fast" })```
|
|
42
40
|
|
|
43
|
-
|
|
41
|
+
- `perplexity`: Technical Q&A, citations
|
|
42
|
+
- `bing`: Recent news, Microsoft ecosystem
|
|
43
|
+
- `google`: Broad coverage
|
|
44
|
+
- `gemini`: Different training data
|
|
44
45
|
|
|
45
|
-
|
|
46
|
+
### Examples
|
|
47
|
+
|
|
48
|
+
```greedy_search({ query: "what changed in React 19", depth: "fast" })```
|
|
49
|
+
```greedy_search({ query: "best auth patterns for SaaS", depth: "deep" })```
|
|
50
|
+
```greedy_search({ query: "Prisma vs Drizzle 2026", depth: "standard", fullAnswer: true })```
|
|
51
|
+
|
|
52
|
+
### Legacy
|
|
53
|
+
|
|
54
|
+
`deep_research` tool still works — aliases to `greedy_search` with `depth: "deep"`.
|
|
46
55
|
|
|
47
56
|
## coding_task
|
|
48
57
|
|
|
@@ -58,17 +67,17 @@ Browser-based coding assistant via Gemini/Copilot.
|
|
|
58
67
|
| `context` | string | — | Code snippet to include |
|
|
59
68
|
|
|
60
69
|
**Modes:**
|
|
61
|
-
- `debug`:
|
|
62
|
-
- `plan`: Big refactor
|
|
70
|
+
- `debug`: Tricky bugs — fresh eyes catch different failure modes
|
|
71
|
+
- `plan`: Big refactor — plays devil's advocate on risks
|
|
63
72
|
- `review`: High-stakes code review before merge
|
|
64
73
|
- `test`: Edge cases the author missed
|
|
65
74
|
- `code`: Simple generation (but you're probably faster)
|
|
66
75
|
|
|
67
76
|
**When to use:** Second opinions on hard problems. Skip for simple code.
|
|
68
77
|
|
|
69
|
-
##
|
|
78
|
+
## Result Interpretation
|
|
70
79
|
|
|
71
|
-
- **All 3 agree** → High confidence, present as fact
|
|
72
|
-
- **2 agree, 1 differs** → Likely correct, note
|
|
73
|
-
- **
|
|
74
|
-
- **
|
|
80
|
+
- **All 3 engines agree** → High confidence, present as fact
|
|
81
|
+
- **2 agree, 1 differs** → Likely correct, note dissent
|
|
82
|
+
- **Sources [3/3] or [2/3]** → Multiple engines cite, higher confidence
|
|
83
|
+
- **Deep research confidence scores** → Structured confidence metadata
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"success": true,
|
|
3
|
-
"clones": [
|
|
4
|
-
{
|
|
5
|
-
"fileA": "extractors\\gemini.mjs",
|
|
6
|
-
"startA": 63,
|
|
7
|
-
"fileB": "extractors\\perplexity.mjs",
|
|
8
|
-
"startB": 34,
|
|
9
|
-
"lines": 20,
|
|
10
|
-
"tokens": 0
|
|
11
|
-
},
|
|
12
|
-
{
|
|
13
|
-
"fileA": "extractors\\gemini.mjs",
|
|
14
|
-
"startA": 82,
|
|
15
|
-
"fileB": "extractors\\google-ai.mjs",
|
|
16
|
-
"startB": 96,
|
|
17
|
-
"lines": 13,
|
|
18
|
-
"tokens": 0
|
|
19
|
-
},
|
|
20
|
-
{
|
|
21
|
-
"fileA": "extractors\\bing-copilot.mjs",
|
|
22
|
-
"startA": 44,
|
|
23
|
-
"fileB": "extractors\\gemini.mjs",
|
|
24
|
-
"startB": 60,
|
|
25
|
-
"lines": 24,
|
|
26
|
-
"tokens": 0
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
"fileA": "extractors\\bing-copilot.mjs",
|
|
30
|
-
"startA": 67,
|
|
31
|
-
"fileB": "extractors\\google-ai.mjs",
|
|
32
|
-
"startB": 96,
|
|
33
|
-
"lines": 13,
|
|
34
|
-
"tokens": 0
|
|
35
|
-
},
|
|
36
|
-
{
|
|
37
|
-
"fileA": "extractors\\bing-copilot.mjs",
|
|
38
|
-
"startA": 111,
|
|
39
|
-
"fileB": "extractors\\perplexity.mjs",
|
|
40
|
-
"startB": 74,
|
|
41
|
-
"lines": 8,
|
|
42
|
-
"tokens": 0
|
|
43
|
-
},
|
|
44
|
-
{
|
|
45
|
-
"fileA": "extractors\\bing-copilot.mjs",
|
|
46
|
-
"startA": 134,
|
|
47
|
-
"fileB": "extractors\\perplexity.mjs",
|
|
48
|
-
"startB": 85,
|
|
49
|
-
"lines": 7,
|
|
50
|
-
"tokens": 0
|
|
51
|
-
},
|
|
52
|
-
{
|
|
53
|
-
"fileA": "extractors\\bing-copilot.mjs",
|
|
54
|
-
"startA": 151,
|
|
55
|
-
"fileB": "extractors\\perplexity.mjs",
|
|
56
|
-
"startB": 110,
|
|
57
|
-
"lines": 17,
|
|
58
|
-
"tokens": 0
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
"fileA": "test.mjs",
|
|
62
|
-
"startA": 35,
|
|
63
|
-
"fileB": "extractors\\common.mjs",
|
|
64
|
-
"startB": 25,
|
|
65
|
-
"lines": 6,
|
|
66
|
-
"tokens": 0
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
"fileA": "index.ts",
|
|
70
|
-
"startA": 410,
|
|
71
|
-
"fileB": "index.ts",
|
|
72
|
-
"startB": 396,
|
|
73
|
-
"lines": 11,
|
|
74
|
-
"tokens": 0
|
|
75
|
-
},
|
|
76
|
-
{
|
|
77
|
-
"fileA": "index.ts",
|
|
78
|
-
"startA": 573,
|
|
79
|
-
"fileB": "index.ts",
|
|
80
|
-
"startB": 504,
|
|
81
|
-
"lines": 7,
|
|
82
|
-
"tokens": 0
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
"fileA": "index.ts",
|
|
86
|
-
"startA": 601,
|
|
87
|
-
"fileB": "index.ts",
|
|
88
|
-
"startB": 531,
|
|
89
|
-
"lines": 9,
|
|
90
|
-
"tokens": 0
|
|
91
|
-
},
|
|
92
|
-
{
|
|
93
|
-
"fileA": "index.ts",
|
|
94
|
-
"startA": 699,
|
|
95
|
-
"fileB": "index.ts",
|
|
96
|
-
"startB": 36,
|
|
97
|
-
"lines": 15,
|
|
98
|
-
"tokens": 0
|
|
99
|
-
},
|
|
100
|
-
{
|
|
101
|
-
"fileA": "coding-task.mjs",
|
|
102
|
-
"startA": 161,
|
|
103
|
-
"fileB": "coding-task.mjs",
|
|
104
|
-
"startB": 103,
|
|
105
|
-
"lines": 11,
|
|
106
|
-
"tokens": 0
|
|
107
|
-
}
|
|
108
|
-
],
|
|
109
|
-
"duplicatedLines": 148,
|
|
110
|
-
"totalLines": 3187,
|
|
111
|
-
"percentage": 4.64
|
|
112
|
-
}
|