Back to Case Studies

Private LLM App Platform on AMD GPUs

vLLM on ROCm, Private RAG and One-Click AI Apps for a Private AI Cloud

ProductionEnterprise Software & IT ServicesMar 2024 – Aug 2024MLOps, Infrastructure & Data Science
~20–30%
Lower GPU cost per model on AMD
2 vendors
Same apps on AMD MI210 and H100
One-click
LLM apps as Helm charts
5 + CTO
Team I worked in as MLOps engineer

My Role

Role
MLOps engineer, full-time consulting contract
Independent consulting
Team
Team of 5 developers + CTO
Stage reached
Live on the platform
Key decisions
  • Build vLLM from source for ROCm, patched for bf16
  • Build flash-attention kernels for AMD ROCm
  • Persistent volume for every PrivateGPT chart component

Approach at a Glance

Details
  1. 1vLLM on AMD ROCm
  2. 2Private RAG App
  3. 3Agent and Graph-RAG Apps
  4. 4Monitoring for LLM Apps
  5. 5Kubernetes Platform

Executive Summary

The client is a platform for deploying AI systems quickly while keeping them secure, private and fully owned by the customer. It runs on its own GPU infrastructure in a dedicated data center, not on a public cloud. Customers launch AI workloads and ready-made AI applications as one-click apps on Kubernetes, without sending their data to a third-party API.

I worked there as an MLOps engineer on a full-time consulting contract, in a team of five developers and the CTO. A large part of my work was adapting the LLM stack to AMD's ROCm accelerators, so that models could be served on AMD Instinct GPUs instead of only on NVIDIA hardware. Getting vLLM and its attention kernels to build and run on ROCm cut GPU hosting costs by about 20–30% per model across the platform.

I also built apps for the platform's catalogue, packaged as Helm charts:

  • a private RAG application, a self-hosted ChatGPT-style assistant over your own documents;
  • an agent application;
  • a Graph-RAG application with Neo4j;
  • monitoring for the LLM apps.

Client Profile

The platform's customers want to use LLMs without giving up control: their data stays on infrastructure they trust, the models are their own, and nothing leaves for an external provider. That creates two challenges for the platform:

  • Cost of GPUs: serving LLMs on NVIDIA GPUs is expensive, and NVIDIA hardware is in short supply. AMD Instinct accelerators are a cheaper alternative, but in 2024 the LLM software ecosystem was built mostly for NVIDIA's CUDA. Serving frameworks, attention kernels and Docker images often didn't work on AMD's ROCm out of the box.
  • Speed of deployment: a private LLM application is several services: the model server, an embedding model, a vector database and the application itself. Customers needed them deployed together, quickly and the same way every time.

Technical Approach

  1. vLLM on AMD ROCm – I adapted vLLM, the platform's LLM serving engine, to AMD Instinct MI210 accelerators:

    • Custom builds: a Docker build of vLLM from source for ROCm, with patches such as bf16 support.
    • Flash-attention on AMD: fast attention kernels built for ROCm. This was the hardest part, because they were written for NVIDIA first.
    • Running on the platform: vLLM jobs on MI210 nodes next to the existing NVIDIA H100 and DGX node pools.

    Serving models on AMD hardware lowered GPU hosting costs by about 20–30% per model across the platform.

  2. Private RAG App – A one-click PrivateGPT application packaged as a Helm chart:

    • Model serving: vLLM with an OpenAI-compatible API, for models such as Llama 3 8B Instruct.
    • Embeddings: Ollama or Hugging Face Text Embeddings Inference.
    • Vector store: pgvector on PostgreSQL.
    • Application: PrivateGPT, based on LlamaIndex, for chatting with your own documents.
    • Storage: persistent volumes for every component, so models and data survive restarts.
  3. Agent and Graph-RAG Apps – Catalogue apps for agent-based workflows and for Graph-RAG, which combines retrieval with a Neo4j knowledge graph.

  4. Monitoring for LLM Apps – Observability for the deployed LLM applications, so they can be operated in production.

  5. Kubernetes Platform – All apps run on the platform's own Kubernetes infrastructure, deployed through Helm, with GPU resource presets (AMD MI210, NVIDIA H100, DGX and smaller GPUs), persistent storage, secrets and ingress.


Business Outcome

The platform could serve LLMs on AMD accelerators as well as NVIDIA, which lowered GPU hosting costs by about 20–30% per model across the platform and gave it a way around NVIDIA supply constraints. Its customers got one-click private LLM applications, private RAG, agents and Graph-RAG with monitoring, running entirely on infrastructure they control. The apps went live on the platform.

Technologies

LLMOpsKubernetesHelmDockervLLMAMD ROCmNVIDIA H100PrivateGPTLlamaIndexpgvectorOllamaText Embeddings InferenceNeo4j

Planning something similar?

Tell me about it on a short call. New projects can start within 2 weeks