Mlserver

MLServer is an open-source Python inference server by Seldon that serves ML models using the standardized V2 Inference Protocol — supporting multiple frameworks (Scikit-Learn, XGBoost, LightGBM, MLflow, Hugging Face Transformers) through a single unified API, providing adaptive batching that groups multiple requests into efficient tensor operations, and serving as the default inference runtime for both Seldon Core and KServe on Kubernetes, making it the production-grade serving solution for teams that need framework-agnostic model deployment.

What Is MLServer?

  • Definition: A Python-based inference server (pip install mlserver) that implements the V2 Inference Protocol (standardized by KServe/NVIDIA Triton) — providing a common REST/gRPC API for any ML model regardless of framework.
  • The Problem: Every ML framework has its own serving solution (TF Serving for TensorFlow, TorchServe for PyTorch). Teams with diverse model stacks need a unified serving layer. MLServer provides one server that handles any Python model.
  • The V2 Protocol: A standardized inference API (originally called the "KServe Predict Protocol V2") that defines endpoints like /v2/models/{model}/infer — shared by MLServer, NVIDIA Triton, and TorchServe, enabling interchangeable backends.

Core Features

FeatureDescriptionBenefit
Multi-FrameworkScikit-Learn, XGBoost, LightGBM, MLflow, HF, customOne server for all your models
Adaptive BatchingGroups incoming requests into batches automaticallyHigher GPU throughput
V2 ProtocolStandardized KServe/Triton-compatible APIPortable across serving platforms
Multi-Model ServingRun multiple models in a single server instanceResource efficiency
Custom RuntimesWrite a Python class to serve any custom modelMaximum flexibility
Parallel InferenceMulti-worker inference with configurable parallelismScale to high traffic

Supported Runtimes

RuntimeFrameworkInstall
mlserver-sklearnScikit-Learnpip install mlserver-sklearn
mlserver-xgboostXGBoostpip install mlserver-xgboost
mlserver-lightgbmLightGBMpip install mlserver-lightgbm
mlserver-mlflowMLflow modelspip install mlserver-mlflow
mlserver-huggingfaceTransformerspip install mlserver-huggingface
CustomAny Python modelImplement MLModel class

MLServer vs Alternatives

FeatureMLServerTF ServingTritonBentoML
LanguagePythonC++C++Python
ProtocolV2 (KServe standard)Custom TF protocolV2Custom
Multi-FrameworkYes (via runtimes)TensorFlow onlyYes (backends)Yes
KubernetesSeldon Core / KServe nativeManual setupKServe supportedBentoCloud
Best ForPython-first teams on K8sTensorFlow shopsGPU-heavy, multi-frameworkRapid prototyping

MLServer is the Python-native inference server for production model serving — providing a standardized V2 Protocol API, multi-framework support through pluggable runtimes, adaptive batching for throughput optimization, and native integration with Kubernetes orchestrators (Seldon Core, KServe) for teams that need a unified, scalable serving layer across diverse ML model stacks.

Take mlserver further

Ask the copilot about this term, or have our engineers assess it against your process.