cafe-core
The CAFE evaluation engine: define a compound AI system as a black box, declare the factors to vary, and run a design-of-experiments study over it — headless, no web stack, no database required.
CAFE generates full and fractional factorial designs, runs each configuration
with replication (resumable checkpoints), scores answers with a configurable
LLM judge and/or human raters, and attributes quality to the factors with
mixed-effects models matched to the rubric's scale (linear · cumulative-link ·
logistic) plus inter-rater reliability (Krippendorff's α). See the examples/
notebooks for the full walkthrough.
Install (dev)
uv venv && uv pip install -e "packages/cafe-core[dev]"
Try it (no API keys)
cafe run example # run the bundled toy 2-factor study
cafe run example --smoke # preflight: 1 input, 1 rep, cost/time estimate
cafe validate example # expand the design without running
Library use
import cafe
async def my_system(config, item):
# your compound system: routing, RAG, cascade, agent — anything.
return f"answer for {item!r} using {config['model']}"
study = cafe.Study(
name="my-study",
system=my_system,
factors=[
cafe.Factor("model", ["small", "large"]),
cafe.Factor("prompt", ["plain", "cot"]),
],
dataset=["question 1", "question 2"],
replications=3,
)
results = study.run(checkpoint_path=".cafe/my-study.jsonl") # resumable
print(results.summary())
for obs in results:
print(obs.config, obs.output, obs.elapsed_s)
study.run() returns a Results object you hold like any value. The optional
checkpoint_path makes a long run crash-safe: re-running resumes instead of
restarting.
Metadata
Release files for cafe-core 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| cafe_core-0.0.1.tar.gz | 101.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| cafe_core-0.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 212.7 kB
Release files / cafe_core-0.0.1.tar.gz
| Download URL | cafe_core-0.0.1.tar.gz |
|---|---|
| Size | 101.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9342ee8cf37113f38ece095f227868c1e4b020ba4ed1ee318db0c84d9a5da93f
|
|
BLAKE2b-256 checksum How to use checksums |
4f1886690b2372e3a35ee9a07a1bbe17b0c8d946587fc6bca36cd14c01c90f70
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Aug 20, 2026.
Transparency logRelease files / cafe_core-0.0.1-py3-none-any.whl
| Download URL | cafe_core-0.0.1-py3-none-any.whl |
|---|---|
| Size | 111.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7a090a1bd6dc41ed49f17d23812cf63015c085278219de2aa712f4a5b8204e4a
|
|
BLAKE2b-256 checksum How to use checksums |
0ce0f06ef2024f066e3026daff747cb5d84b7b7659754ddc0bf933e1977ad35d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
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 Aug 20, 2026.
Transparency log