scoutline 0.15.0 → 0.16.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.
Files changed (41) hide show
  1. package/README.md +68 -11
  2. package/dist/capabilities/repository.d.ts +96 -0
  3. package/dist/capabilities/repository.d.ts.map +1 -1
  4. package/dist/capabilities/repository.js.map +1 -1
  5. package/dist/commands/cache.d.ts +38 -0
  6. package/dist/commands/cache.d.ts.map +1 -1
  7. package/dist/commands/cache.js +64 -5
  8. package/dist/commands/cache.js.map +1 -1
  9. package/dist/commands/config.d.ts +17 -1
  10. package/dist/commands/config.d.ts.map +1 -1
  11. package/dist/commands/config.js +25 -2
  12. package/dist/commands/config.js.map +1 -1
  13. package/dist/commands/repo.d.ts +96 -1
  14. package/dist/commands/repo.d.ts.map +1 -1
  15. package/dist/commands/repo.js +420 -0
  16. package/dist/commands/repo.js.map +1 -1
  17. package/dist/commands/search.d.ts +150 -0
  18. package/dist/commands/search.d.ts.map +1 -1
  19. package/dist/commands/search.js +368 -27
  20. package/dist/commands/search.js.map +1 -1
  21. package/dist/index.d.ts +199 -0
  22. package/dist/index.d.ts.map +1 -1
  23. package/dist/index.js +352 -20
  24. package/dist/index.js.map +1 -1
  25. package/dist/lib/cache.d.ts +111 -7
  26. package/dist/lib/cache.d.ts.map +1 -1
  27. package/dist/lib/cache.js +316 -7
  28. package/dist/lib/cache.js.map +1 -1
  29. package/dist/lib/config-store.d.ts +51 -1
  30. package/dist/lib/config-store.d.ts.map +1 -1
  31. package/dist/lib/config-store.js +90 -6
  32. package/dist/lib/config-store.js.map +1 -1
  33. package/dist/lib/url.d.ts +43 -0
  34. package/dist/lib/url.d.ts.map +1 -0
  35. package/dist/lib/url.js +172 -0
  36. package/dist/lib/url.js.map +1 -0
  37. package/dist/providers/selection.d.ts +21 -0
  38. package/dist/providers/selection.d.ts.map +1 -1
  39. package/dist/providers/selection.js +58 -0
  40. package/dist/providers/selection.js.map +1 -1
  41. package/package.json +1 -1
@@ -23,8 +23,57 @@
23
23
  * before reaching the Explorer rather than silently degrading.
24
24
  */
25
25
  import type { CommandContext, CommandResult } from "../command-invocation.js";
26
- import type { RepositoryCapability } from "../capabilities/repository.js";
26
+ import type { RepositoryBrief, RepositoryCapability, RepositoryTreeResult, RepoBriefFocus } from "../capabilities/repository.js";
27
27
  import type { ExecutionDependencies } from "../lib/execution.js";
