Skip to main content

Bench

Bench is a tool for evaluating LLMs for production use cases. Whether you are comparing different LLMs, considering different prompts, or testing generation hyperparameters like temperature and # tokens, Bench provides one touch point for all your LLM performance evaluation.

If you have encountered a need for any of the following in your LLM work, then Bench can help with your evaluation:

  • to standardize the workflow of LLM evaluation with a common interface across tasks and use cases
  • to test whether open source LLMs can do as well as the top closed-source LLM API providers on your specific data
  • to translate the rankings on LLM leaderboards and benchmarks into scores that you care about for your actual use case

Join the bench community on Discord.

For bug fixes and feature requests, please file a Github issue.

Package installation

Install Bench to your python environment with optional dependencies for serving results locally (recommended): pip install 'arthur-bench[server]'

Alternatively, install Bench to your python environment with minimum dependencies: pip install arthur-bench

For further setup instructions visit our installation guide

Using Bench

For a more in-depth walkthrough of using bench, visit our quickstart walkthrough and our test suite creation guide on our docs.

To make sure you can run test suites in bench, you can run the following code snippets to create a test suite and run it to give a score to candidate outputs.

from arthur_bench.run.testsuite import TestSuite
suite = TestSuite(
    "bench_quickstart",
    "exact_match",
    input_text_list=["What year was FDR elected?", "What is the opposite of down?"],
    reference_output_list=["1932", "up"]
)
suite.run("quickstart_run", candidate_output_list=["1932", "up is the opposite of down"])

Saved test suites can be loaded later on to benchmark test performance over time, without needing to re-prepare reference data:

existing_suite = TestSuite("bench_quickstart", "exact_match")
existing_suite.run("quickstart_new_run", candidate_output_list=["1936", "up"])

To view the results for these runs in the local UI that comes with the bench package, run bench from the command line (this requires the bench optional server dependencies to be installed):

bench

Viewing examples in the bench UI will look something like this:

Examples UI

Running Bench from source

To launch Bench from source:

  1. Install the dependencies
    • pip install -e '.[server]'
  2. Build the Front End
    • cd arthur_bench/server/js
    • npm i
    • npm run build
  3. Launch the server
    • bench

Because the server was installed with pip -e, local changes will be picked up. However, the server will need to be restarted between changes in order for those changes to be picked up.

Metadata

Release files for arthur-bench 0.3.1

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

Source distribution (sdist)

Source distribution for arthur-bench 0.3.1
File Size Uploaded Provenance
arthur_bench-0.3.1.tar.gz 5.1 MB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for arthur-bench 0.3.1
File Interpreter ABI Platform
arthur_bench-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 10.2 MB

Release files / arthur_bench-0.3.1.tar.gz

Download URL arthur_bench-0.3.1.tar.gz
Size 5.1 MB
Tags Source
SHA-256 checksum
How to use checksums
d809cb3a1822e446c45546f4932a7b585353f4d7b8edbf0b1c1b80f9f0625364
BLAKE2b-256 checksum
How to use checksums
a4359b25c0687daa8cf82d1621f48f8424b06d4578a86f39c026bc0287663696
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.18

Release files / arthur_bench-0.3.1-py3-none-any.whl

Download URL arthur_bench-0.3.1-py3-none-any.whl
Size 5.1 MB
Tags Python 3
SHA-256 checksum
How to use checksums
ebfb9f2360ace9ead1f56c0691a9643020fd141db6749fbe5f0cc47793e77d6c
BLAKE2b-256 checksum
How to use checksums
dcea844c1f054f53a96393abe95bb14136b33d953774688d09f0e54b1a3b14c3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.18

Security for arthur-bench 0.3.1

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.

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