Skip to main content

duelbench

Any AI against any other, on the same items, with statistics that say who really wins.

ci license: MIT python: 3.11+ status: alpha local AI first results: welcome

duelbench puts AI systems head to head on exactly the same items: LLMs (local with Ollama, llama.cpp or vLLM, or through an API), image classifiers, embedding models, agents, or your own Python function. It records every answer, compares the contestants item by item, and ends each comparison with a plain verdict: A is better, B is better, or no clear difference, with a confidence interval, an exact paired test and a correction for the number of comparisons. It is made for comparing AIs of different kinds, on the hardware you actually own, with results anyone can recompute (why another evaluation tool?).

First results

Three duels on a CPU-only laptop (Intel Core i5-1035G1, 8 GB of RAM, 12 W). Each card gives the question, the plan fixed before the run, the limits, and the raw records to recompute every number.

Question Verdict Time on this laptop
A CNN, zero-shot CLIP or a small vision-language model on ImageNetV2? ResNet-50 68.6% > CLIP 52.7% > Qwen3.5 0.8B 28.0% (each p < 0.001) median 0.15 s, 0.11 s and 4 s per photo
Three local embedding models on STS-B EmbeddingGemma 84.9 ≈ nomic 84.2 (no clear difference); both beat MiniLM 82.0 (p = 0.002) median 212, 96 and 25 ms per pair
Does thinking pay? Qwen3 1.7B on GSM8K thinking on 88.7% > off 76.3% (+12.3 points, p < 0.001) 16.6 h against 1.5 h for 300 problems

All results, rankings by task and duels we would love to see: results/.

Your hardware (a GPU, a Mac, a Raspberry Pi), your AIs and your ideas are exactly what is missing, especially for AIs that are not LLMs. Propose a duel, share a result or argue about a method. Francophone ? On peut aussi en discuter en français.

Install

pip install duelbench             # API and Ollama contestants, your own tasks, reports
pip install "duelbench[all]"      # + the Hugging Face catalog, vision, embeddings, transformers, Anthropic

Python 3.11 or later. Smaller extras: hf (benchmarks on the Hugging Face Hub), vision, embeddings, transformers, math, anthropic. On Linux without an NVIDIA GPU, install the CPU build of PyTorch first: pip install torch torchvision --index-url https://download.pytorch.org/whl/cpu. Latest version: pip install "duelbench @ git+https://github.com/cyyyp100/duelbench".

Use

duel doctor                     # what this machine offers: GPU, Docker, Ollama, API keys
duel tasks                      # the catalog: GSM8K, MMLU-Pro, GPQA, AIME, HumanEval+, ImageNet, STS-B, games...
duel run -t gsm8k --limit 200 -m "small=ollama:qwen3:1.7b?think=false" -m "big=openai:gpt-5-mini"

A verdict looks like this (a toy task from examples/ that needs no model: the gold answers against a weak lookup):

capitals (accuracy, 12 items)
 contestant   score [95% CI]         errors   median latency
 oracle       100.0% [75.8, 100.0]   0        –
 lookup       8.3% [1.5, 35.4]       0        0 ms
  oracle − lookup: +91.7 pts [+49.3, +100.0], p < 0.001 → oracle is better

Each run writes runs/<date>-<name>/: report.html (charts and every answer), report.md (verdict sentences ready to quote), results.json, every record and the exact command. Interrupted runs resume from the cache. A whole comparison can live in a file and run with duel run duel.yaml:

name: small-models
models: ["qwen=ollama:qwen3:1.7b?think=false", "gemma=ollama:gemma3:1b"]
tasks: [gsm8k, arc_challenge, humaneval_plus]
limit: 200
Contestant What
ollama:…, llamacpp:…, vllm:…, lmstudio:…, mlx:… a local model
openai:…, anthropic:…, gemini:…, openrouter:…, mistral:…... an API
timm:…, clip:…, st:…, hf:… an image classifier, zero-shot CLIP/SigLIP, an embedding model, a transformers model
py:module:function, cmd:program anything else: a Python function, or a program reading and writing JSON
  • Your own task: duel new my_task --kind choice writes a task.yaml and a data.jsonl; duel check verifies it (writing tasks).
  • Code written by models runs in a Docker container without network, or under Seatbelt on a Mac (sandbox).
  • Results from other tools: duel import results.csv applies the same statistics to per-item scores from lm-evaluation-harness, Inspect or Harbor.

Documentation · statistics · contestants · catalog · contributing · security. Alpha: formats may still change. Code under MIT, published results under CC BY 4.0; datasets are not redistributed: each task downloads its data from the original source, whose license and terms apply.

Metadata

Release files for duelbench 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for duelbench 0.1.0
File Size Uploaded Provenance Actions
duelbench-0.1.0.tar.gz 214.4 kB With provenance Details for duelbench-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for duelbench 0.1.0
File Interpreter ABI Platform Actions
duelbench-0.1.0-py3-none-any.whl Python 3 none any Details for duelbench-0.1.0-py3-none-any.whl

Total release size: 390.9 kB

Release files / duelbench-0.1.0.tar.gz

Download URL duelbench-0.1.0.tar.gz
Size 214.4 kB
Tags Source
SHA-256 checksum
How to use checksums
3afce4383c0ac2b58cdc03ab430af2edfd0d393f6649ed054ad81760d754ca1d
BLAKE2b-256 checksum
How to use checksums
b108f8e3e5e680f1770950b03c9cb2e3bc405ecc2d919c18fcb555a3cd56857a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.

Transparency log

Release files / duelbench-0.1.0-py3-none-any.whl

Download URL duelbench-0.1.0-py3-none-any.whl
Size 176.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
bad5068e36c8249db399c730a6841d0378f62ec27da079834d5c85dd154019c8
BLAKE2b-256 checksum
How to use checksums
e95bee830250ab5be2d50e57866b3570c360de54385c342abb7a5e3e21d72742
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.

Transparency log

Security for duelbench 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for duelbench-0.1.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Dec 1, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page