28
+ /**
29
+ * Sealed v1 probe set. Opening the set later is additive — do NOT
30
+ * mutate this constant at runtime.
31
+ */
32
+ export declare const REPO_BRIEF_FOCUS: readonly RepoBriefFocus[];
33
+ /**
34
+ * Probe query constants per DESIGN D7. These are NOT constructed at
35
+ * call time — they are literal constants so the brief's evidence
36
+ * chain (search.query inside the envelope) is reproducible byte-for-
37
+ * byte across providers and reruns.
38
+ */
39
+ export declare const README_QUERY = "README";
40
+ export declare const MANIFEST_QUERY = "package.json pyproject.toml Cargo.toml go.mod";
41
+ /**
42
+ * Pure tree-derived file selection (DESIGN D1 / D7 steps 5–8). The
43
+ * tree is the path inventory — search excerpts carry no paths, so
44
+ * file selection MUST be tree-derived. The returned `manifests` array
45
+ * is in canonical kind order; `readme` is the single shallowest
46
+ * README match. Non-file entries (directories) are ignored even when
47
+ * their `name` happens to look like a README/manifest.
48
+ */
49
+ export declare function selectBriefFiles(tree: RepositoryTreeResult): {
50
+ readme?: string;
51
+ manifests: string[];
52
+ };
53
+ /**
54
+ * Parse the `--focus` flag value. Splits on `,`, trims, drops empties,
55
+ * validates against the sealed `REPO_BRIEF_FOCUS` set, dedupes
56
+ * preserving first occurrence, and rejects empty-after-processing.
57
+ *
58
+ * The error message names the sealed set so a consumer can fix the
59
+ * value without consulting docs (DESIGN D7 step 3).
60
+ */
61
+ export declare function parseBriefFocus(raw: string): readonly RepoBriefFocus[];
62
+ /**
63
+ * Parse the `--depth` flag value. Positive integer (≥ 1); `undefined`
64
+ * means "unset — use the Explorer's default". Accepts only numbers and
65
+ * numeric strings (CLI parses flags as strings); every other runtime
66
+ * type — booleans, null, objects — is rejected BEFORE coercion so a
67
+ * `true` can never ride `Number(true) === 1` past validation.
68
+ */
69
+ export declare function parseBriefDepth(raw: unknown): number | undefined;
70
+ /**
71
+ * Parse the `--max-chars` flag value. Positive integer (≥ 1);
72
+ * `undefined` means "unset — use the Explorer's default upper bound".
73
+ * Same runtime-type gate as `parseBriefDepth`: only numbers and numeric
74
+ * strings are coerced.
75
+ */
76
+ export declare function parseBriefMaxChars(raw: unknown): number | undefined;
28
77
  export interface RepoSearchOptions {
29
78
  language?: "en" | "zh";
30
79
  maxChars?: number;
@@ -39,6 +88,25 @@ export interface RepoReadOptions {
39
88
  maxChars?: number;
40
89
  noCache?: boolean;
41
90
  }
91
+ export interface RepoBriefOptions {
92
+ /**
93
+ * Requested focus, a subset of the sealed `REPO_BRIEF_FOCUS` set, in
94
+ * caller order. Omitted defaults to all four. Non-empty; each token
95
+ * must be a sealed member (DESIGN D7 step 3). Duplicate tokens are
96
+ * collapsed preserving first occurrence, matching `parseBriefFocus`,
97
+ * so direct handler callers cannot smuggle duplicates into the
98
+ * envelope's `focus` field.
99
+ */
100
+ focus?: readonly RepoBriefFocus[];
101
+ /** Tree-only scope (DESIGN D3: search/read have no path parameter). */
102
+ path?: string;
103
+ /** Tree-only depth; defaults to the Explorer's default (1). */
104
+ depth?: number;
105
+ /** Per-call search/read budget; tree is never character-limited. */
106
+ maxChars?: number;
107
+ /** Bypasses the response cache for every probe. */
108
+ noCache?: boolean;
109
+ }
42
110
  /**
43
111
  * Dependencies injected by `src/index.ts` after Provider selection,
44
112
  * capability support check, configuration check, Adapter
@@ -49,6 +117,14 @@ export interface RepoReadOptions {
49
117
  export interface RepoHandlerDependencies {
50
118
  readonly capability: RepositoryCapability;
51
119
  readonly execution: ExecutionDependencies;
120
+ /**
121
+ * Invocation-resolved credential values used to redact failed-probe
122
+ * error messages. Injected by `src/index.ts` already resolved from
123
+ * the invocation's env (including injected credentials absent from
124
+ * ambient `process.env`). Omitted → the ambient `configuredSecrets()`
125
+ * fallback, mirroring `invokeCommand`'s output/error boundary.
126
+ */
127
+ readonly secrets?: readonly string[];
52
128
  }
53
129
  /**
54
130
  * Repository Search. Validates parse-level request shape, delegates
@@ -69,5 +145,24 @@ export declare function repoTree(repo: string, options: RepoTreeOptions, deps: R
69
145
  * and returns the normalized File result as base data.
70
146
  */
71
147
  export declare function repoRead(repo: string, path: string, options: RepoReadOptions, deps: RepoHandlerDependencies, _context?: CommandContext): Promise<CommandResult>;
