← All questions
MediumCodingSystem design

Implement a BPE tokenizer from scratch

Asked atOpenAI
1Give yourself 5 minutes
2Answer out loud, not in your head
3Then compare with the answer below

Reference answer

Then expect these follow-ups

  • Why BPE over word-level or char-level vocab?

  • (OOV handling vs sequence length.) What breaks with multilingual text if you train on English-heavy data?

Hiring now

OpenAI has 728 open roles right now

landed applies to roles like these for you, on each company’s own site, with answers written for the role.

Get 5x interviews10 free auto-applies. No card.
  • Integrated Marketing Manager - Consumer & Brand, LATAM

    Remote

  • Partner Director, IBM North America

    Remote

  • Partner Director, EY North America

    Remote

Or practice this question first

Next question