qmd-memory

Search and manage agent memory using hybrid BM25 and vector search over markdown files.

1|Updated May 13, 2026
One-click install
npx skills add https://github.com/coolrobertj/Agency-Cowork --skill qmd-memory-coolrobertj
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: qmd-memory
Source: https://github.com/coolrobertj/Agency-Cowork/tree/main/skills/qmd-memory/skills/qmd-memory
Command: npx skills add https://github.com/coolrobertj/Agency-Cowork --skill qmd-memory-coolrobertj

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires sentence-transformers, llama-cpp-python, openai, python-dotenv, and includes scripts (resource) components.

What problem does it solve? Agents lose context between sessions and cannot reliably recall past decisions, notes, or project knowledge. This Skill provides a persistent, searchable memory layer so the agent can retrieve prior context, maintain daily logs, and keep a curated knowledgebase without manual file digging. ## Core Features & Use Cases - Hybrid Memory Search: Query daily logs, knowledgebase, and weekly reports using BM25 keyword search combined with local vector embeddings via the qmd-query MCP tool or hybrid-search.py fallback. - Memory Maintenance: Update MEMORY.md with permanent facts, append daily context logs, and organize long-term knowledge into structured knowledgebase folders. - Session-End Memory Flush: Automatically save decisions, action items, and summaries before a session ends, then re-index content for future retrieval. - Use Case: Ask "what did we decide about the firmware timeline last month?" and the agent searches indexed daily logs and PEC minutes, returning cited source files with the answer. ## Quick Start Ask the agent to search memory for a past decision or topic, such as "find what we know about the project alpha release timeline."

Frequently Asked Questions about qmd-memory

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I search agent memory for past decisions?

Use the qmd-query MCP tool with a lex sub-query for exact terms or combine lex and vec sub-queries for conceptual questions. If the MCP server is unavailable, run hybrid-search.py, which merges BM25 and local vector results with Reciprocal Rank Fusion.

What is the difference between keyword and semantic memory search?

Keyword (lex) search uses BM25 and works best for exact names, IDs, and phrases. Semantic (vec) search uses local embeddings to match conceptual queries where you do not know the exact vocabulary, and hyde queries maximize recall for complex topics.

Does QMD memory search require a cloud API or internet connection?

No. The default SentenceTransformer provider runs the bge-small-en-v1.5 embedding model entirely on-device via CPU, with no API keys or cloud dependency. An optional Azure OpenAI provider exists but corporate policy restricts it to approved endpoints.

How do I re-index memory after adding new files?

Run qmd update to rebuild the BM25 text index, then run azure-embed.py to regenerate vector embeddings for changed documents. The QMD MCP server also auto-reindexes text every five minutes, but embeddings must be refreshed manually.

When should information go in MEMORY.md versus daily logs?

MEMORY.md stores permanent facts like user preferences, contacts, and tool configurations, kept under roughly 200 lines. Temporary or episodic context such as daily decisions and progress notes belongs in dated daily log files under memory/DailyLogs.