This post exists to break things on purpose. Every paragraph below leans on a different part of the publishing pipeline, from the dropcap you are reading now to the interactive plot near the end. When it is all stacked in one place — a single feature-test page instead of hunting across the archive — a regression has nowhere to hide.
Along the way we touch inline code like torch.compile, a link back to the blog, and the kind of emphasis that separates a claim from a measurement.
Where the words go
A short list of what a reader should be able to lean on:
- Headings that step down cleanly, from the title through h2 and h3.
- Body type set for distance reading, not for skimming.
- Code that reads like a printed listing, not a wall of colour.
And an ordered version, because ordered lists render differently:
- Parse the Markdown once.
- Hand the tree to the diagram and math plugins.
- Let the reader page style whatever falls out.
Recall tells you the answer is in the room. It never tells you whether anyone in the room was listening.
— a note taped to my monitor
Code, three ways
Python, with the editorial code chrome — three window dots and a language label:
def rerank(query, candidates, ce, *, keep=5, margin=0.15):
# score every (query, passage) pair with a cross-encoder
scores = ce.predict([(query, c.text) for c in candidates])
ranked = sorted(zip(scores, candidates), reverse=True)
top = [c for s, c in ranked[:keep] if s > ranked[0][0] - margin]
return topA little JavaScript, to prove the language label follows the fence:
const debounce = (fn, ms) => {
let t;
return (...args) => { clearTimeout(t); t = setTimeout(() => fn(...args), ms); };
};And a shell one-liner:
rg --files-with-matches "TODO" src | xargs -I{} echo "still open: {}"A diagram that has to survive both themes
The retrieval loop, drawn with D2 and re-themed to the page — the connectors carry the accent and the text stays readable whether you are in light or dark:
The maths should be typeset, not screenshotted
Inline, the per-sequence cache cost is bytes. Set as a display block, the same idea gets room to breathe and a rule above and below:
A figure with a caption
The live plot
The interactive figure below is computed at publish time and hydrated on scroll — drag to rotate, scroll to zoom, and flip to the source with the Code toggle. It sits on the dark plot surface so it reads the same in either theme.
import numpy as np
import plotly.graph_objects as go
x = np.linspace(-6, 6, 40)
y = np.linspace(-6, 6, 40)
X, Y = np.meshgrid(x, y)
R = np.sqrt(X**2 + Y**2)
Z = np.sin(R) / (R + 1e-6)
fig = go.Figure(go.Surface(z=Z, x=x, y=y, colorscale="Viridis"))
fig.update_layout(scene=dict(xaxis_title="x", yaxis_title="y", zaxis_title="amplitude"))
fig.show()One table, then we stop
| Store | Reads/s | p99 (ms) | Notes |
|---|---|---|---|
| in-process | 1.2M | 0.4 | no network, no durability |
| local SSD KV | 180k | 2.1 | survives a restart |
| replicated KV | 44k | 9.7 | survives a node |
That is the whole kit on one page. If the diagram is a grey box, the plot is on a pale mat, or the maths is an image, something regressed — and now it is obvious at a glance.
Comments
Sign in to join inLoading comments…