@pragmatic-growth/memory-mcp
v3.0.2
Published
Stdio proxy for PG-Memory - connects stdio-based MCP clients (Claude Desktop, Raycast) to your PG-Memory HTTP server using Clerk API key authentication. Supports both read-only and full edit modes.
Maintainers
Readme
PG-Memory MCP (stdio proxy)
Stdio proxy for PG-Memory - connects stdio-based MCP clients to your PG-Memory HTTP server.
Two Transport Modes
PG-Memory supports two MCP transport modes:
1. HTTP Transport (Direct)
For clients that support HTTP/SSE transport (Codex, Cursor, Claude Code):
{
"mcpServers": {
"pg-memory": {
"type": "http",
"url": "https://your-server.up.railway.app/api/mcp",
"headers": {
"X-API-Key": "your-clerk-api-key"
}
}
}
}The X-API-Key header must contain your Clerk User API Key.
2. Stdio Transport (This Package)
For clients that only support stdio (Raycast, local tools):
{
"name": "pg-memory",
"type": "stdio",
"command": "npx",
"args": ["-y", "@pragmatic-growth/memory-mcp"],
"env": {
"CLERK_API_KEY": "your-api-key"
}
}Two Operating Modes
Both transports support two operating modes:
Read-Only Mode (Default)
Safe for general use - search, read, and conversation tracking:
- Core Knowledge: search, get content, answer questions, list content
- Knowledge Graph: find related articles, get entities, search entities
- Episodic Memory: start/track conversations, get session context
- Q&A: add questions for later answering
Full Mode (with --full flag)
Includes all read-only tools PLUS write operations:
add_article- Create new articlesedit_article- Update existing articlesremove_article- Soft-delete articlesrate_answer- Rate previous answers
Installation
For Raycast (Read-Only)
{
"name": "pg-memory",
"type": "stdio",
"command": "npx",
"args": ["-y", "@pragmatic-growth/memory-mcp"],
"env": {
"CLERK_API_KEY": "your-api-key-here"
}
}For Raycast (Full Mode)
{
"name": "pg-memory-full",
"type": "stdio",
"command": "npx",
"args": ["-y", "@pragmatic-growth/memory-mcp", "--full"],
"env": {
"CLERK_API_KEY": "your-api-key-here"
}
}Global Installation
npm install -g @pragmatic-growth/memory-mcpThen run directly:
# Read-only mode (default)
CLERK_API_KEY=your-key memory-mcp
# Full mode
CLERK_API_KEY=your-key memory-mcp --fullEnvironment Variables
| Variable | Required | Description |
|----------|----------|-------------|
| CLERK_API_KEY | Yes | Clerk API key for authentication |
| MCP_SERVER_URL | No | Custom server URL (default: production) |
| MCP_MODE | No | Set to full to enable write operations |
Note: The --full CLI flag takes precedence over MCP_MODE env var.
Available Tools (21 Total)
Core Knowledge Tools (7)
| Tool | Description |
|------|-------------|
| search_knowledge | Semantic search across articles AND Q&A entries |
| get_content | Retrieve full content by ID (articles or Q&A) |
| answer_question | Full RAG pipeline with graph-augmented retrieval |
| log_unanswered | Flag questions for knowledge gap analysis |
| list_content | Browse articles and Q&A with filtering |
| list_categories | List all categories with content counts |
| health_check | Check system status and connectivity |
Knowledge Graph Tools (4)
| Tool | Description |
|------|-------------|
| find_related | Find related articles via shared entities |
| get_entities | Get named entities from an article |
| search_entities | Search entities by name or type |
| get_knowledge_graph | Get graph structure for visualization |
Episodic Memory Tools (5)
| Tool | Description |
|------|-------------|
| start_conversation | Begin tracking a conversation session |
| add_message | Add message with automatic fact extraction |
| get_conversation | Retrieve conversation with all messages |
| list_conversations | List recent conversations |
| get_session_context | Get context for follow-up questions |
Q&A Tools (1)
| Tool | Description |
|------|-------------|
| add_question | Add question for later expert answering |
Full Mode Tools (4)
| Tool | Description |
|------|-------------|
| add_article | Create a new article with automatic embedding |
| edit_article | Update article content, metadata, or category |
| remove_article | Soft-delete an article |
| rate_answer | Rate previous answers: -1, 0, or 1 |
MCP Resources
| URI | Description |
|-----|-------------|
| pgmemory://categories | List all knowledge base categories |
| pgmemory://stats | System statistics (article count, gaps, latency) |
| pgmemory://recent | Recently added/updated articles |
MCP Prompts
| Prompt | Description |
|--------|-------------|
| system-context | Knowledge base context for AI assistants |
| search-tips | Guidelines for effective search queries |
How It Works
This package runs locally as a stdio MCP server and proxies requests to the remote PG-Memory HTTP server. This allows clients that only support stdio to use the cloud-hosted knowledge base.
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ Raycast/Local │────▶│ memory-mcp │────▶│ PG-Memory │
│ (stdio only) │ │ (this package) │ │ HTTP Server │
└─────────────────┘ └─────────────────┘ └─────────────────┘
stdio proxy HTTPFor full mode to work:
- The stdio proxy must have
--fullflag ORMCP_MODE=full - The remote server must have
MCP_MODE=fullin its environment
Changelog
v3.0.2 (Latest)
- Clean npm package metadata (
binpath, repository URL) - Limit published files to the essentials
v3.0.1
- Fix HTTP transport example (
type: "http"; nocommand)
v3.0.0
- Breaking:
CLERK_API_KEYreplacesMCP_API_KEY - Adds MCP protocol negotiation for 2025-11-25, 2025-06-18, 2025-03-26
- Sends
MCP-Protocol-Versionon follow-up requests
v2.4.0
- Changed default server URL to custom domain:
https://memory.pragmaticgrowth.com/api/mcp - Simplified authentication to API key only (removed OAuth infrastructure)
- Updated dependencies to latest versions
- Improved error messages and documentation
v2.3.0
- Added unified
get_contentandlist_contenttools (replacingget_article/list_articles) - Added Knowledge Graph tools:
find_related,get_entities,search_entities,get_knowledge_graph - Added Episodic Memory tools:
start_conversation,add_message,get_conversation,list_conversations,get_session_context - Added Q&A tool:
add_question - Updated to MCP Protocol (supports 2025-11-25, 2025-06-18, 2025-03-26)
v2.1.1
- Initial public release with core knowledge tools
License
MIT
