the meter
Naive 0 tok
Real 0 tok
Saved 0 tok
All demos

Algolia Agent Studio · context APIs unstable

Chat witha book

A conversation runs out of room long before it runs out of things to say. Two endpoints fix that: context/trim counts what you are carrying, context/compact folds the old part into a summary. Paste a long document below, or fetch a URL, and watch the fold happen. Bring something that overflows the model window outright and it gets folded in sections first — a summary is only useful if it fits. A fold is not a shredder, though: every folded section is still here. Dive into one to ask a question against its full original text, refold it around what you actually care about, or watch the assistant reopen a section by itself when your question needs a detail the digest dropped.

0 tokens carried
0 folds so far
0 tokens reclaimed
Like it? Use the code in your project

1 · Load the context

Whatever you paste becomes the first user message. Nothing leaves your browser except the API calls shown in the wire log.


2 · Pick the engine


3 · Watch the fold

Context carried 0 / 8,000 tokens
0 70% · compaction 8,000

Room to spare


The ledger

One band per message, height proportional to its estimated tokens. Folded history keeps its crease.

The conversation

Nothing carried yet.

Ingest a document, or just ask a question — the meter starts moving from the first turn.

Wire log 0 calls

Every request this page makes, in order. Method, path, and the stats the API sent back.