[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-71929":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":18,"stars30d":19,"stars90d":16,"forks30d":16,"starsTrendScore":20,"compositeScore":21,"rankGlobal":10,"rankLanguage":10,"license":22,"archived":23,"fork":23,"defaultBranch":24,"hasWiki":23,"hasPages":25,"topics":26,"createdAt":10,"pushedAt":10,"updatedAt":31,"readmeContent":32,"aiSummary":33,"trendingCount":16,"starSnapshotCount":16,"syncStatus":34,"lastSyncTime":35,"discoverSource":36},71929,"hindsight","vectorize-io\u002Fhindsight","vectorize-io","Hindsight: Agent Memory That  Learns","https:\u002F\u002Fhindsight.vectorize.io\u002F",null,"Python",16132,918,51,30,0,269,800,1830,807,43.89,"MIT License",false,"main",true,[27,28,29,30],"agentic-ai","agents","ai-memory","memory","2026-06-12 02:02:56","\u003Cdiv align=\"center\">\n\n![Hindsight Banner](.\u002Fhindsight-docs\u002Fstatic\u002Fimg\u002Fhindsight-github-banner.png)\n\n[Documentation](https:\u002F\u002Fhindsight.vectorize.io) • [Paper](https:\u002F\u002Farxiv.org\u002Fabs\u002F2512.12818) • [Cookbook](https:\u002F\u002Fhindsight.vectorize.io\u002Fcookbook) • [Hindsight Cloud](https:\u002F\u002Fui.hindsight.vectorize.io\u002Fsignup)\n\n[![CI](https:\u002F\u002Fgithub.com\u002Fvectorize-io\u002Fhindsight\u002Factions\u002Fworkflows\u002Frelease.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002Fvectorize-io\u002Fhindsight\u002Factions\u002Fworkflows\u002Frelease.yml)\n[![Slack Community](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FSlack-Join%20Community-4A154B?logo=slack)](https:\u002F\u002Fjoin.slack.com\u002Ft\u002Fhindsight-space\u002Fshared_invite\u002Fzt-3nhbm4w29-LeSJ5Ixi6j8PdiYOCPlOgg)\n[![License: MIT](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-MIT-yellow.svg)](https:\u002F\u002Fopensource.org\u002Flicenses\u002FMIT)\n[![gitcgr](https:\u002F\u002Fgitcgr.com\u002Fbadge\u002Fvectorize-io\u002Fhindsight.svg)](https:\u002F\u002Fgitcgr.com\u002Fvectorize-io\u002Fhindsight)\n![PyPI - Downloads](https:\u002F\u002Fimg.shields.io\u002Fpypi\u002Fdm\u002Fhindsight-api?label=PyPI)\n![NPM Downloads](https:\u002F\u002Fimg.shields.io\u002Fnpm\u002Fdm\u002F%40vectorize-io%2Fhindsight-client?logoColor=orange&label=NPM&color=blue&link=https%3A%2F%2Fwww.npmjs.com%2Fpackage%2F%40vectorize-io%2Fhindsight-client)\n\u003Cbr\u002F>\n\n\u003Ca href=\"https:\u002F\u002Ftrendshift.io\u002Frepositories\u002F15603\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Ftrendshift.io\u002Fapi\u002Fbadge\u002Frepositories\u002F15603\" alt=\"vectorize-io%2Fhindsight | Trendshift\" style=\"width: 250px; height: 55px;\" width=\"250\" height=\"55\"\u002F>\u003C\u002Fa>\n\u003C\u002Fdiv>\n\n---\n\n## What is Hindsight?\n\nHindsight™ 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.\n\n\n\u003Cvideo src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F923b798d-3581-4897-bb62-9cfa5a931682\" controls>\u003C\u002Fvideo>\n\nIt eliminates the shortcomings of alternative techniques such as RAG and knowledge graph and delivers state-of-the-art performance on long term memory tasks.\n\n## Memory Performance & Accuracy\n\nHindsight 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. The current reported performance of Hindsight and other agent memory solutions as of January 2026 is shown here:\n\n![Overview](.\u002Fhindsight-docs\u002Fstatic\u002Fimg\u002Fhindsight-benchmarks.png)\n\nThe benchmark performance data for Hindsight has been independently reproduced by research collaborators at the Virginia Tech [Sanghani Center for Artificial Intelligence and Data Analytics](https:\u002F\u002Fsanghani.cs.vt.edu\u002F) and The Washington Post. Other scores are self-reported by software vendors.\n\nHindsight is being used in production at Fortune 500 enterprises and by a growing number of AI startups. \n\n## Adding Hindsight to Your AI Agents\n\nThe easiest way to use Hindsight with an existing agent is with the LLM Wrapper. You can add memory to your agent with 2 lines of code. That will swap your current LLM client out with the Hindsight wrapper. After that, memories will be stored and retrieved automatically as you make LLM calls.\n\nIf you need more control over how and when your agent stores and recalls memories, there's also a simple API you can integrate with using the SDKs or directly via HTTP.\n\n![Hindsight Banner](.\u002Fhindsight-docs\u002Fstatic\u002Fimg\u002Fmigration-code.png)\n\n---\n\n> 🤖 **Using a coding agent?** Install the Hindsight documentation skill for instant access to docs while you code:\n> ```bash\n> npx skills add https:\u002F\u002Fgithub.com\u002Fvectorize-io\u002Fhindsight --skill hindsight-docs\n> ```\n> Works with Claude Code, Cursor, and other AI coding assistants.\n\n---\n\n\n## Quick Start\n\n### Docker (recommended)\n\n```bash\nexport OPENAI_API_KEY=sk-xxx\n\ndocker run --rm -it --pull always -p 8888:8888 -p 9999:9999 \\\n  -e HINDSIGHT_API_LLM_API_KEY=$OPENAI_API_KEY \\\n  -v $HOME\u002F.hindsight-docker:\u002Fhome\u002Fhindsight\u002F.pg0 \\\n  ghcr.io\u002Fvectorize-io\u002Fhindsight:latest\n```\n\n>API: http:\u002F\u002Flocalhost:8888\n>UI: http:\u002F\u002Flocalhost:9999\n\nYou can modify the LLM provider by setting `HINDSIGHT_API_LLM_PROVIDER`. Valid options are `openai`, `anthropic`, `gemini`, `groq`, `ollama`, `lmstudio`, and `minimax`. The documentation provides more details on [supported models](https:\u002F\u002Fhindsight.vectorize.io\u002Fdeveloper\u002Fmodels).\n\n\n\n### Docker (external PostgreSQL)\n\n```bash\nexport OPENAI_API_KEY=sk-xxx\nexport HINDSIGHT_DB_PASSWORD=choose-a-password\ncd docker\u002Fdocker-compose\ndocker compose up \n```\n\n> Oracle AI Database is also supported for enterprise deployments with full feature parity. See the [storage documentation](https:\u002F\u002Fhindsight.vectorize.io\u002Fdeveloper\u002Fstorage) for details.\n\n\n>API: http:\u002F\u002Flocalhost:8888\n>UI: http:\u002F\u002Flocalhost:9999\n\n### Client\n\n```bash\npip install hindsight-client -U\n# or\nnpm install @vectorize-io\u002Fhindsight-client\n```\n\n#### Python\n\n```python\nfrom hindsight_client import Hindsight\n\nclient = Hindsight(base_url=\"http:\u002F\u002Flocalhost:8888\")\n\n# Retain: Store information\nclient.retain(bank_id=\"my-bank\", content=\"Alice works at Google as a software engineer\")\n\n# Recall: Search memories\nclient.recall(bank_id=\"my-bank\", query=\"What does Alice do?\")\n\n# Reflect: Generate disposition-aware response\nclient.reflect(bank_id=\"my-bank\", query=\"Tell me about Alice\")\n```\n\n#### Node.js \u002F TypeScript\n\n```bash\nnpm install @vectorize-io\u002Fhindsight-client\n```\n\n```javascript\nconst { HindsightClient } = require('@vectorize-io\u002Fhindsight-client');\n\nconst main = async () => {\n  const client = new HindsightClient({ baseUrl: 'http:\u002F\u002Flocalhost:8888' });\n\n  await client.retain('my-bank', 'Alice loves hiking in Yosemite');\n\n  const results = await client.recall('my-bank', 'What does Alice like?');\n  console.log(results);\n}\n\nmain();\n```\n\n\n### Python Embedded (no server required)\n\n```bash\npip install hindsight-all -U\n```\n\n```python\nimport os\nfrom hindsight import HindsightServer, HindsightClient\n\nwith HindsightServer(\n    llm_provider=\"openai\",\n    llm_model=\"gpt-5-mini\", \n    llm_api_key=os.environ[\"OPENAI_API_KEY\"]\n) as server:\n    client = HindsightClient(base_url=server.url)\n    client.retain(bank_id=\"my-bank\", content=\"Alice works at Google\")\n    results = client.recall(bank_id=\"my-bank\", query=\"Where does Alice work?\")\n```\n\n\n---\n\n## Use Cases\n\n\nHindsight is built to support conversational AI agents as well as agents that are intended to perform tasks autonomously. The ideal use case for Hindsight are agents that require a blend of these features such as AI employees that need to handle open-ended tasks, change behavior based on user feedback, and learn to perform complex tasks to automate work at a level that approximates a human work. Hindsight can be used with simple AI workflows like those built with n8n and other similar tools, but may be overkill for such applications.\n\n### Per-User Memories and Chat History\n\nOne of the simpler use cases you can use Hindsight for is to personalize AI chatbots and other conversational agents by storing and recalling memories associated with individual users.\n\nThe requirements for this use case usually look something like this:\n\n![Per-User Memories](.\u002Fhindsight-docs\u002Fstatic\u002Fimg\u002Fper-user-memory-requirements.png)\n\n\u003Cvideo src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002F4805e8e1-e7d1-47c6-a4f8-2344a5ec8906\" controls>\u003C\u002Fvideo>\n\nSatisfying these requirements in Hindsight is straightforward. When new user inputs and tool calls are ingested into Hindsight using the retain operation, custom metadata can be used to enrich the new memories. Metadata provides a convenient way to isolate memories that need to be restricted to a given user. Once these are fed into the retain operation, any raw memories and mental models that get created can be filtered when retrieving relevant memories. \n\n![Per-User Memories](.\u002Fhindsight-docs\u002Fstatic\u002Fimg\u002Fper-user-memory-howto.png)\n\n---\n\n## Architecture & Operations\n\n![Overview](.\u002Fhindsight-docs\u002Fstatic\u002Fimg\u002Fhindsight-overview.webp)\n\nMost agent memory implementations rely on basic vector search or sometimes use a knowledge graph. Hindsight uses biomimetic data structures to organize agent memories in a way that is more like how human memory works:\n\n- **World:** Facts about the world (\"The stove gets hot\")\n- **Experiences:** Agent's own experiences (\"I touched the stove and it really hurt\")\n- **Mental Models:** Learned understanding of the agent's world formed by reflecting on raw memories and experiences.\n\nMemories in Hindsight are stored in banks (i.e. memory banks). When memories are added to Hindsight, they are pushed into either the world facts or experiences memory pathway. They are then represented as a combination of entities, relationships, and time series with sparse\u002Fdense vector representations to aid in later recall.\n\nHindsight provides three simple methods to interact with the system:\n\n- **Retain:** Provide information to Hindsight that you want it to remember\n- **Recall:** Retrieve memories from Hindsight\n- **Reflect:** Reflect on memories and experiences to generate new observations and insights from existing memories.\n\n### Retain\n\nThe `retain` operation is used to push new memories into Hindsight. It tells Hindsight to _retain_ the information you pass in as an input.\n\n```python\nfrom hindsight_client import Hindsight\n\nclient = Hindsight(base_url=\"http:\u002F\u002Flocalhost:8888\")\n\n# Simple\nclient.retain(\n    bank_id=\"my-bank\",\n    content=\"Alice works at Google as a software engineer\"\n)\n\n# With context and timestamp\nclient.retain(\n    bank_id=\"my-bank\",\n    content=\"Alice got promoted to senior engineer\",\n    context=\"career update\",\n    timestamp=\"2025-06-15T10:00:00Z\"\n)\n```\n\nBehind the scenes, the retain operation uses an LLM to extract key facts, temporal data, entities, and relationships. It passes these through a normalization process to transform extracted data into canonical entities, time series, and search indexes along with metadata. These representations create the pathways for accurate memory retrieval in the recall and reflect operations. \n\n![Retain Operation](hindsight-docs\u002Fstatic\u002Fimg\u002Fretain-operation.webp)\n\n### Recall\n\nThe recall operation is used to retrieve memories. These memories can come from any of the memory types (world, experiences, etc.)\n\n```python\nfrom hindsight_client import Hindsight\n\nclient = Hindsight(base_url=\"http:\u002F\u002Flocalhost:8888\")\n\n# Simple\nclient.recall(bank_id=\"my-bank\", query=\"What does Alice do?\")\n\n# Temporal\nclient.recall(bank_id=\"my-bank\", query=\"What happened in June?\")\n```\n\nRecall performs 4 retrieval strategies in parallel:\n- Semantic: Vector similarity\n- Keyword: BM25 exact matching\n- Graph: Entity\u002Ftemporal\u002Fcausal links\n- Temporal: Time range filtering\n\n![Retain Operation](hindsight-docs\u002Fstatic\u002Fimg\u002Frecall-operation.webp)\n\nThe individual results from the retrievals are merged, then ordered by relevance using reciprocal rank fusion and a cross-encoder reranking model.\n\nThe final output is trimmed as needed to fit within the token limit.\n\n### Reflect\n\nThe reflect operation is used to perform a more thorough analysis of existing memories. This allows the agent to form new connections between memories and build a more thorough understanding of its world.\n\nFor example, the `reflect` operation can be used to support use cases such as:\n\n- An **AI Project Manager** reflecting on what risks need to be mitigated on a project.\n- A **Sales Agent** reflecting on why certain outreach messages have gotten responses while others haven't.\n- A **Support Agent** reflecting on opportunities where customers have questions not answered by current product documentation.\n\nThe `reflect` operation can also be used to handle on-demand question answering or analysis which require more deep thinking.\n\n```python\nfrom hindsight_client import Hindsight\n\nclient = Hindsight(base_url=\"http:\u002F\u002Flocalhost:8888\")\n\nclient.reflect(bank_id=\"my-bank\", query=\"What should I know about Alice?\")\n```\n\n![Retain Operation](hindsight-docs\u002Fstatic\u002Fimg\u002Freflect-operation.webp)\n\n---\n\n## Resources\n\n**Documentation:** \n- [https:\u002F\u002Fhindsight.vectorize.io](https:\u002F\u002Fhindsight.vectorize.io)\n\n**Clients:**\n- [Python](http:\u002F\u002Fhindsight.vectorize.io\u002Fsdks\u002Fpython)\n- [Node.js](http:\u002F\u002Fhindsight.vectorize.io\u002Fsdks\u002Fnodejs)\n- [REST API](https:\u002F\u002Fhindsight.vectorize.io\u002Fapi-reference)\n- [CLI](https:\u002F\u002Fhindsight.vectorize.io\u002Fsdks\u002Fcli)\n\n**Community:**\n- [Slack](https:\u002F\u002Fjoin.slack.com\u002Ft\u002Fhindsight-space\u002Fshared_invite\u002Fzt-3nhbm4w29-LeSJ5Ixi6j8PdiYOCPlOgg)\n- [GitHub Issues](https:\u002F\u002Fgithub.com\u002Fvectorize-io\u002Fhindsight\u002Fissues)\n\n---\n## Star History\n\n[![Star History Chart](https:\u002F\u002Fapi.star-history.com\u002Fsvg?repos=vectorize-io\u002Fhindsight&type=date&legend=top-left)](https:\u002F\u002Fwww.star-history.com\u002F#vectorize-io\u002Fhindsight&type=date&legend=top-left)\n---\n\n## Contributing\n\nSee [CONTRIBUTING.md](.\u002FCONTRIBUTING.md).\n\n## License\n\nMIT — see [LICENSE](.\u002FLICENSE)\n\n---\n\nBuilt by [Vectorize.io](https:\u002F\u002Fvectorize.io)\n\n\u003Cimg src=\"https:\u002F\u002Fumami-pixel.chris-latimer.workers.dev\u002F?id=a8b043e6-6964-454d-80df-69b69d3f0d50&host=github.com&url=\u002Fvectorize-io\u002Fhindsight\" width=\"1\" height=\"1\" alt=\"\" \u002F>\n","Hindsight 是一个旨在创建能够随时间学习的智能代理的记忆系统。该项目的核心功能在于通过先进的记忆机制使代理不仅能够记住信息，还能从经验中学习，从而在长期记忆任务上展现出色性能。技术上，Hindsight 采用了一种超越传统方法（如RAG和知识图谱）的新颖方式，以解决这些方法存在的局限性，并在LongMemEval基准测试中达到了顶尖水平。适合于需要高度准确且具备学习能力的对话AI场景，包括但不限于客户服务、个人助手等应用领域。",2,"2026-06-11 03:39:31","high_star"]