← Latest papers
💬 NLP

Tokenisation via Convex Relaxations

This paper introduces ConvexTok, a novel tokenization algorithm that formulates vocabulary construction as a linear program solvable via convex optimization, thereby outperforming traditional greedy methods in intrinsic metrics and language model efficiency while providing a certified bound on its proximity to optimality.

Original authors: Jan Tempus, Philip Whittington, Craig W. Schmidt, Dennis Komm, Tiago Pimentel

Published 2026-05-22
📖 5 min read🧠 Deep dive

Original authors: Jan Tempus, Philip Whittington, Craig W. Schmidt, Dennis Komm, Tiago Pimentel

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

The Big Picture: Packing a Suitcase

Imagine you are trying to pack a massive library of books into a single suitcase (the computer's memory) to send it to a friend. To do this efficiently, you need a tokeniser.

In the world of AI, a tokeniser is like a set of custom stamps. Instead of sending every single letter of every book (which is slow and bulky), the tokeniser groups letters into "chunks" or "tokens" (like whole words or common phrases) and sends those instead. The goal is to make the suitcase as small as possible (high compression) while still being able to reconstruct the books perfectly when they arrive.

The Problem: The "Greedy" Packer

Currently, most AI models use a method called BPE (Byte-Pair Encoding). Think of BPE as a greedy packer.

  • How it works: The packer looks at the books, finds the two most common letters that appear next to each other (like "t" and "h"), glues them together into a new stamp ("th"), and repeats this process over and over.
  • The flaw: Because the packer only looks at the immediate next step (locally optimal), they might glue together two letters that seem helpful right now but end up creating a weird, inefficient shape later that doesn't fit well in the suitcase. They make a series of small, good decisions that lead to a bad overall result. They never step back to see the "big picture."

The Solution: The "Architect" Approach (ConvexTok)

The authors of this paper, Jan Tempus and colleagues, decided to stop using the greedy packer. Instead, they built an Architect.

They realized that finding the perfect way to pack the suitcase is a math problem so hard that computers usually give up on it (it's "NP-hard"). However, they found a clever trick: Convex Relaxation.

  • The Analogy: Imagine trying to find the lowest point in a mountain range to build a house. The greedy packer just walks downhill until they hit a small valley and stops there, thinking it's the bottom.
  • The Architect's Trick: The authors smoothed out the jagged mountains into a perfect, smooth bowl (a "convex" shape). In this smooth bowl, it is mathematically easy to find the absolute lowest point.
  • The Result: They solved this smooth, easy version of the problem using a tool called a Linear Program (LP). This gave them a "blueprint" for the perfect packing.

The Catch: From Blueprint to Reality

The blueprint they got from the smooth bowl had a problem: it suggested using "half-stamps." For example, it might say, "Use 0.7 of the 'th' stamp and 0.3 of the 'ing' stamp." You can't actually print a half-stamp.

To fix this, they invented three ways to round these numbers to whole stamps (like rounding 0.7 up to 1):

  1. Deterministic (Det): Just pick the top KK stamps with the highest scores.
  2. Biased (Bias): Pick stamps that are short and efficient, even if their score is slightly lower.
  3. Integral (Int): Only pick stamps that the blueprint was 99% sure about.

What They Found (The Results)

The team tested their new ConvexTok method against the standard greedy BPE method. Here is what happened:

  1. Better Packing: The ConvexTok suitcases were consistently smaller (better compression) than the BPE suitcases. This means the AI models could read the same amount of text using fewer "tokens."
  2. The "Near-Perfect" Guarantee: One of the coolest things about their math is that it gives a "lower bound." Think of this as a certificate that says, "We know the perfect suitcase size is at least this small." They found that their ConvexTok suitcases were within 1% of that perfect theoretical size. In other words, they are almost as good as mathematically possible.
  3. AI Performance: When they trained AI models using these new suitcases:
    • The models were slightly better at understanding text (measured by "bits-per-byte").
    • On complex reasoning tasks (like answering logic puzzles), the results were mixed. Sometimes ConvexTok was better, sometimes BPE was better, but ConvexTok was never significantly worse.
  4. Stability: The greedy BPE method is very stable; if you give it slightly different books, it makes the same stamps. The new ConvexTok method is a bit more sensitive to the specific books it sees, meaning the stamps might change slightly if you change the training data.

Summary

The paper argues that we have been using a "greedy" method to teach AI how to read for too long. By using advanced math (convex optimization) to look at the entire problem at once, they created a new tokeniser called ConvexTok.

It's like switching from a person who blindly glues the most common letters together, to an architect who designs the entire suitcase layout at once. The result is a more efficient way to compress text, bringing us closer to the theoretical limit of how small we can make these AI "suitcases."

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →