now: writing about AI and formal math
quanglee

field notes.

vol. 02 Β· no. 25
nov 26 Β· paris
~/hql hi!

I develop apps that are useful and cheap to run. Senior software engineer in Paris, math, tech and AI enthusiast, creator of dim0, minmux and kiframe. Here I write about what I learn, with figures you can poke.

also: draws, plays PES, null at Age of EmpiresbarΓ§a Β· arsenal, all the way

Latest, interactive

9 figures Β· all running code
FIG 5 Β· ATTENTIONrunning
"it" looks at "animal" Β· 66%theanimaldidn'tcrossthestreetbecauseitwastootired
latest03 oct 268 min#ai#llm

How a transformer reads

A walk through the parts of a transformer, from tokens to sampling, with a working figure for each step.

read it β†’

Writing

  1. 25

    How Claude Code records a session, and what a subagent is

    10 live figuresaiagentsclaude-code

    A Claude Code session is a file of JSON records, one per line. This lesson reads that file on my laptop, then uses it to explain resume, compaction, rewind and subagents, with the key terms defined as they come up.

    22 min
  2. 24

    How Claude Code's memory works

    6 live figuresaiagentsclaude-code

    Claude Code's memory is a folder of Markdown files per project, with a one-line index that loads into every session. I had Claude inspect its own files and transcripts on my laptop to see where memories live, what gets loaded, how they change and how to undo a change.

    9 min
  3. 23

    Shortest paths, a lesson with exercises

    10 live figuresalgorithmsgraphscompetitive-programming

    How Dijkstra's algorithm finds shortest paths and why it's right, what breaks it, and its relatives, from breadth-first search and Bellman-Ford to A*, searching from both ends, landmarks, Floyd-Warshall, many starts at once and other path problems, with ten figures to play with and exercises.

    22 min
  4. 22

    Pathfinding for games, and a planner of blocks, areas and doors

    14 live figuresalgorithmsgamespathfinding

    How games find paths on big maps. Dijkstra and A* on a grid of cells, why they slow down, what Age of Empires, StarCraft, Supreme Commander, 0 A.D., Factorio and the Spring engine do instead, and the planner I built for large maps with costly ground and thin walls.

    26 min
  5. 21

    B-trees, a lesson with exercises

    6 live figuresalgorithmsdata-structuresdatabases

    How a B-tree keeps a huge sorted index a few page reads deep, how splits, borrows and merges keep it balanced, B+ trees and page fill, the variants from B-link trees to LSM-trees, how PostgreSQL, InnoDB, SQLite, LMDB, Btrfs and the Linux kernel use them, and fifteen exercises, from proofs to building a small database.

    34 min
  6. 20

    Segment trees, a lesson with exercises

    5 live figuresalgorithmsdata-structurescompetitive-programming

    How a segment tree answers range queries and updates in O(log n), starting from buckets, with lazy propagation, searching inside the tree, the variants worth knowing, the sum tree inside prioritized experience replay, and three proofs and sixteen judge problems to practise on.

    24 min
  7. 19

    Red-black trees, a lesson with exercises

    5 live figuresalgorithmsdata-structurescompetitive-programming

    How a red-black tree keeps a binary search tree balanced with one colour bit, why that bounds its height, how insertion and deletion repair it, how it compares with AVL trees and B-trees, where Linux, Java, nginx and VS Code use it, and four proofs and ten judge problems to practise on.

    24 min
  8. 18

    How HNSW works, and why constant writes are hard on it

    6 live figuressearchvectorsalgorithms

    HNSW is the default vector index in almost every database. This post explains the graph and why a search touches so few vectors, then why building it costs so much, what that does to databases that take writes all day, and how Elasticsearch, Qdrant, Milvus, Weaviate, pgvector, ClickHouse and newer designs deal with it.

    20 min
  9. 17

    Vector search and BM25 in ClickHouse, compared with Postgres, Qdrant and the rest

    4 live figuresclickhousesearchvectors

    How the ClickHouse vector index works, how to set it up, where it stands on BM25 and hybrid search, and how it compares with pgvector, Qdrant, Elasticsearch, Milvus and Weaviate. The last section compares what coding and research agents get from grep and from vector search.

    14 min
  10. 16

    3-SAT and the exponential time hypothesis

    7 live figuresmathcomplexityai

    3-SAT asks whether a list of three-variable rules can all be true at once. This post covers why it is hard, the algorithms people built for it over forty years, the hypothesis that said they could never get much better, and the two AI-found algorithms that broke it in October 2026.

    24 min
  11. 15

    How the Claude Code team reviews code

    4 live figuresaiagentscode-review

    Claude writes about 90% of Claude Code's own code, so its team rebuilt code review around scarce human attention. A summary of their seven review layers, risk tiers and reviewer tuning, plus how one person can automate the same layers.

    17 min
  12. 14

    AI writes a lot more code, and... that's it?

    7 live figuresaiagentsproductivity

    Anthropic's report on its own workforce shows 5x the commits per engineer. In this article I look at whether the rest of the industry sees the same, and whether more code really turns into more productivity. So far the picture is less epic and a lot dimmer.

    19 min
  13. 13

    Why buy anything if you can reverse anything?

    5 live figuresaiagentsreverse-engineering

    REA, "Reverse Engineer Anything", went from about 4,200 to 148,000 GitHub stars in a week. It connects coding agents to Ghidra, JADX and other reverse-engineering tools. Across 51 public attempts and three benchmarks, agents rebuild small features they can check, and nobody has shown a full rebuild of an app of real size.

    10 min
  14. 12

    The best agent harness is a while loop and a lot of upkeep

    8 live figuresaiagentsbenchmarks

    Every coding agent is a model inside a harness, the program that runs the loop, the tools and the context. This post measures how much a harness adds on Terminal-Bench, which ones lead in October 2026, what the top ones share inside and what they are built on. Claude Code and Codex lead every current board, and mini-swe-agent, a 190-line harness, comes within a few points of them.

    23 min
  15. 11

    Mistral Large 4, seven months behind the frontier

    5 live figuresaillmbenchmarks

    Mistral Large 4 is the best model built outside the US and China and a big jump from Large 3. Independent tests put it about seven months behind the US labs and behind five Chinese open models, and a task on it costs about fifteen times more than on the small US models with the same score.

    12 min
  16. 10

    πŸ‡¦πŸ‡·πŸ Messi in numbers

    15 live figuresfootballdata

    Lionel Messi made football look like art, and no spreadsheet can hold that. But the spreadsheet still says it, plainly. The best forward who ever played and the best playmaker who ever played are the same person.

    19 min
  17. 09

    How Lean checks a proof

    4 live figuresmathleanai

    Lean is a programming language in which a theorem is a type and a proof is a program, checked by a small kernel. This post covers how that works, where it can still go wrong, and why it lets language models write proofs nobody has to read.

    8 min
  18. 08

    OpenAI's 722 math manuscripts

    5 live figuresaimathlean

    On 6 October OpenAI published 722 machine-written math papers with claims on the Unique Games Conjecture, the colouring of the plane, a $5,000 ErdΕ‘s problem and dozens of other open problems. This post goes through the claims, the parts that come with Lean proofs, and the first day of reactions.

    12 min
  19. 07

    DeepSeek V4.1 vs GLM-5.3, and how far both are from Claude Code and Codex

    6 live figuresaillmagents

    DeepSeek V4.1 and GLM-5.3 compared on agentic work and coding in two weight classes, next to the closed models behind Claude Code and Codex, with benchmark scores by task type, speed, cost per solved task and reports from daily use.

    12 min
  20. 06

    How a transformer reads

    9 live figuresaillmtransformers

    A walk through the parts of a transformer, from tokens to sampling, with a working figure for each step.

    8 min
  21. 05

    LeetCode 1977: number of ways to separate numbers

    5 live figuresleetcodedynamic-programmingalgorithms

    A hard DP that's worth knowing, because it stacks three classics in one problem. Partition DP, prefix sums and an LCP table take it from O(nΒ³) to O(nΒ²).

    7 min
  22. 04

    Behind prompt caching: a friendly intro to KV caching

    5 live figuresaillmtransformers

    What actually happens when a provider says your prompt is cached. The trick underneath is called KV caching, and it's a small idea with a big memory bill.

    7 min
  23. 03

    The real cost of running agentic AI, and how not to go broke

    4 live figuresaiagentscost

    Agents loop, and every loop resends everything. Where the tokens actually go, how prefix caching claws most of it back, which benchmarks matter when you pick a model, and a router you write yourself.

    10 min
  24. 02

    Elasticsearch best practices, and a few twists nobody mentions

    6 live figureselasticsearchinfraperformance

    What I check first when an Elasticsearch cluster gets slow. Shards, segments, refreshes, and the profiling result that changed how we fetch ids.

    10 min
  25. 01

    Notes on making this site

    4 live figuresmetabuild-logastro

    The site, twice. A one-font page I shipped in april, then a rebuild with figures you can poke, a small green critter and a status bar.

    6 min

Built

open source
ideamini-app@board agent

dim0 dim0.net β†—

A thinking canvas. Notes, mini-apps and agents on one infinite board, and the AI reads the board before it acts.

apiwebdocs~/minmux main ❯ claude● reading src/pane.rs● editing 2 files● needs input● 2 running ● 1 waiting utf-8

minmux minmux.dev β†—

A terminal for agentic coding. Tabs, splits and real shells, plus the panels that show what your agents actually did.

scenario β†’demo video

kiframe in dev β†—

An agent that turns a written scenario into a product demo video: it drives a real browser, moves like a person, and cuts the footage.