Lemmalog
JordyZomer/lemmalog
Externalize working memory and logical state into the lemmalog Datalog engine (MCP).
Persistent memory enhancement for AI agents. An agent skill from sopaco/cortex-mem.
$ npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install sopaco/cortex-mem cortex-mem-mcp --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/sopaco/cortex-mem.git skills-src && mkdir -p .claude/skills && cp -r skills-src/cortex-mem-mcp/skill .claude/skills/cortex-mem-mcp && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "cortex-mem-mcp" agent skill from https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skill into .claude/skills/cortex-mem-mcp/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "cortex-mem-mcp", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skillType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install sopaco/cortex-mem cortex-mem-mcp --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sopaco/cortex-mem.git skills-src && mkdir -p .agents/skills && cp -r skills-src/cortex-mem-mcp/skill .agents/skills/cortex-mem-mcp && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "cortex-mem-mcp" agent skill from https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skill into .agents/skills/cortex-mem-mcp/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "cortex-mem-mcp", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install sopaco/cortex-mem cortex-mem-mcp --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sopaco/cortex-mem.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/cortex-mem-mcp/skill .cursor/skills/cortex-mem-mcp && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "cortex-mem-mcp" agent skill from https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skill into .cursor/skills/cortex-mem-mcp/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "cortex-mem-mcp", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/sopaco/cortex-mem.git --path cortex-mem-mcp/skill--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install sopaco/cortex-mem cortex-mem-mcp --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sopaco/cortex-mem.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/cortex-mem-mcp/skill .gemini/skills/cortex-mem-mcp && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "cortex-mem-mcp" agent skill from https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skill into .gemini/skills/cortex-mem-mcp/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "cortex-mem-mcp", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install sopaco/cortex-mem cortex-mem-mcpInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/sopaco/cortex-mem.git skills-src && mkdir -p .github/skills && cp -r skills-src/cortex-mem-mcp/skill .github/skills/cortex-mem-mcp && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "cortex-mem-mcp" agent skill from https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skill into .github/skills/cortex-mem-mcp/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "cortex-mem-mcp", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install sopaco/cortex-mem cortex-mem-mcp --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/sopaco/cortex-mem.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/cortex-mem-mcp/skill .opencode/skills/cortex-mem-mcp && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "cortex-mem-mcp" agent skill from https://github.com/sopaco/cortex-mem/tree/main/cortex-mem-mcp/skill into .opencode/skills/cortex-mem-mcp/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "cortex-mem-mcp", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
cortex-mem-mcpPersistent memory enhancement for AI agents. An agent skill from sopaco/cortex-mem.
Cortex Mem MCP is an agent skill from sopaco/cortex-mem. Persistent memory enhancement for AI agents. Store conversations, search memories with semantic retrieval, and recall context across sessions. Use this skill when you need to remember user preferences, past conversations, project context, or any information that should persist beyond the current session. Provides tiered access (abstract/overview/content) for efficient context management.
Its SKILL.md is about 2.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts. Compatibility notes: Requires cortex-mem-mcp MCP server running with configured LLM and vector database (Qdrant). Needs API keys for LLM and embedding services.
It sits in Agent Workflows, covering MCP servers, Agent memory and Context engineering. It works with Model Context Protocol, Linux and macOS. The repository describes itself as: 🧠 The production-ready cognitive foundation for autonomous systems such as Embodied-AI and OpenClaw. For memory management, from extraction and search to automated optimization… The licence is MIT.
5 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit 82a1c83. It shows what the files ask for, not the result of running them.
Pre-approves these tools, so the agent can use them without asking each time:
storesearchrecalllsexploreabstractoverviewcontentcommitdelete…and 2 more on the same allowed-tools line.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
cargogitdockercurlFrom the folder's file list and the shell code blocks in SKILL.md.
Hosts in commands or code, which the agent is likely to contact:
api.openai.comFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Requires cortex-mem-mcp MCP server running with configured LLM and vector database (Qdrant). Needs API keys for LLM and embedding services.
From compatibility in the SKILL.md frontmatter.
Cortex Mem MCP loads about 2.8k tokens when it runs. Until then it costs about 101 tokens; SKILL.md has 689 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from sopaco/cortex-mem at commit 82a1c83, republished under its MIT licence (© sopaco). 689 words, ~2,814 tokens.
.claude/skills/cortex-mem-mcp/SKILL.md (or your agent's skills folder).This skill enables persistent memory capabilities for AI agents, allowing them to store, search, and recall information across sessions using semantic retrieval.
Before configuring this skill, verify if cortex-mem-mcp is available in your system:
# Check if cortex-mem-mcp is in PATH
which cortex-mem-mcp || where cortex-mem-mcp # Linux/macOS || WindowsIf the command returns a path, the binary is already installed. If not, proceed to the installation section below.
cargo install cortex-mem-mcpAfter installation, verify:
cortex-mem-mcp --version# Clone the repository
git clone https://github.com/sopaco/cortex-mem.git
cd cortex-mem
# Build the release binary
cargo build --release --bin cortex-mem-mcp
# The binary will be at:
# ./target/release/cortex-mem-mcp (Linux/macOS)
# .\target\release\cortex-mem-mcp.exe (Windows)Download the latest release from GitHub:
Choose the appropriate binary for your platform:
cortex-mem-mcp-linux-x86_64 (Linux x64)cortex-mem-mcp-darwin-arm64 (macOS Apple Silicon)cortex-mem-mcp-darwin-x86_64 (macOS Intel)cortex-mem-mcp-windows-x86_64.exe (Windows x64)Create a config.toml file (e.g., ~/.config/cortex-mem/config.toml):
[cortex]
# Data directory for storing memories
data_dir = "~/.cortex-data"
[llm]
# LLM API configuration
api_base_url = "https://api.openai.com/v1"
api_key = "your-api-key"
model_efficient = "gpt-5-mini"
temperature = 0.1
max_tokens = 65536
[embedding]
# Embedding configuration
api_base_url = "https://api.openai.com/v1"
api_key = "your-embedding-api-key"
model_name = "text-embedding-3-small"
batch_size = 10
timeout_secs = 30
[qdrant]
# Vector database configuration
url = "http://localhost:6334"
collection_name = "cortex_memories"
embedding_dim = 1536
timeout_secs = 30# Using Docker
docker run -d -p 6333:6333 qdrant/qdrant
# Verify Qdrant is running
curl http://localhost:6333Configure your MCP client (e.g., Claude Desktop, Cursor, etc.) to use cortex-mem-mcp.
Edit the configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.json~/.config/Claude/claude_desktop_config.jsonAdd the following configuration:
{
"mcpServers": {
"cortex-memory": {
"command": "cortex-mem-mcp",
"args": [
"--config", "/path/to/config.toml",
"--tenant", "default"
],
"env": {
"RUST_LOG": "info"
}
}
}
}If you built from source, use the full path to the binary:
{
"mcpServers": {
"cortex-memory": {
"command": "/path/to/cortex-mem/target/release/cortex-mem-mcp",
"args": [
"--config", "/path/to/config.toml",
"--tenant", "default"
]
}
}
}Add to your Cursor MCP settings:
{
"mcpServers": {
"cortex-memory": {
"command": "cortex-mem-mcp",
"args": ["--config", "/path/to/config.toml"]
}
}
}After configuration, restart Claude Desktop or your MCP client to load the new server.
Test the MCP server manually:
# Run with debug logging
RUST_LOG=debug cortex-mem-mcp --config /path/to/config.toml --tenant default| Argument | Default | Description |
|---|---|---|
--config / -c | config.toml | Path to configuration file |
--tenant | default | Tenant ID for memory isolation |
--auto-trigger-threshold | 10 | Message count to auto-trigger memory extraction |
--auto-trigger-interval | 300 | Min seconds between auto-trigger executions |
--auto-trigger-inactivity | 120 | Inactivity timeout to trigger extraction |
--no-auto-trigger | false | Disable auto-trigger feature entirely |
| Variable | Description |
|---|---|
CORTEX_DATA_DIR | Override data directory path |
RUST_LOG | Logging level (debug, info, warn, error) |
Use this skill when you need to:
storeAdd a message to memory for a specific session.
{
"content": "The user prefers dark mode in all applications",
"thread_id": "project-alpha",
"role": "user"
}content: The message content to storethread_id: Optional session/thread identifier (defaults to "default")role: Message role - "user", "assistant", or "system"commitCommit accumulated conversation content and trigger memory extraction.
{
"thread_id": "project-alpha"
}This triggers:
searchLayered semantic search across memory using L0/L1/L2 tiered retrieval.
{
"query": "user preferences for UI",
"scope": "project-alpha",
"limit": 10,
"min_score": 0.5,
"return_layers": ["L0", "L1"]
}recallRecall memories with full context (L0 snippet + L2 content).
{
"query": "what did we discuss about authentication",
"scope": "project-alpha",
"limit": 5
}lsList directory contents to browse the memory space.
{
"uri": "cortex://session",
"recursive": true,
"include_abstracts": true
}Common URIs:
cortex://session - List all sessionscortex://user - List user-level memoriescortex://user/{user_id}/preferences - User preference memoriesexploreSmart exploration of memory space, combining search and browsing.
{
"query": "authentication implementation details",
"start_uri": "cortex://session",
"return_layers": ["L0"]
}Memory is organized in layers for efficient context management:
| Layer | Size | Purpose |
|---|---|---|
| L0 | ~100 tokens | Quick relevance checking (abstract) |
| L1 | ~2000 tokens | Understanding core information (overview) |
| L2 | Full content | Complete original content |
abstractGet L0 abstract layer for quick relevance checking.
{
"uri": "cortex://session/project-alpha/timeline/2024-03/15/10_30_45_abc123.md"
}overviewGet L1 overview layer for understanding core information.
{
"uri": "cortex://session/project-alpha/timeline/2024-03/15/10_30_45_abc123.md"
}contentGet L2 full content layer - the complete original content.
{
"uri": "cortex://session/project-alpha/timeline/2024-03/15/10_30_45_abc123.md"
}deleteDelete a memory by its URI.
{
"uri": "cortex://session/old-project/timeline/2024-03/15/10_30_45_xyz.md"
}layersGenerate L0/L1 layer files for memories.
{
"thread_id": "project-alpha"
}indexIndex memory files for vector search.
{
"thread_id": "project-alpha"
}Memories are organized using a URI scheme:
cortex://session/{thread_id}/timeline/{YYYY-MM}/{DD}/{HH_MM_SS}_{id}.md
cortex://user/{user_id}/preferences/{topic}.md
cortex://user/{user_id}/entities/{name}.md
cortex://user/{user_id}/events/{name}.md
cortex://agent/{agent_id}/cases/{name}.md
cortex://agent/{agent_id}/skills/{name}.mdNote: Session dimension stores conversation timeline; extracted memories (preferences, entities, etc.) are stored in user/agent dimensions after commit.
Use meaningful thread IDs - Use descriptive names like project-alpha or user-123-support instead of generic IDs
Commit periodically - Call commit after significant conversation milestones to ensure memory extraction
Start with search - Before storing new information, search to avoid duplication
Use tiered access - Start with abstract or search to find relevant memories, then use overview or content for details
Scope your searches - Use the scope parameter to limit searches to relevant sessions
1. Store the preference:
store(content="User prefers TypeScript over JavaScript for all new projects", role="user")
2. Commit to persist:
commit()1. Search for relevant memories:
search(query="TypeScript preferences", limit=5)
2. Get overview of most relevant result:
overview(uri="cortex://user/default/preferences/typescript.md")1. Store project decisions:
store(content="Decided to use PostgreSQL for the main database", thread_id="project-x", role="assistant")
2. Later, recall project decisions:
recall(query="database decisions", scope="project-x")The MCP server supports automatic memory processing:
--no-auto-trigger flagThe MCP server requires a config.toml with:
[cortex]
data_dir = "./cortex-data"
[llm]
api_base_url = "https://api.openai.com/v1"
api_key = "your-api-key"
model_efficient = "gpt-5-mini"
[embedding]
api_base_url = "https://api.openai.com/v1"
api_key = "your-api-key"
model_name = "text-embedding-3-small"
[qdrant]
url = "http://localhost:6333"
collection_name = "cortex_mem"
embedding_dim = 1536© sopaco, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in cortex-mem-mcp/skill of sopaco/cortex-mem.
Open the folder on GitHubat commit 82a1c83
Cortex Mem MCP next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Cortex Mem MCP this skillsopaco/cortex-mem | 312 | — | ~2.8k | Automated safety check: Pass | MIT | |
| LemmalogJordyZomer/lemmalog | 329 | — | ~2.8k | Automated safety check: Pass | MIT | |
| Mps Project ManagementJetBrains/MPS | 1.7k | — | ~2.2k | Automated safety check: Pass | Apache-2.0 | |
| Gearcoleco Romhackingdrhelius/Gearcoleco | 141 | — | ~3.9k | Automated safety check: Pass | GPL-3.0 | |
| Context Mode Searchmksglu/context-mode | 26k | — | ~250 | Automated safety check: Pass | Custom licence | |
| AI Memory Obsidiankipperacademy/skillpper | 134 | — | ~1.4k | Automated safety check: Notes | None |
JordyZomer/lemmalog
Externalize working memory and logical state into the lemmalog Datalog engine (MCP).
JetBrains/MPS
Open an MPS project in a running or freshly started MPS instance when MCP tools fail because no project is open (welcome screen), close an open project with mpsmcpcloseproject, or create a new empty…
drhelius/Gearcoleco
Hack, modify, and translate ColecoVision and Super Game Module ROMs using the Gearcoleco emulator MCP server.
mksglu/context-mode
Search context-mode's persistent FTS5 knowledge base for previously indexed local project content, documentation, or session memory. Trigger…
kipperacademy/skillpper
Portable workflows for persistent memory and Obsidian across macOS, Linux, and Windows.
ogham-mcp/ogham-mcp
Structured memory capture for Ogham shared memory. An agent skill from ogham-mcp/ogham-mcp.
Works with
Categories
Persistent memory enhancement for AI agents. An agent skill from sopaco/cortex-mem. Cortex Mem MCP is an agent skill from sopaco/cortex-mem. Persistent memory enhancement for AI agents.
Cortex Mem MCP fits situations like: you need to remember user preferences; past conversations; project context; any information that should persist beyond the current session.
Run `npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a claude-code`. Or copy the skill folder (cortex-mem-mcp/skill in sopaco/cortex-mem) into .claude/skills/cortex-mem-mcp in your project. Claude Code loads it when a task matches its description.
Run `npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a codex`. Or copy the skill folder (cortex-mem-mcp/skill in sopaco/cortex-mem) into .agents/skills/cortex-mem-mcp in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add sopaco/cortex-mem --skill cortex-mem-mcp -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/cortex-mem-mcp, .gemini/skills/cortex-mem-mcp, .github/skills/cortex-mem-mcp and .opencode/skills/cortex-mem-mcp in your project.
Going by SKILL.md and its folder, Cortex Mem MCP needs the command-line tools its instructions call (cargo, git, docker and curl). Our summary lists: Docker. Its frontmatter pre-approves these tools: store, search, recall, ls, explore, abstract, overview, content, commit, delete, layers, index. Compatibility (from SKILL.md): Requires cortex-mem-mcp MCP server running with configured LLM and vector database (Qdrant). Needs API keys for LLM and embedding services..
SKILL.md names 1 domain. In commands or code: api.openai.com; the agent is likely to contact it when it follows the instructions. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Cortex Mem MCP is published under the MIT licence (declared in SKILL.md). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.8k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Cortex Mem MCP: Lemmalog (JordyZomer/lemmalog, 329 stars), Mps Project Management (JetBrains/MPS, 1.7k stars), Gearcoleco Romhacking (drhelius/Gearcoleco, 141 stars) and Context Mode Search (mksglu/context-mode, 26k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
sopaco (a GitHub user) maintains it in sopaco/cortex-mem, which has 312 GitHub stars. The repository was last updated on July 22, 2026.
Source: sopaco/cortex-mem on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.