148
+ /**
149
+ * Repository Brief. Composes the three Explorer operations into one
150
+ * schema-version-1 envelope (DESIGN D2/D3/D4). Fixed probe order:
151
+ * tree → search("README") → search(manifest names) → read loop (README
152
+ * first, then manifests in canonical kind order, cap 4 total reads).
153
+ *
154
+ * Parse-level validation (DESIGN D7): `validateRepo`, `--depth` and
155
+ * `--max-chars` positive integers, `--focus` a non-empty subset of the
156
+ * sealed set (default all four). Forwarding (DESIGN D3): `--no-cache`
157
+ * to every call; `--max-chars` to searches/reads only (the tree is
158
+ * never character-limited); `--depth`/`--path` to the tree only.
159
+ *
160
+ * Every Explorer call runs settled (DESIGN D6): a throw becomes a
161
+ * `failed` probe record and the brief continues. Exit policy: ≥1 probe
162
+ * `ok` → `{kind: "data"}` (exit 0); every probe terminal and failed →
163
+ * the last error is rethrown so the executor routes it through the
164
+ * standard stderr boundary (exit 1).
165
+ */
166
+ export declare function repoBrief(repo: string, options: RepoBriefOptions, deps: RepoHandlerDependencies, _context?: CommandContext): Promise<CommandResult<RepositoryBrief>>;
72
167
  export declare const REPO_HELP: string;
73
168
  //# sourceMappingURL=repo.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"repo.d.ts","sourceRoot":"","sources":["../../src/commands/repo.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAC9E,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAA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UxB;AAwFD;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAsB,SAAS,CAC7B,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE,gBAAgB,EACzB,IAAI,EAAE,uBAAuB,EAC7B,QAAQ,CAAC,EAAE,cAAc,GACxB,OAAO,CAAC,aAAa,CAAC,eAAe,CAAC,CAAC,CAuLzC;AAcD,eAAO,MAAM,SAAS,QAsFd,CAAC"}
@@ -25,6 +25,7 @@
25
25
  import { OUTPUT_MODES } from "../lib/output.js";
26
26
  import { explorerSearch, explorerReadFile, explorerTree } from "./repository-explorer.js";
27
27
  import { ValidationError } from "../lib/errors.js";
28
+ import { configuredSecrets, redactCredentialString } from "../lib/redact.js";
28
29
  // ---------------------------------------------------------------------------
29
30
  // Parse-level validation
30
31
  // ---------------------------------------------------------------------------
@@ -40,6 +41,179 @@ function validateRepo(repo) {
40
41
  }
41
42
  }
42
43
  // ---------------------------------------------------------------------------
