项目处于 alpha 阶段,API 可能在进入 Beta 前变更;下载需要 HuggingFace token 的模型前,要先创建 modelhub-secret 这个 Secret;默认创建的是 ClusterIP 服务,本地访问需要先用 kubectl port-forward 转发
llmaz
InftyAIApache-2.0活跃维护在 Kubernetes 上部署大模型推理的简易平台,支持 vLLM、SGLang、llama.cpp 等多种后端,帮你在集群里轻松跑起推理服务。
☸️ Easy, advanced inference platform for large language models on Kubernetes. 🌟 Star to support our work!
kubectl apply -f <model-and-playground-yaml>README 未说明具体显存要求;示例中 GPU 场景通过 nvidia.com/gpu 申请 1 张卡,纯 CPU 场景可参考 llama.cpp 示例
在 Kubernetes 上快速部署大模型推理服务的平台,帮你省去繁琐配置
在 Kubernetes 上部署大模型推理的简易平台,支持 vLLM、SGLang、llama.cpp 等多种后端,帮你在集群里轻松跑起推理服务。
核心能力
- 用 Model 和 Playground 两个 CRD 声明式部署 LLM 服务
- 集成 vLLM、TGI、SGLang、llama.cpp、TensorRT-LLM 等推理后端
- 自动从 HuggingFace、ModelScope、对象存储拉取并加载模型
- 借助 LWS 支持多机分布式推理与同构 xPyD
- 集成 Open WebUI 提供开箱即用的聊天界面
容易踩的坑
- v0.1.4最新正式版2025-06-10 · 2025-06-10 16:03 UTC
What's Changed
🚀 Major Features:
- Initialize documentation site by @rudeigerc in https://github.com/InftyAI/llmaz/pull/388
- feat: add TensorRT-LLM as backend by @cr7258 in https://github.com/InftyAI/llmaz/pull/392
- RFC: Gateway Metric Aggregator by @kerthcet in https://github.com/InftyAI/llmaz/pull/404
- Proposal for karpenter intergation by @carlory in https://github.com/InftyAI/llmaz/pull/439
✨ Features:
- feat: add preStop hook for llamacpp and tgi in the BackendRuntime by @cr7258 in https://github.com/InftyAI/llmaz/pull/381
- feat: support speculative decoding for llamacpp by @cr7258 in https://github.com/InftyAI/llmaz/pull/402
- Add global configmap by @kerthcet in https://github.com/InftyAI/llmaz/pull/431
- Add dispatcher & memoryStore & latencyAwarePlugin by @kerthcet in https://github.com/InftyAI/llmaz/pull/440
- feat: support runai streamer for vllm by @cr7258 in https://github.com/InftyAI/llmaz/pull/423
🐛 Bugs:
- feat: update sglang version to v0.4.5 to fix /health_generate endpoint 404 error by @cr7258 in https://github.com/InftyAI/llmaz/pull/383
- fix: remove trailing slashes from envoyproxy repository URLs in Chart.yaml by @OKevinoo in https://github.com/InftyAI/llmaz/pull/407
♻️ Cleanups:
- use lws as sub chart by @carlory in https://github.com/InftyAI/llmaz/pull/408
- Disable prometheus by default by @kerthcet in https://github.com/InftyAI/llmaz/pull/416
- Clarify Kubernetes version requirement and fallback plan in Key Features by @SanjanShiv in https://github.com/InftyAI/llmaz/pull/380
- Add ci test with helm chart by @kerthcet in https://github.com/InftyAI/llmaz/pull/432
- fix: add ut for backend runtime. by @X1aoZEOuO in https://github.com/InftyAI/llmaz/pull/428
- Add inftyai-scheduler support and config updates by @carlory in https://github.com/InftyAI/llmaz/pull/447
New Contributors
- @cr7258 made their first contribution in https://github.com/InftyAI/llmaz/pull/370
- @kenwoodjw made their first contribution in https://github.com/InftyAI/llmaz/pull/372
- @SanjanShiv made their first contribution in https://github.com/InftyAI/llmaz/pull/380
- @rudeigerc made their first contribution in https://github.com/InftyAI/llmaz/pull/388
- @OKevinoo made their first contribution in https://github.com/InftyAI/llmaz/pull/407
- @IRONICBo made their first contribution in https://github.com/InftyAI/llmaz/pull/409
- @X1aoZEOuO made their first contribution in https://github.com/InftyAI/llmaz/pull/428
Full Changelog: https://github.com/InftyAI/llmaz/compare/v0.1.3...v0.1.4
- v0.1.32025-04-22 · 2025-04-22 16:18 UTC
查看更新说明
What's Changed
🚀 Major Features:
- Add open-webui as the default chatbot by @kerthcet in https://github.com/InftyAI/llmaz/pull/357
- Add enovy ai gateway (helm dependencies + doc) by @pacoxu in https://github.com/InftyAI/llmaz/pull/360
✨ Features:
- feature: install lws controller in llmaz-system namespace by @googs1025 in https://github.com/InftyAI/llmaz/pull/354
♻️ Cleanups:
- Add default to configName by @kerthcet in https://github.com/InftyAI/llmaz/pull/349
- feat: move lws controller replicas to global values by @Whitea029 in https://github.com/InftyAI/llmaz/pull/358
- kubectl apply using
--server-sideto avoid apply failure by @pacoxu in https://github.com/InftyAI/llmaz/pull/363
New Contributors
- @Whitea029 made their first contribution in https://github.com/InftyAI/llmaz/pull/358
Full Changelog: https://github.com/InftyAI/llmaz/compare/v0.1.2...v0.1.3
- v0.1.22025-04-17 · 2025-04-17 08:45 UTC
查看更新说明
What's Changed
✨ Features:
- feat: spread container env to initContianers by @nayihz in https://github.com/InftyAI/llmaz/pull/294
- feature(BackendRuntime): support lifecycle hook fields for BackendRuntime by @googs1025 in https://github.com/InftyAI/llmaz/pull/303
- feat: add e2e test to verify service is avaliable by @nayihz in https://github.com/InftyAI/llmaz/pull/310
- feat: make elasticConfig.maxReplicas to a required parameter by @nayihz in https://github.com/InftyAI/llmaz/pull/331
- feat: metrics support for llmaz by @googs1025 in https://github.com/InftyAI/llmaz/pull/316
♻️ Cleanups:
- build(deps): bump github.com/google/go-cmp from 0.6.0 to 0.7.0 by @dependabot in https://github.com/InftyAI/llmaz/pull/283
- API refactor by @kerthcet in https://github.com/InftyAI/llmaz/pull/285
- Refactor multi-host example by @kerthcet in https://github.com/InftyAI/llmaz/pull/286
- cleanup: upgrade vllm version to v0.7.3 by @nayihz in https://github.com/InftyAI/llmaz/pull/289
- Enable debug mode in workflow by @kerthcet in https://github.com/InftyAI/llmaz/pull/290
- fix: fix some warnings when building images by @nayihz in https://github.com/InftyAI/llmaz/pull/295
- build(deps): bump sigs.k8s.io/structured-merge-diff/v4 from 4.5.0 to 4.6.0 by @dependabot in https://github.com/InftyAI/llmaz/pull/298
- build(deps): bump sigs.k8s.io/controller-runtime from 0.20.2 to 0.20.3 by @dependabot in https://github.com/InftyAI/llmaz/pull/299
- build(deps): bump github.com/onsi/ginkgo/v2 from 2.22.2 to 2.23.0 by @dependabot in https://github.com/InftyAI/llmaz/pull/297
- cleanup: upgrade e2e test tools by @nayihz in https://github.com/InftyAI/llmaz/pull/296
- chore: fix BackendRuntime crds field Commands -> Command by @googs1025 in https://github.com/InftyAI/llmaz/pull/315
- feature: add in-tree vllm BackendRuntime for preStop Hook by @googs1025 in https://github.com/InftyAI/llmaz/pull/319
- cleanup: remove kube-rbac-proxy by @nayihz in https://github.com/InftyAI/llmaz/pull/321
- use local GOPROXY by @pacoxu in https://github.com/InftyAI/llmaz/pull/322
- add image repo for lws and all backend runtime, like llama.cpp by @pacoxu in https://github.com/InftyAI/llmaz/pull/328
- build(deps): bump github.com/onsi/gomega from 1.36.3 to 1.37.0 by @dependabot in https://github.com/InftyAI/llmaz/pull/337
- build(deps): bump github.com/onsi/ginkgo/v2 from 2.23.3 to 2.23.4 by @dependabot in https://github.com/InftyAI/llmaz/pull/336
- build(deps): bump sigs.k8s.io/structured-merge-diff/v4 from 4.6.0 to 4.7.0 by @dependabot in https://github.com/InftyAI/llmaz/pull/338
- chore: refactor handleUnexpectedCondition func by @googs1025 in https://github.com/InftyAI/llmaz/pull/344
- fix(env): ensure BackendRuntimeConfig.Envs overrides base Envs by @googs1025 in https://github.com/InftyAI/llmaz/pull/341
New Contributors
- @nayihz made their first contribution in https://github.com/InftyAI/llmaz/pull/289
- @pacoxu made their first contribution in https://github.com/InftyAI/llmaz/pull/322
Full Changelog: https://github.com/InftyAI/llmaz/compare/v0.1.1...v0.1.2
- v0.1.12025-02-18 · 2025-02-18 06:57 UTC
查看更新说明
What's Changed
🚀 Major Features:
- Add recommendedConfigs to backendRuntime by @kerthcet in https://github.com/InftyAI/llmaz/pull/276
✨ Features:
- Add api reference by @kerthcet in https://github.com/InftyAI/llmaz/pull/263
- Create a clusterIP service for load balancing by @kerthcet in https://github.com/InftyAI/llmaz/pull/267
- Support shared memory size by @kerthcet in https://github.com/InftyAI/llmaz/pull/269
♻️ Cleanups:
- Rename request to limits in Flavor by @kerthcet in https://github.com/InftyAI/llmaz/pull/271
Full Changelog: https://github.com/InftyAI/llmaz/compare/v0.1.0...v0.1.1
- v0.1.02025-01-24 · 2025-01-24 17:32 UTC
查看更新说明
What's Changed
🚀 Major Features:
- Support HPA with Playground by @kerthcet in https://github.com/InftyAI/llmaz/pull/252
✨ Features:
- Support multi-host inference with Playground by @kerthcet in https://github.com/InftyAI/llmaz/pull/235
- Support multi probes in backendRuntime by @kerthcet in https://github.com/InftyAI/llmaz/pull/242
- Support hostpath models by @kerthcet in https://github.com/InftyAI/llmaz/pull/247
🐛 Bugs:
- Fix: golangci-lint slow by @kerthcet in https://github.com/InftyAI/llmaz/pull/236
♻️ Cleanups:
- Add inferenceConfig to Playground by @kerthcet in https://github.com/InftyAI/llmaz/pull/245
Full Changelog: https://github.com/InftyAI/llmaz/compare/v0.0.9...v0.1.0
用户点评
登录用户的真实使用记录,可按版本和硬件筛选还没有人点评。第一个说出真实体验的人最有价值。
llmaz (pronounced /lima:z/), aims to provide a Production-Ready inference platform for large language models on Kubernetes. It closely integrates with the state-of-the-art inference backends to bring the leading-edge researches to cloud.
🌱 llmaz is alpha now, so API may change before graduating to Beta.
Overview
Architecture
Key Features
- Easy of Use: People can quick deploy a LLM service with minimal configurations.
- Broad Backends Support: llmaz supports a wide range of advanced inference backends for different scenarios, like vLLM, Text-Generation-Inference, SGLang, llama.cpp, TensorRT-LLM. Find the full list of supported backends here.
- Heterogeneous Cluster Support: llmaz supports serving the same LLM with heterogeneous devices together with InftyAI Scheduler for the sake of cost and performance.
- Various Model Providers: llmaz supports a wide range of model providers, such as HuggingFace, ModelScope, ObjectStores. llmaz will automatically handle the model loading, requiring no effort from users.
- Distributed Inference: Multi-host & homogeneous xPyD support with LWS from day 0. Will implement the heterogeneous xPyD in the future.
- AI Gateway Support: Offering capabilities like token-based rate limiting, model routing with the integration of Envoy AI Gateway.
- Scaling Efficiency: Horizontal Pod scaling with HPA with LLM-based metrics and node(spot instance) autoscaling with Karpenter.
- Build-in ChatUI: Out-of-the-box chatbot support with the integration of Open WebUI, offering capacities like function call, RAG, web search and more, see configurations here.
Quick Start
Installation
Read the Installation for guidance.
Deploy
Here's a toy example for deploying facebook/opt-125m, all you need to do
is to apply a Model and a Playground.
If you're running on CPUs, you can refer to llama.cpp.
Note: if your model needs Huggingface token for weight downloads, please run
kubectl create secret generic modelhub-secret --from-literal=HF_TOKEN=<your token>ahead.
Model
apiVersion: llmaz.io/v1alpha1
kind: OpenModel
metadata:
name: opt-125m
spec:
familyName: opt
source:
modelHub:
modelID: facebook/opt-125m
inferenceConfig:
flavors:
- name: default # Configure GPU type
limits:
nvidia.com/gpu: 1
Inference Playground
apiVersion: inference.llmaz.io/v1alpha1
kind: Playground
metadata:
name: opt-125m
spec:
replicas: 1
modelClaim:
modelName: opt-125m
Verify
Expose the service
By default, llmaz will create a ClusterIP service named like <service>-lb for load balancing.
kubectl port-forward svc/opt-125m-lb 8080:8080
Get registered models
curl http://localhost:8080/v1/models
Request a query
curl http://localhost:8080/v1/completions \
-H "Content-Type: application/json" \
-d '{
"model": "opt-125m",
"prompt": "San Francisco is a",
"max_tokens": 10,
"temperature": 0
}'
More than quick-start
Please refer to examples for more tutorials or read develop.md to learn more about the project.
Roadmap
- Serverless support for cloud-agnostic users
- Prefill-Decode disaggregated serving
- KV cache offload support
- Model training, fine tuning in the long-term
Community
Join us for more discussions:
- Discord: #llmaz
Contributions
All kinds of contributions are welcomed ! Please following CONTRIBUTING.md.
We also have an official fundraising venue through OpenCollective. We'll use the fund transparently to support the development, maintenance, and adoption of our project.