Code Review Bot Dashboard
An AI-powered code review dashboard for real GitHub pull requests. Paste a PR URL, inspect the actual changed files, stream an SDK-powered review over the real PR diff, and copy or optionally post the generated review.
Getting started
Install dependencies:
bun install
bun run build:sdk
Set an API key:
export CLINE_API_KEY="cline_..."
Optionally set a GitHub token. Public PRs can be loaded without one, but a token is recommended for private repositories and higher rate limits:
export GITHUB_TOKEN="github_pat_..."
Run the dashboard:
bun dev
Open http://localhost:3457, paste a GitHub pull request URL, and click Run Review.
By default the app copies the generated review to your clipboard. To allow posting a summary comment back to GitHub, run with both GITHUB_TOKEN and:
export ENABLE_GITHUB_REVIEW_POSTING=1
What it does
- Fetches a real GitHub PR, including metadata, changed files, patches, and check status
- Renders the PR in a dashboard with file navigation, diff view, review lanes, and finding cards
- Sends the real PR diff to an agent with three custom tools:
get_file_context- reads full file contents from the PR head commit for surrounding contextadd_review_finding- records a structured finding with file, line, severity, category, and suggestionsubmit_review- a completion tool that ends the run with a summary and approve/request-changes decision
- Streams findings to the browser via Server-Sent Events as the agent reviews the PR
- Copies the final review locally, or posts it as a GitHub PR comment when explicitly enabled
Concepts demonstrated
- Multiple
createTooldefinitions with zod schemas lifecycle: { completesRun: true }to make a tool end the agent loop- Rich
systemPromptwith structured instructions - Event subscription filtered by tool name
- GitHub REST API integration for pull request metadata and diffs
- Server-Sent Events (SSE) for a live review dashboard
- Guarded external writes through an explicit posting opt-in
Notes
For a simpler starting point, see quickstart. For an interactive chat agent, see cli-agent.