44
+ // Repository Brief — constants and pure helpers (DESIGN D1, D7; SCHEMA.md)
45
+ //
46
+ // These helpers are exported for unit testing and are pure (no I/O,
47
+ // no Provider, no env). The handler composition in `repoBrief` is a
48
+ // separate ticket that wires them into the Explorer envelope.
49
+ // ---------------------------------------------------------------------------
50
+ /**
51
+ * Sealed v1 probe set. Opening the set later is additive — do NOT
52
+ * mutate this constant at runtime.
53
+ */
54
+ export const REPO_BRIEF_FOCUS = [
55
+ "structure",
56
+ "readme",
57
+ "manifest",
58
+ "files",
59
+ ];
60
+ /**
61
+ * Probe query constants per DESIGN D7. These are NOT constructed at
62
+ * call time — they are literal constants so the brief's evidence
63
+ * chain (search.query inside the envelope) is reproducible byte-for-
64
+ * byte across providers and reruns.
65
+ */
66
+ export const README_QUERY = "README";
67
+ export const MANIFEST_QUERY = "package.json pyproject.toml Cargo.toml go.mod";
68
+ /**
69
+ * Canonical manifest-kind priority order (DESIGN D7 step 8). The
70
+ * README, when present, is always selected first; manifests follow in
71
+ * this exact order, capped so total reads ≤ 4.
72
+ */
73
+ const MANIFEST_KIND_ORDER = [
74
+ "package.json",
75
+ "pyproject.toml",
76
+ "Cargo.toml",
77
+ "go.mod",
78
+ ];
79
+ /** Hard cap on total read probes (1 README + up to 3 manifests). */
80
+ const BRIEF_READ_CAP = 4;
81
+ /** README basename pattern per DESIGN D7 step 6 (case-insensitive). */
82
+ const README_BASENAME_RE = /^readme(?:\.[a-z0-9]+)?$/i;
83
+ /**
84
+ * Compute the depth (number of segments past root) of a
85
+ * repository-relative POSIX path. Root (`""`) has depth 0; `"a/b"`
86
+ * has depth 2; `"a"` has depth 1.
87
+ */
88
+ function pathDepth(path) {
89
+ if (path.length === 0)
90
+ return 0;
91
+ // For non-empty paths the depth IS the segment count returned by
92
+ // split("/").length — no subtraction: the root ("") already returned
93
+ // 0 above, so "a" → 1 and "a/b" → 2, matching the JSDoc.
94
+ return path.split("/").length;
95
+ }
96
+ /** Last segment of a repository-relative POSIX path (basename). */
97
+ function basenameOf(path) {
98
+ const segments = path.split("/");
99
+ return segments[segments.length - 1] ?? "";
100
+ }
101
+ /**
102
+ * Pick the winning entry for a given match predicate using D7's
103
+ * selection rule: minimum depth; ties broken by first occurrence in
104
+ * (snapshot order, then entry order) — i.e. BFS / provider order,
105
+ * which is stable for a given Provider response.
106
+ *
107
+ * The predicate is invoked with `(path, basename, kind)`; non-file
108
+ * entries (directories) are filtered out before the predicate runs.
109
+ */
110
+ function selectWinnerByDepth(tree, predicate) {
111
+ let best;
112
+ for (const snapshot of tree.snapshots) {
113
+ for (const entry of snapshot.entries) {
114
+ if (entry.kind !== "file")
115
+ continue;
116
+ if (!predicate(entry.path, basenameOf(entry.path), entry.kind))
117
+ continue;
118
+ const depth = pathDepth(entry.path);
119
+ if (best === undefined || depth < best.depth) {
120
+ best = { path: entry.path, depth };
121
+ }
122
+ }
123
+ }
124
+ return best ? { path: best.path } : undefined;
125
+ }
126
+ /**
127
+ * Pure tree-derived file selection (DESIGN D1 / D7 steps 5–8). The
128
+ * tree is the path inventory — search excerpts carry no paths, so
129
+ * file selection MUST be tree-derived. The returned `manifests` array
130
+ * is in canonical kind order; `readme` is the single shallowest
131
+ * README match. Non-file entries (directories) are ignored even when
132
+ * their `name` happens to look like a README/manifest.
133
+ */
134
+ export function selectBriefFiles(tree) {
135
+ const readme = selectWinnerByDepth(tree, (_path, basename) => README_BASENAME_RE.test(basename));
136
+ const manifests = [];
137
+ for (const kind of MANIFEST_KIND_ORDER) {
138
+ if (manifests.length + (readme ? 1 : 0) >= BRIEF_READ_CAP)
139
+ break;
140
+ const winner = selectWinnerByDepth(tree, (_path, basename) => basename === kind);
141
+ if (winner)
142
+ manifests.push(winner.path);
143
+ }
144
+ return {
145
+ ...(readme ? { readme: readme.path } : {}),
146
+ manifests,
147
+ };
148
+ }
149
+ /**
150
+ * Parse the `--focus` flag value. Splits on `,`, trims, drops empties,
151
+ * validates against the sealed `REPO_BRIEF_FOCUS` set, dedupes
152
+ * preserving first occurrence, and rejects empty-after-processing.
153
+ *
154
+ * The error message names the sealed set so a consumer can fix the
155
+ * value without consulting docs (DESIGN D7 step 3).
156
+ */
157
+ export function parseBriefFocus(raw) {
158
+ const tokens = raw
159
+ .split(",")
160
+ .map((t) => t.trim())
161
+ .filter((t) => t.length > 0);
162
+ if (tokens.length === 0) {
163
+ throw new ValidationError("--focus must include at least one of: structure, readme, manifest, files");
164
+ }
165
+ const seen = new Set();
166
+ const out = [];
167
+ for (const token of tokens) {
168
+ if (!REPO_BRIEF_FOCUS.includes(token)) {
169
+ throw new ValidationError(`Unknown --focus value "${token}". Allowed: ${REPO_BRIEF_FOCUS.join(", ")}`);
170
+ }
171
+ const focus = token;
172
+ if (seen.has(focus))
173
+ continue;
174
+ seen.add(focus);
175
+ out.push(focus);
176
+ }
177
+ return out;
178
+ }
179
+ /**
180
+ * Parse the `--depth` flag value. Positive integer (≥ 1); `undefined`
181
+ * means "unset — use the Explorer's default". Accepts only numbers and
182
+ * numeric strings (CLI parses flags as strings); every other runtime
183
+ * type — booleans, null, objects — is rejected BEFORE coercion so a
184
+ * `true` can never ride `Number(true) === 1` past validation.
185
+ */
186
+ export function parseBriefDepth(raw) {
187
+ if (raw === undefined)
188
+ return undefined;
189
+ if (typeof raw !== "number" && typeof raw !== "string") {
190
+ throw new ValidationError("--depth must be a positive integer");
191
+ }
192
+ const value = typeof raw === "number" ? raw : Number(raw);
193
+ if (!Number.isFinite(value) || !Number.isInteger(value) || value < 1) {
194
+ throw new ValidationError("--depth must be a positive integer");
195
+ }
196
+ return value;
197
+ }
198
+ /**
199
+ * Parse the `--max-chars` flag value. Positive integer (≥ 1);
200
+ * `undefined` means "unset — use the Explorer's default upper bound".
201
+ * Same runtime-type gate as `parseBriefDepth`: only numbers and numeric
202
+ * strings are coerced.
203
+ */
204
+ export function parseBriefMaxChars(raw) {
205
+ if (raw === undefined)
206
+ return undefined;
207
+ if (typeof raw !== "number" && typeof raw !== "string") {
208
+ throw new ValidationError("--max-chars must be a positive integer");
209
+ }
210
+ const value = typeof raw === "number" ? raw : Number(raw);
211
+ if (!Number.isFinite(value) || !Number.isInteger(value) || value < 1) {
212
+ throw new ValidationError("--max-chars must be a positive integer");
213
+ }
214
+ return value;
215
+ }
216
+ // ---------------------------------------------------------------------------
43
217
  // Handlers — thin wrappers over the Explorer
