Llama API Benchmark
Project description
llama_api_bench
Table of Contents
Installation
pip install llama-api-bench
Install from source
pip install -e .
# dev
pip install -e ".[dev]"
Usage
Run All
llama-api-bench run-all
Run Subset
- Run on a specific criteria for all models and providers
llama-api-bench run-criteria --criteria tool_call
- Run on a specific test case data for all models and providers
llama-api-bench run-test-case --test-case tool_call_get_weather
- Run all test cases on a specific provider
llama-api-bench run-provider --provider openrouter
- Run on a specific test case x model x provider
# streaming
llama-api-bench run --test-case basic_dont_call_tool --model Cerebras-Llama-4-Scout-17B-16E-Instruct --provider llamaapi --stream
# non-streaming
llama-api-bench run --test-case basic_dont_call_tool --model Cerebras-Llama-4-Scout-17B-16E-Instruct --provider llamaapi --no-stream
- Run on specific provider x model
llama-api-bench run-provider --provider openai --models gpt-4o
llama-api-bench run-provider --provider llamaapi --models Llama-4-Maverick-17B-128E-Instruct-FP8
Customization
Add a New Test Case / Criteria
- Add a new test case in llama_api_bench/data/.
- If the new test case requires a new Test Criteria to run evaluation, add it to llama_api_bench/core/criterias.
Add New Provider
- Add supported models in llama_api_bench/models/. See an example in llamaapi.py.
- Add ProviderConfig in llama_api_bench/core/providers.py.
- If the provider requires has a new request format, add it to get_request_json.
- If the provider requires a new response format parsing, add its evaluation criteria in llama_api_bench/core/criterias.
License
llama-api-bench is distributed under the terms of the MIT license.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
llama_api_bench-0.0.10.tar.gz
(15.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file llama_api_bench-0.0.10.tar.gz.
File metadata
- Download URL: llama_api_bench-0.0.10.tar.gz
- Upload date:
- Size: 15.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-httpx/0.28.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cc2d53215da01dd7bad27108dbd5287b2205b62de5e53d3d0917031de0dd45d1
|
|
| MD5 |
45c53d4eb9d519681517eef1359dfa75
|
|
| BLAKE2b-256 |
f0c72e01184322e1972c60bdd3501040666d2de7143eab92504d6ab359a6fd76
|
File details
Details for the file llama_api_bench-0.0.10-py3-none-any.whl.
File metadata
- Download URL: llama_api_bench-0.0.10-py3-none-any.whl
- Upload date:
- Size: 25.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-httpx/0.28.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2bd528b1f016e17cc8e3b1636ce02061c8546e2b91ea10d972c96b0bfe8ada7e
|
|
| MD5 |
d21604f3d855db0db9d8974e116aaee5
|
|
| BLAKE2b-256 |
25167a1578f8360bd11f0e2e7118ccb0d0bb5dfe7db2050acf33d923fe54e0b5
|