# predibase/lorax

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/predibase-lorax).**

3,724 stars · 308 forks · Python · apache-2.0

## Links

- GitHub: https://github.com/predibase/lorax
- Homepage: https://loraexchange.ai
- awesome-repositories: https://awesome-repositories.com/repository/predibase-lorax.md

## Topics

`fine-tuning` `gpt` `llama` `llm` `llm-inference` `llm-serving` `llmops` `lora` `model-serving` `pytorch` `transformers`

## Description

Lorax is a GPU-accelerated inference server and multi-adapter engine designed for serving large language models. It functions as a high-throughput system capable of deploying models via Kubernetes and managing the dynamic swapping of Low-Rank Adaptation adapters per request.

The server distinguishes itself through multi-adapter dynamic batching, which allows requests using different adapter weights to be processed in a single GPU forward pass. It employs just-in-time adapter loading and weighted adapter merging to maximize throughput and enable multi-tasking without sacrificing performance.

The project provides a standardized interface for chat and completions that is compatible with common API protocols, supporting structured outputs via JSON schema enforcement. Its performance surface includes tensor parallelism, speculative decoding, paged attention, and model weight quantization to reduce latency and memory overhead.

Infrastructure is managed through Helm charts for Kubernetes orchestration, with integrated telemetry exported via Prometheus and Open Telemetry.

## Tags

### Artificial Intelligence & ML

