LBI: LLM Batch Inference
Many LLM providers offer 50% token discounts by using batches. This project wraps each provider's batch API in a unified interface.
Running Tests
To run the unit tests:
uv run pytest
To run the integration tests:
uv run pytest -m integration
Use the verbose flag -v to get more detailed output and use the -n flag to run multiple tests in parallel (-n auto runs one test per CPU core in parallel).
Example:
uv run pytest -n auto -v -m integration
You can also run specific tests and fixtures by keyword:
uv run pytest -n auto -v -m integration -k 'full_batch_lifecycle and mistral'
Publishing to PyPI
-
Bump the version in
[pyproject.toml](./pyproject.toml):version = "0.1.2" -
Build the package:
uv build -
Publish package:
uv publish -
Add tag in Git:
git add pyproject.toml git commit -m "Bump version to 0.1.2" git tag v0.1.2 git push origin main --tags
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
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 llm_batch_inference-0.1.8.tar.gz.
File metadata
- Download URL: llm_batch_inference-0.1.8.tar.gz
- Upload date:
- Size: 16.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
85fbe7c7456615d04aded33f3da582fd01adf9fbff1b3ebb63e98660c8249e26
|
|
| MD5 |
e8e8d7b02d3d1e3a554f1da3307c35fc
|
|
| BLAKE2b-256 |
71df01d231462cb4e57a51380c1953e1a78904ed6d734ce60bd1edf548b6e129
|
File details
Details for the file llm_batch_inference-0.1.8-py3-none-any.whl.
File metadata
- Download URL: llm_batch_inference-0.1.8-py3-none-any.whl
- Upload date:
- Size: 24.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.10.7 {"installer":{"name":"uv","version":"0.10.7","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fcc27a479ccc4edc7985726d547ce8076be92f9d500838b1d3748d74f511ddc1
|
|
| MD5 |
a4dfddbdb43313a9647bec37ca988ac6
|
|
| BLAKE2b-256 |
041f1fbfa4a674958a0714a753c4732386485a90403b9ed37d1ec0224c9bb305
|