Blog
Notes on AI engineering
Practical articles on AI agents, RAG, LLM integrations, evals and security — from real projects, no fluff.
Reliable LLM integrations: timeouts, retries, rate limits, fallbacks and graceful degradation
How to build LLM features that survive provider outages and rate limits: error types, exponential backoff with jitter, timeouts for streaming, idempotency for agents, model and provider fallbacks, circuit breakers, queues and degradation strategies.
Spring AI for Java and Kotlin teams: chat, RAG, tools and structured output in Spring Boot
A practical guide to Spring AI: ChatClient, advisors, chat memory, RAG with pgvector, tool calling, structured output, streaming, observability with Micrometer and testing — plus how it compares with LangChain4j.
Building an AI chat in Next.js: streaming, tools, structured output and production hardening
A hands-on guide to adding an AI assistant to a Next.js App Router application with the Vercel AI SDK: streaming responses, tool calling, structured output, rate limiting, persistence, accessibility and cost control.
Self-hosting LLMs: vLLM, Ollama and llama.cpp, GPU sizing and when it pays off
A practical guide to running open-weight language models on your own infrastructure: when self-hosting makes sense, choosing an inference server, quantization, GPU memory sizing, Kubernetes deployment, security and total cost compared with APIs.
Fine-tuning vs RAG vs prompting: how to choose the right way to customise an LLM
A decision guide for customising language models: what prompting, RAG and fine-tuning each change, what research says about knowledge injection, LoRA and QLoRA basics, data requirements, costs and common combinations.