Skip to main content

License GitHub Release PyPI Release Container Image Tests Coverage Status Join Slack DOI

Inference Perf

Inference Perf is a production-scale GenAI inference performance benchmarking tool that allows you to benchmark and analyze the performance of inference deployments. It is agnostic of model servers and can be used to measure performance and compare different systems apples-to-apples.

It was founded as a part of the inference benchmarking and metrics standardization effort in wg-serving to standardize the benchmark tooling and the metrics used to measure inference performance across the Kubernetes and model server communities.


🏗️ Architecture

Architecture Diagram


🌟 Key Capabilities

📊 Rich Metrics & Analysis

  • Comprehensive Latency Metrics: TTFT, TPOT, ITL, and Normalized TPOT.
  • Throughput Tracking: Input, Output, and Total tokens per second.
  • Goodput Measurement: Measure rate of requests meeting your SLO constraints. See goodput.md.
  • Automatic Visualization: Generate charts for QPS vs Latency/Throughput/Goodput. See analysis.md.

🧠 Smart Data Generation

  • Real-world Datasets: Support for ShareGPT, CNN DailyMail, Infinity Instruct, Billsum, and the VisionArena image dataset.
  • Synthetic & Random: Configure exact input/output distributions.
  • Advanced Scenarios: Shared prefix and multi-turn chat conversations.
  • Multimodal: Synthetic image, video, and audio payloads with per-modality reporting. Resolutions/profiles/durations are passed through as-is; pick values within your model's accepted range. See docs/config.md.

⏱️ Flexible Load Generation

  • Load Patterns: Constant rate, Poisson arrival, and concurrent user simulation.
  • Multi-Stage Runs: Define stages with varying rates and durations to find saturation points.
  • Trace Replay: Replay real-world traces (e.g., Azure dataset) or OpenTelemetry traces with agentic tree-of-thought simulation and visualization.

🚀 High Scalability

  • 10k+ QPS: Scalable to very high load due to optimized multi-process architecture.
  • Automatic Saturation Detection: Find the limits of your system via sweeps.

🔌 Engine Agnostic

  • Verified support for vLLM, SGLang, and TGI with server side aggregate metrics and time series metrics.
  • Easily extensible to any OpenAI-compatible endpoint.

🚀 Quick Start

Run Locally

  1. Install inference-perf:

    pip install inference-perf
    
  2. Run a benchmark with a simple random workload:

    inference-perf --server.type vllm --server.base_url http://localhost:8000 --data.type random --load.type constant --load.stages '[{"rate": 10, "duration": 60}]' --api.streaming true
    

Alternatively, you can run using a configuration file:

inference-perf --config_file config.yml

Sample Output

When you run inference-perf, it displays a rich summary table in the CLI:

Metrics Summary

Run in Docker

docker run -it --rm -v $(pwd)/config.yml:/workspace/config.yml quay.io/inference-perf/inference-perf

Run in Kubernetes

Refer to the guide in /deploy.


📚 Documentation Hub

Explore detailed documentation for specific topics:

Topic Description Link
Configuration Full YAML configuration schema and options. config.md
CLI Flags All command line flags: global options and configuration overrides. cli_flags.md
Load Generation Detailed explanation of load patterns and multi-worker setup. loadgen.md
Collected Metrics Definitions of TTFT, TPOT, ITL, etc. metrics.md
Emitted Metrics Prometheus metrics inference-perf exports about its own runtime. runtime_metrics.md
Comparability Configuring runs that are comparable with other benchmarking tools. comparability.md
Goodput How to measure requests meeting SLOs. goodput.md
Reports Understanding generated JSON reports. reports.md
OTel Observability Instrument benchmark runs with OpenTelemetry tracing to export to Jaeger, Tempo, etc. otel_instrumentation.md
OTel Trace Replay Data/load type for replaying production traces with complex dependency graphs. otel_trace_replay.md
Synthetic Agentic (implementation in progress) Data/load type for generating agentic workloads (tool loops, sub-agent fan-out, context growth) procedurally, without a recorded trace. synthetic_agentic.md
Weka Trace Replay Data/load type for replaying raw Weka agent traces via graph-based session execution. weka_trace_replay.md
Conversation Replay Data/load type for benchmarking concurrent multi-turn agentic conversations with configurable distributions. conversation_replay.md
BR0.2 Reports Always-emitted llm-d-benchmark BR0.2 partial per stage; designed for clean yq-merge with other producers. br_v0_2.md
Analysis Visualizations and plots for performance metrics. analysis.md
E2E Tests Contributor guide to the end-to-end test tier: running and extending it. e2e_tests.md

🤝 Contributing & Community

We welcome contributions! Please join us:

See CONTRIBUTING.md for details on how to get started.

Metadata

Release files for inference-perf 0.7.0

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

Source distribution (sdist)

Source distribution for inference-perf 0.7.0
File Size Uploaded Provenance Actions
inference_perf-0.7.0.tar.gz 2.3 MB Without provenance Details for inference_perf-0.7.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for inference-perf 0.7.0
File Interpreter ABI Platform Actions
inference_perf-0.7.0-py3-none-any.whl Python 3 none any Details for inference_perf-0.7.0-py3-none-any.whl

Total release size: 4.8 MB

Release files / inference_perf-0.7.0.tar.gz

Download URL inference_perf-0.7.0.tar.gz
Size 2.3 MB
Tags Source
SHA-256 checksum
How to use checksums
0985e37653382e79c1a16b60a0f737260badd6bd0411c17466bf85f525fee8e3
BLAKE2b-256 checksum
How to use checksums
1c9743fd097b92f70bb0d4dc27cc5d3f714090c5c7a9198629fa2db8d25d36c3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / inference_perf-0.7.0-py3-none-any.whl

Download URL inference_perf-0.7.0-py3-none-any.whl
Size 2.4 MB
Tags Python 3
SHA-256 checksum
How to use checksums
7652d1bdb66f0cbd6e24fd128dc86e2a585196e3c98445e39ca41ca2a01fcd03
BLAKE2b-256 checksum
How to use checksums
e8a12e1b0043e1c017903e1b32c9dd471f8ef1e17e5f0a89414dd9b73ea9c3e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Security for inference-perf 0.7.0

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.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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