> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cekura.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# A/B Testing

> Compare two versions of your agent side-by-side to measure prompt, model, or configuration changes.

export const CopyPageButton = () => {
  if (typeof window !== 'undefined') {
    setTimeout(function () {
      if (document.getElementById('ck-tools')) return;
      var anchor = document.getElementById('content-area') || document.querySelector('.mdx-content');
      if (!anchor) return;
      if (!document.getElementById('ck-style')) {
        var s = document.createElement('style');
        s.id = 'ck-style';
        s.textContent = '#ck-tools{position:absolute;top:6px;right:0;z-index:100;font-family:inherit;}' + '.ck-row{display:inline-flex;align-items:stretch;border:1px solid rgba(0,0,0,0.15);border-radius:8px;overflow:hidden;background:#fff;}' + ':root.dark .ck-row{background:rgba(255,255,255,0.06);border-color:rgba(255,255,255,0.12);}' + '.ck-btn{padding:5px 12px;border:none;background:none;cursor:pointer;font-size:13px;font-weight:500;font-family:inherit;color:#374151;}' + ':root.dark .ck-btn{color:#d1d5db;}' + '.ck-btn:hover{background:rgba(0,0,0,0.04);}' + ':root.dark .ck-btn:hover{background:rgba(255,255,255,0.06);}' + '.ck-chevron{padding:5px 8px;border:none;background:none;cursor:pointer;font-size:14px;font-family:inherit;color:#374151;}' + ':root.dark .ck-chevron{color:#d1d5db;}' + '.ck-chevron:hover{background:rgba(0,0,0,0.04);}' + ':root.dark .ck-chevron:hover{background:rgba(255,255,255,0.06);}' + '.ck-divider{width:1px;background:rgba(0,0,0,0.12);flex-shrink:0;}' + ':root.dark .ck-divider{background:rgba(255,255,255,0.12);}' + '.ck-dd{position:absolute;top:calc(100% + 4px);right:0;min-width:180px;background:#fff;border:1px solid rgba(0,0,0,0.12);border-radius:8px;box-shadow:0 4px 12px rgba(0,0,0,0.1);padding:4px;display:none;z-index:200;}' + ':root.dark .ck-dd{background:#1f2937;border-color:rgba(255,255,255,0.1);box-shadow:0 4px 16px rgba(0,0,0,0.35);}' + '.ck-item{display:block;width:100%;padding:7px 12px;border:none;background:none;border-radius:6px;cursor:pointer;font-size:13px;font-family:inherit;text-align:left;color:#374151;}' + ':root.dark .ck-item{color:#d1d5db;}' + '.ck-item:hover{background:rgba(0,0,0,0.05);}' + ':root.dark .ck-item:hover{background:rgba(255,255,255,0.07);}';
        document.head.appendChild(s);
      }
      var wrap = document.createElement('div');
      wrap.id = 'ck-tools';
      var row = document.createElement('div');
      row.className = 'ck-row';
      var mainBtn = document.createElement('button');
      mainBtn.className = 'ck-btn';
      mainBtn.textContent = 'Copy page';
      var divider = document.createElement('span');
      divider.className = 'ck-divider';
      var chevron = document.createElement('button');
      chevron.className = 'ck-chevron';
      chevron.textContent = '▾';
      var dd = document.createElement('div');
      dd.className = 'ck-dd';
      function closeDD() {
        dd.style.display = 'none';
      }
      function openDD() {
        dd.style.display = 'block';
      }
      chevron.onclick = function (e) {
        e.stopPropagation();
        if (dd.style.display === 'block') {
          closeDD();
        } else {
          openDD();
        }
      };
      document.addEventListener('click', function (e) {
        if (!e.target.closest('#ck-tools')) {
          closeDD();
        }
      });
      document.addEventListener('keydown', function (e) {
        if (e.key === 'Escape') {
          closeDD();
        }
      });
      function makeItem(label, fn) {
        var b = document.createElement('button');
        b.className = 'ck-item';
        b.textContent = label;
        b.onclick = function () {
          fn();
          closeDD();
        };
        return b;
      }
      function getMarkdown() {
        var walk = function (node) {
          if (!node) return '';
          if (node.nodeType === 3) return node.textContent || '';
          if (node.nodeType !== 1) return '';
          var tag = node.tagName.toLowerCase();
          var skip = ['script', 'style', 'svg', 'noscript', 'button', 'iframe'];
          if (skip.indexOf(tag) !== -1) return '';
          if (node.id === 'ck-tools') return '';
          var ch = Array.from(node.childNodes).map(walk).join('');
          if (tag === 'h1') return '\n# ' + ch.trim() + '\n\n';
          if (tag === 'h2') return '\n## ' + ch.trim() + '\n\n';
          if (tag === 'h3') return '\n### ' + ch.trim() + '\n\n';
          if (tag === 'p') return '\n' + ch.trim() + '\n\n';
          if (tag === 'pre') return '\n```\n' + node.textContent.trim() + '\n```\n\n';
          if (tag === 'li') return '- ' + ch.trim() + '\n';
          if (tag === 'code') return '`' + ch.trim() + '`';
          return ch;
        };
        var content = document.querySelector('.mdx-content') || document.getElementById('content-area') || document.body;
        return walk(content).replace(/\n\n\n+/g, '\n\n').trim();
      }
      function copyMd() {
        var md = getMarkdown();
        navigator.clipboard.writeText(md).then(function () {
          mainBtn.textContent = 'Copied!';
          setTimeout(function () {
            mainBtn.textContent = 'Copy page';
          }, 2000);
        });
      }
      function viewMd() {
        var md = getMarkdown();
        var safe = md.split('&').join('&amp;').split('<').join('&lt;').split('>').join('&gt;');
        var html = '<!DOCTYPE html><html><head><meta charset="utf-8"><style>body{font-family:monospace;max-width:860px;margin:40px auto;padding:0 24px;line-height:1.7;white-space:pre-wrap;word-wrap:break-word}</style></head><body>' + safe + '</body></html>';
        window.open(URL.createObjectURL(new Blob([html], {
          type: 'text/html'
        })), '_blank');
      }
      function openClaude() {
        var prompt = 'Can you read this Cekura docs page ' + window.location.href + ' so I can ask you questions?';
        window.open('https://claude.ai/new?q=' + encodeURIComponent(prompt), '_blank');
      }
      mainBtn.onclick = copyMd;
      dd.appendChild(makeItem('Copy page', copyMd));
      dd.appendChild(makeItem('View as Markdown', viewMd));
      dd.appendChild(makeItem('Open in Claude', openClaude));
      row.appendChild(mainBtn);
      row.appendChild(divider);
      row.appendChild(chevron);
      wrap.appendChild(row);
      wrap.appendChild(dd);
      anchor.style.position = 'relative';
      anchor.insertBefore(wrap, anchor.firstChild);
    }, 50);
  }
  return null;
};

