SommBench: Assessing Sommelier Expertise of Language Models
SommBench is a multilingual benchmark for evaluating sommelier-level wine knowledge in large language models. It spans three complementary tasks — Wine Theory Q&A, Food & Wine Pairing, and Wine Feature Completion.
Quick Start
uv add sommbench
Create a .env file with your API credentials:
API_KEY="your-api-key"
API_BASE="https://api.openai.com/v1"
Run the full benchmark suite:
sommbench run "lm_studio/qwen3.5-0.8b-mlx"
Usage
Command Line
sommbench <COMMAND> <MODEL> [OPTIONS]
Commands
| Command | Description |
|---|---|
run |
Runs all three benchmarks and prints the composite SommBench Score |
wtqa |
Wine Theory Question-Answering — multiple-choice wine knowledge quiz |
fwp |
Food & Wine Pairing — predicts whether a wine pairs with a dish (English only) |
wfc |
Wine Feature Completion — fills in masked wine attributes via structured output |
Examples
Run all benchmarks:
sommbench run "gpt-4o" --output ./benchmark_results/
Single task — WTQA on all languages:
sommbench wtqa "gpt-4o"
Specify languages for WFC (Italian and German):
sommbench wfc "gemini-1.5-pro" -l it -l de --batch-size 64 --output wfc_results.json
Multiple passes for FWP:
sommbench fwp "claude-sonnet-4-6" --num-passes 3 --output fwp_results.json
Extra model parameters:
sommbench run "lm_studio/my-model" --model-params '{"stop": ["<|im_end|>"], "max_tokens": 512}'
Inline credentials:
sommbench wtqa "gpt-4-turbo" --api-key "sk-..." --api-base "https://api.openai.com/v1"
Options
sommmbech --help
| Option | Description | Default |
|---|---|---|
model (positional) |
Required. Model name/identifier passed to LiteLLM. | — |
--output <PATH> |
Output file (or directory) for results. | results.json (results/ for run) |
-l, --language <LANG> |
Language(s) to benchmark. Repeat for multiple. Not available for fwp. |
all |
--num-passes <INT> |
Number of full benchmark passes (each pass evaluates every item once). | 1 |
--batch-size <INT> |
Items per API batch call. | 32 |
--sample-size <INT> |
Randomly sample N items instead of the full dataset. | full dataset |
--temperature <FLOAT> |
Sampling temperature forwarded to the model. | model default |
--no-think |
Append /no_think to prompts (disables extended reasoning on supported models). |
off |
--model-params <JSON> |
JSON string of extra parameters forwarded to the model via LiteLLM (e.g. stop, max_tokens). |
none |
--api-key <KEY> |
API key. Overrides API_KEY from .env. |
from .env |
--api-base <URL> |
Base URL for the API endpoint. Overrides API_BASE from .env. |
from .env |
Python API
Full suite — run all benchmarks in one call:
from pathlib import Path
from sommbench import run
run(
model="gpt-4o",
output=Path("results/"),
api_key="sk-...",
api_base="https://api.openai.com/v1",
)
Single task — run one benchmark with custom options:
import json
from sommbench import run_wtqa_benchmark
results = run_wtqa_benchmark(
model="gpt-4o",
language=["en", "de"],
num_passes=2,
api_key="sk-...",
api_base="https://api.openai.com/v1",
batch_size=16,
)
with open("wtqa_results.json", "w", encoding="utf-8") as f:
json.dump(results, f, indent=4, ensure_ascii=False)
Granular workflow — run each task individually and compute the composite score:
from sommbench import (
compute_sommbench_score,
run_fwp_benchmark,
run_wfc_benchmark,
run_wtqa_benchmark,
)
api_key = "sk-..."
api_base = "https://api.openai.com/v1"
wtqa = run_wtqa_benchmark(model="gpt-4o", language=None, num_passes=1, api_key=api_key, api_base=api_base)
fwp = run_fwp_benchmark(model="gpt-4o", num_passes=1, api_key=api_key, api_base=api_base)
wfc = run_wfc_benchmark(model="gpt-4o", language=["en", "de", "it"], num_passes=1, api_key=api_key, api_base=api_base)
score = compute_sommbench_score(wtqa, fwp, wfc)
print(score)
# {'sommbench_score': 0.6821, 's_wtqa': 0.8012, 's_fwp': 0.5432, 's_wfc': 0.7019}
License
This project is licensed under the MIT License. See LICENSE for details.
Citation
If you use SommBench in your research, please cite:
@misc{brach2025sommbench,
title={SommBench: Assessing Sommelier Expertise of Language Models},
author={William Brach and Peter Hartman and Marek Šuppa},
year={2025},
eprint={2603.12117},
archivePrefix={arXiv},
primaryClass={cs.CL},
url={https://arxiv.org/abs/2603.12117},
}
Metadata
Release files for sommbench 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| sommbench-0.1.2.tar.gz | 228.6 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| sommbench-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 256.4 kB
Release files / sommbench-0.1.2.tar.gz
| Download URL | sommbench-0.1.2.tar.gz |
|---|---|
| Size | 228.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f88fe5d25fb137dfb98b1ffcb8bf2b967cd7ae5c9ce881851ac75df557098b9d
|
|
BLAKE2b-256 checksum How to use checksums |
15d3e28e19b44adbfe3cd8948051263bacde2a162ee8d7b05c34aab2edd51168
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / sommbench-0.1.2-py3-none-any.whl
| Download URL | sommbench-0.1.2-py3-none-any.whl |
|---|---|
| Size | 27.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
56953c723c80667e2818829d4246403d56bcae00f3f181fe255b25755d0d15a2
|
|
BLAKE2b-256 checksum How to use checksums |
ff9433677108c52b2d1e173de0735ba35555e1500c1bdcd71f40eeb45bd9877b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for sommbench 0.1.2
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.