Memory Plugin for Microsoft Semantic Kernel
Semantic Kernel's plugin architecture makes it straightforward to extend AI agents with new capabilities. This guide shows how to build a REM Labs memory plugin that gives your Semantic Kernel agents persistent, cross-session recall -- with vector, full-text, and entity graph retrieval built in.
Why Semantic Kernel Needs External Memory
Semantic Kernel provides a flexible orchestration layer for building AI agents in C# and Python. But its built-in memory connectors are limited to vector-only stores. For production use cases -- where you need to recall proper nouns, handle knowledge updates, and search across thousands of past interactions -- you need multi-signal retrieval. That is what REM Labs provides.
Step 1: Install
Step 2: Build the Memory Plugin
The plugin exposes two kernel functions: recall for semantic search and remember for storing new facts. Semantic Kernel's planner can invoke these automatically when the agent decides it needs context or wants to persist something.
Step 3: Register and Use
With function_choice_behavior set to "auto", the agent automatically calls memory.recall when it determines context would help, and memory.remember when it encounters facts worth persisting.
Step 4: Direct API Access
Triple-Indexed Retrieval
Every memory stored through REM is automatically indexed three ways: vector embeddings for semantic similarity, full-text indexing for exact keyword matching, and entity graph extraction for structured relationships. Multi-signal fusion retrieval combines all three at query time, reaching 90% on LongMemEval -- far beyond what vector-only connectors achieve.
Works with C# too: The REM Labs API is a standard REST API. Use HttpClient to call POST /v1/memory/store and POST /v1/memory/search from any .NET application. See the API docs for the full endpoint reference.
Give your Semantic Kernel agents a memory
Free tier. No credit card. pip install and go.
Get started free →