Skip to main content
Glama
markdown-vault-mcp

markdown-vault-mcp

by pvliesdonk

Query Notes

query_documents
Read-onlyIdempotent

Browse paginated indexed notes by text, path, folder, metadata, or modification date, returning exact totals and snippets to locate relevant Markdown content.

Instructions

Page through all matching indexed notes with an exact total.

Queries with text rank by keyword score then path; blank queries rank by modification time descending then path. Pages are live views, so concurrent writes can move notes between pages. Use read to retrieve full note content.

Input Schema

NameRequiredDescriptionDefault
pathNoCase-sensitive exact vault-relative path, including .md.
limitNoMaximum returned notes, 1-1000; total is independent of this cap.
queryNoFTS5 expression; blank selects all indexed notes. Malformed syntax matches its literal words.
scopeNoIndexed columns to match: metadata (path, title, headings, summary), body, or all. Terms must match within one indexed section.all
folderNoRestrict to this folder and descendants; empty selects root notes.
offsetNoNotes to skip in this live view, at least 0.
filtersNoAND equality over fields in indexed_frontmatter_fields from stats. List fields match a member; computed OKF fields use search instead.
patternNoCase-sensitive path glob; *, ? and bracket classes are wildcards.
snippet_wordsNoExcerpt width in words, at least 0; 0 returns whole sections.
modified_afterNoInclusive RFC3339 modification instant with timezone.
chunks_per_fileNoMaximum matching sections per note, at least 1.
modified_beforeNoExclusive RFC3339 modification instant with timezone.
wait_for_pending_writesNoWait for recent index writes. On timeout, answer from the current index with _meta.index_stale=true. Default false.

Output Schema

NameRequiredDescriptionDefault
itemsYes
limitYes
totalYes
offsetYes
truncatedYes
index_staleYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv6.1.0

TDQS

A3.8/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already establish readOnly/idempotent/non-destructive, and the description adds genuine behavior: exact totals independent of the page cap, ranking rules (keyword score then path for text, modification time descending for blank queries), and the important caveat that pages are live views where concurrent writes can shift notes across pages. That live-view instability note is a real operational disclosure not derivable from annotations or schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short sentences, front-loaded with the core action and total guarantee, then ranking rules, then the live-view caveat and the pointer to `read`. Nothing is redundant and no sentence is filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With 13 parameters, an output schema, and full schema coverage, the description needs only to explain the query model and result-stability semantics, which it does. The main residual gap is sibling disambiguation among the many list/search/count tools, which the description does not address.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all 13 parameters in detail. The description adds only indirect meaning about how `query` behaves (text vs blank ranking, total vs limit), without explaining scope, filters, pattern, or the pending-writes flag. Baseline 3 applies when the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

"Page through all matching indexed notes with an exact total" names a specific verb (page/query), the resource (indexed notes), and the distinguishing output property (exact total). It is clearly a paginated index-listing tool rather than a content fetch, but it never explicitly contrasts with siblings like list_documents, search, or count_documents.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The only explicit routing is "Use read to retrieve full note content," which usefully separates querying from fetching. There is no guidance on when to prefer this over list_documents, search, count_documents, or get_recent, despite those being close alternatives in the sibling set.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.