SuperAPIAI Directory

turnbook

github.com · AI coding

Turnbook is a local long-term memory tool for AI coding agents. It saves every conversation verbatim into a SQLite file, with no LLM calls, no token consumption, and no account or cloud required at write time, and it can share the same memory across Claude Code, Codex, Cursor, Copilot CLI, Gemini CLI, OpenCode, and other MCP-capable applications. Retrieval happens locally, combining word search, a local embedding model (EmbeddingGemma, ONNX, no GPU required), and temporal information, then ranking results with a small learned ranking model and passing relevant snippets as prompts to the existing model to answer. The official claims include a score of 91.8% on LongMemEval, support for cross-language retrieval, adding project documents to retrieval, encrypted memory sharing across multiple computers, and exporting/importing memory files.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)
PlatformsmacOS · Linux

About this tool

Turnbook is a local long-term memory tool for AI coding agents, open-sourced under the Apache-2.0 license. Its starting point: AI sessions forget their earlier content once they end, whereas Turnbook keeps conversations verbatim and shares them across different applications and different models.

Purpose and positioning Turnbook provides coding agents with long-term memory across sessions and applications. A user can make a decision with one agent on Monday and ask a question with another agent on Wednesday, and the latter can read the earlier content. Rather than relying on an application's built-in note-style memory, it saves the original wording of every conversation and lets multiple agents on the same machine read and write the same memory.

Main capabilities

  • Verbatim saving: every turn is stored in its original words in a SQLite file, with no model calls, no token consumption, and no account or cloud required at write time.
  • Multi-application sharing: Claude Code, Codex, Cursor, Copilot CLI, Gemini CLI, OpenCode, and any MCP application can read and write the same memory.
  • Automatic injection of relevant memories: in Claude Code, Codex, Copilot CLI, Gemini CLI, and OpenCode, Turnbook looks up the needed information from past content based on the current message and adds it before the model answers.
  • Local retrieval: it combines word search, a local embedding model (Google EmbeddingGemma, 4-bit, ONNX, no GPU required), and temporal information, then ranks results with a small learned ranking model and returns a short information packet containing the source turns to the agent.
  • Cross-language: the official claim is that the search model understands Korean nearly as well as English, so you can ask in Korean about content in English memory and vice versa.
  • Project document retrieval: turnbook docs add FOLDER adds Markdown and text files in a folder to retrieval by section and keeps them updated as the files change.
  • Multi-machine sharing: turnbook folder share and turnbook folder <code> can share memory across your own multiple computers over TLS encryption, suitable for office networks or Tailscale.
  • Export and import: turnbook export FILE exports all memory, while --project FOLDER exports only conversations in that folder; the other party uses turnbook import FILE import.
  • Privacy: no account, no proprietary cloud, no telemetry; sensitive information such as keys is masked before storage; supports deleting previously entered content such as passwords.
  • Team sharing (optional): can share project decisions and progress with teammates' AI without sharing personal memory; files remain in Slack and GitHub.

How to use Windows users can download Turnbook-Setup.cmd and double-click it, or run it in PowerShell; Python is not required. Users who already have Python installed can run pip install turnbook && turnbook-install . Users who only use Claude Code and already have uv installed can also install it as a plugin. Codex users can run codex plugin marketplace add goyohan0611-png/turnbook-plugin, then run codex plugin add turnbook@turnbook. After running pip install turnbook, you can use claude mcp add turnbook -- python -m turnbook.mcp_server . to connect only the tools; turnbook-install also automatically saves every conversation. After installation, restart the AI application, use it normally for a while, then ask questions in a new session, in another application, or in another model, for example "Where did we leave off yesterday?" "Which database did the billing service choose, and why?" "What did you change in the authentication middleware last week?" No manual tagging or saving is needed.

Use cases Suitable for programming work that needs context continuity across sessions, multi-agent collaboration orchestration, switching between multiple AI programming tools, retrieving project documentation, and syncing memory across multiple personal computers.

Limitations and notes The official benchmark uses gpt-5-mini as the answer model and official gpt-4o as the judge, scoring 91.8% on LongMemEval; the official notes that its lost points mainly come from questions that require spanning multiple sessions, reasoning about dates, or obtaining the latest changed values, because Turnbook does not rewrite conversations through an LLM. The Python API and multi-user server mode have not yet been built. The official statement says it is mainly used on Windows in daily use; macOS and Linux pass tests in CI, but daily useis less frequent. To uninstall, run turnbook-uninstall; memory is kept in ~/.turnbook by default, and adding --purge clears it.

Up/Down to navigate · Enter to open · ESC to closeBrowse all tools