GitHub - v1r3n/dinesh-gilfoyle: What if Dinesh and Gilfoyle reviewed your code? · GitHub
/" data-turbo-transient="true" />
Skip to content
Search or jump to...
Search code, repositories, users, issues, pull requests...
-->
Search
Clear
Search syntax tips
Provide feedback
--><br>We read every piece of feedback, and take your input very seriously.
Include my email address so I can be contacted
Cancel
Submit feedback
Saved searches
Use saved searches to filter your results more quickly
-->
Name
Query
To see all available qualifiers, see our documentation.
Cancel
Create saved search
Sign in
/;ref_cta:Sign up;ref_loc:header logged out"}"<br>Sign up
Appearance settings
Resetting focus
You signed in with another tab or window. Reload to refresh your session.<br>You signed out in another tab or window. Reload to refresh your session.<br>You switched accounts on another tab or window. Reload to refresh your session.
Dismiss alert
{{ message }}
v1r3n
dinesh-gilfoyle
Public
Notifications<br>You must be signed in to change notification settings
Fork<br>15
Star<br>186
main
BranchesTags
Go to file
CodeOpen more actions menu
Folders and files<br>NameNameLast commit message<br>Last commit date<br>Latest commit
History<br>17 Commits<br>17 Commits
.claude
.claude
.codex
.codex
.cursor
.cursor
.opencode
.opencode
.windsurf
.windsurf
cursor
cursor
dg
dg
docs
docs
windsurf
windsurf
LICENSE
LICENSE
README.md
README.md
View all files
Repository files navigation
/dg
/dg is an adversarial code review skill for your coding agent, inspired by the Dinesh-Gilfoyle dynamic from HBO's Silicon Valley.
How it works
When you run /dg, your agent doesn't just do a standard code review. Instead, it spins up two independent AI agents — one playing Gilfoyle, one playing Dinesh — and makes them argue about your code.
Gilfoyle goes first. He reviews your code with the deadpan, withering precision of a systems engineer who considers bad code a moral failing. He finds the real issues — security vulnerabilities, architectural rot, performance problems — and delivers them wrapped in devastating commentary.
Then Dinesh gets his turn. He defends the code like his reputation depends on it (because it does). He concedes when Gilfoyle is genuinely right — grudgingly — but pushes back hard when the criticism is unfair. He cites constraints, context, and documentation that Gilfoyle conveniently ignored.
They go back and forth. Round after round, until one of them runs out of new things to say, or you decide you've heard enough. The debate is adaptive — it keeps going as long as new issues are being surfaced, with a default cap of 5 rounds.
When it's over, you get an actionable summary: what to fix, what's actually fine, and the funniest exchanges from the banter. Because code review shouldn't be a chore.
Why this works: When Dinesh can't defend a point, that's a confirmed issue — not a "maybe." When he successfully defends, the code has been validated under pressure, which is stronger than any "LGTM." The adversarial tension surfaces things a single reviewer would miss.
Installation
curl -sL https://v1r3n.github.io/dinesh-gilfoyle/install.sh | bash
That's it. The installer auto-detects which coding agents you have — Claude Code, Codex, OpenCode, Cursor, Windsurf — and sets up /dg for each one.
Start a new session and type /dg. If Gilfoyle insults your code, you're good.
Usage
/dg Review your git diff<br>/dg 3 Git diff, max 3 rounds<br>/dg src/auth.ts Review a specific file<br>/dg src/auth.ts 3 Specific file, 3 rounds max
The Debate
Gilfoyle attacks — Reviews the code with devastating technical precision. Finds security issues, bugs, architectural flaws. Scans dependencies for known CVEs. Delivers findings in character.
Dinesh defends — Responds to each critique. Concedes real issues (grudgingly), pushes back on unfair criticism, dismisses nitpicks.
Repeat — They go back and forth until no new issues are raised, Dinesh concedes everything, or the round cap is hit.
Verdict — A structured summary categorizes every issue by who won the argument, plus a clean checklist of what to actually fix.
Comic strip — Optionally generates an HTML comic strip of the best moments, with SVG character avatars and speech bubbles. Can be attached directly to a PR.
What It Checks
This isn't a surface-level linter. Both agents review across seven deep technical domains:
Security — Hardcoded credentials, PII exposure, injection attacks (SQL, command, template), buffer overflows, auth/authz gaps, OWASP Top 10. Gilfoyle also runs a dependency vulnerability scan using native audit tools (npm audit, pip audit, govulncheck, cargo audit, etc.) with fallback to the OSV.dev API and NVD for CVE details.
Database — Missing indexes, N+1 query patterns, connection pooling issues, missing transactions, schema problems, queries that work at 1K rows but die at 1M.
Distributed Systems — Missing retry logic and backoff, no idempotency, no circuit...