- [GPU-Accelerated Inference](https://awesome-repositories.com/f/artificial-intelligence-ml/gpu-accelerated-inference.md) — Provides a GPU-accelerated inference server that optimizes LLM performance through tensor parallelism and quantization.
- [LLM Inference Servers](https://awesome-repositories.com/f/artificial-intelligence-ml/agent-deployment-servers/llm-inference-servers.md) — Serves large language models with high throughput and dynamic LoRA adapter swapping per request.
- [OpenAI-Compatible APIs](https://awesome-repositories.com/f/artificial-intelligence-ml/agentic-systems-frameworks/model-integration-serving/model-integration-interfaces/ai-integration-apis/openai-compatible-apis.md) — Provides a standardized HTTP interface compatible with OpenAI's API for chat and completions. ([source](https://cdn.jsdelivr.net/gh/predibase/lorax@main/README.md))
- [Multi-Adapter Batching](https://awesome-repositories.com/f/artificial-intelligence-ml/batch-inference-engines/multi-adapter-batching.md) — Batches requests using different LoRA adapters into a single GPU forward pass to maximize throughput.
- [Inference Acceleration](https://awesome-repositories.com/f/artificial-intelligence-ml/inference-acceleration.md) — Implements tensor parallelism, quantization, and paged attention to reduce latency and increase throughput during model execution. ([source](https://loraexchange.ai))
- [Just-In-Time Weight Loading](https://awesome-repositories.com/f/artificial-intelligence-ml/just-in-time-weight-loading.md) — Prefetches and offloads task-specific adapter weights between CPU and GPU memory in real-time.
- [Large Language Model Serving](https://awesome-repositories.com/f/artificial-intelligence-ml/large-language-model-serving.md) — Hosts and exposes large language models from weight caches to serve as the foundation for inference. ([source](https://loraexchange.ai/getting_started/docker/))
- [Inference Optimizations](https://awesome-repositories.com/f/artificial-intelligence-ml/machine-learning/infrastructure/model-optimization-and-inference/serving-and-runtime/inference-optimizations.md) — Optimizes inference throughput and latency using quantization, speculative decoding, and tensor parallelism.
- [Tensor-Parallel Inference Distributions](https://awesome-repositories.com/f/artificial-intelligence-ml/model-optimization/inference-deployment/model-deployment-toolkits/distributed-deployment-utilities/multi-gpu-distribution/tensor-parallel-inference-distributions.md) — Splits model weights across multiple GPUs using tensor parallelism to serve models exceeding single-card memory.
- [LoRA Adapter Loaders](https://awesome-repositories.com/f/artificial-intelligence-ml/model-weight-management/lora-adapter-loaders.md) — Deploys and serves models trained with Low-Rank Adaptation to improve response quality. ([source](https://loraexchange.ai/models/adapters/lora/))
- [Dynamic Adapter Swapping](https://awesome-repositories.com/f/artificial-intelligence-ml/model-weight-management/lora-adapter-loaders/dynamic-adapter-swapping.md) — Dynamically swaps and batches parameter-efficient fine-tuning adapters at runtime to optimize GPU throughput. ([source](https://predibase.github.io/lorax/models/adapters/))
- [LLM Completion Interfaces](https://awesome-repositories.com/f/artificial-intelligence-ml/speech-to-text-integrations/unified-model-interfaces/llm-completion-interfaces.md) — Implements a standardized API interface for chat and completions compatible with common LLM client libraries.
- [Text Completion Engines](https://awesome-repositories.com/f/artificial-intelligence-ml/text-completion-engines.md) — Generates text completions from prompts using single-response or streaming delivery. ([source](https://predibase.github.io/lorax/reference/rest_api))
- [Text Generation APIs](https://awesome-repositories.com/f/artificial-intelligence-ml/text-generation-apis.md) — Provides APIs for generating text responses from prompts using specific adapters or structured formats. ([source](https://loraexchange.ai/reference/python_client/client/))
- [Base Model Architecture Support](https://awesome-repositories.com/f/artificial-intelligence-ml/base-model-architecture-support.md) — Supports a wide variety of large language model architectures to serve as foundations for fine-tuned adapters. ([source](https://predibase.github.io/lorax/models/base_models))
- [GPU Memory Optimizers](https://awesome-repositories.com/f/artificial-intelligence-ml/gpu-memory-optimizers.md) — Provides tools to optimize VRAM usage by balancing memory between the KV cache and adapter storage. ([source](https://loraexchange.ai/reference/launcher/))
- [Speculative Decoding Strategies](https://awesome-repositories.com/f/artificial-intelligence-ml/machine-learning/infrastructure/model-inference-serving/inference-optimization/inference-acceleration-techniques/speculative-decoding-strategies.md) — Uses draft models or projection layers to predict multiple tokens and accelerate generation speed.
- [Multi-GPU Distribution](https://awesome-repositories.com/f/artificial-intelligence-ml/model-optimization/inference-deployment/model-deployment-toolkits/distributed-deployment-utilities/multi-gpu-distribution.md) — Distributes large model weights across multiple GPUs to enable inference for models exceeding single-card memory. ([source](https://loraexchange.ai/reference/launcher/))
- [Adapter-Aware Routing](https://awesome-repositories.com/f/artificial-intelligence-ml/model-weight-management/lora-adapter-loaders/adapter-aware-routing.md) — Directs inference requests to specific nodes based on which LoRA adapters are currently loaded. ([source](https://loraexchange.ai/reference/openai_api/))
- [Weight Quantization](https://awesome-repositories.com/f/artificial-intelligence-ml/quantized-inference-runtimes/weight-quantization.md) — Reduces memory overhead by loading base models in low-precision formats while maintaining adapters in higher precision. ([source](https://loraexchange.ai/guides/quantization/))
- [Paged Key-Value Cache Stores](https://awesome-repositories.com/f/artificial-intelligence-ml/transformer-encoders/key-value-cache-reuse/paged-key-value-cache-stores.md) — Optimizes GPU memory by storing key-value caches in non-contiguous pages to reduce fragmentation.

### Data & Databases

- [Multi-Adapter Batching](https://awesome-repositories.com/f/data-databases/request-batching/inference-batching/multi-adapter-batching.md) — Processes requests using different LoRA adapters in a single GPU forward pass to maximize throughput.
- [Inference Batch Packing](https://awesome-repositories.com/f/data-databases/request-batching/inference-batch-packing.md) — Maximizes aggregate throughput by packing requests for different adapters into a single GPU forward pass. ([source](https://loraexchange.ai))
- [Inference Batching](https://awesome-repositories.com/f/data-databases/request-batching/inference-batching.md) — Groups multiple model inference requests into single hardware execution passes to maximize GPU throughput. ([source](https://loraexchange.ai/reference/python_client/))
- [LLM Schema Outputs](https://awesome-repositories.com/f/data-databases/data-governance-modeling/data-modeling-schemas/data-schemas/schema-validated-data-structures/schema-enforced-output-parsers/llm-schema-outputs.md) — Constrains model responses to valid JSON schemas to ensure predictable data formats for programmatic use.
- [JSON-Schema](https://awesome-repositories.com/f/data-databases/data-processing-pipelines/data-serialization/json-schema.md) — Constrains model responses to valid JSON schemas for programmatic consumption. ([source](https://loraexchange.ai/guides/structured_output/))
- [Structured JSON Generation](https://awesome-repositories.com/f/data-databases/data-processing-pipelines/data-serialization/json-schema/structured-json-generation.md) — Enforces JSON schema adherence during the generative process to ensure predictable data extraction. ([source](https://cdn.jsdelivr.net/gh/predibase/lorax@main/README.md))
- [Schema-Constrained Sampling](https://awesome-repositories.com/f/data-databases/json-schema-modeling/schema-validators/schema-constrained-sampling.md) — Restricts token selection during inference based on a JSON schema to force structured output.

### Networking & Communication

- [Token Streaming](https://awesome-repositories.com/f/networking-communication/real-time-event-streams/token-streaming.md) — Sends generated tokens incrementally as they are produced to reduce perceived latency. ([source](https://loraexchange.ai/reference/python_client/client/))

### Part of an Awesome List

- [Adapter Merging](https://awesome-repositories.com/f/awesome-lists/ai/model-adaptation-and-merging/adapter-merging.md) — Combines multiple adapters into a single ensemble per request using weighted merge strategies. ([source](https://loraexchange.ai/guides/merging_adapters/))
- [Inference Engines](https://awesome-repositories.com/f/awesome-lists/ai/inference-engines.md) — Multi-LoRA inference server for scaling fine-tuned model deployments.

### DevOps & Infrastructure

- [Cloud Native GPU Orchestration](https://awesome-repositories.com/f/devops-infrastructure/cloud-native-orchestration/cloud-native-gpu-orchestration.md) — Manages and scales GPU resources through Kubernetes and Helm for high-performance model serving.
- [LLM Deployment Operators](https://awesome-repositories.com/f/devops-infrastructure/kubernetes-deployments/llm-deployment-operators.md) — Offers a containerized serving system managed via Helm for high-availability LLM deployments on Kubernetes.
- [Kubernetes Orchestration](https://awesome-repositories.com/f/devops-infrastructure/kubernetes-orchestration.md) — Provides Helm charts and orchestration tools for deploying the server within Kubernetes clusters. ([source](https://loraexchange.ai/getting_started/kubernetes/))
- [Adapter Management](https://awesome-repositories.com/f/devops-infrastructure/model-serving/adapter-management.md) — Retrieves model adapters from local paths, cloud buckets, or hosted model hubs for runtime serving. ([source](https://predibase.github.io/lorax/models/adapters/))

### Operating Systems & Systems Programming

- [Adapter Offloading](https://awesome-repositories.com/f/operating-systems-systems-programming/gpu-memory-optimizations/memory-offloading-frameworks/adapter-offloading.md) — Optimizes throughput by asynchronously prefetching and offloading adapters between GPU and CPU memory. ([source](https://cdn.jsdelivr.net/gh/predibase/lorax@main/README.md))
