跳到正文
Skillpedia
分析与电子表格41k · #6882

scanning-experiments-with-replay-vision

它能做什么

本技能设置一个自动扫描器,审查某个实验的会话录制,并比较其各个变体。适合希望了解用户在每个变体中实际做了什么的团队。

适用场景

  • ✓当你希望对正在运行的实验的录制内容进行自动审查时。
  • ✓当你希望比较用户在每个变体中的行为,而无需逐个观看录制的时候。
  • ✓当你想在开启扫描器之前,先在几次真实会话上预览其提示词的时候。

技能链接

https://github.com/PostHog/posthog/blob/master/products/experiments/skills/scanning-experiments-with-replay-vision/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/PostHog/posthog/blob/master/products/experiments/skills/scanning-experiments-with-replay-vision/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请观看我的入职实验的录制内容,告诉我每个变体有何不同。”

每周 5 个新技能,1 分钟读完。

工作原理

它会创建一个与实验曝光用户相关联的扫描器,均匀地对每个变体进行抽样,并在实验结束时停止。该扫描器创建时处于禁用状态,因此你可以先检查其提示词。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Scanning experiments with Replay Vision

The job: "I'm running an experiment. Watch the recordings and tell me what's actually happening in each variant."

A Replay Vision scanner is a standing LLM probe over session recordings (see [[creating-replay-vision-scanners]] for the general mechanics). The experiment scanner type is built for this job, so use it rather than scoping another type to an experiment:

  • The population is the experiment's exposed people, derived server-side from the experiment instead of a hand-built filter.
  • Each session's variant comes from the exposure data, never from the model. The model is told what the experiment changes, but not the session's variant, so it describes what the recording shows.
  • Variants are sampled evenly, so a 90/10 rollout still gives the small variant enough observations to compare.
  • Scanning stops when the experiment ends, and pauses while it is paused.
  • Results split by variant with no join: vision-scanners-variants-list and the observations variant filter.

This skill covers what is experiment-specific; the generic create and size mechanics stay in the parent skill.

The flow: resolve the experiment → write the config → size it → create disabled → preview the prompt on a few real sessions → let the user enable it → read the results per variant.

Step 1: Resolve the experiment

experiment-get returns everything needed: the linked feature_flag (its filters.multivariate.variants list is the source of truth for variant keys; parameters.feature_flag_variants can be stale), exposure_criteria, start_date, end_date, and status. If the user didn't identify the experiment, resolve it via [[finding-experiments]] rather than guessing.

Guards before doing anything else:

  • Draft (no start_date): there are no exposures and nothing to scan. The API refuses an experiment scanner for an experiment that hasn't launched. Say so and stop.
  • Ended: a new scanner sweeps only from creation onward, and it stops at the end date, so it scans nothing new. Cover the run with a backfill (see Limits).
  • Running or exposure-frozen: proceed. A frozen experiment stops enrolling, but already-exposed users keep producing sessions, so scanning stays useful.
  • Already half over: the scanner watches only the remaining run unless you backfill. Say so, so a per-variant readout isn't mistaken for full-run coverage.

Step 2: Write the config

The experiment lives in scanner_config, next to the prompt:

{
  "prompt": "Focus on how the user moves through checkout after the payment step first appears: where they hesitate, retry, or leave.",
  "experiment_id": 123,
  "variants": null,
  "balance_variants": true
}
  • experiment_id: the experiment from Step 1. It is fixed once the scanner exists; watching a different experiment means a new scanner.
  • variants: the variant keys to watch, or null for every variant. Default to null, one scanner for the whole experiment. A comparison needs every variant, and one scanner keeps one prompt version across them (see Limits on version skew). Narrow it only when the user asks to watch some variants.
  • balance_variants (default true): one sampling rate per variant, so each gets roughly equal coverage for the same spend. Leave it on for comparisons.
  • length (optional): short, medium (the default) or long, as for a summarizer.

The API owns the exposure filter and its access control. It resolves the same exposed-person population the experiment's Recordings tab shows. The filter is person-scoped, so it covers people whose exposure fired server-side or in an earlier session. Don't build event or property filters for exposure; the API rejects an experiment_exposure set directly inside query, and it checks access to the experiment, so a scanner can only reach an experiment its editor can view.

Keep query for non-exposure filters only. Set filter_test_accounts to exposure_criteria.filterTestAccounts ?? true, the same rule every experiment surface uses. When the experiment omits the setting, use true. Keep an explicit false, because that is an intentional opt-out. A minimal query is enough:

{ "kind": "RecordingsQuery", "filter_test_accounts": true }

Add other recording filters (duration, console errors, a specific page) only when the user asks. No date_from/date_to: the scanner strips them on save, because its 5-minute swe

常见问题

扫描器会决定某次会话属于哪个变体吗?

不会。变体信息来自曝光数据,因此模型只描述录制内容所显示的情况。

为什么要均匀抽样各个变体?

这样即使较小的变体也能获得足够的会话,以便与较大的变体进行比较。

这会消耗积分吗?

会。在开启扫描器之前,本技能会根据实验自身的用户数量估算积分消耗。

详情

作者的原始描述

Provisions a Replay Vision `experiment` scanner, which watches one experiment's exposed sessions, records each session's variant, samples the variants evenly, and stops when the experiment ends. Covers status guards, a prompt that stays comparable across variants, sizing credit spend against the experiment's own population, creating it disabled so its prompt can be previewed on real sessions, and reading the results per variant. TRIGGER when: user wants Replay Vision to watch an experiment, asks to scan or analyze an experiment's recordings with AI, asks \"what are users actually doing in the

repo: PostHog/posthog

热度

GitHub 星标
41k
排名
#6882
许可证
—
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能