explaingit

yohadh/thrift-memory

Analysis updated 2026-05-18

2TypeScriptAudience · developerComplexity · 2/5Setup · easy

TLDR

An MCP memory server for AI coding agents that recalls only task-relevant context under a token budget and shows exactly how many tokens were saved.

Mindmap

mindmap
  root((thrift-memory))
    What it does
      Token-budgeted recall
      Savings receipts
      Session memory
    MCP Tools
      remember
      recall
      search_memory
    Features
      Local dashboard
      Optional HTTP proxy
      Pin and disable memories
    Audience
      AI coding agents
      Developer teams
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Stop Claude Code from reloading a large MEMORY.md or AGENTS.md file every session by caching only relevant snippets

USE CASE 2

Set a hard token budget on context recall to control API costs for a team of coding agents sharing memory

USE CASE 3

See a savings receipt after each recall showing how many tokens were injected versus the full baseline

USE CASE 4

Build a memory layer for any MCP-compatible coding assistant using the remember, recall, and search_memory tools

What is it built with?

TypeScriptNode.jsnpm

How does it compare?

yohadh/thrift-memoryarashthr/hugo-flowargeneau12e/kairos-tx
Stars222
LanguageTypeScriptTypeScriptTypeScript
Setup difficultyeasymoderatehard
Complexity2/53/54/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 5min

Requires an MCP-compatible coding agent like Claude Code or Cursor. No external API keys needed.

In plain English

This is a memory server for AI coding assistants, designed to reduce the token cost of reloading project context files at the start of every session. Tools like Claude Code or Cursor often re-read the same large documentation files each time they start, which costs tokens every single time. Thrift Memory sits between the agent and those files, stores memories from previous sessions, and at each new session recalls only the pieces relevant to the current task, subject to a token limit you set. What sets this tool apart from other memory systems is that every recall operation returns a receipt showing how many tokens the full context would have cost (the baseline), how many were actually injected, and how many were saved. The formula is savedTokens equals baselineTokens minus injectedTokens. This lets you see the actual cost reduction rather than assuming savings are happening. The tool provides three main capabilities. The first is an MCP server with three commands: remember (store a memory in organization, agent, or session scope), recall (retrieve relevant memories under a hard token budget), and search_memory (browse stored memories without applying a tight budget). The second is a local dashboard where you can see savings over time and manage individual memories, including pinning important ones so they are always included. The third is an optional HTTP proxy that trims live requests and retries failed ones from rate limits. Installation is done through npm. For Claude Code users there is a plugin that sets up the MCP server and adds slash commands in one step. For other MCP-compatible tools, you add a short JSON configuration block pointing to the npx command.

Copy-paste prompts

Prompt 1
Install thrift-memory globally with npm and configure it as an MCP server in my Claude Code settings to replace my MEMORY.md reload.
Prompt 2
How does thrift-memory's recall command decide which memories are relevant to a given task? What does the relevance floor mean?
Prompt 3
Help me use thrift-memory's JavaScript library directly to store org-level memories and recall them under a 2000-token budget.
Prompt 4
What is the difference between org, agent, and session scope in thrift-memory when tracking context for a team of agents?
Prompt 5
How do I pin a memory in thrift-memory so it is always injected regardless of the task or token budget?

Frequently asked questions

What is thrift-memory?

An MCP memory server for AI coding agents that recalls only task-relevant context under a token budget and shows exactly how many tokens were saved.

What language is thrift-memory written in?

Mainly TypeScript. The stack also includes TypeScript, Node.js, npm.

How hard is thrift-memory to set up?

Setup difficulty is rated easy, with roughly 5min to a first successful run.

Who is thrift-memory for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Scan in gitsafehub Deploy in gitdeployhub yohadh on gitmyhub

Verify against the repo before relying on details.