: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(replay-vision): finish the quality to calibration rename (#75713)
Arno Hillendfc2d27e9ac3
diff --git a/products/replay_vision/backend/api/observations.py b/products/replay_vision/backend/api/observations.pyindex cdf03938a223..2c3222419b14 100644--- a/products/replay_vision/backend/api/observations.py+++ b/products/replay_vision/backend/api/observations.py@@ -958,7 +958,7 @@ class ReplayObservationViewSet("created_by": user,},)- # The core quality/calibration signal: thumbs up/down on whether the scanner got the session right.+ # The core calibration signal: thumbs up/down on whether the scanner got the session right.report_user_action(user,"replay_vision_observation_rated",diff --git a/products/replay_vision/backend/feedback_themes.py b/products/replay_vision/backend/feedback_themes.pyindex 0ad569a7adaf..65f369c6ffa9 100644--- a/products/replay_vision/backend/feedback_themes.py+++ b/products/replay_vision/backend/feedback_themes.py@@ -1,7 +1,7 @@"""Summarize the team's written thumbs-down feedback into recurring failure modes.Themes are cached on the scanner (`ReplayScanner.feedback_themes`) and shown as chips on the-Quality tab, so raters know what to look for. They also feed the prompt-suggestion generation+calibration tab, so raters know what to look for. They also feed the prompt-suggestion generationcontext, so the rewrite attacks the failure modes the team keeps reporting."""diff --git a/products/replay_vision/backend/prompt_suggestions.py b/products/replay_vision/backend/prompt_suggestions.pyindex 6fd4b309df5c..9d9854f232e1 100644--- a/products/replay_vision/backend/prompt_suggestions.py+++ b/products/replay_vision/backend/prompt_suggestions.py@@ -2,7 +2,7 @@Mirrors the frontend "Improve scanner prompt" message: the current prompt plus the rated sessions(thumbs down with feedback to fix, thumbs up to keep passing), handed to Gemini for a structured-rewrite. Suggestions are persisted so the Quality tab can show the current one and its history.+rewrite. Suggestions are persisted so the calibration tab can show the current one and its history."""import json@@ -591,7 +591,7 @@ def generate_prompt_suggestion(base_config = dict(scanner.scanner_config or {})distinct_id = str(user.uuid) if user else f"replay-vision-scanner-{scanner.id}"try:- # Fresh themes feed the briefing below and the Quality tab's chips; stale ones beat none.+ # Fresh themes feed the briefing below and the calibration tab's chips; stale ones beat none.refresh_feedback_themes_if_stale(scanner, distinct_id=distinct_id)except Exception:logger.exception("replay_vision.feedback_themes.refresh_failed", scanner_id=str(scanner.id))diff --git a/products/replay_vision/frontend/observations/ObservationLabelControl.tsx b/products/replay_vision/frontend/observations/ObservationLabelControl.tsxindex 57970a48add1..03d1e695a998 100644--- a/products/replay_vision/frontend/observations/ObservationLabelControl.tsx+++ b/products/replay_vision/frontend/observations/ObservationLabelControl.tsx@@ -66,7 +66,7 @@ function FeedbackEditor({}/**- * Feedback cell for the quality table: optional written context on a rated observation (thumbs up or down).+ * Feedback cell for the calibration table: optional written context on a rated observation (thumbs up or down).* Collapses to a truncated one-liner until clicked, so only the row being edited grows. Unrated rows* show a hint to rate first, since feedback lives on the shared label.*/diff --git a/products/replay_vision/mcp/tools.yaml b/products/replay_vision/mcp/tools.yamlindex dcd445e01fa1..ff182d02fde9 100644--- a/products/replay_vision/mcp/tools.yaml+++ b/products/replay_vision/mcp/tools.yaml@@ -113,8 +113,8 @@ tools:Set or update the shared thumbs up/down rating on a replay scanner observation: `is_correct` true means thescanner got the session right (thumbs up), false means it got it wrong (thumbs down), plus optional written`feedback` explaining why (applies to both directions). One shared rating per observation, team-wide, last- write wins; re-posting updates it in place. These ratings power the scanner's Quality tab: the- quality-over-time chart and the AI prompt recommendations (see+ write wins; re-posting updates it in place. These ratings power the scanner's calibration tab: the+ ratings-over-time chart and the AI prompt recommendations (see`vision-scanners-prompt-suggestions-generate`). Find observation IDs via `vision-scanners-observations-list`(filter `labeled=false` for unrated ones) or `vision-observations-list` for a session.feature_flag: replay-visiondiff --git a/services/mcp/schema/generated-tool-definitions.json b/services/mcp/schema/generated-tool-definitions.jsonindex 29c27e1a248b..306e2ce4dc4b 100644--- a/services/mcp/schema/generated-tool-definitions.json+++ b/services/mcp/schema/generated-tool-definitions.json@@ -9799,7 +9799,7 @@"feature_flag": "replay-vision"},"vision-observations-label-create": {- "description": "Set or update the shared thumbs up/down rating on a replay scanner observation: `is_correct` true means the scanner got the session right (thumbs up), false means it got it wrong (thumbs down), plus optional written `feedback` explaining why (applies to both directions). One shared rating per observation, team-wide, last write wins; re-posting updates it in place. These ratings power the scanner's Quality tab: the quality-over-time chart and the AI prompt recommendations (see `vision-scanners-prompt-suggestions-generate`). Find observation IDs via `vision-scanners-observations-list` (filter `labeled=false` for unrated ones) or `vision-observations-list` for a session.",+ "description": "Set or update the shared thumbs up/down rating on a replay scanner observation: `is_correct` true means the scanner got the session right (thumbs up), false means it got it wrong (thumbs down), plus optional written `feedback` explaining why (applies to both directions). One shared rating per observation, team-wide, last write wins; re-posting updates it in place. These ratings power the scanner's calibration tab: the ratings-over-time chart and the AI prompt recommendations (see `vision-scanners-prompt-suggestions-generate`). Find observation IDs via `vision-scanners-observations-list` (filter `labeled=false` for unrated ones) or `vision-observations-list` for a session.","category": "Replay vision","feature": "replay_vision","summary": "Rate a scanner observation",diff --git a/services/mcp/schema/tool-definitions-all.json b/services/mcp/schema/tool-definitions-all.jsonindex 3127d798f907..733ff1982a10 100644--- a/services/mcp/schema/tool-definitions-all.json+++ b/services/mcp/schema/tool-definitions-all.json@@ -10439,7 +10439,7 @@"feature_flag": "replay-vision"},"vision-observations-label-create": {- "description": "Set or update the shared thumbs up/down rating on a replay scanner observation: `is_correct` true means the scanner got the session right (thumbs up), false means it got it wrong (thumbs down), plus optional written `feedback` explaining why (applies to both directions). One shared rating per observation, team-wide, last write wins; re-posting updates it in place. These ratings power the scanner's Quality tab: the quality-over-time chart and the AI prompt recommendations (see `vision-scanners-prompt-suggestions-generate`). Find observation IDs via `vision-scanners-observations-list` (filter `labeled=false` for unrated ones) or `vision-observations-list` for a session.",+ "description": "Set or update the shared thumbs up/down rating on a replay scanner observation: `is_correct` true means the scanner got the session right (thumbs up), false means it got it wrong (thumbs down), plus optional written `feedback` explaining why (applies to both directions). One shared rating per observation, team-wide, last write wins; re-posting updates it in place. These ratings power the scanner's calibration tab: the ratings-over-time chart and the AI prompt recommendations (see `vision-scanners-prompt-suggestions-generate`). Find observation IDs via `vision-scanners-observations-list` (filter `labeled=false` for unrated ones) or `vision-observations-list` for a session.","category": "Replay vision","feature": "replay_vision","summary": "Rate a scanner observation",