AI 101

What a tokenizer does to a prompt

From

Why can two phrases of the same length occupy different amounts of a model’s input?

A tokenizer converts text into units a model can process. Those units may include words, word fragments, punctuation or bytes. The vocabulary and splitting rules belong to a particular tokenizer, so character counts give only a rough indication of input length.

Two parallel strips of terracotta clay are cut into sections on a dark blue board.
A cut in the upper strip falls halfway across a piece in the lower strip.Illustrated with Seedream 5.5 · Jude Norvell Studio
Concept study
One possible split
brushed-steel
Another possible split
brushed-steel
A tokenizer can split a compound in different places. These are illustrative boundaries. Check the actual IDs in your model’s tokenizer.

Inspect a proper name

Run a model’s own tokenizer over an ordinary material name and then a made-up name for the same material. A familiar word might fit one unit while the invented term splits several ways. Token boundaries help explain length differences. They give limited information about how the final image will interpret either phrase.

Keep the instruction recoverable

When a long product brief has to fit a tool with an input limit, first extract the visible requirements. Place the subject, action and framing in a short sentence. Keep copy text, palette values and finishing notes in the production brief so the next editor can verify them independently of the rendered result.

Studio exercise

Tokenize the same sentence with two documented vocabularies. Record the split around a hyphenated material name, then write a shorter description that preserves the visual instruction.

Sources