> For the complete documentation index, see [llms.txt](https://docs.layerlens.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.layerlens.ai/more-in-this-section-3/compare-prompts.md).

# Recipe: compare prompts on a small test set

Recipe — A/B compare prompt variants. Pointer to the canonical SDK sample.

The canonical sample lives in the SDK: [`samples/core/compare_evaluations.py`](https://github.com/layerlens/stratix-python/blob/main/samples/core/compare_evaluations.py) — compare evaluation runs side-by-side to measure improvement over time.

## Pattern

1. Hold model and dataset fixed; vary the prompt.
2. Create an evaluation per variant with `client.evaluations.create(model=, benchmark=)`.
3. Wait for completion on each via `client.evaluations.wait_for_completion(evaluation)`.
4. Compare top-line `accuracy` and per-result deltas.

## See also

* [SDK sample: `compare_evaluations.py`](https://github.com/layerlens/stratix-python/blob/main/samples/core/compare_evaluations.py)
* [Tutorial 1: First evaluation](/8.-evaluate-score-the-outputs/01-first-evaluation.md)
* [Workflow: Improve](/5.-select-pick-the-model/workflow.md)
