cognee

cognee

Topoteretes · Coding · Leaning

Cognee is an open-source AI memory engine that turns documents and conversations into a knowledge graph AI agents can query, giving them long-term memory across sessions.

Interface preview of cognee

About cognee

What Is Cognee

Cognee sits between your data and whatever model you already use. Give it files, chats, or URLs, and it builds a graph of entities and the relationships between them. The model stays the same; Cognee just hands it the right context before each call.

It's built for people who are tired of starting every session from scratch. A support agent forgets last week's ticket. A coding assistant loses the decisions you made an hour ago. Cognee stores that context as durable memory, so an agent can pull it back when it matters.

The catch is that memory costs money to build. Every document you remember has to be chunked, embedded, and run through an LLM to extract entities, so a large corpus takes real time and tokens. Cognee is a Python package first, which means you need a working Python environment and at least one provider API key to get anywhere.

Getting Started

  1. Install the package with pip install cognee and confirm you're on Python 3.10 or newer.
  2. Drop an LLM key into a .env file. A single OpenAI key covers both the model and the embeddings.
  3. Call await cognee.remember() with your text, files, or URLs. Cognee chunks, extracts entities, and builds the graph.
  4. Call await cognee.recall() with a plain question. It picks a retrieval strategy on its own.
  5. Wire it into an agent through the MCP server, the REST API, or a direct integration like Claude Code.

Product Information

A quick look at cognee's pricing, supported platforms, and performance.

Free PlanYes
Paid Plans$0 - $5/workspace/mo
PlatformPython (library, CLI, REST API), MCP server, Node.js and Rust SDKs, web UI
DeveloperTopoteretes
CategoryCoding · Leaning
Release DateJan 2023
Latest UpdatedOct 2025
Website Visits117.6K
Website Global Rank350.2K
API AvailabilityYes

Best for

The users, tasks, and scenarios where this tool fits best.

Users

  • Developers building AI agents
  • Engineering teams with a shared knowledge base
  • Researchers who need traceable answers

Tasks

  • Giving an agent cross-session memory
  • Building a company knowledge base
  • Codebase understanding

Scenarios

  • A support agent that remembers past tickets
  • A coding assistant across long projects
  • Early-stage research with scattered sources

Key features

One Memory API

Cognee v1.0 folds the whole lifecycle into four calls. remember stores data and builds the graph, recall queries it in plain language, improve enriches an existing graph, and forget deletes a single item, a dataset, or everything you own. You don't need to know which database sits underneath.

Knowledge Graph, Not Just Vectors

Plain RAG matches text by similarity and stops there. Cognee adds a graph of entities and relationships on top, so a query can follow connections between documents instead of only finding near-identical chunks. That's the difference between "this text looks similar" and "this person is connected to that project."

Works With Any Model

Cognee doesn't replace your LLM. Point it at OpenAI, Gemini, Anthropic, or a local Ollama model, and it prepares context for whichever one you call. Switching providers is a config change, not a rewrite.

Automatic Retrieval Routing

When you call recall, Cognee picks a retrieval strategy based on the question. Some queries want graph traversal, others want vector search, and Cognee decides instead of making you choose.

MCP Server and Agent Integrations

The bundled MCP server adds Cognee memory to Cursor, Claude Code, Codex, Cline, and other MCP-aware tools. First-party integrations cover LangGraph, CrewAI, OpenAI Agents, and more, so most agents connect without custom glue code.

Cognee Cloud and Company Brain

Cognee Cloud hosts the same engine with a web UI, managed storage, and dataset-level permissions for a team. You can also run that UI locally for free with no account. Company Brain reads Slack, GitHub, and Google Drive into shared workspace memory.

Pros and cons

Pros

  • Open source under Apache 2.0, so this open-source memory layer can be self-hosted for free.
  • Combines vector search and graph reasoning in one layer, which beats plain RAG on questions that need relationships.
  • Four-operation API keeps the learning curve short for developers who just want memory to work.
  • Broad integrations mean it slots into tools you already run, from Cursor to LangGraph.
  • A free local UI means you can try the whole platform without signing up.

Cons

  • It's a developer library first. Non-coders won't get far without writing Python.
  • Building memory burns LLM tokens and time, so a big corpus is slower and pricier than a plain index.
  • The docs are dense and change fast, which makes older tutorials risky to follow.
  • The project is young, so you may hit rough edges that a more mature database wouldn't have.

Frequently asked questions

Cognee turns your documents and conversations into a knowledge graph that AI agents can query. It gives a model long-term memory so it can recall context across separate sessions instead of starting fresh each time.