You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(mcp): cora.scan_prepare needs include/exclude, smarter batch ordering and size hints (agent mode is impractical on large repos) #686
cora scan has --include, --exclude, --extensions, --batch-files and --incremental; cora.scan_prepare accepts only path and batch. Together with a path-sorted batch order, this makes agent mode hard to use on a real repository.
scan_prepare with no path returns total_batches: 44 of roughly 60 KB each (about 2.7 MB of prompt text, hundreds of thousands of tokens) with no way to estimate that up front.
Batch 0 is made of CODE_OF_CONDUCT.md, Cargo.toml, six evals/traces/**.meta.json files, a baseline JSON, evals/tier2/*.py ... because files are ordered by path. The core Rust sources land in later batches, so a user who judges the first few batches gets the least valuable code.
The only way to narrow the scope is path (a directory); for this repo the useful batches were found by listing all 11 batches of one subdirectory and choosing by file name.
Proposal
Accept the same selection inputs as the CLI: include, exclude, extensions, batch_files, and incremental (or changed_since: <git rev> which is the natural unit for an agent: "review what changed on this branch").
Order batches by value: source files before docs/data/traces/lockfiles, then by directory depth; or expose order: "path" | "source-first".
Return planning data from every prepare call: total_chars and estimated_tokens for the whole scan, files with sizes per batch, so the agent (or a human) can decide how much to review.
Done when
scan_prepare {"include": ["crates/**/*.rs"], "exclude": ["**/tests/**"]} returns only matching files, reports an estimated total size, and orders source files first.
Activity