docs: Prune redundant JSON schemas from instructions in favor of strong static typing

This commit is contained in:
Riz Ashraf committed 2026-09-12 22:22:09 +01:00
1 parent 2d3aaed289
commit 6872957195
1 file changed
+7 -34
+7 -34
View File
@@ -1,36 +1,7 @@
# MCP Memory Server Guidelines # Memory MCP Strategic Guidelines
This server provides an OS-agnostic, persistent Knowledge Graph and working memory. The following guidelines dictate **when** and **how** to best utilize these tools. This document outlines the STRATEGY and SEMANTICS for using the MCP Memory Server.
You do not need to memorize JSON schemas for these tools; they are strictly defined and typed in the ools/list endpoint. Focus purely on WHEN and WHY to use them.
## 1. Ephemeral Working Memory (Sticky Notes)
- **Tools:** add_sticky_note, ␍ead_sticky_notes
- **When to use:**
- When you need to remember a specific context, broken build state, or pending task across conversation boundaries (e.g., "We are in the middle of refactoring main.rs, next step is testing").
- When saving short-term scratchpad thoughts that don't belong in the permanent knowledge graph.
- **Behavior:** Notes have a 24-hour TTL and are pruned automatically. Always consider reading sticky notes at the start of a session if picking up an ongoing task.
## 2. The Knowledge Graph (Entities & Relations)
- **Tools:** search_nodes, open_nodes, ␍ead_graph
- **When to use search_nodes:** Use this for **fuzzy searching** when you aren't 100% sure of the exact entity name, or you want to find everything related to a topic (e.g., "Docker", "Jenkins"). It uses Jaro-Winkler distance and token matching.
- **When to use open_nodes:** Use this for **1-hop traversal**. If you know a specific entity name (e.g., "auth-service") and want to see how it connects to other services, open_nodes will pull the entity AND all directly connected neighbors.
## 3. Graph Maintenance & Condensation
- **Tool:** condense_entity
- **When to use:** Proactively use this tool if you notice an entity's observations array is getting excessively long (e.g., >10 items) or repetitive. Condense the list into a shorter, more concise summary of the core facts to preserve token limits.
## 4. The Audit Ledger (Code Changes)
- **Tools:** log_code_change, query_recent_changes
- **When to use log_code_change:** *MANDATORY.* Immediately after successfully making significant file modifications (e.g., refactoring a script, fixing a bug). Log the file path and a short description.
- **When to use query_recent_changes:** When the user asks "What did we do yesterday?", "What changed recently?", or when trying to debug a newly introduced issue. (The ledger retains 7 days of history, max 1000 items).
## 5. Architectural Visualization
- **Tool:** isualize_graph
- **When to use:** When you need to explain complex system relationships, dependencies, or architectures to the user. This tool outputs a raw Mermaid.js string. Put the output inside a ``mermaid` markdown block in an Artifact so the user can see a visual diagram.
## 6. Structured Task Queue (Agentic Kanban)
- **Tools:** `add_task`, `update_task_status`, `list_active_tasks`
- **When to use:** Use this for structured checklist tracking of complex, multi-day features or goals (e.g., when the user initiates a `/goal`).
- **Behavior:** Log tasks with a title and description. When resuming sessions, always run `list_active_tasks` to see what is still `pending`, `in_progress`, or `blocked`, and pick up where you left off. Use `update_task_status` to transition tasks to `done`.
## 7. Snippet & Command Vault ## 7. Snippet & Command Vault
- **Tools:** `store_snippet`, `search_snippets`, `delete_snippet` - **Tools:** `store_snippet`, `search_snippets`, `delete_snippet`
@@ -53,7 +24,8 @@ This server provides an OS-agnostic, persistent Knowledge Graph and working memo
- **Behavior:** merge_entities will safely combine their observations and automatically remap all relations pointing to or from the deleted duplicate. - **Behavior:** merge_entities will safely combine their observations and automatically remap all relations pointing to or from the deleted duplicate.
## 11. Dynamic Learned Preferences ## 11. Dynamic Learned Preferences
- **Tools:** learn_preference, ␍ead_preferences - **Tools:** learn_preference,
ead_preferences
- **When to use:** When the user corrects you on a specific local nuance (e.g. "Actually, use Python 3.10 instead of 3.12 for this repo"). - **When to use:** When the user corrects you on a specific local nuance (e.g. "Actually, use Python 3.10 instead of 3.12 for this repo").
- **Behavior:** Use this Key-Value store to record dynamic behavioral preferences to ensure you adapt instantly without modifying global Markdown files. - **Behavior:** Use this Key-Value store to record dynamic behavioral preferences to ensure you adapt instantly without modifying global Markdown files.
@@ -82,7 +54,8 @@ When working in a multi-session or multi-agent environment, agents need to commu
## Environment & Blueprint Tracker ## Environment & Blueprint Tracker
Stop wasting tokens rediscovering how to run or configure the project. Stop wasting tokens rediscovering how to run or configure the project.
- **update_env_fingerprint:** Run this when you set up a new project to snapshot the OS, shell, and key language versions (e.g. python, ␍ustc). - **update_env_fingerprint:** Run this when you set up a new project to snapshot the OS, shell, and key language versions (e.g. python,
ustc).
- **read_env_fingerprint:** Query this to instantly know how the project is run. - **read_env_fingerprint:** Query this to instantly know how the project is run.
- **log_env_requirement:** Log required .env variables (e.g. DATABASE_URL) without logging the secret itself. - **log_env_requirement:** Log required .env variables (e.g. DATABASE_URL) without logging the secret itself.