Docs: Update Effective Discourse instructions for users and agents

This commit is contained in:
Riz Ashraf committed 2026-09-30 12:24:35 +01:00
1 parent 63f8ec6281
commit 292a6e95ab
2 files changed
+56 -1

No files matched your search

+53
View File
@@ -0,0 +1,53 @@
# Effective Discourse: LLM Prompting Guide for MCP Memory
To get the most out of the Antigravity MCP Memory server and its advanced developer tools, use specific phrases that clearly state your intent. This guides the LLM to use the most efficient tools, reducing token consumption, speeding up time-to-resolve (T2R), and avoiding brute-force file reading.
## 1. Global Semantic Code Search & Navigation
Instead of having the LLM use brute-force text searches or `grep` to find abstract logic, instruct it to use the new local vector embeddings.
* **Don't say:** "Grep the codebase for database connection strings."
* **Do say:** "Perform a semantic code search for how database connections are established."
* **Tool Triggered:** `semantic_code_search`
## 2. Codebase Exploration & Token Efficiency
When entering a new file, avoid having the LLM read the entire contents blindly.
* **Don't say:** "Read server.rs and tell me what it does." *(Consumes massive tokens)*
* **Do say:** "Extract the AST skeleton of server.rs to understand its structure first."
* **Tool Triggered:** `read_file_skeleton`
## 3. Debugging & Log Parsing
Stop copy-pasting giant walls of logs into the chat interface.
* **Don't say:** "Here is the error: [paste 500 lines of logs]"
* **Do say:** "The daemon crashed. Fetch the recent logs from daemon.log." or "Watch the process logs for server.log."
* **Tool Triggered:** `get_recent_logs`, `watch_process_logs`
## 4. Git & Context Handoff
When you've been working independently and need to loop the LLM back in on your current state.
* **Don't say:** "I changed some files, here are the diffs..."
* **Do say:** "Get the active git worktree context to review my uncommitted changes before we continue."
* **Tool Triggered:** `get_active_worktree_context`
## 5. Clipboard Watch Mode (Research & Triage)
When you are doing intense debugging across StackOverflow, logs, and docs, use the clipboard watcher to auto-ingest your breadcrumbs.
* **Action:** Ask the LLM to turn it on: "Enable clipboard watch mode."
* **Do say:** "I'm going to reproduce the bug and copy some stack traces and IDs. Give me a minute, then read my latest sticky notes to catch up."
* **Tool Triggered:** `toggle_clipboard_watch_mode`, followed by internal Sticky Note reads.
## 6. Proactive Background Hooks & Autonomous Review
The Memory Server actively watches your filesystem for changes in `.rs`, `.lua`, `.md`, and `.toml` files.
* **Don't say:** "Can you run a linter and review the file I just saved?"
* **Do say:** "I just saved `file.rs`, check the autonomous review results to see if the daemon found any issues." (The daemon hooks fire automatically on file save).
## 7. Neovim Ghost Text (Live Previews)
Keep your workflow entirely within your editor rather than copy-pasting code blocks from the chat.
* **Don't say:** "Write the updated function here so I can copy-paste it."
* **Do say:** "Push this refactor to my active Neovim buffer as ghost text so I can review it in-line."
* **Tool Triggered:** `nvim_set_preview` (via `win-nvim` or `linux-nvim`)
## 8. Graph, Memory & Decay Management
Actively instruct the LLM to maintain its own memory constraints and organize data. The daemon automatically consolidates old sticky notes and snippets to prevent unbounded context growth.
* **Do say:** "Log this architectural decision in the knowledge graph."
* **Do say:** "Add a sticky note with the test database credentials for this session."
* **Do say:** "Create a milestone for the 'Rich Clipboard' feature and break it down into active tasks."
* **Tools Triggered:** `create_entities`, `log_decision`, `add_sticky_note`, `add_milestone`, `add_task`
By phrasing requests around *actions* rather than *information retrieval*, the LLM is primed to leverage the rich MCP toolset built into the Antigravity Memory Server.
+3 -1
View File
@@ -5,8 +5,10 @@ A high-performance, persistent Knowledge Graph and Context daemon for Antigravit
mcp-memory acts as the persistent "brain" for the agy CLI agents. It tracks entities, relations, background tasks, engineering debt, and architectural decisions across sessions.
`
To eliminate heavy Cross-OS I/O penalties when using WSL and Windows simultaneously, mcp-memory operates using a **Dual-Transport Leader/Stub Architecture**:
* **The Server (mcp-memory-server)**: Runs natively on the Windows host. It binds to .0.0.0:3000, serving standard stdio to the primary Windows agy instance while simultaneously hosting an Axum HTTP server for secondary clients.
* **The Server (mcp-memory-server)**: Runs natively on the Windows host. It binds to 0.0.0.0:3000, serving standard stdio to the primary Windows agy instance while simultaneously hosting an Axum HTTP server for secondary clients.
* **The Stub (mcp-memory-stub)**: An ultra-lightweight proxy binary. WSL agy instances run this native Linux stub, which transparently pipes stdio JSON-RPC traffic over the network to the Windows HTTP server (http://127.0.0.1:3000), completely bypassing WSL NTFS mounts. It features full MPSC queue buffering and a WebSocket reconnect handshake (notifications/tools/list_changed) so that tools automatically refresh seamlessly without disconnecting the CLI if the background server restarts.
> **Note for Users & LLMs**: Please read the [Effective Discourse Guide](./EFFECTIVE_DISCOURSE.md) to learn which natural language phrases to use to perfectly trigger this server's advanced MCP tools.
`
## Quick Start & Usage