Expand description
rs-guard — AI-powered code review CLI for GitHub Pull Requests.
This crate provides the core functionality for fetching PR diffs, sending them to an LLM for review, parsing structured verdicts, and submitting review states back to GitHub.
§Modules
cache— LLM response caching with SHA-256 keyed entriescli— Command-line argument parsingconfig— Environment and configuration resolutiondiff— PR diff fetching (GitHub API and local git)error— Unified error typesgithub— GitHub review submission and dismissalhttp— Shared HTTP utilities and URL validationllm— LLM provider abstraction and implementationsoutput— Terminal output and artifact writingpipeline— Orchestration of the full review workflowredact— Secret redaction and content filteringretry— Transient failure retry logic and circuit breakerverdict— Verdict parsing and review state determination
Modules§
- cache
- Response caching for LLM results.
- cli
- CLI argument definitions using
clapderive macros. - config
- Configuration resolution from environment variables, TOML file, and CLI arguments.
- diff
- Diff fetching from GitHub Pull Requests and local git staging.
- error
- Error types for the rs-guard application.
- github
- GitHub API interaction for submitting reviews and dismissing stale blockers.
- http
- Shared HTTP utilities for GitHub API communication.
- llm
- LLM provider abstraction and shared types.
- output
- Terminal output formatting and review artifact writing.
- pipeline
- Pipeline orchestration and result types.
- redact
- Secret redaction and content filtering.
- retry
- Retry logic for transient API failures.
- verdict
- Verdict parsing and review state determination.