twin memory

Limits

The size, count and length bounds on every request, how requests for one end user are ordered, and what happens when your daily budget is spent.

Request size

LimitValueOver it
Request body1,000,000 bytes413 body over 1000000 bytes
Items per add1 to 500422
Ids per list in forget (items, sessions, threads, events)up to 500 each422
Ids per status1 to 500422
about tags per itemup to 20422

The body limit is checked against Content-Length before the body is read, and counted as it arrives when the body is chunked. A large document is the usual reason to reach it: split it into several documents, or send fewer items per add.

Text lengths

FieldBound
query (search), pattern (grep)1 to 2,000 characters
Names: ids, paths, session, title, role, subject, attribute, scope, place, author fields, each aboutup to 512 characters
replacement (correct)up to 4,000 characters
Item textat least 1 character; bounded by the body limit
Dates: at, expires, before, aftermust begin YYYY-MM-DD and be a real day; up to 40 characters
X-Twin-Accountsee End users & tenancy

2026-13-01 is refused with 422, as is "last week": dates are ISO, never words.

Result sizes

RouteFieldRangeDefault
greplimit1 to 5050
latestk1 to 5010
aroundwidth1 to 52

Search takes no count. It returns what the question needs: up to 8 records in a ranked list, and passages of up to 1,400 characters each. A grep match is a fragment of up to 320 characters.

Concurrency

  • One request per end user at a time. Requests for the same end user run one after another, in the order they arrived. Requests for different end users run side by side.
  • A service-wide cap. When the service has as many requests in hand as it can take, a new one is refused at once with a plain 503. Retry with backoff.

If you add many items for one end user, send them as batches of up to 500 rather than one request per item.

Rate limits

There are no per-key or per-project request rate limits today. Plan limits Soon.

Daily budget

Two steps call a model: reading conversations into records, and the filter that keeps what a search needs. Both count against your organisation's daily budget, which you set in the console.

When the day's budget is spent:

  • Reading waits. New items still land and are searchable by their words and meaning. They are read into records the next UTC day, once the budget allows.
  • Search answers unfiltered. It returns the ranked passages and records without the model call, so it spends nothing against the budget. held is absent from the response.
  • Nothing is refused. No request fails because of the budget.

On this page