<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"><channel><title>Raphael Friedmann - Writing</title><description>Notes on CUDA, LLM inference and training on consumer GPUs, and the infrastructure underneath.</description><link>https://rfriedmann.de/</link><item><title>Continuous batching: how one GPU serves a crowd</title><link>https://rfriedmann.de/blog/continuous-batching/</link><guid isPermaLink="true">https://rfriedmann.de/blog/continuous-batching/</guid><description>A single decode stream wastes most of the GPU. The fix is to serve many requests at once and let them share each pass over the weights, but only if you stop waiting for the whole batch to finish. Continuous batching, and why it&apos;s the throughput trick that matters.</description><pubDate>Wed, 24 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Prompt injection: the security hole in every LLM app</title><link>https://rfriedmann.de/blog/prompt-injection/</link><guid isPermaLink="true">https://rfriedmann.de/blog/prompt-injection/</guid><description>The moment your AI reads anything an attacker can influence, a web page, an email, a document, that content can hijack it. There&apos;s no clean fix, only containment. The honest ops briefing on the vulnerability nobody demos.</description><pubDate>Wed, 24 Jun 2026 00:00:00 GMT</pubDate></item><item><title>How a model sees a picture</title><link>https://rfriedmann.de/blog/how-models-see-images/</link><guid isPermaLink="true">https://rfriedmann.de/blog/how-models-see-images/</guid><description>You can hand a modern AI a photo and ask about it. But a language model only understands tokens, so what happens to the image? A plain-words look at how vision gets bolted onto a model that only ever knew words.</description><pubDate>Tue, 23 Jun 2026 00:00:00 GMT</pubDate></item><item><title>How to actually ask: prompting without the magic words</title><link>https://rfriedmann.de/blog/how-to-prompt/</link><guid isPermaLink="true">https://rfriedmann.de/blog/how-to-prompt/</guid><description>There are no secret incantations. Good prompting is just clear instructions to a brilliant, literal-minded assistant with no memory. A practical guide that follows straight from how the model works.</description><pubDate>Tue, 23 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Speculative decoding: let a small model do the guessing</title><link>https://rfriedmann.de/blog/speculative-decoding/</link><guid isPermaLink="true">https://rfriedmann.de/blog/speculative-decoding/</guid><description>Decode is bandwidth-bound, so the GPU&apos;s maths units sit half-idle one token at a time. Speculative decoding spends that idle compute to verify several guessed tokens at once, for the same output, faster.</description><pubDate>Mon, 22 Jun 2026 00:00:00 GMT</pubDate></item><item><title>What the model remembers: the context window</title><link>https://rfriedmann.de/blog/the-context-window/</link><guid isPermaLink="true">https://rfriedmann.de/blog/the-context-window/</guid><description>An LLM has no memory between messages. Everything it &apos;knows&apos; about your conversation is re-read from scratch each turn, and it only fits so much. Meet the context window, the single most useful thing to understand about how chatbots behave.</description><pubDate>Mon, 22 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Pointing an LLM at your own documents (RAG, honestly)</title><link>https://rfriedmann.de/blog/your-own-documents/</link><guid isPermaLink="true">https://rfriedmann.de/blog/your-own-documents/</guid><description>Everyone wants &apos;a ChatGPT that knows our internal docs&apos;. The mechanism is called RAG, it&apos;s simpler than the hype, and most of the work is the boring retrieval half nobody demos. An ops-eye view.</description><pubDate>Sun, 21 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Why models make things up</title><link>https://rfriedmann.de/blog/why-models-make-things-up/</link><guid isPermaLink="true">https://rfriedmann.de/blog/why-models-make-things-up/</guid><description>A model will hand you a wrong fact, a fake citation or an invented function with total confidence. It&apos;s not lying and it&apos;s not broken. Here&apos;s where &apos;hallucinations&apos; actually come from, and how to work around them.</description><pubDate>Sat, 20 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Why you get a different answer every time</title><link>https://rfriedmann.de/blog/why-different-answers/</link><guid isPermaLink="true">https://rfriedmann.de/blog/why-different-answers/</guid><description>Ask a model the same thing twice and you can get two different replies. That&apos;s a deliberate dice-roll, not a glitch, and one knob controls how loaded the dice are. Meet temperature.</description><pubDate>Fri, 19 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Why an LLM trips over the r&apos;s in &apos;strawberry&apos;</title><link>https://rfriedmann.de/blog/why-models-cant-spell/</link><guid isPermaLink="true">https://rfriedmann.de/blog/why-models-cant-spell/</guid><description>Ask a top model to count the letters in a word and it often gets it wrong. Not a bug, and not stupidity: it&apos;s because the model never sees letters at all. A plain-words tour of tokens.</description><pubDate>Thu, 18 Jun 2026 00:00:00 GMT</pubDate></item><item><title>axo: learning without backprop</title><link>https://rfriedmann.de/blog/axo-learning-without-backprop/</link><guid isPermaLink="true">https://rfriedmann.de/blog/axo-learning-without-backprop/</guid><description>A from-scratch spiking neural network in C++/CUDA on one RTX 5090 that learns with purely local rules, no backprop and no central optimiser, and grows into a little creature that learns to hunt over a single continuous life.</description><pubDate>Wed, 17 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Bumping a dependency you can&apos;t read</title><link>https://rfriedmann.de/blog/bumping-a-dependency-you-cant-read/</link><guid isPermaLink="true">https://rfriedmann.de/blog/bumping-a-dependency-you-cant-read/</guid><description>Updating CUTLASS, the GEMM library under imp&apos;s 4-bit maths, from v4.5.1 to v4.5.2. In numerical CUDA a bad bump doesn&apos;t crash, it quietly returns wrong numbers. So you don&apos;t review the change, you make it verifiable.</description><pubDate>Wed, 17 Jun 2026 00:00:00 GMT</pubDate></item><item><title>How an agent uses tools and memory</title><link>https://rfriedmann.de/blog/how-an-agent-uses-tools-and-memory/</link><guid isPermaLink="true">https://rfriedmann.de/blog/how-an-agent-uses-tools-and-memory/</guid><description>The loop, one level down: how the model actually requests a tool, why its whole memory is just the growing transcript, and why long multi-step tasks fall apart.</description><pubDate>Wed, 17 Jun 2026 00:00:00 GMT</pubDate></item><item><title>When to let an agent loose: an ops take</title><link>https://rfriedmann.de/blog/letting-an-agent-loose/</link><guid isPermaLink="true">https://rfriedmann.de/blog/letting-an-agent-loose/</guid><description>An agent that can act can also act wrongly. After twenty years of running systems, here&apos;s how I decide how much rope to give one, and the guardrails that earn their keep.</description><pubDate>Wed, 17 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Online softmax, and the register that can&apos;t move</title><link>https://rfriedmann.de/blog/online-softmax-and-flashattention/</link><guid isPermaLink="true">https://rfriedmann.de/blog/online-softmax-and-flashattention/</guid><description>The deep version of FlashAttention on consumer Blackwell: how online softmax avoids the giant score matrix, and why keeping the output in registers forces raw mma.sync over WMMA.</description><pubDate>Wed, 17 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Decoding GGUF faster than llama.cpp on a 5090</title><link>https://rfriedmann.de/blog/gguf-decode-beats-llama-cpp/</link><guid isPermaLink="true">https://rfriedmann.de/blog/gguf-decode-beats-llama-cpp/</guid><description>imp decodes dense GGUF 37 to 72% faster than llama.cpp on a 5090. Not because llama.cpp is naive, it isn&apos;t, but because imp is built for one exact chip. And the one model where it loses.</description><pubDate>Tue, 16 Jun 2026 00:00:00 GMT</pubDate></item><item><title>What an AI agent actually is</title><link>https://rfriedmann.de/blog/what-is-an-ai-agent/</link><guid isPermaLink="true">https://rfriedmann.de/blog/what-is-an-ai-agent/</guid><description>Strip the buzzword and an agent is one simple thing: a language model put in a loop and handed tools, so it can do things instead of just talking about them.</description><pubDate>Tue, 16 Jun 2026 00:00:00 GMT</pubDate></item><item><title>AI that isn&apos;t an LLM</title><link>https://rfriedmann.de/blog/ai-that-isnt-an-llm/</link><guid isPermaLink="true">https://rfriedmann.de/blog/ai-that-isnt-an-llm/</guid><description>Language models get all the attention, but they&apos;re one corner of AI. A quick tour of the other big families, what each is for, and how to tell when an LLM is the wrong tool.</description><pubDate>Mon, 15 Jun 2026 00:00:00 GMT</pubDate></item><item><title>NVFP4 at the bit level</title><link>https://rfriedmann.de/blog/nvfp4-at-the-bit-level/</link><guid isPermaLink="true">https://rfriedmann.de/blog/nvfp4-at-the-bit-level/</guid><description>Every other post says &apos;4-bit&apos; and moves on. Here&apos;s what NVFP4 actually is, down to the four bits and the two scales, and the two Blackwell instructions (cvt and mma) that make it fly.</description><pubDate>Mon, 15 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Pretraining, fine-tuning, and RLHF</title><link>https://rfriedmann.de/blog/pretraining-finetuning-rlhf/</link><guid isPermaLink="true">https://rfriedmann.de/blog/pretraining-finetuning-rlhf/</guid><description>A raw trained model can continue text but won&apos;t answer you. The three stages that turn a text-continuer into a helpful assistant, and which one you actually need.</description><pubDate>Sun, 14 Jun 2026 00:00:00 GMT</pubDate></item><item><title>When not to use AI: an ops take</title><link>https://rfriedmann.de/blog/when-not-to-use-ai/</link><guid isPermaLink="true">https://rfriedmann.de/blog/when-not-to-use-ai/</guid><description>The unfashionable half of the conversation. The cases where reaching for an LLM is the wrong choice, and a simple heuristic for telling them apart from the good ones.</description><pubDate>Sun, 14 Jun 2026 00:00:00 GMT</pubDate></item><item><title>How a model learns: training, in plain words</title><link>https://rfriedmann.de/blog/how-a-model-learns/</link><guid isPermaLink="true">https://rfriedmann.de/blog/how-a-model-learns/</guid><description>Every LLM starts as random noise and is shaped by one repeated loop: guess, measure the error, nudge billions of dials. Here&apos;s how that training actually works, and why it costs a fortune.</description><pubDate>Sat, 13 Jun 2026 00:00:00 GMT</pubDate></item><item><title>When the model isn&apos;t a transformer: GDN and Mamba2</title><link>https://rfriedmann.de/blog/when-the-model-is-not-a-transformer/</link><guid isPermaLink="true">https://rfriedmann.de/blog/when-the-model-is-not-a-transformer/</guid><description>Not every LLM is built on attention. Gated DeltaNet and Mamba2 replace the score matrix with a recurrence, which gives constant memory, and one stubborn precision floor.</description><pubDate>Sat, 13 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Self-hosting an LLM for your team: usually don&apos;t</title><link>https://rfriedmann.de/blog/self-hosting-an-llm-for-your-team/</link><guid isPermaLink="true">https://rfriedmann.de/blog/self-hosting-an-llm-for-your-team/</guid><description>The tempting case for running your own model, and the honest reason most teams shouldn&apos;t: a small model&apos;s error rate burns more working time than the API fees it saves. Plus the cases where it still wins.</description><pubDate>Fri, 12 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Three kernels for a chip the ecosystem skipped</title><link>https://rfriedmann.de/blog/optimizing-kernels-consumer-blackwell/</link><guid isPermaLink="true">https://rfriedmann.de/blog/optimizing-kernels-consumer-blackwell/</guid><description>FlashAttention-2 and NVFP4 GEMM, tuned from scratch for the RTX 5090, and what the profiler taught me when every textbook optimisation turned out to be a red herring.</description><pubDate>Thu, 11 Jun 2026 00:00:00 GMT</pubDate></item><item><title>LLMs in the terminal: a sysadmin&apos;s honest list</title><link>https://rfriedmann.de/blog/llms-in-the-terminal/</link><guid isPermaLink="true">https://rfriedmann.de/blog/llms-in-the-terminal/</guid><description>The concrete, everyday ways an LLM actually earns its place in a sysadmin&apos;s workflow, and the handful of rules that keep it from causing real damage.</description><pubDate>Wed, 10 Jun 2026 00:00:00 GMT</pubDate></item><item><title>How 97,000 lines of CUDA got written by an AI agent</title><link>https://rfriedmann.de/blog/writing-cuda-with-an-agent/</link><guid isPermaLink="true">https://rfriedmann.de/blog/writing-cuda-with-an-agent/</guid><description>Both of my imp posts end with &apos;every line was written by Claude Code&apos;. This is the question that always follows: how does that actually work, and how do you trust it?</description><pubDate>Tue, 09 Jun 2026 00:00:00 GMT</pubDate></item><item><title>What an LLM can and can&apos;t do in your infrastructure</title><link>https://rfriedmann.de/blog/llms-in-your-infrastructure/</link><guid isPermaLink="true">https://rfriedmann.de/blog/llms-in-your-infrastructure/</guid><description>After twenty years of keeping systems running and a couple of years deep in LLMs, an honest split: where AI genuinely helps an ops team, and where it&apos;s a liability waiting to happen.</description><pubDate>Mon, 08 Jun 2026 00:00:00 GMT</pubDate></item><item><title>Serving 30B models at 300 tok/s on a single RTX 5090</title><link>https://rfriedmann.de/blog/serving-30b-models-rtx-5090/</link><guid isPermaLink="true">https://rfriedmann.de/blog/serving-30b-models-rtx-5090/</guid><description>Why no existing inference engine fully exploits consumer Blackwell, what NVFP4 changes, and the numbers from building one that does.</description><pubDate>Tue, 02 Jun 2026 00:00:00 GMT</pubDate></item><item><title>What a consumer RTX 5090 is missing next to a datacenter GPU</title><link>https://rfriedmann.de/blog/what-the-5090-lacks-vs-datacenter/</link><guid isPermaLink="true">https://rfriedmann.de/blog/what-the-5090-lacks-vs-datacenter/</guid><description>The 5090 and the B200 are both Blackwell, but the consumer chip is missing whole capabilities. Here is what is gone, what it costs, and why you cannot just port data centre code.</description><pubDate>Tue, 26 May 2026 00:00:00 GMT</pubDate></item><item><title>The KV cache, and what really limits long context</title><link>https://rfriedmann.de/blog/kv-cache-and-long-context/</link><guid isPermaLink="true">https://rfriedmann.de/blog/kv-cache-and-long-context/</guid><description>The beginner version calls it short-term memory. The engineering reality: the KV cache, not the weights, is what decides how long your context can get, and what runs you out of memory.</description><pubDate>Tue, 19 May 2026 00:00:00 GMT</pubDate></item><item><title>Mixture of Experts: how a 30B model runs like a 3B one</title><link>https://rfriedmann.de/blog/mixture-of-experts-explained/</link><guid isPermaLink="true">https://rfriedmann.de/blog/mixture-of-experts-explained/</guid><description>The trick behind names like Qwen3-30B-A3B: split the model into many experts, run only a few per token. Why it suits a single GPU so well, and the headaches it brings.</description><pubDate>Tue, 12 May 2026 00:00:00 GMT</pubDate></item><item><title>Prefill, decode, and the roofline that explains everything</title><link>https://rfriedmann.de/blog/prefill-vs-decode-roofline/</link><guid isPermaLink="true">https://rfriedmann.de/blog/prefill-vs-decode-roofline/</guid><description>An inference engine doesn&apos;t have one speed, it has two, and they obey opposite laws. The roofline model is the single most useful lens for reasoning about LLM performance.</description><pubDate>Tue, 05 May 2026 00:00:00 GMT</pubDate></item><item><title>How imp turns a model file into words</title><link>https://rfriedmann.de/blog/how-imp-works-model-to-token/</link><guid isPermaLink="true">https://rfriedmann.de/blog/how-imp-works-model-to-token/</guid><description>A plain-language tour of what happens inside an AI engine: how a model gets loaded, and the steps every message runs through to come back as text. Jargon explained as we go.</description><pubDate>Tue, 28 Apr 2026 00:00:00 GMT</pubDate></item><item><title>How to read a model&apos;s name and specs</title><link>https://rfriedmann.de/blog/reading-model-specs/</link><guid isPermaLink="true">https://rfriedmann.de/blog/reading-model-specs/</guid><description>Model names like Qwen3-30B-A3B-Q4_K_M look like a cat walked across the keyboard. Here&apos;s how to decode them, and the handful of specs that actually matter.</description><pubDate>Fri, 17 Apr 2026 00:00:00 GMT</pubDate></item><item><title>How a 30-billion-parameter model fits on one card</title><link>https://rfriedmann.de/blog/how-a-big-model-fits-on-one-card/</link><guid isPermaLink="true">https://rfriedmann.de/blog/how-a-big-model-fits-on-one-card/</guid><description>Quantisation, explained for normal people: how shrinking each number in a model lets a giant fit on a desktop graphics card, and what it costs.</description><pubDate>Fri, 10 Apr 2026 00:00:00 GMT</pubDate></item><item><title>What a GPU is, and why AI needs one</title><link>https://rfriedmann.de/blog/what-is-a-gpu/</link><guid isPermaLink="true">https://rfriedmann.de/blog/what-is-a-gpu/</guid><description>Why running AI means buying a graphics card, what makes a GPU different from a CPU, and why the amount of memory on the card is the number that really matters.</description><pubDate>Fri, 03 Apr 2026 00:00:00 GMT</pubDate></item><item><title>Why run AI on your own machine?</title><link>https://rfriedmann.de/blog/why-run-ai-locally/</link><guid isPermaLink="true">https://rfriedmann.de/blog/why-run-ai-locally/</guid><description>Cloud chatbots are easy and, honestly, hard to beat. The real and narrower case for running a model yourself, and the big things you give up to do it.</description><pubDate>Fri, 27 Mar 2026 00:00:00 GMT</pubDate></item><item><title>What is an LLM, and how does it actually make words?</title><link>https://rfriedmann.de/blog/what-is-an-llm/</link><guid isPermaLink="true">https://rfriedmann.de/blog/what-is-an-llm/</guid><description>A jargon-free explanation of large language models: what they are, why they&apos;re basically a very good autocomplete, and how they write one word at a time.</description><pubDate>Thu, 19 Mar 2026 00:00:00 GMT</pubDate></item></channel></rss>