Repolode
vectorize-io

vectorize-io/hindsight

Agent memory system that stores, recalls and reflects on memories so AI agents learn over time instead of only replaying chat history.

Stars
51,907
Forks
6,178
Open issues
148
Last commit
6 hours ago

What is it?

Hindsight is an agent memory system aimed at making AI agents that learn, not just remember. Instead of only recalling conversation history, it organizes memories into world facts, the agent's own experiences, consolidated observations, and mental models that are synthesized over time.

The core API has three operations: retain stores new information, with an LLM extracting facts, entities and relationships; recall runs semantic, BM25 keyword, entity-graph and temporal searches in parallel and merges the results; and reflect performs deeper analysis across existing memories. Memories are isolated in banks, one per user, agent or project, and the server exposes an MCP endpoint per bank.

Hindsight runs as a Docker container, a pip package, or a Helm chart on Kubernetes, backed by PostgreSQL with pgvector. Python, Node.js, Go and CLI clients are provided, and it supports a wide range of LLM providers, including fully local ones such as Ollama and LM Studio.

Key features

  • 01Retain, recall and reflect operations for storing and querying agent memories
  • 02Recall combines vector, keyword, entity-graph and temporal search with reranking
  • 03Memory banks isolate memories per user, agent or project
  • 04Built-in MCP endpoint per bank for MCP-compatible clients
  • 05Works with 25+ LLM providers, including local models via Ollama and LM Studio
  • 06Python, Node.js, Go and CLI clients plus a REST API

Use cases

  • Personalizing a chatbot by remembering each user's preferences and history
  • Giving coding agents long-term memory of a project's architecture and past sessions
  • Adding memory to an existing LLM app with a wrapper around the OpenAI or Anthropic client
  • Building autonomous agents that adapt their behavior based on accumulated feedback

Quick start

  1. 1

    Start a server with Docker

    docker run -it --pull always --name hindsight --restart unless-stopped -p 8888:8888 -p 9999:9999 -e HINDSIGHT_API_LLM_API_KEY=$OPENAI_API_KEY -v hindsight-data:/home/hindsight/.pg0 ghcr.io/vectorize-io/hindsight:latest
  2. 2

    Install the Python client

    pip install hindsight-client -U
  3. 3

    Connect the client and retain, recall, or reflect on memories

Things to know

  • Full self-hosting needs an LLM provider API key or a local model setup.
  • Intel Macs need the separate hindsight-all-slim package for embedded use.

Topics

FAQ

What is hindsight?
Agent memory system that stores, recalls and reflects on memories so AI agents learn over time instead of only replaying chat history. Hindsight is an agent memory system aimed at making AI agents that learn, not just remember. Instead of only recalling conversation history, it organizes memories into world facts, the agent's own experiences, consolidated observations, and mental models that are synthesized over time.
Is hindsight free to use? What license does it have?
hindsight is open source under the MIT license. Check the license terms before using it in commercial products.
Is hindsight still maintained?
Actively maintained. The last commit to hindsight was on Oct 20, 2026.
What can I use hindsight for?
Personalizing a chatbot by remembering each user's preferences and history Giving coding agents long-term memory of a project's architecture and past sessions Adding memory to an existing LLM app with a wrapper around the OpenAI or Anthropic client Building autonomous agents that adapt their behavior based on accumulated feedback
How do I install hindsight?
Start a server with Docker: docker run -it --pull always --name hindsight --restart unless-stopped -p 8888:8888 -p 9999:9999 -e HINDSIGHT_API_LLM_API_KEY=$OPENAI_API_KEY -v hindsight-data:/home/hindsight/.pg0 ghcr.io/vectorize-io/hindsight:latest Install the Python client: pip install hindsight-client -U Connect the client and retain, recall, or reflect on memories
Where can I get hindsight?
The source code and installation instructions are on GitHub: https://github.com/vectorize-io/hindsight

Summary generated by AI from the project's README. GitHub stats refresh daily.

Related projects