AWS Builder Center
Benchmarking local LLMs for enterprise use: what I learned comparing Ollama, vLLM and llama.cpp

Benchmarking local LLMs for enterprise use: what I learned comparing Ollama, vLLM and llama.cpp

How I compared four open-source LLMs on enterprise tasks using Promptfoo, an LLM judge and response-time monitoring, and what I learned about serving them locally.

Running an LLM in the cloud is easy. Running one on your own infrastructure, with predictable quality and speed, is a different problem. During an internship on a sovereign local AI infrastructure project, I built a pipeline to compare open-source models on realistic enterprise tasks. Here is the approach and what I took away from it.
The goal
The question was simple: can local models replace a cloud LLM for everyday enterprise tasks, and which one should we choose? That comes down to two things: how good the answers are and how fast they arrive.
The setup
  • Test suite: a broad set of enterprise-style prompts run with Promptfoo, covering the kind of requests employees actually make.
  • Models: Mistral, Llama 3, Qwen and Gemma.
  • Serving engines: Ollama, vLLM and llama.cpp, so I could compare the engine as well as the model.
  • Monitoring: metrics sent to InfluxDB and visualized in Grafana dashboards, so performance is visible over time instead of buried in logs.
How I evaluated
  • Quality: an LLM-as-a-judge scores each answer against the expected behavior of the prompt. This works well for open-ended answers, where exact-match checks fall short.
  • Speed: I measured response time for every request and tracked it per model and per serving engine.
Lessons learned
  • Measure quality and speed together. A model that answers well but slowly may not be usable in practice.
  • An LLM judge makes it possible to evaluate open-ended answers at scale, as long as its criteria are clear.
  • Dashboards help. Watching response times over time is more informative than a single average.
What’s next
I am extending the test suite with adversarial, multilingual and long-context cases, since multilingual use matters a lot in my context. I also plan to compare these local results with a managed option on AWS.
Questions or suggestions? Leave a comment.
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article