mcp-thread-persistence-demo
MCP Thread Persistence Demo
SQLite에 채팅 스레드 메모를 저장하는 최소한의 MCP(Model Context Protocol) 서버로, 단순히 내부 함수를 직접 호출하는 것이 아니라 실제 stdio 전송을 통해 이 서버를 동작시키는 실제 클라이언트도 포함합니다.
실제 프리랜스 작업 패턴을 본뜬 학습용 예제입니다: "MCP 도구 호출을 수정/구현하여 채팅 스레드 상태를 데이터베이스에 저장하되, upsert 의미(새 항목이면 생성, 기존 항목이면 업데이트, 스레드당 중복 행 없음)를 적용하십시오."
포함 내용
server.py— MCP 서버로 세 가지 도구를 노출합니다:save_note(user_id, thread_id, content)—(user_id, thread_id)를 키로 하여 SQLite에 upsert합니다. 같은 스레드에 두 번째 호출하면 중복 행을 만들지 않고 기존 행을 업데이트합니다.get_note(user_id, thread_id)— 저장된 메모를 다시 읽어옵니다.list_threads(user_id)— 사용자의 모든 스레드를 나열합니다.
test_client.py— stdio를 통해server.py에 연결하는 실제 MCP 클라이언트로,list_tools를 호출한 다음 세 도구를 순서대로 실행합니다(같은 스레드에서save_note를 두 번 호출하여 upsert가 중복 행을 만들지 않는지 확인하는 것을 포함).
Related MCP server: Claw Memory Bridge
실행
python3.12 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
python test_client.py참고
의도적으로 mcp<2로 고정했습니다. mcp SDK의 2.x 릴리스에서는 FastMCP가 MCPServer로 이름이 바뀌고 다른 API도 변경되었습니다. 현재 실제로 존재하는 대부분의 튜토리얼/코드베이스는 여전히 1.x FastMCP API를 대상으로 하므로, 이 프로젝트도 그것을 대상으로 합니다.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
- TaprootOAuthcom.taproothq
Persistent memory layer for AI tools. Save and recall notes across Claude and other MCP clients.
MCP-native notes and memory for ChatGPT, Claude, and other AI tools.
Google Keep-style notes app with an MCP server for AI agents to read/write notes.
- HeirmosOAuthcom.heirmos
Persistent memory shared across Claude, ChatGPT, Grok and other MCP clients.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceProvides persistent memory management with SQLite, enabling storage and retrieval of conversational context with metadata via MCP tools and REST API.-
- AlicenseNot gradedqualityCmaintenanceProvides a shared memory bridge for AI agents (QClaw, Claude Code, Codex) allowing them to store, search, and retrieve notes, decisions, and conclusions via MCP tools, using local SQLite with optional TencentDB integration.MIT
- AlicenseNot gradedqualityCmaintenanceA local notes app that enables AI tools to manage notes via MCP (list, get, create, update, delete) using the same SQLite database as the GUI.16MIT
- AlicenseNot gradedqualityCmaintenanceEnables MCP-capable agents to safely and persistently participate in technocore.chat rooms and notes with local did:key identity signing, an append-only activity ledger, duplicate post protection, and injection-hardened reads.MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/BenzyTAi/mcp-thread-persistence-demo'
If you have feedback or need assistance with the MCP directory API, please join our Discord server