Threadless Hosted memory for agents on OpenAI

Memory for agents. It forgets the way people do.

Before every model call, your agent hands over what is new and gets back the request to submit. Old episodes fade with time, their facts stay, and recall brings them back when the conversation turns to them.

Around every model call
const request = await memory.chat.decorate(memoryId, newMessages, { model, tools });
const reply = await openai.chat.completions.create(request);
memory.chat.report(memoryId, reply);
npm i @threadlessai/sdkpip install threadlessai
mem_8fK2qLmN… · turn 41activation
Each line fades by 1/√age. What keeps being used stays bright. What fades leaves its facts behind.

An example conversation, oldest message first. Older lines are drawn fainter, by one over the square root of their age, except an early line giving the launch date, which stays bright because the conversation keeps coming back to it.

01 One call, step by step

Watch a conversation get decorated.

Turn 41 of a long conversation. The agent sends one new message; the request that comes back has the history in proportion, two facts recalled from weeks ago, and an ask for the facts of what is leaving.

your agentscripted example
await memory.chat.decorate(memoryId, [lastReply, { role: 'user', content: 'Did legal come back…' }], { model, tools: [...tools, memory.chat.noteTool] })

    Ember marks what we add. Your messages come back as you sent them. The model’s reply to this request carries the note, and turns 12–15 leave the view on the next call.

    02 How it works

    Three steps around the call you already make.

    01 · before

    Decorate

    Send what is new since the last call. Get back the full request: your instructions, the facts block, the history still in view, recall, and the note ask when history is leaving.

    02 · the call

    Submit it yourself

    Send the request to OpenAI with your own key, from your own process. Chat Completions or Responses, any model, your tools. It never passes through us.

    03 · after

    Report

    Hand over the reply. It returns at once; facts are scored, what left the view is indexed and recall for the next message is prepared in the background.

    03 The code you write

    About ten lines. Your loop stays yours.

    Wrap the model call, add the note tool to your tools, and answer note calls with NOTE_RESULT. When we cannot be reached, the SDK builds the request from a local tail of recent turns and the call goes ahead.

    TypeScript
    import OpenAI from 'openai';
    import { Threadless } from '@threadlessai/sdk';
    
    const openai = new OpenAI();
    const memory = new Threadless(); // reads THREADLESS_API_KEY
    
    const tools = [...yourTools, memory.chat.noteTool];
    const request = await memory.chat.decorate(memoryId, newMessages, { model: 'gpt-5', tools });
    const reply = await openai.chat.completions.create(
      request as unknown as OpenAI.ChatCompletionCreateParamsNonStreaming,
    );
    memory.chat.report(memoryId, reply);
    04 What happens to the history

    Forgetting by time and use. Facts kept. Recall on cue.

    Truncation loses the start, summaries drift, and searching everything makes nothing stand out. People forget well instead; so does this.

    Episodes

    The conversation is cut into episodes, one per concept, never splitting a tool call from its output.

    Forgetting by time

    Each episode's activation fades with the square root of real time and rises every time it matters again. The least active leave the view first.

    Facts kept

    Before an episode leaves, your model writes its facts and milestones with the note tool. They stay in view after the turns are gone.

    Recall

    When the conversation touches something old, the facts and passages about it come back, dated, before the model is called.

    After a day of silence the next turn sleeps first: the view fades before the reply, so the agent comes back with the gap accounted for. The mechanism in full

    05 Proof

    Benchmark results are coming.

    We are running the public long-memory benchmarks against the hosted service. We will publish the scores with the method and the runs behind them. Until then we publish no numbers.

    LongMemEval
    Long-term memory in chat assistants
    pending
    LoCoMo
    Very long conversations across sessions
    pending

    Results will appear in the changelog when they are in.

    06 Pricing

    Two meters. Pricing is being finalised.

    You pay OpenAI for your model calls directly. We meter the memory: the turns it serves and the history it holds.

    per user turn

    User turns

    A decorate call that carries a new user message. Calls inside a tool loop are free.

    per GB-month

    Stored memory

    What each memory holds, measured daily and averaged over the month.

    free tier

    Start free

    A free allowance of turns and memories, no card. Enterprise terms on request.

    See what each meter covers

    Give your agent a memory that keeps what matters.