AI-powered code review for diffs
Sight provides intelligent code review capabilities by analyzing diffs with AI. It understands context, identifies issues, and suggests improvements.
Sight reviews source changes, diffs, dependency structure, and static-analysis
results. It does not crawl or audit a running website. Browser or deployed-URL
auditing belongs to inspect; Hawk is responsible for composing results when a
workflow needs both source review and live-target verification.
Sight is a Hawk support engine. Keep the dependency edge one-way:
- use
hawk-core-contractsfor any cross-repo shared contracts (severity/finding vocabulary) - do not import
hawk/internal/* - do not import removed legacy path
hawk/shared/types; usehawk-core-contracts/types - do not import other engines (
eyrie,yaad,tok,trace,inspect) — engines are peers, not dependencies
- Diff-aware analysis - Reviews only changed code with full context
- Severity classification - Categorizes findings by impact
- Provider agnostic - Works with any LLM provider through the
Providerinterface - Extensible rules - Add custom review rules for your codebase
go get github.com/GrayCodeAI/sightimport "github.com/GrayCodeAI/sight"
reviewer := sight.NewReviewer(
sight.WithProvider(myLLMProvider),
sight.Thorough,
)
result, err := reviewer.Review(ctx, diff)
for _, f := range result.Findings {
fmt.Printf("[%s] %s:%d - %s\n", f.Severity, f.File, f.Line, f.Message)
}See the examples/ directory for runnable code samples.
Implement the Provider interface to use any LLM:
type Provider interface {
Chat(ctx context.Context, messages []Message, opts ChatOpts) (*Response, error)
}go get github.com/GrayCodeAI/sight@latestRequires Go 1.26+.
Contributions are welcome — please read CONTRIBUTING.md before opening a pull request.
MIT - see LICENSE for details.