← Questions

Find the planted bugs in a small Transformer training script

0
OpenAIApplied IntuitionCodingLast asked Oct 2026

A coding interview question asked in OpenAI's onsite coding round and at Applied Intuition, last asked Oct 2026. It tests transformers, pytorch and debugging.

You get a small decoder-only Transformer language model in PyTorch, its training script and a few tests. A handful of bugs are hidden in them: some crash, others let training run while the loss never improves, goes NaN, or the model…

Sign in to unlock this question

The full prompt, the worked answer and your own canvas or code with the AI tutor. New accounts get 5 credits: each one unlocks a question for good.

Where it's asked

  • OpenAI · Onsite coding · Last asked Oct 202660 min · Live coding; the problem often rebuilds a familiar system in several parts · No AI
  • Applied Intuition · Technical phone screen · Last asked Sep 202545 min · Live coding in CoderPad; the language can be fixed by the role (Python, C++, or C for embedded)

What it tests

transformers · pytorch · debugging

Your code and the AI tutor open when you unlock this question.