vectorize-io / hindsight

vectorize-io / hindsight

Documentation • Integrations • Cookbook • Benchmarks • Paper • Hindsight Cloud 文档 • 集成 • 开发指南 • 基准测试 • 论文 • Hindsight 云服务

What is Hindsight?

什么是 Hindsight?

Hindsight™ is an agent memory system built to create smarter agents that learn over time. Most agent memory systems focus on recalling conversation history. Hindsight is focused on making agents that learn, not just remember. Hindsight™ 是一个智能体记忆系统,旨在构建能够随时间推移不断学习的更智能的智能体。大多数智能体记忆系统侧重于回溯对话历史,而 Hindsight 则专注于让智能体实现“学习”,而不仅仅是“记忆”。

It eliminates the shortcomings of alternative techniques such as RAG and knowledge graph and delivers state-of-the-art performance on long-term memory tasks. 它消除了 RAG(检索增强生成)和知识图谱等替代技术的缺陷,并在长期记忆任务中提供了业界领先的性能。


Memory Performance & Accuracy

记忆性能与准确性

Hindsight is the most accurate agent memory system ever tested according to benchmark performance. It has achieved state-of-the-art performance on the LongMemEval benchmark, widely used to assess memory system performance across a variety of conversational AI scenarios. 根据基准测试表现,Hindsight 是迄今为止测试过的最准确的智能体记忆系统。它在 LongMemEval 基准测试中达到了业界领先水平,该基准测试被广泛用于评估各种对话式 AI 场景下的记忆系统性能。

The current reported performance of Hindsight and other agent memory solutions as of January 2026 is shown here: 截至 2026 年 1 月,Hindsight 及其他智能体记忆解决方案的当前报告性能如下所示:

Live, continuously updated results — including per-model accuracy, latency and cost — are published at benchmarks.hindsight.vectorize.io. 实时且持续更新的结果(包括各模型的准确率、延迟和成本)已发布在 benchmarks.hindsight.vectorize.io。

The benchmark performance data for Hindsight has been independently reproduced by research collaborators at the Virginia Tech Sanghani Center for Artificial Intelligence and Data Analytics and The Washington Post. Other scores are self-reported by software vendors. Hindsight 的基准测试数据已由弗吉尼亚理工大学 Sanghani 人工智能与数据分析中心以及《华盛顿邮报》的研究合作者独立复现。其他分数则由软件供应商自行报告。

Hindsight is being used in production at Fortune 500 enterprises and by a growing number of AI startups. Hindsight 目前正被财富 500 强企业以及越来越多的 AI 初创公司用于生产环境。


🤖 Using a coding agent?

🤖 正在使用编程智能体?

Install the Hindsight documentation skill for instant access to docs while you code: 安装 Hindsight 文档技能,以便在编程时即时查阅文档:

npx skills add https://github.com/vectorize-io/hindsight --skill hindsight-docs

Works with Claude Code, Cursor, and other AI coding assistants. 适用于 Claude Code、Cursor 及其他 AI 编程助手。


Quick Start

快速开始

1. Start a server

1. 启动服务器

Docker (recommended) Docker(推荐)

export OPENAI_API_KEY=sk-xxx
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

API: http://localhost:8888 UI: http://localhost:9999

Hindsight works with 25+ LLM providers via HINDSIGHT_API_LLM_PROVIDER — hosted (openai, anthropic, gemini, groq, bedrock, vertexai, minimax, deepseek, atlas, meta, …), fully local (ollama, lmstudio, llamacpp), any OpenAI-compatible endpoint, and gateways (litellm, litellmrouter) that reach the rest. Hindsight 通过 HINDSIGHT_API_LLM_PROVIDER 支持 25 种以上的 LLM 提供商,包括托管服务(OpenAI、Anthropic、Gemini、Groq、Bedrock、VertexAI、Minimax、DeepSeek、Atlas、Meta 等)、完全本地化运行(Ollama、LMStudio、LlamaCPP)、任何兼容 OpenAI 的端点,以及连接其余服务的网关(LiteLLM、LiteLLMRouter)。

Existing subscriptions work too: openai-codex (ChatGPT Plus/Pro), claude-code (Claude Pro/Max), cursor (Cursor) and github-copilot (GitHub Copilot) need no API key. See supported models. 现有的订阅服务同样适用:openai-codex (ChatGPT Plus/Pro)、claude-code (Claude Pro/Max)、cursor (Cursor) 和 github-copilot (GitHub Copilot) 无需 API 密钥。请参阅支持的模型列表。


2. Connect a client

2. 连接客户端

pip install hindsight-client -U # Python
npm install @vectorize-io/hindsight-client # Node.js / TypeScript
go get github.com/vectorize-io/hindsight/hindsight-clients/go # Go
curl -fsSL https://hindsight.vectorize.io/get-cli | bash # CLI

Python

from hindsight_client import Hindsight
client = Hindsight(base_url="http://localhost:8888")

# Retain: Store information
client.retain(bank_id="my-bank", content="Alice works at Google as a software engineer")

# Recall: Search memories
client.recall(bank_id="my-bank", query="What does Alice do?")

# Reflect: Generate disposition-aware response
client.reflect(bank_id="my-bank", query="Tell me about Alice")

Node.js / TypeScript

const { HindsightClient } = require('@vectorize-io/hindsight-client');
const main = async () => {
  const client = new HindsightClient({ baseUrl: 'http://localhost:8888' });
  await client.retain('my-bank', 'Alice loves hiking in Yosemite');
  const results = await client.recall('my-bank', 'What does Alice like?');
  console.log(results);
}
main();

Adding Hindsight to Your Agent

将 Hindsight 添加到你的智能体

LLM Wrapper (2 lines of code) LLM 包装器(仅需 2 行代码)

The easiest way to add memory to an existing agent is to… 为现有智能体添加记忆的最简单方法是……