Definition
Token
A token is the unit a language model reads and generates — typically a word fragment of a few characters rather than a whole word. Text is split into tokens before processing, and models bill, limit, and reason in tokens, not characters. As a rough guide, one token is about four characters or three-quarters of a word in English.
Key takeaways
- A token is the unit a language model reads and generates — usually a word fragment, with one token roughly four characters or three-quarters of an English word.
- Tokens are the currency of LLMs: pricing, rate limits, and the context window are all measured in tokens, not characters.
- A subword tokenizer lets a fixed vocabulary represent any text, composing rare or misspelled words from smaller pieces.
- Reasoning over tokens rather than letters is why models can stumble on letter-counting and precise arithmetic.
Language models do not see raw characters or whole words; they see tokens. A tokenizer splits input text into a sequence of these subword units — common words may be a single token, while rarer or longer words break into several. This subword approach lets a fixed vocabulary represent any text, including misspellings and made-up words, by composing them from smaller pieces.
Tokens are the currency of working with models. Pricing is per token, in and out; rate limits are expressed in tokens; and the context window — how much the model can consider at once — is measured in tokens. Estimating token counts is therefore essential to managing both cost and whether a given input will even fit.
Tokenization is also why models can be quirky about characters and arithmetic: since they reason over chunks rather than individual letters or digits, tasks like counting letters or precise math can trip them up in ways that look surprising until you remember what they actually perceive.
Planoda routes model calls through an AI gateway that tracks token usage per workspace, so spend is metered against a budget before a request runs.
Related terms
- Large Language Model (LLM)A large language model is an AI system trained on vast amounts of text to predict and generate language, enabling it to answer questions, summarize, write, and reason over natural language. LLMs power modern AI assistants and agents. They are probabilistic next-token predictors, which makes them remarkably capable but also prone to confident errors.
- Context WindowA context window is the maximum amount of text — measured in tokens — that a language model can consider at once, spanning its input and its output. Everything the model 'sees' for a given request must fit inside it: the prompt, retrieved data, conversation history, and the answer. When content exceeds the window, the oldest or least relevant parts must be dropped.
- InferenceInference is the act of running a trained model to produce output from new input — the moment a model is actually used, as opposed to trained. Every prompt sent to a language model triggers an inference pass. Inference dominates the running cost and latency of AI features, since it happens on every request while training happens once.
- Model GatewayA model gateway is a unified layer that sits between an application and one or more AI model providers, routing requests through a single interface. It centralizes provider abstraction, authentication, rate limiting, cost tracking, caching, and failover — so an app can swap models, enforce spending budgets, and observe usage without rewiring every call site.
- EmbeddingAn embedding is a numeric vector that represents a piece of content — text, image, or other data — as a point in high-dimensional space, positioned so that similar items land near each other. Produced by a model trained to capture meaning, embeddings let software compare content by semantic similarity rather than by matching exact words.