使用说明
MCP Server
Memory-Based AI Agent Backend
Overview
A backend engine for memory-based AI agents with persistent context, vector search, and multi-user support. Built on the Model Context Protocol (MCP) specification.
Features
- Persistent Memory — PostgreSQL + pgvector for long-term context
- Vector Search — Semantic retrieval of relevant memories
- Multi-user — Isolated contexts per user/session
- MCP Compliant — Standard protocol for AI tool integration
- Real-time — WebSocket support for streaming responses
Tech Stack
FastAPI React PostgreSQL Supabase pgvector LangChain WebSockets TypeScript
Architecture
Client -> FastAPI -> pgvector Search -> LangChain Agent -> Response
| |
Memory Store Context Injection
Project Structure
mcp-server/
├── backend/ # FastAPI server
├── frontend/ # React dashboard
├── database/ # SQL schemas, migrations
└── public-assets/ # Static assets
API Endpoints
POST /memory/add — Store new memory
POST /memory/search — Semantic search
GET /memory/list — List user memories
WS /chat — Streaming chat
License
MIT License
