:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
chore(agents): require the exact model in PR agent context (#100427)
Raúl Negrón-Otero4d7afb0597d2
diff --git a/.agents/skills/writing-pr-descriptions/SKILL.md b/.agents/skills/writing-pr-descriptions/SKILL.mdindex ef23e811a1e8..35326907ad29 100644--- a/.agents/skills/writing-pr-descriptions/SKILL.md+++ b/.agents/skills/writing-pr-descriptions/SKILL.md@@ -171,7 +171,7 @@ Everything under them is evidence and provenance, and a reviewer reaches it lastWhen the lower half outgrows the upper half, cut the lower half.- Testing: name the regression each new test catches, under the claim rules above. Transcripts go in a `<details>` block.-- Agent context: autonomy, tools, skills invoked, and what changed across the session.+- Agent context: autonomy, tool and exact model, skills invoked, and what changed across the session.- The reason your design beats the obvious alternative belongs in Changes. A reviewer needs it to review, and nobody scrolls past the changelog checkbox to find it.The test: **the body must come out shorter than your first draft.** Pass 5 checks it.@@ -255,7 +255,7 @@ A "no" anywhere means the body is ordered for the writer, not the reader. Go bac14. Does prose compare several values across the same dimensions? Replace it with a table.15. Does every claim about what you ran, measured or saw link its evidence, or say it went unchecked? Descriptions of behavior need no link.16. Did a `<!-- -->` template comment survive anywhere? That section is unfilled. Fill it or delete it.-17. Is the `## 🤖 Agent context` section filled, listing the skills invoked?+17. Is the `## 🤖 Agent context` section filled, naming the exact model and listing the skills invoked?18. Does the body claim manual testing that did not happen? Delete it.19. Does the body name an internal customer, incident, Slack quote, or operational metric? This repo is public. Delete it.diff --git a/.github/pull_request_template.md b/.github/pull_request_template.mdindex a171fd8c850b..9b07020cc30b 100644--- a/.github/pull_request_template.md+++ b/.github/pull_request_template.md@@ -45,6 +45,10 @@**Autonomy:** Human-driven (agent-assisted) - or - Fully autonomous+<!-- Name the tool and the exact model, e.g. "Claude Code, Opus 5". List each model if more than one wrote code. -->++**Agent:** tool, model+<!-- Definition of done (agents): not done until each gate below holds. Verify against the named artifact or skill — don't assume. Add gates as the PR touches more areas.- No duplicate: when this PR fixes something believed to be live on master, no open PR already fixes it. A broken master attracts parallel agents, so search before opening — `gh pr list --state open --search "<keywords>" --limit 20`, which lists drafts too, and most agent PRs start as drafts. Say here which PR you found and why this one is still needed, or that the search found nothing.- Patch coverage: the lines this PR changed are covered, or the uncovered ones are justified under "How did you test this code?". Don't pad untouched code to lift the number. Check the "🧪 Backend test coverage" PR comment (and its patch-coverage artifact).@@ -52,7 +56,7 @@--><!-- Keep this short: 1-3 short paragraphs or a handful of bullets — not an exhaustive log. Include:- - tools/agent used and link to session. List the agent and tool names used, but do not include tool call results.+ - link to session and the tool names used, but do not include tool call results.- skills invoked: always explicitly call out any repo-provided or public skills (e.g. /django-migrations, /improving-drf-endpoints) that were invoked while producing this PR. This helps reviewers judge where and how the code was shaped by an agent.- CodeRabbit CLI pass: each finding and its disposition (fixed, or rejected with the reason), or that the CLI was unavailable and the PR opened without a local pass. The findings only appeared in the terminal, so this is their only record.- decisions made along the way: what changed across the session. The reason the shipped design beats the obvious alternative goes in Changes instead, where a reviewer will actually see it.diff --git a/AGENTS.md b/AGENTS.mdindex 7af39f25aba9..d61944878763 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -63,7 +63,7 @@ Examples:**Required:** Read `.github/pull_request_template.md` and use its exact section structure. Do not invent a different format.Invoke `/writing-pr-descriptions` before writing the body — it carries the shape rules.-Always fill the `## 🤖 Agent context` section.+Always fill the `## 🤖 Agent context` section, including the exact model that wrote the code.NEVER put sensitive information in a PR description or comment. A user may share sensitive data in an agent session; none of it belongs on the PR.**Screenshots:** Upload frontend/visual changes with `hogli pr:upload-image <file>` and embed the printed markdown. The first run only warns and uploads nothing; re-run with `--yes` to confirm. Only PostHog employees can upload, but the public can permanently view these assets, so only upload the image if you're certain it doesn't contain customer data (including customer names), secrets, or sensitive internal info.