review-hog-authoring
它能做什么
本技能说明如何为 PostHog 的自动化拉取请求审查器编写你自己的审查视角和规则。适合希望审查结果贴合自身代码的团队。
适用场景
- ✓当你想要一个自定义的审查视角,检查拉取请求中某个特定问题时。
- ✓当你想设定哪些审查发现会被发布的标准时。
- ✓当你希望审查器发现你的代码中它目前遗漏的问题时。
技能链接
https://github.com/PostHog/posthog/blob/master/products/review_hog/skills/review-hog-authoring/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请帮我编写一条审查规则,检查我们的拉取请求中数据库查询是否缺少租户检查。”
每周 5 个新技能,1 分钟读完。
工作原理
它会说明审查规则的类型、每条规则如何命名以及应检查什么,还有决定哪些发现会被保留的标准。它会帮助你一次编写一条规则。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Authoring PostHog Review skills
PostHog Review is PostHog's automated PR reviewer. A review splits the PR into chunks, then for each chunk runs every enabled perspective in parallel (independent specialist lenses), a single blind-spot check afterwards (a final sweep conditioned on what the perspectives found), and finally judges every surviving candidate finding against one validation criteria skill — only findings that pass get published to the pull request. After a published review, the resolution stage goes back over the PR's unresolved review threads and judges each against one resolution criteria skill — worth-and-safe asks get implemented on the PR branch, every thread gets a reply.
All four kinds are team LLMSkill rows the review agents pull over MCP at run time. PostHog ships
canonicals; this skill is the guide for authoring custom ones. The skill itself is team-level;
whether it runs is a per-user setting in Inbox → Code review.
| Kind | Name contract | Cardinality per user | Canonical example |
|---|---|---|---|
| Review perspective | review-hog-perspective-<slug> |
Multi-enable, at least one stays on | review-hog-perspective-logic-correctness |
| Blind-spot check | review-hog-blind-spots-<slug> |
Exactly one active; selecting swaps | review-hog-blind-spots-general |
| Validation criteria | review-hog-validation-<slug> |
Exactly one active; selecting swaps | review-hog-validation-criteria |
| Resolution criteria | review-hog-resolution-<slug> |
Exactly one active; selecting swaps | review-hog-resolution-criteria |
Authoring flow
- Ground yourself. Using the PostHog MCP skill tools,
skill-listthe team'sreview-hog-*skills andskill-getthe canonical of the kind you're authoring (see the table above) — it is the reference for structure and tone. For a perspective, skim the descriptions of every existingreview-hog-perspective-*so the new lens doesn't re-cover ground an enabled one already owns (overlap gets deduplicated later, but it wastes review passes). - Interview the user. Ask what the skill should focus on, and offer a few concrete directions the current set doesn't cover — grounded in what you saw in step 1 and, when useful, in the project itself. Don't start writing until the direction is picked.
- Draft the body following the per-kind guidance below. Keep it a focused instruction set the review agent can apply to one chunk in one pass — not an essay.
- Create the skill yourself with
posthog:skill-create— actually create the teamLLMSkillrow; never hand the user a body to copy-paste. Pass the exact name per the contract above (lowercase slug), a one-paragraphdescriptionof what the lens/sweep/bar is, and the body. The name prefix is the whole identity — it is how the Code review tab and the review runs discover the skill. There is nocategoryparameter on the skill tools and you don't need one: the backend stamps thereview_hoggrouping category itself (it only affects grouping on the Skills page) — do not spend turns trying to set or verify it. Iterate withposthog:skill-updateif the user wants changes. Author fresh — don'tskill-duplicatea canonical to edit: seeded metadata rides along with the copy, and the canonical sync may overwrite or prune it. - Tell the user how to activate it. A custom skill starts inactive for them:
- Perspective — toggle it on under Inbox → Code review → Perspectives (it appears disabled until they enable it; at least one perspective must stay on).
- Blind-spot check / validation criteria / resolution criteria — select it under the matching section; exactly one runs at a time, so selecting it swaps out the current one for their reviews only. Reviews pin skill versions when a run starts, so an edit mid-review applies from the next run.
Writing a review perspective
The body instructs one specialist review pass over one PR chunk. Match the canonical logic-correctness skill's shape:
- The lane — one sentence on what this lens is responsible for; report everything in lane and leave the rest to the other perspectives.
- **Hunting ground
常见问题
什么是视角?
视角是一种专业的审查角度,例如安全或逻辑,它会与其他视角并行审查拉取请求的每个部分。
自定义规则总是开启的吗?
规则按用户单独开启,并且至少必须保留一个视角为开启状态。
编写规则需要写代码吗?
规则以说明的形式编写,描述应检查代码的哪些内容。
详情
作者的原始描述
How to author custom PostHog Review skills: the review perspectives, blind-spot checks, validation criteria, and resolution criteria that drive PostHog Review's automated PR reviews. Use when a user wants a new review perspective (a specialist lens on their PRs), a custom blind-spot sweep, their own validation bar for which findings get published, or their own bar for which review comments get implemented. Trigger on "create a PostHog Review perspective", "custom review perspective", "my own blind-spot check", "custom validation criteria", "custom resolution criteria", "tune what PostHog Revie
repo: PostHog/posthog
热度
- GitHub 星标
- 41k
- 排名
- #6913
- 许可证
- —
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
depot-ci
41k帮你的智能体设置并运行 Depot CI 工作流(GitHub Actions 的替代方案),包括迁移现有工作流和读取运行日志。
depot-container-builds
41k帮你的智能体在 Depot 的远程构建器上构建 Docker 镜像,包括多平台镜像、推送到镜像仓库,以及修复构建失败。
depot-github-runners
41k帮你的智能体把 GitHub Actions 任务迁移到 Depot 托管的运行器上,选择运行器规格和标签,并排查运行器设置问题。
editing-agents-md
41k帮你的智能体判断某条规则应写入 AGENTS.md 还是 CLAUDE.md,并以不会让文件臃肿的方式写下,确保规则真正生效。