<CopyPageButton />

## Overview

A/B testing on Cekura lets you compare two (or more) runs of your agent against the same set of evaluators — so you can see whether a prompt change, model swap, or configuration tweak actually improves behavior before shipping it.

The flow is simple:

1. Run the same set of evaluators against **Version A** of your agent.
2. Make your change (update the prompt, switch the model, adjust tools, etc.).
3. Run the **same** evaluators against **Version B**.
4. Select both runs on the Results page and compare metric-by-metric.

<Note>
  Always run both versions against the **same evaluators** with the **same test profile**. Otherwise you're measuring noise from different test inputs rather than the change itself.
</Note>

## Prerequisites

Before running an A/B test, make sure you have:

* An agent configured on Cekura — see the [Testing Overview](/documentation/guides/testing-agents/overview) for the basic testing flow
* A stable set of evaluators that pass reliably for your baseline — see the [Suggested Testing Approach](/documentation/guides/testing-agents/suggested-testing-approach)
* A clear hypothesis about what you expect the change to improve (pass rate, latency, adherence to a specific metric, etc.)

## Running an A/B Test

<Steps>
  <Step title="Run Version A (baseline)">
    Select your evaluators and run them against your current agent configuration. Wait for the run to complete and record the run name or ID.
  </Step>

  <Step title="Apply your change">
    Update the agent's prompt, model, voice, tool configuration, or any other parameter you want to test. Change **one variable at a time** — otherwise you won't know which change caused the difference.
  </Step>

  <Step title="Run Version B">
    Run the **same evaluators** against the updated agent. Use the same test profile, personalities, and frequency so the only difference between the two runs is your change.
  </Step>

  <Step title="Select both runs and compare">
    On the Results page, select the checkboxes next to both runs and click **Compare**. Cekura shows a side-by-side breakdown of every metric and evaluator across the two runs.

    Look for:

    * **Overall pass rate** — did B improve or regress?
    * **Per-metric deltas** — which specific metrics moved, and by how much?
    * **Individual evaluator diffs** — open any evaluator to see the transcripts side-by-side and read why one passed and the other failed.
  </Step>
</Steps>

## Best Practices

### Change One Variable at a Time

If you change the prompt **and** swap the model in the same run, you can't attribute any improvement (or regression) to either change. Test changes in isolation.

### Use Frequency > 1 to De-Noise

Voice agents are non-deterministic. A single run can pass or fail by chance. Set frequency to 3–5 so each evaluator runs multiple times — the aggregate result is far more reliable than any single call. See [Load Testing](/documentation/guides/testing-agents/load-testing) for how frequency works.

### Keep the Test Set Fixed

Don't add or remove evaluators between A and B. If you want to expand coverage, do that first, re-establish the baseline, and then run the A/B test.

### Compare More Than Pass Rate

Two runs can have the same pass rate while differing dramatically on latency, talk ratio, or a specific workflow metric. The compare view surfaces all of these — don't stop at the headline number.

## Related Resources

* [Testing Overview](/documentation/guides/testing-agents/overview) — Run your first evaluators
* [Suggested Testing Approach](/documentation/guides/testing-agents/suggested-testing-approach) — Build a reliable evaluator suite
* [Load Testing](/documentation/guides/testing-agents/load-testing) — Use frequency to run each evaluator multiple times
* [Metrics Overview](/documentation/key-concepts/metrics/overview) — Understand what each metric measures
