Benchmark and compare local Ollama models against a prompt suite with declarative checks. Get pass rates, latency, and a ranked markdown report — so you can pick the right local model for your task. Offline, no API keys.
🌍 English · Português · 📚 Documentation
"Which local model should I use?" usually gets answered by vibes. ollabench answers it with numbers: write a small suite of prompts + checks, run it across several Ollama models, and compare pass rate and latency side by side. Everything runs on your machine.
# 1. Write a suite (or use the bundled example) # 2. Run it across models npx ollabench examples/basics.suite.json --models llama3.2,qwen2.5 --out report.md
Example report:
# ollabench — Basics ## Models | Model | Pass rate | Passed | Avg latency | | --- | --- | --- | --- | | qwen2.5 | 100% | 6/6 | 820 ms | | llama3.2 | 83% | 5/6 | 540 ms | ## Per-case | Case | qwen2.5 | llama3.2 | | --- | --- | --- | | capital-of-portugal | 2/2 | 2/2 | | json-output | 2/2 | 1/2 |
{
"name": "Basics",
"cases": [
{
"name": "json-output",
"prompt": "Return a JSON object with keys a and b. Only JSON.",
"checks": [{ "type": "jsonValid" }, { "type": "regex", "value": "\"a\"" }]
}
]
}contains · notContains · regex · equals · jsonValid · minLength · maxLatencyMs
import { loadSuite, runSuite, renderReport, OllamaModelClient } from 'ollabench'; const report = await runSuite(loadSuite('suite.json'), ['llama3.2', 'qwen2.5'], new OllamaModelClient()); console.log(renderReport(report));
MIT © Marcelo Domingues