Sift the repo.
Keep the signal.
sift walks a project directory, ranks files by git relevance, and renders one LLM-ready context document. Token budgeting, secret redaction, and signature-only compression are built in.
Noise stays gray and drops out. Everything else gets ranked, then rendered full or as signatures until the budget runs out.
Context curation is the bottleneck
Three ways teams feed code to models today — and why each breaks down.
- Raw concatenation doesn't rank. Piping every file into a prompt ships vendored code, lockfiles, build output, and secrets — unranked and over budget.
- A cloud service sees your code. Hosted context tools charge per seat and upload your repository. sift is a local MIT-licensed binary; nothing leaves your machine.
- Hand-picking doesn't scale. Choosing files by hand stops working past a dozen. Git-relevance ranking re-curates on every run, for free.
One document, ranked and trimmed to fit
Two ideas do the heavy lifting; four more handle the details.
Git-relevance ranking
Modified files first, then recent diffs, then recent commits — weighted with churn and import fan-in, so the files you actually touched lead the document.
Signature compression
--mode signatures keeps declarations and doc comments via tree-sitter and drops function bodies — the full structure at a fraction of the tokens.
Token budgets
Set --budget and sift keeps the highest-priority files inside your model's context window.
Secret redaction
AWS, GitHub, Slack, Google, and Stripe keys are redacted before anything renders. On by default.
Interactive picker
A dual-pane TUI with per-file FULL/SIGS/SKIP modes, smart-select, and task prompts.
Incremental deltas
sift delta renders only what changed since your last dump, as full files or a raw patch.
Seven ways to generate the document
Run sift --help or
sift <command> --help for the full flag list.
siftLaunch the interactive picker (bare invocation)sift dump [path]Render every eligible file in the treesift pick [path]Select files interactively, then rendersift select [path]Auto-select the most useful files and render themsift diff [ref]Render only files changed relative to a git refsift delta [path]Render only changes since the last recorded dumpsift watch [path]Re-render the document whenever files changeInstall in one line
macOS and Linux: