llm

Articles about large language models: how they work and how to use them from Python.

LLM-as-a-Judge: Online Evals, CI Gates, and Canary Sets

Your chatbot ships, users complain, and the dashboards show nothing wrong. Free-form text has no single right answer to diff against, which is why teams use an LLM as a judge to put a number on quality. The LLM evaluation tutorial scored builds offline, before anyone shipped; this post drags that judge into production with agreement audits, canary sets, and CI gates. The uncomfortable truth of shipping language models is that evaluation is the new system design. You do not ... Read More

LLM Observability with Langfuse: Traces, Spans, and Cost

LLM observability, short for Large Language Model observability, is how you see inside a language model app after it leaves your laptop: every request broken into timed steps, with the tokens, cost, latency, and quality score attached, so a slow answer or a surprise bill becomes something you can actually read instead of guess at. Evaluation tells you whether your app is good on a fixed test set; observability tells you what real users are hitting in production right now. ... Read More

LLM Tool Calling: Build a Raw Agent Loop From Scratch

LLM tool calling is what turns a chatbot into something that does real work: the model reads a request, decides it needs one of your functions, and hands that decision back as JSON for your code to run. Frameworks like LangGraph and CrewAI wrap this in nice classes, but underneath they all run one small loop. Here we build that loop by hand, about sixty lines of plain Python. “An agent is a model calling tools in a loop. Everything ... Read More