@kerryhatcher/pi-cognee

extensionmaintained

Pi extension for Cognee AI memory — supports both direct SDK and MCP bridge modes. Remember, recall, forget, and manage knowledge graphs from your coding agent.

by · v0.1.0 · published 3w ago

$ pi install npm:@kerryhatcher/pi-cognee
downloads/mo
153
stars
0
last push
3w ago
open issues
0

Signals

license: MITtestspi manifest: missinginstall size: —deps: 0peer deps: 0

Download trend

No downloads in the last 12 weeks.

README

pi-cognee

Cognee AI memory for Pi — your coding agent with persistent, queryable knowledge graph memory.

Two backends, one interface:

ModeHowBest for
SDK (default)In-process via @cognee/cognee-tsZero-infrastructure, works out of the box
MCPRemote Cognee MCP serverShared memory across agents, self-hosted

Install

pi install npm:@kerryhatcher/pi-cognee

Quick Start (SDK mode)

SDK mode works immediately — no server needed. Just set your LLM API key:

# In pi:
/cognee-config llmApiKey sk-...
/cognee-config llmModel gpt-4o-mini

Then start using memory:

> Remember this: the project uses Postgres with Prisma ORM
> What database does this project use?

MCP Mode

If you run a Cognee MCP server, switch to MCP mode:

/cognee-mode mcp
/cognee-config mcpUrl http://localhost:8001/mcp

Commands

CommandDescription
/cognee-mode [sdk|mcp]Switch backend mode
/cognee-configShow all config
/cognee-config <key>Show one config value
/cognee-config <key> <value>Set a config value

Tools

All tools work identically in both modes:

ToolDescription
cognee_healthCheck connectivity
cognee_rememberStore text in memory
cognee_recallSearch memory
cognee_forgetDelete datasets or all memory
cognee_datasetsList datasets
cognee_dataset_dataList items in a dataset
cognee_create_datasetCreate a new dataset
cognee_client_infoShow client identity and mode
cognee_cognify_fileIngest a file (base64)

Config Keys

KeyDefaultDescription
modesdkBackend mode: sdk or mcp
mcpUrlhttp://localhost:8001/mcpMCP server URL
llmModelLLM model (SDK mode)
llmApiKeyLLM API key (SDK mode)
embeddingProviderEmbedding provider (SDK mode)
embeddingModelEmbedding model (SDK mode)
vectorDbProviderVector DB provider (SDK mode)
graphDbProviderGraph DB provider (SDK mode)

License

MIT