RAG retrieves. Synapse remembers.
Persistent memory infrastructure for AI agents — AES-256-GCM encrypted at rest, semantic search, MCP-native.
Synapse Layer is open-source persistent memory infrastructure for AI agents and assistants. Memories are encrypted at rest with AES-256-GCM, indexed via pgvector HNSW for semantic recall, and exposed through MCP JSON-RPC for native integration with Claude, GPT, Gemini, and any MCP-compatible client. Apache 2.0 licensed.
pip install synapse-layerfrom synapse_layer import Synapse
s = Synapse(token="sk_connect_YOUR_TOKEN")
s.save("user likes coffee")
print(s.recall("what does user like?"))Get your token at forge.synapselayer.org → Dashboard → Connect
Superpowers proved agents need discipline. Synapse provides the continuity layer that makes that discipline persistent across sessions, tools, and handoffs.
| Capability | Description |
|---|---|
| State Continuity | Persistent context across sessions and models. |
| Encrypted at Rest | AES-256-GCM encrypted at rest with per-operation random IV. |
| Agent-Native | 30-second install. Built for the MCP ecosystem. |
| Cross-Agent | Share memory between agents via A2A protocol. |
| Trust Quotient | Weighted memory ranking: confidence, recency, and usage. |
pip install synapse-layerpip install synapse-layer[langchain]
pip install synapse-layer[crewai]from synapse_layer import SynapseA2AClient
async with SynapseA2AClient(api_key="your-key") as client:
# Store a memory
await client.store_memory(
user_id="agent-001",
content="User prefers dark mode and Portuguese.",
source_type="user_input",
confidence=0.95
)
# Recall memories
result = await client.recall_memory(
user_id="agent-001",
query="What are the user preferences?",
limit=10
)from synapse_layer import SynapseMemory
memory = SynapseMemory(
api_key="your-key",
user_id="agent-001",
input_key="input",
memory_key="history"
)
# Use with any LangChain agent
variables = await memory.load_memory_variables({"input": "What do I know?"})from synapse_layer import SynapseStoreMemoryTool, SynapseRecallMemoryTool
store_tool = SynapseStoreMemoryTool(api_key="your-key")
recall_tool = SynapseRecallMemoryTool(api_key="your-key")
# Use as CrewAI tools in your agents┌───────────────────────────────────────────────────────────┐
│ YOUR AGENT │
│ (Claude, GPT-4o, Gemini, etc.) │
└─────────────────────────────┬─────────────────────────────┘
│
┌─────────┴─────────┐
│ synapse-layer │
│ Python SDK │
└─────────┬─────────┘
│
┌─────────────┴─────────────┐
│ SYNAPSE LAYER VAULT │
│ │
│ ✓ AES-256-GCM encrypted │
│ ✓ Server-side at rest │
│ ✓ Per-operation random IV │
│ ✓ Trust Quotient scoring │
└─────────────┬─────────────┘
│
┌───────┴───────┐
│ │
▼ ▼
┌────────────┐ ┌────────────┐
│ Session 2 │ │ Session 3 │
│ (GPT-4o) │ │ (Gemini) │
│ recalls ✓ │ │ recalls ✓ │
└────────────┘ └────────────┘
| Layer | Implementation |
|---|---|
| Encryption | AES-256-GCM with per-operation random IV. GCM auth tag validated on every read. |
| Key Management | Keys rotated per environment. Never logged. |
| Privacy | Differential privacy via Gaussian noise on embeddings. |
| Validation | Intent validation pipeline with confidence scoring. |
All sensitive data is AES-256-GCM encrypted at rest with per-operation random IV. Designed for LGPD/GDPR alignment.
Core async client for the Synapse Layer A2A protocol (JSON-RPC 2.0 over HTTPS).
| Method | Description |
|---|---|
store_memory() |
Store encrypted memory with semantic embedding |
recall_memory() |
Retrieve memories ranked by Trust Quotient |
create_handover() |
Create signed context for cross-agent transfer |
forget_memory() |
Soft-delete specific memories |
LangChain BaseMemory adapter for persistent agent memory.
LangChain BaseChatMessageHistory for persistent chat histories.
SynapseStoreMemoryTool— Store memoriesSynapseRecallMemoryTool— Recall memoriesSynapseHandoverTool— Cross-agent context transfer
Memories are ranked using a weighted scoring formula:
TQ = f(confidence, recency, usage)
Higher TQ scores surface the most relevant and reliable memories first. The exact weights are proprietary and dynamically calibrated.
| Project | Description |
|---|---|
| synapse-layer | Core server — MCP endpoint, encryption engine, pgvector indexing |
| synapse-layer-skill | MCP skill configuration for Claude Desktop, Cursor, Windsurf |
| synapse-layer-langgraph | LangGraph checkpoint saver with encrypted state persistence |
- Website: synapselayer.org
- Forge (Dashboard): forge.synapselayer.org
- Documentation: synapselayer.org/docs
- Issues: GitHub Issues
- MCP Server: Smithery
Apache 2.0 — see LICENSE for details.
Synapse Layer
Persistent memory infrastructure for AI agents — AES-256-GCM encrypted at rest, semantic search, MCP-native.
PyPI ·
Website ·
Forge