Skip to lesson
Exit
Deep Dive: Foundations & Training Systems1 / 3

2 min lesson

Transformer internals from first principles

Put yourself in this case: "Attention divides the Q·K scores by sqrt(d_k). What goes wrong if you drop this scaling entirely?" Give the clearest next step.

Step 1 of 3

Cursor's Research Scientist loop opens with fundamentals interviewers expect cold. If you stumble deriving attention or explaining why the KV cache eats inference memory, the rest of the conversation never reaches the interesting RL questions.

The bar here is not reciting the Attention Is All You Need abstract. It is reconstructing a transformer block from the matmuls up, knowing which design choices the ComposerCursor's own fast coding model, tuned for the editor and priced well below frontier models; the recommended day-to-day model for executing a plan. Press Enter for the full definition. model family actually depends on and being able to reason about where the compute and the memory go when you serve it to millions of developers.

Learn more

Full explanation

Full explanation

Interview move

When asked "why sqrt(d_k) and not d_k?", answer with the variance argument: if query and key entries are unit-variance and independent, their dot product over d_k terms has variance d_k, so dividing by sqrt(d_k) (the standard deviation) renormalizes to unit variance. Dividing by d_k would over-shrink the logits toward a uniform, low-signal softmax.