Skip to content

Add tone_variant A/B campaign to breaking-change-checker workflow#42597

Merged
pelikhan merged 4 commits into
mainfrom
copilot/ab-advisor-experiment-tone-variant
Jul 1, 2026
Merged

Add tone_variant A/B campaign to breaking-change-checker workflow#42597
pelikhan merged 4 commits into
mainfrom
copilot/ab-advisor-experiment-tone-variant

Conversation

Copilot AI commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

This updates breaking-change-checker to run an A/B experiment on reporting tone (neutral vs urgent) without changing breaking-change detection logic. The campaign metadata and prompt conditionals were added so tone can be assigned at runtime and compared against engagement and guardrail metrics.

  • Experiment frontmatter

    • Added experiments.tone_variant in rich-object form with:
      • variants, description, hypothesis
      • metric, secondary_metrics
      • guardrail_metrics (run_success_rate, empty_output_rate)
      • min_samples, weight, start_date, issue
  • Prompt-body tone branching

    • Added variant-aware handlebars conditionals in the issue-generation instructions:
      • tone guidance block (urgent vs neutral)
      • Summary -> Status line (Requires Immediate Review vs Review Recommended)
      • Recommendations wording (prioritized risk/action framing vs neutral guidance)
  • Compiled workflow output

    • Regenerated breaking-change-checker.lock.yml from the markdown workflow so runtime experiment selection and outputs reflect the new campaign.
{{#if experiments.tone_variant == "urgent" }}
- **Status**: ⚠️ Requires Immediate Review
{{else}}
- **Status**: Review Recommended
{{/if}}

Copilot AI and others added 2 commits July 1, 2026 01:08
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Add A/B test for tone variant in breaking change checker Add tone_variant A/B campaign to breaking-change-checker workflow Jul 1, 2026
Copilot AI requested a review from pelikhan July 1, 2026 01:24
@pelikhan pelikhan marked this pull request as ready for review July 1, 2026 01:25
Copilot AI review requested due to automatic review settings July 1, 2026 01:25
@pelikhan

pelikhan commented Jul 1, 2026

Copy link
Copy Markdown
Collaborator

@copilot check conditional syntax

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an A/B experiment (experiments.tone_variant) to the breaking-change-checker workflow so the issue-reporting prompt can branch between neutral and urgent tone variants while keeping breaking-change detection logic unchanged.

Changes:

  • Introduces experiments.tone_variant frontmatter metadata (variants, hypothesis, metrics, guardrails, sampling/weighting, tracking issue).
  • Adds variant-aware handlebars conditionals to adjust tone guidance and issue template fields (Status + Recommendations wording).
  • Regenerates breaking-change-checker.lock.yml to include runtime experiment selection, persistence, and prompt substitutions.
Show a summary per file
File Description
.github/workflows/pr-code-quality-reviewer.lock.yml Unrelated gh-aw metadata hash churn included in this PR (does not support the stated PR purpose).
.github/workflows/breaking-change-checker.md Adds the tone_variant experiment configuration and prompt-body tone branching.
.github/workflows/breaking-change-checker.lock.yml Updates compiled workflow to pick/restore/persist experiment state and pass tone variant into prompt substitution.

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 3/3 changed files
  • Comments generated: 1
  • Review effort level: Low

@@ -1,4 +1,4 @@
# gh-aw-metadata: {"schema_version":"v4","frontmatter_hash":"0a7a1cc9a9d3e316b42d163c8f7452df59e96a2dd1056a07170aca6d955bd9ca","body_hash":"4b304b423080e4bab9d72281c704a8436fe09fa92cf666fe179d4681a922d405","strict":true,"agent_id":"copilot","engine_versions":{"copilot":"1.0.65","copilot-sdk":"1.0.4"}}
# gh-aw-metadata: {"schema_version":"v4","frontmatter_hash":"0a7a1cc9a9d3e316b42d163c8f7452df59e96a2dd1056a07170aca6d955bd9ca","body_hash":"3741a05e0a954d005c6a5d50b7567b198260ad61d940646d75c20b3b923c1606","strict":true,"agent_id":"copilot","engine_versions":{"copilot":"1.0.65","copilot-sdk":"1.0.4"}}
@github-actions

github-actions Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

🤖 PR Triage — §28486872548

Field Value
Category feature
Risk medium
Score 28 / 100
Priority low
Action defer

Score breakdown: Impact 15/50 · Urgency 5/30 · Quality 8/20

Batch: draft-wip (PRs #42595, #42596, #42597)

Rationale: WIP/Draft A/B tone experiment for breaking-change checker. Low urgency, no reviews yet. Should be completed and marked ready before further review.

Labels applied: pr-type:feature pr-risk:medium pr-priority:low pr-action:defer pr-batch:draft-wip pr-agent:copilot-swe-agent

Generated by 🔧 PR Triage Agent · 77.2 AIC · ⌖ 9.82 AIC · ⊞ 1.6K ·

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>

Copilot AI commented Jul 1, 2026

Copy link
Copy Markdown
Contributor Author

@copilot check conditional syntax

Fixed in df78190.

@pelikhan pelikhan merged commit 30b3a15 into main Jul 1, 2026
@pelikhan pelikhan deleted the copilot/ab-advisor-experiment-tone-variant branch July 1, 2026 01:45
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

github-actions Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Hey @app/copilot-swe-agent 👋 — nice work setting up the tone_variant A/B campaign! The experiment frontmatter is well-structured (hypothesis, guardrail metrics, min_samples, 50/50 weight) and the handlebars branching in the prompt body is clean and readable.

A couple of things to tighten up before this lands:

  • Add tests for the tone branching — the new {{#if experiments.tone_variant == 'urgent'}} conditionals in breaking-change-checker.md aren't covered by any test changes. At minimum, consider adding snapshot or render tests that exercise both the urgent and neutral paths and assert the correct Status line and Recommendations wording appears in each case.
  • Explain the pr-code-quality-reviewer.lock.yml body-hash change — the diff touches that file (only the body_hash in the metadata comment changes; no corresponding .md source file is modified). This looks like it may be a stale or incidental recompilation artifact. If expected, a one-liner in the PR description noting why would help reviewers confirm it's benign.

If you'd like a hand, you can assign this prompt to your coding agent:

Add tests for the tone_variant A/B experiment in .github/workflows/breaking-change-checker.md.

Cover the following scenarios:
1. When experiments.tone_variant == 'urgent': assert the rendered output contains "Requires Immediate Review" in the Status line and the urgent Recommendations copy.
2. When experiments.tone_variant == 'neutral' (else branch): assert the rendered output contains "Review Recommended" in the Status line and the neutral Recommendations copy.
3. Verify both branches emit the shared structural fields (Title, Date, Total Breaking Changes, Severity, Commits Analyzed) unchanged.

Also investigate whether the body_hash change in .github/workflows/pr-code-quality-reviewer.lock.yml is an expected compilation side-effect or an accidental inclusion, and either remove it or add a note in the PR description explaining it.

Generated by ✅ Contribution Check · 360.2 AIC · ⌖ 15.7 AIC · ⊞ 6.3K ·

@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

🎉 This pull request is included in a new release.

Release: v0.82.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ab-advisor] Experiment campaign for breaking-change-checker: A/B test tone_variant

3 participants