feat(code-review): Send experiment assignment to Seer#107483
Merged
giovanni-guidini merged 2 commits intomasterfrom Feb 5, 2026
Merged
feat(code-review): Send experiment assignment to Seer#107483giovanni-guidini merged 2 commits intomasterfrom
giovanni-guidini merged 2 commits intomasterfrom
Conversation
853d51f to
e4aef30
Compare
vaind
approved these changes
Feb 4, 2026
Add experiment_enabled field to PR review payloads sent to Seer. The field indicates whether an organization is enrolled in code review A/B testing experiments, controlled by the feature flag organizations:code-review-experiments-enabled. Changes: - Add experiment_enabled bool field to SeerCodeReviewRequestForPrReview - Conditionally include experiment_enabled in payload for PR review requests only - Add type annotation to prevent mypy errors when adding bool to dict - Add comprehensive test coverage using @with_feature decorator The field is only included for pr-review request types, not pr-closed, allowing Seer to apply different experimental behaviors based on the assignment. Refs CW-697 Co-Authored-By: Claude <noreply@anthropic.com>
29b7ed2 to
94222de
Compare
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
jaydgoss
pushed a commit
that referenced
this pull request
Feb 12, 2026
## Summary
Adds experiment assignment to code review payloads sent to Seer. This
allows Seer to apply different experimental behaviors (e.g., different
prompts, features) based on whether an organization is enrolled in A/B
testing experiments.
## Changes
- Add `experiment_enabled` field to `SeerCodeReviewRequestForPrReview`
model
- Conditionally include `experiment_enabled` in payload for PR review
requests only (not PR closed)
- Add explicit type annotation to prevent mypy errors
- Add comprehensive test coverage using `@with_feature` decorator
## Implementation Details
The monolith checks the feature flag
`organizations:code-review-experiments-enabled` and includes the boolean
flag in the request payload sent to Seer. The field is only included for
`pr-review` request types, not `pr-closed` events.
**Payload structure:**
```json
{
"request_type": "pr-review",
"external_owner_id": "...",
"data": {
"repo": {...},
"bug_prediction_specific_information": {...},
"config": {...},
"experiment_enabled": true // <-- New field
}
}
```
dcramer
pushed a commit
that referenced
this pull request
Feb 17, 2026
## Summary
Adds experiment assignment to code review payloads sent to Seer. This
allows Seer to apply different experimental behaviors (e.g., different
prompts, features) based on whether an organization is enrolled in A/B
testing experiments.
## Changes
- Add `experiment_enabled` field to `SeerCodeReviewRequestForPrReview`
model
- Conditionally include `experiment_enabled` in payload for PR review
requests only (not PR closed)
- Add explicit type annotation to prevent mypy errors
- Add comprehensive test coverage using `@with_feature` decorator
## Implementation Details
The monolith checks the feature flag
`organizations:code-review-experiments-enabled` and includes the boolean
flag in the request payload sent to Seer. The field is only included for
`pr-review` request types, not `pr-closed` events.
**Payload structure:**
```json
{
"request_type": "pr-review",
"external_owner_id": "...",
"data": {
"repo": {...},
"bug_prediction_specific_information": {...},
"config": {...},
"experiment_enabled": true // <-- New field
}
}
```
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds experiment assignment to code review payloads sent to Seer. This allows Seer to apply different experimental behaviors (e.g., different prompts, features) based on whether an organization is enrolled in A/B testing experiments.
Changes
experiment_enabledfield toSeerCodeReviewRequestForPrReviewmodelexperiment_enabledin payload for PR review requests only (not PR closed)@with_featuredecoratorImplementation Details
The monolith checks the feature flag
organizations:code-review-experiments-enabledand includes the boolean flag in the request payload sent to Seer. The field is only included forpr-reviewrequest types, notpr-closedevents.Payload structure:
{ "request_type": "pr-review", "external_owner_id": "...", "data": { "repo": {...}, "bug_prediction_specific_information": {...}, "config": {...}, "experiment_enabled": true // <-- New field } }Dependencies
Requires: #107478 (CW-696 - feature flag registration)
References
Linear: CW-697