Cognee
Type: full-code · Vendor: Topoteretes · Language: Python · License: Apache-2.0 · Status: active · Status in practice: emerging
Knowledge-graph-backed memory control plane that turns raw documents, conversations, and structured data into a queryable graph of entities and relationships, paired with a vector store for semantic similarity.
Description. Cognee is an open-source memory framework that ingests heterogeneous sources (text, code, conversations, structured records) and runs a `.cognify` pipeline that converts plain text into chunks, embeddings, summaries, nodes, and edges. The graph store captures entities and relationships in a knowledge graph, and a parallel vector store holds embeddings for semantic similarity, so agents can search by meaning and by explicit relationships from a single query API. Cognee positions itself as a memory control plane combining embeddings, graphs, and cognitive-science approaches.
Agent loop shape. Pipeline-style ingestion plus query API. The application calls cognee.add() on raw sources and cognee.cognify() to run a six-task extraction pipeline; chunks, embeddings, summaries, nodes, and edges are persisted into a graph store and a parallel vector store. At agent turn time the application calls a search API that can combine vector similarity with graph traversal, and injects results into the prompt.
Primary use cases
- knowledge-graph memory for agents
- hybrid graph + vector retrieval
- long-term semantic memory over heterogeneous sources
- entity-relation extraction for agent context
Key concepts
- .cognify pipeline (docs) — Six ordered tasks that turn ingested plain text into chunks, embeddings, summaries, nodes, and edges in Cognee's vector and graph stores.
- Graph store → knowledge-graph-memory (docs) — Captures entities and relationships in a knowledge graph (nodes and edges that show connections between concepts).
- Vector store → vector-memory (docs) — Holds embeddings for semantic similarity; numerical representations that find conceptually related content.
- Dual storage architecture → semantic-memory (docs) — Vector + graph storage gives both semantic search and structural reasoning over the same data.
- Triplet extraction (docs) — Cognee asks the LLM to turn each chunk into graph nodes and edges as (start_node, relationship_name, end_node) triplets, with names inferred from content.
Patterns this full-code implements —
- ★Knowledge Graph Memory
Cognee's core artefact is a typed knowledge graph built by the `.cognify` pipeline: nodes are entities, edges are relationships, and they are committed to a graph database.
- ★Semantic Memory
Cognee's dual storage architecture exposes both semantic search and structural reasoning; summaries and embeddings are indexed in the vector database for semantic search, while the graph holds entiti…
- ★★Vector Memory
Cognee maintains a parallel vector store of embeddings produced by the `.cognify` pipeline, so hybrid graph+vector retrieval is possible from one query call.