ab-test-analysis

SkillProductivity

Lets your agent analyze A/B test results for statistical significance and recommend whether to ship, extend, or stop a variant.

Available today. Use it from your connected AI after setup.

Connect ahel once, and every AI you use reads what you have installed.

Then ask your AI: use the ab-test-analysis skill

About this capability

Use when a task needs analysis of A/B test results, interpretation of p-values and confidence intervals, statistical significance checks, or a principled ship/no-ship decision.

What this skill tells your AI

The instructions your AI receives, as published by jshsakura/awesome-opencode-skills in skills/ab-test-analysis/SKILL.md and read by ahel’s review.


name: ab-test-analysis description: Analyze A/B test results with statistical rigor — calculate significance, check guardrails, and make ship/extend/stop decisions. Use when evaluating experiment results or interpreting test data.

A/B Test Analysis

Analyze experiment results with statistical rigor and produce a clear Ship / Investigate / Extend / Stop recommendation.

This skill complements ab-test-setup (which handles experiment design). Use this skill when you have results to analyze.


Purpose

Most A/B test interpretations are wrong — teams either call tests too early, ignore guardrail metrics, or ship on directional trends without statistical significance. This skill enforces disciplined analysis.


When to Use

  • An A/B test has completed its planned duration
  • You have conversion data for control and variant groups
  • Stakeholders are asking "did the test win?"
  • You need to decide: ship, extend, or kill

When NOT to Use

  • Designing or setting up an experiment (use ab-test-setup)
  • The test hasn't reached minimum sample size yet
  • You're analyzing observational data (not a controlled experiment)

Required Data (Ask If Missing)

FieldDescription
Primary metricWhat the test is trying to improve (e.g., conversion rate)
Control groupSample size (N) and conversions (C) for the control
Variant groupSample size (N) and conversions (C) for the variant
Test durationHow long the test ran
Planned durationHow long it was designed to run
Guardrail metricsMetrics that must not degrade (e.g., revenue, page load time)
MDEMinimum Detectable Effect used in power calculation

Analysis Process

Step 1: Validate the Setup

Before analyzing results, check:

  • Sample size adequate? Compare actual N to planned N from power analysis
  • Duration sufficient? Must cover at least 1–2 full business cycles (e.g., weekday + weekend)
  • SRM check? Sample Ratio Mismatch — control and variant should have ~equal N (within 1%). If skewed, the test is invalid.
  • No novelty effects? If you can, check early vs. late behavior. New UI elements get more clicks initially.

If any check fails, the test results may be unreliable. Flag this before proceeding.

Step 2: Calculate Core Statistics

For conversion rate tests:

Control conversion rate: p_c = C_control / N_control
Variant conversion rate: p_v = C_variant / N_variant
Relative lift: (p_v - p_c) / p_c × 100%

Pooled proportion: p = (C_control + C_variant) / (N_control + N_variant)
Standard error: SE = sqrt(p × (1-p) × (1/N_control + 1/N_variant))
Z-score: Z = (p_v - p_c) / SE
P-value: two-tailed from Z

95% Confidence Interval: (p_v - p_c) ± 1.96 × SE

Step 3: Assess Significance

CriterionThresholdStatus
Statistical significancep-value < 0.05Pass / Fail
Practical significanceLift > MDEPass / Fail
Confidence intervalDoes CI exclude 0?Pass / Fail

Both statistical AND practical significance are required to ship.

Step 4: Check Guardrail Metrics

For each guardrail metric:

GuardrailControlVariantChangeStatus
[metric name][value][value][+/- %]OK / Warning / Degraded

A guardrail is degraded if it shows a statistically significant negative change.

Step 5: Make the Decision

Use this decision matrix:

Primary MetricGuardrailsRecommendation
Significant positiveAll OKShip — roll out to 100%
Significant positiveSome degradedInvestigate — understand trade-off before deciding
Not significant, positive trendAll OKExtend — run longer if sample size was insufficient
Not significant, flatAll OKStop — no effect detected, free up the experiment slot
Significant negativeAnyDon't Ship — revert and learn from the result

Output Format

# A/B Test Results: [Test Name]

## Summary

| Field | Value |
| --- | --- |
| Test name | [name] |
| Hypothesis | [We believed X would cause Y] |
| Primary metric | [metric name] |
| Duration | [start] — [end] ([N] days) |
| Decision | **Ship / Investigate / Extend / Stop / Don't Ship** |

---

## Results

| Group | Sample Size | Conversions | Rate |
| --- | --- | --- | --- |
| Control | [N] | [C] | [rate]% |
| Variant | [N] | [C] | [rate]% |

**Relative lift:** [+/- X.X%]
**P-value:** [value]
**95% CI:** [[lower]%, [upper]%]
**Statistically significant:** Yes / No
**Practically significant:** Yes / No (MDE was [X]%)

---

## Guardrail Metrics

| Metric | Control | Variant | Change | Status |
| --- | --- | --- | --- | --- |
| [metric] | [val] | [val] | [change] | OK / Warning |

---

## Recommendation

**Decision: [Ship / Investigate / Extend / Stop / Don't Ship]**

**Rationale:** [2–3 sentences explaining the decision]

**Next steps:**
1. [action]
2. [action]

---

## Learnings

- [What we learned from this test, regardless of outcome]
- [How this informs future experiments]

Common Pitfalls

PitfallWhy It's WrongCorrect Approach
Peeking at results dailyInflates false positive rateWait for planned duration and sample size
Calling it at p=0.06"Almost significant" isn't significantSet the threshold before the test, stick to it
Ignoring guardrailsWinning on one metric while losing on anotherAlways check guardrails before shipping
Post-hoc segmentationFinding "it worked for mobile users!" after the fact is data miningPre-register segments or treat as hypothesis for next test
Running too many variantsEach variant needs full sample sizeLimit to 1–2 variants per test
Not learning from losses"It didn't work" is not a learningDocument WHY it didn't work and what to try next

Anti-Patterns

AvoidWhyInstead
"Directional win"Not a statistical standardRequire p < 0.05 and lift > MDE
Shipping without guardrail checkMay degrade critical metricsAlways check before shipping
Ending early because it "looks good"Sequential testing biasRun to planned duration
Not documenting learningsSame failed experiments get repeatedMaintain an experiment log

References

Signals

GitHub stars
26
Forks
2
Last commit
Sep 2026
Advanced
Catalog kind
skill
Gateway key
ab-test-analysis
Source
github.com/jshsakura/awesome-opencode-skills