ragstrap is a CLI that builds local reference snapshots from GitHub repositories for
RAG workflows. It downloads the repo archive into a references/<name>/raw folder,
records metadata, generates an index.md, and can optionally capture --help output
for Rust CLIs.
uv tool install ragstrapgit clone https://github.com/erichamiter/ragstrap.git
cd ragstrap
uv tool install -e .ragstrap fetch https://github.com/OWNER/REPOOther commands:
ragstrap list
ragstrap info <name>
ragstrap update <name>Common flags:
--name/-n: Name the reference directory (defaults to the repo name).--force/-f: Overwrite an existing reference directory.--capture-cli/--no-capture-cli: Capture CLI help output; auto-enabled for Rust CLIs whenCargo.tomland asrc/main.rs(or[[bin]]) are present.--json: Output machine-readable JSON (supported bylistandinfo).
references/<name>/
meta.json
index.md
raw/...
cli/ (optional help output)
- Python >= 3.9 is required.
- GitHub API rate limits apply; set
GITHUB_TOKENto increase the limit. - CLI capture for Rust runs
cargo build --releaseand requires a Rust toolchain.