44
218
  // ---------------------------------------------------------------------------
45
219
  /**
@@ -82,6 +256,234 @@ export async function repoRead(repo, path, options, deps, _context) {
82
256
  const result = await explorerReadFile(deps.capability, { repository: repo, path }, { noCache: options.noCache, maxChars: options.maxChars }, deps.execution);
83
257
  return { kind: "data", data: result };
84
258
  }
259
+ /**
260
+ * Run one Explorer call inside the settled wrapper (DESIGN D6): a throw
261
+ * becomes a `failed` probe record (stable code + redacted message) and
262
+ * the brief continues. On success the probe is recorded `ok`.
263
+ */
264
+ async function settleProbe(probes, kind, label, fn, secrets) {
265
+ try {
266
+ const value = await fn();
267
+ probes.push({ kind, label, status: "ok" });
268
+ return { ok: true, value };
269
+ }
270
+ catch (error) {
271
+ probes.push({ kind, label, status: "failed", error: probeErrorInfo(error, secrets) });
272
+ return { ok: false, error };
273
+ }
274
+ }
275
+ /**
276
+ * Derive the stable code + redacted message for a probe failure record.
277
+ * Mirrors the standard stderr boundary (`formatErrorOutput`): a shaped
278
+ * error's `code` string is preserved, everything else falls back to
279
+ * `UNKNOWN_ERROR`; the message is redacted against the invocation's
280
+ * resolved credentials (threaded via `RepoHandlerDependencies.secrets`
281
+ * so injected-environment credentials absent from ambient `process.env`
282
+ * are still covered) so no credential-shaped substring leaks into the
283
+ * envelope.
284
+ */
285
+ function probeErrorInfo(error, secrets) {
286
+ const code = error !== null &&
287
+ typeof error === "object" &&
288
+ typeof error.code === "string"
289
+ ? error.code
290
+ : "UNKNOWN_ERROR";
291
+ const rawMessage = error instanceof Error ? error.message : String(error);
292
+ return { code, message: redactCredentialString(rawMessage, [...secrets]) };
293
+ }
294
+ /**
295
+ * Tree-derived structural signals (SCHEMA.md `RepoBriefDetected`). Every
296
+ * field is `null` when the tree probe failed or was focus-excluded —
297
+ * never guessed from search excerpts. `manifestKinds` lists every
298
+ * present kind in canonical order, independent of the 4-read selection
299
+ * cap (the cap is a read-budget, not a detection signal).
300
+ */
301
+ function detectBriefSignals(tree) {
302
+ let hasReadme = false;
303
+ for (const snapshot of tree.snapshots) {
304
+ for (const entry of snapshot.entries) {
305
+ if (entry.kind !== "file")
306
+ continue;
307
+ if (README_BASENAME_RE.test(basenameOf(entry.path))) {
308
+ hasReadme = true;
309
+ }
310
+ }
311
+ }
312
+ const manifestKinds = [];
313
+ for (const kind of MANIFEST_KIND_ORDER) {
314
+ const winner = selectWinnerByDepth(tree, (_path, basename) => basename === kind);
315
+ if (winner)
316
+ manifestKinds.push(kind);
317
+ }
318
+ return {
319
+ hasReadme,
320
+ hasManifest: manifestKinds.length > 0,
321
+ manifestKinds,
322
+ };
323
+ }
324
+ /**
325
+ * Repository Brief. Composes the three Explorer operations into one
326
+ * schema-version-1 envelope (DESIGN D2/D3/D4). Fixed probe order:
327
+ * tree → search("README") → search(manifest names) → read loop (README
328
+ * first, then manifests in canonical kind order, cap 4 total reads).
329
+ *
330
+ * Parse-level validation (DESIGN D7): `validateRepo`, `--depth` and
331
+ * `--max-chars` positive integers, `--focus` a non-empty subset of the
332
+ * sealed set (default all four). Forwarding (DESIGN D3): `--no-cache`
333
+ * to every call; `--max-chars` to searches/reads only (the tree is
334
+ * never character-limited); `--depth`/`--path` to the tree only.
335
+ *
336
+ * Every Explorer call runs settled (DESIGN D6): a throw becomes a
337
+ * `failed` probe record and the brief continues. Exit policy: ≥1 probe
338
+ * `ok` → `{kind: "data"}` (exit 0); every probe terminal and failed →
339
+ * the last error is rethrown so the executor routes it through the
340
+ * standard stderr boundary (exit 1).
341
+ */
342
+ export async function repoBrief(repo, options, deps, _context) {
343
+ validateRepo(repo);
344
+ // Bind the parsed values: the VALIDATED (coerced) numbers are what
345
+ // every probe receives — a direct caller's numeric string never leaks
346
+ // downstream as a string.
347
+ const depth = parseBriefDepth(options.depth);
348
+ const maxChars = parseBriefMaxChars(options.maxChars);
349
+ const focus = options.focus === undefined ? [...REPO_BRIEF_FOCUS] : [...new Set(options.focus)];
350
+ if (focus.length === 0) {
351
+ throw new ValidationError("--focus must include at least one of: structure, readme, manifest, files");
352
+ }
353
+ for (const token of focus) {
354
+ if (!REPO_BRIEF_FOCUS.includes(token)) {
355
+ throw new ValidationError(`Unknown --focus value "${token}". Allowed: ${REPO_BRIEF_FOCUS.join(", ")}`);
356
+ }
357
+ }
358
+ const wantsStructure = focus.includes("structure");
359
+ const wantsReadme = focus.includes("readme");
360
+ const wantsManifest = focus.includes("manifest");
361
+ const wantsFiles = focus.includes("files");
362
+ const probes = [];
363
+ let lastError = undefined;
364
+ // Invocation-resolved credentials for failed-probe redaction. Direct
365
+ // handler callers that omit `deps.secrets` get the ambient fallback
366
+ // (same posture as `invokeCommand`'s error boundary).
367
+ const secrets = deps.secrets ?? configuredSecrets();
368
+ // Probe 1: tree — always runs (read-path selection and `detected`
369
+ // both derive from it; DESIGN D1).
370
+ const treeProbe = await settleProbe(probes, "tree", "tree", () => explorerTree(deps.capability, { repository: repo, path: options.path, depth }, { noCache: options.noCache }, deps.execution), secrets);
371
+ if (!treeProbe.ok)
372
+ lastError = treeProbe.error;
373
+ // Probe 2: search("README") — only under `readme` focus.
374
+ let docs;
375
+ if (wantsReadme) {
376
+ const probe = await settleProbe(probes, "search", "search:readme", () => explorerSearch(deps.capability, { repository: repo, query: README_QUERY }, { noCache: options.noCache, maxChars }, deps.execution), secrets);
377
+ if (probe.ok)
378
+ docs = probe.value;
379
+ else
380
+ lastError = probe.error;
381
+ }
382
+ else {
383
+ probes.push({
384
+ kind: "search",
385
+ label: "search:readme",
386
+ status: "skipped",
387
+ reason: "focus-excluded",
388
+ });
389
+ }
390
+ // Probe 3: search(manifest names) — only under `manifest` focus.
391
+ let entryPoints;
392
+ if (wantsManifest) {
393
+ const probe = await settleProbe(probes, "search", "search:manifest", () => explorerSearch(deps.capability, { repository: repo, query: MANIFEST_QUERY }, { noCache: options.noCache, maxChars }, deps.execution), secrets);
394
+ if (probe.ok)
395
+ entryPoints = probe.value;
396
+ else
397
+ lastError = probe.error;
398
+ }
399
+ else {
400
+ probes.push({
401
+ kind: "search",
402
+ label: "search:manifest",
403
+ status: "skipped",
404
+ reason: "focus-excluded",
405
+ });
406
+ }
407
+ // Probe 4: read loop — only under `files` focus, using Ticket 1's
408
+ // deterministic tree-derived selection (DESIGN D1/D7 steps 5-8).
409
+ const files = [];
410
+ if (wantsFiles) {
411
+ if (treeProbe.ok) {
412
+ const selection = selectBriefFiles(treeProbe.value);
413
+ const readPaths = [];
414
+ if (selection.readme !== undefined)
415
+ readPaths.push(selection.readme);
416
+ readPaths.push(...selection.manifests);
417
+ if (readPaths.length === 0) {
418
+ // The stage was requested but the tree-derived selection is
419
+ // empty (no README, no manifest): record the terminal
420
+ // `read:<files>` sentinel so a focus-requested read stage ALWAYS
421
+ // ends in a read record (SCHEMA: probes is total over requested
422
+ // stages). `no-selection` distinguishes this from focus-excluded
423
+ // and dependency-failed.
424
+ probes.push({
425
+ kind: "read",
426
+ label: "read:<files>",
427
+ status: "skipped",
428
+ reason: "no-selection",
429
+ });
430
+ }
431
+ for (const path of readPaths) {
432
+ const probe = await settleProbe(probes, "read", `read:${path}`, () => explorerReadFile(deps.capability, { repository: repo, path }, { noCache: options.noCache, maxChars }, deps.execution), secrets);
433
+ if (probe.ok) {
434
+ files.push({
435
+ path: probe.value.path,
436
+ content: probe.value.content,
437
+ truncated: probe.value.truncated,
438
+ originalContentLength: probe.value.originalContentLength,
439
+ });
440
+ }
441
+ else {
442
+ lastError = probe.error;
443
+ }
444
+ }
445
+ }
446
+ else {
447
+ // The tree failed; read selection has no path inventory to run
448
+ // against, so the files probe is recorded as dependency-failed.
449
+ probes.push({
450
+ kind: "read",
451
+ label: "read:<files>",
452
+ status: "skipped",
453
+ reason: "dependency-failed",
454
+ });
455
+ }
456
+ }
457
+ else {
458
+ probes.push({
459
+ kind: "read",
460
+ label: "read:<files>",
461
+ status: "skipped",
462
+ reason: "focus-excluded",
463
+ });
464
+ }
465
+ // Exit policy (DESIGN D6): ≥1 probe `ok` → data (exit 0), because
466
+ // degradations are data in `coverage`, not stderr noise. Otherwise
467
+ // rethrow the last error so the executor surfaces it via the standard
468
+ // stderr boundary (exit 1).
469
+ if (!probes.some((p) => p.status === "ok")) {
470
+ throw lastError;
471
+ }
472
+ const brief = {
473
+ schemaVersion: 1,
474
+ repository: repo,
475
+ focus,
476
+ coverage: { probes },
477
+ ...(wantsStructure && treeProbe.ok ? { tree: treeProbe.value } : {}),
478
+ ...(wantsReadme && docs !== undefined ? { docs } : {}),
479
+ ...(wantsManifest && entryPoints !== undefined ? { entryPoints } : {}),
480
+ ...(wantsFiles && files.length > 0 ? { files } : {}),
481
+ detected: treeProbe.ok
482
+ ? detectBriefSignals(treeProbe.value)
483
+ : { hasReadme: null, hasManifest: null, manifestKinds: null },
484
+ };
485
+ return { kind: "data", data: brief };
486
+ }
85
487
  // ---------------------------------------------------------------------------
86
488
  // Help
87
489
  // ---------------------------------------------------------------------------
@@ -101,6 +503,7 @@ Commands:
101
503
  search <owner/repo> <query> Search docs and code in repository
102
504
  tree <owner/repo> Get repository directory structure
103
505
  read <owner/repo> <path> Read a file from repository
506
+ brief <owner/repo> Compose tree + search + read into one envelope
104
507
 
105
508
  Search Options:
106
509
  --language <lang> Result language: en (default) or zh
@@ -113,6 +516,15 @@ Tree Options:
113
516
  Read Options:
114
517
  --max-chars <n> Truncate file content to <n> chars
115
518
 
519
+ Brief Options:
520
+ --focus <list> Subset of: structure, readme, manifest, files
521
+ (default: all four; comma-separated, order preserved)
522
+ --path <path> Tree scope (search/read have no path parameter)
523
+ --depth <n> Tree traversal depth (default: 1)
524
+ --max-chars <n> Per-call search/read character budget (forwarded
525
+ to every search and read probe; the tree is
526
+ never character-limited)
527
+
116
528
  Common Options:
117
529
  --no-cache Bypass the response cache for this invocation
118
530
  --provider <id> Override the active Provider (zai | minimax | tavily | exa)
@@ -137,6 +549,12 @@ Output format (intentional schema-version-1 migration):
137
549
  originalContentLength}
138
550
  - tree: {schemaVersion, repository, path, depth,
139
551
  snapshots:[{repository, path, entries:[{name, path, kind}]}]}
552
+ - brief: {schemaVersion, repository, focus, coverage:{probes},
553
+ tree?, docs?, entryPoints?, files?, detected:{hasReadme,
554
+ hasManifest, manifestKinds}} (sections gated by --focus;
555
+ coverage.probes records every probe attempt as ok/failed/
556
+ skipped). Tree is never character-limited; --max-chars
557
+ applies per call to searches and reads only.
140
558
  Root path is the empty string "". --max-chars applies only to
141
559
  search/read content; tree is never character-limited.
142
560
  Output modes for repo results:
@@ -153,6 +571,8 @@ Examples:
153
571
  scoutline repo tree vercel/next.js --path packages --depth 2
154
572
  scoutline repo read anthropics/anthropic-sdk-python src/anthropic/client.py
155
573
  scoutline repo read facebook/react README.md --max-chars 3000
574
+ scoutline repo brief facebook/react
575
+ scoutline repo brief facebook/react --focus structure,readme
156
576
  scoutline --provider minimax repo search ow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