devops

Using Python for DevOps tasks like automation, scripting, and infrastructure work.

LLM Serving: Ollama Locally, vLLM in Production

Renting tokens from an API is easy; the bill and the data both leave the building. LLM serving is the craft of running an open Large Language Model yourself, fast enough for real users, and this post walks both ends of it with tested Python: Ollama on your laptop for development, vLLM in production, plus the KV-cache math that decides how many users one Graphics Processing Unit (GPU) can actually hold. “The cheapest, fastest, and most reliable components are those ... Read More

Model Drift in Python: Detect and Fix Decaying ML Models

Model drift is what happens when a machine learning model that scored 94% on launch day quietly slides to 70% six months later, without a single line of its code changing. The world moved, and the model stayed frozen in the past. This tutorial simulates that decay week by week, catches it early with Evidently, and wires up a monitoring loop that alerts and retrains before your users feel it. “A model is a photograph of the world on the ... Read More

Debugging ML Models in Python: 5 Real Failure Cases

Debugging ML models is a different sport from debugging normal code. Your Python never throws an exception, the pipeline runs green, and yet the model is quietly wrong. This tutorial walks through five real production failures the way a senior reviewer would, each one shown breaking on tested code and then fixed: training loss that diverges, a 99% accuracy that is a lie, a model that shines offline and falls apart online, label leakage caught after deploy, and a loss ... Read More