StampHog
A GitHub-label-triggered PR approval agent that applies fail-closed deterministic safety gates, asks an LLM to check for showstoppers, autonomously approves eligible changes, and refuses or escalates the rest.
- Company
- PostHog
- Approach type
- Agent
- Work
- Code review
- Human involvement
- Autonomous
- Invocation
- Background, Event-driven
- Interfaces
- Github, Ci
- Deployment stage
- Scaled
- Evidence strength
- Detailed primary
- Entry reviewed
How it works
stamphog-labeled pull request through gates, bot wait, LLM review, and verdict.
An engineer adds the stamphog label to a non-draft pull request and the GitHub Action runs the review pipeline[Source 1, Source 3]
The run waits up to five minutes for allowlisted reviewer-bot reviews to finish and returns WAIT with the label kept when one is still in flight[Source 3]
Claude reads the diff, repository files, discussion timeline, and reviewer signals to look for production breakage, security issues, and missed dependencies[Source 2, Source 3]
Eligible changes can be approved while risky, ambiguous, or insufficiently assured changes are refused or escalated to a suitable human reviewer[Source 1, Source 3]
An approval is posted once as the StampHog app and counts toward branch protection; every other verdict updates one sticky comment with its reason and next steps[Source 1, Source 3]
Where people stay involved
People review, approve, or guide the agent’s work here.
Supervision level
Exception-only
A person returns when the system raises an exception.
Level 5 of 5
- eligible pull request → approval decision[Source 1]
Implementation details
- Model
- Claude through the Claude Agent SDK, with Read, Grep, and Glob tools[Source 3]
- Harness
- A GitHub Action invokes a Python pipeline that fetches and classifies a PR, applies hard gates, waits for in-flight reviewer bots, runs an LLM review, and posts a verdict[Source 3]
- Sandbox
- Not reportedThe pinned README documents the GitHub Action host and the reviewer's Read, Grep, and Glob tools but no isolation boundary for a run.
- Tool access
- Reads the diff and repository files plus trusted review-state, discussion, ownership, and reviewer signals[Source 3]
- Knowledge
- Repository-specific deny categories, size and risk tiers calibrated from prior human approvals, review guidance, and ownership data[Source 3]
- Context management
- Each run emits a versioned JSON evidence bundle retained as a CI artifact for 30 days; a sticky GitHub comment carries non-approval verdict history and labels preserve retry state[Source 3]
- Credentials
- A dedicated Anthropic organization secret and a StampHog GitHub App token whose approvals satisfy branch protection[Source 3]
- Interfaces
- github
- ci
Mechanisms
Each run records PR metadata, classification, gate results, reviewer output, and the final verdict[Source 3]
Validation and failure handling
Draft state, conflicts, requested changes, sensitive paths, size ceilings, and risk tiers can block AI approval; the LLM may tighten but never loosen a gate[Source 3]
Reported observations
These results come from the sources. Notes below each result explain what it covers and any reported limits.
Handled 1,600 PRs in the previous month, as reported on July 9, 2026; roughly one in three merged main-repository PRs received its final approval during the reported quarter[Source 1]
- Reported by
- PostHog
- Scope
- Monthly PRs handled autonomously and quarterly final approvals in the main repository
- Denominator
- Merged main-repository PRs for the quarterly share; absolute handled PRs for the monthly count
- Method
- Company-reported production usage
Observed in July 2026
About this result
- Category
- Adoption output
- Evidence type
- Reported measurement
- What it covers
- StampHog-handled PRs per month and main-repository merged-PR approval share per quarter
20% of PRs approved by StampHog in the July 28, 2026 report, at approximately $300 per month in tokens[Source 2]
- Reported by
- PostHog
- Scope
- PostHog PRs approved by StampHog and monthly token cost in the July 28, 2026 report
- Denominator
- PostHog PRs in the report's scope
- Method
- Company-reported production usage and token spend
Observed in July 2026
About this result
- Category
- Adoption output
- Evidence type
- Reported measurement
- What it covers
- PostHog PRs approved by StampHog and its monthly token cost
Lessons
StampHog's deterministic eligibility gates remain authoritative; its model reviewer can impose stricter conditions but cannot relax those gates.[Source 3]
PostHog calibrated StampHog's thresholds and deny categories against repository history, including small changes with sensitive effects.[Source 3]
StampHog withholds approval on backend errors or pending reviewer-bot work and retains its label so a later push can retry.[Source 3]