baseten-performance-client
A ultra-high performance package for sending requests to Baseten Embedding Inference'
What it is and what it does
baseten-performance-client is a Python wrapper around a Rust-based HTTP client designed to send high-volume concurrent requests to Baseten's embedding, reranking, and classification APIs. It releases Python's GIL during network I/O, enabling true parallelism for batch operations. The library supports both synchronous and asynchronous usage patterns, with configurable batching, concurrency limits, request timeouts, and connection pooling via HTTP/1.1 or HTTP/2.
The package is built on pyo3, reqwest, and tokio, and works not only with Baseten endpoints but with any HTTP API accepting JSON POST requests. It offers a RequestProcessingPreference object to tune batch size, concurrent request limits, character limits per request, hedge delays, and total operation timeouts. The library includes response objects for embeddings, reranking, and classification, with optional NumPy integration for embeddings.
Use it for:
- Batch embedding generation for large document corpora using Baseten, OpenAI, or Mixedbread APIs with minimal latency.
- Concurrent reranking of search results or document lists with configurable batch sizes and timeouts.
- Generic high-throughput POST request batching to any JSON API endpoint outside Baseten.
- Async/await integration in event-driven applications needing non-blocking embedding or classification calls.
- Performance-critical pipelines where GIL release and connection pooling reduce end-to-end latency.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
A high-performance Python HTTP client for concurrent requests to Baseten embeddings, reranking, and classification endpoints, built with Rust and Tokio to release the GIL during I/O.
Yes, if you need high-throughput concurrent HTTP requests to embeddings or classification APIs and can tolerate medium install friction. The Rust backend and active maintenance (recent release, 1188 stars) suggest reliability. Verify the license claim before use in proprietary code, and confirm the >1200 rps benchmark applies to your workload. The single runtime dependency (requests) is a plus.
Install
baseten-performance-client on PyPI
pip
pip install baseten-performance-clientuv
uv add baseten-performance-clientpoetry
poetry add baseten-performance-clientInstalling baseten-performance-client
Before you install
Medium install friction due to compiled wheels across many platforms (cp313t, cp38-abi3, musllinux variants). Active maintenance with recent releases and 1188 GitHub stars. Single runtime dependency (requests) keeps the footprint small.
License in practice
License treatment is unclear—the description states MIT licensing, but the fact sheet records no SPDX identifier or license_raw value. Verify the actual license before relying on this package in proprietary or GPL-licensed projects.
Quickstart
pip install baseten_performance_client
import os
from baseten_performance_client import PerformanceClient
api_key = os.environ.get("BASETEN_API_KEY")
client = PerformanceClient(base_url="https://model-xxx.api.baseten.co/environments/production/sync", api_key=api_key)
response = client.embed(input=["Hello world"], model="my_model")
Requires Python >=3.8; API key and valid Baseten endpoint URL needed for actual use.
Verify before relying
- Whether the MIT license claim in the description is reflected in official metadata and whether it applies to the Rust components.
- Whether the >1200 rps benchmark holds for your specific workload and infrastructure.
- Compatibility with PyPy beyond the classifier claim—whether all features work or only a subset.
Package facts
| License | not declared (unclear) |
| Python support | supports the current Python release (>=3.8) |
| Install friction | medium — platform-specific wheel |
| Runtime dependencies | 1 — requests |
| Maintenance | actively maintained — 8 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 461,585/month — #6,531 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: baseten_performance_client-0.1.13-cp313-cp313t-macosx_10_12_x86_64.whl; baseten_performance_client-0.1.13-cp313-cp313t-macosx_11_0_arm64.whl; baseten_performance_client-0.1.13-cp313-cp313t-manylinux_2_17_i686.manylinux2014_i686.whl; baseten_performance_client-0.1.13-cp313-cp313t-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl; baseten_performance_client-0.1.13-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; baseten_performance_client-0.1.13-cp313-cp313t-musllinux_1_2_aarch64.whl; baseten_performance_client-0.1.13-cp313-cp313t-musllinux_1_2_armv7l.whl; baseten_performance_client-0.1.13-cp313-cp313t-musllinux_1_2_i686.whl; baseten_performance_client-0.1.13-cp313-cp313t-musllinux_1_2_x86_64.whl; baseten_performance_client-0.1.13-cp38-abi3-macosx_10_12_x86_64.whl; baseten_performance_client-0.1.13-cp38-abi3-macosx_11_0_arm64.whl; baseten_performance_client-0.1.13-cp38-abi3-manylinux_2_17_i686.manylinux2014_i686.whl; baseten_performance_client-0.1.13-cp38-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl; baseten_performance_client-0.1.13-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; baseten_performance_client-0.1.13-cp38-abi3-manylinux_2_28_aarch64.whl; baseten_performance_client-0.1.13-cp38-abi3-manylinux_2_28_armv7l.whl; baseten_performance_client-0.1.13-cp38-abi3-musllinux_1_2_aarch64.whl; baseten_performance_client-0.1.13-cp38-abi3-musllinux_1_2_armv7l.whl; baseten_performance_client-0.1.13-cp38-abi3-musllinux_1_2_i686.whl; baseten_performance_client-0.1.13-cp38-abi3-musllinux_1_2_x86_64.whl
Tags
More WWW/HTTP packages
urllib3 is an HTTP client library that provides…
permissive · top 100 on PyPI
requestsRequests is a Python HTTP library that…
permissive · top 100 on PyPI
h11h11 is a pure-Python HTTP/1.1 protocol…
permissive · top 100 on PyPI
httpxHTTPX is a fully featured HTTP client library…
permissive · top 100 on PyPI
httpcoreA minimal low-level HTTP client library that…
permissive · top 100 on PyPI
aiohttpaiohttp is an async HTTP client and server…
permissive · top 100 on PyPI
langchain-basetenIntegrates Baseten's chat models and embeddings…
permissive · top 15,000 on PyPI
pyreqwestA Rust-based HTTP client for Python with both…
unclear · top 15,000 on PyPI
rustworkxA high-performance graph library for Python,…
permissive · top 5,000 on PyPI
tensor-grepA high-performance grep-compatible command-line…
unclear · top 15,000 on PyPI
httprhttpr is a fast HTTP client for Python built on…
permissive · top 5,000 on PyPI
pyqwestA Python HTTP client wrapping the Rust reqwest…
permissive · top 5,000 on PyPI
retworkxA deprecated package name for rustworkx, a…
permissive · top 15,000 on PyPI
multitaskingConverts Python methods into non-blocking,…
permissive · top 1,000 on PyPI
grequestsGRequests wraps the requests library with…
permissive · top 15,000 on PyPI
voyageaiProvides Python access to Voyage AI's embedding…
permissive · top 5,000 on PyPI