Skip to main content
Glama
obsidian-mcp-server

obsidian-mcp-server

by mpesavento

Grep Vault

vault_grep

Search Obsidian vault notes with full-text, case-insensitive grep queries. Restrict results by subdirectory and cap result counts to find exact text matches quickly.

Instructions

Full-text grep search across vault notes. Uses ripgrep if available, falls back to pure Node.js search. Case-insensitive. Use vault_search for semantic/keyword search instead.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "<query>"
    },
    "name": "vault_grep"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesSearch query (plain text, matched case-insensitively)
max_resultsNoMaximum number of results to return
path_filterNoRestrict search to a subdirectory (e.g. '60-daily' or '20-context/entities')

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full behavioral burden. It discloses the matching model (literal, case-insensitive) and the ripgrep/Node.js engine fallback, but says nothing about result shape, truncation behavior past max_results, or whether hidden/vault-external files are scanned.

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 what the tool does, then implementation detail, then the routing hint. Nothing is repeated or wasted.

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?

This is a low-complexity read-only search tool with no output schema and fully documented parameters, so the description covers what an agent needs to invoke it correctly. Only the return format and result-cap semantics remain unstated, which is a minor gap.

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

Parameters4/5

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

Schema coverage is 100%, so the parameters are already documented, and the baseline is 3. The description adds little parameter-specific meaning beyond restating case-insensitive matching, though the path_filter example in the schema plus the described vault layout make the scoping parameter unambiguous.

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

Purpose5/5

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

"Full-text grep search across vault notes" states a specific verb and resource, and the final sentence names the sibling vault_search as the semantic/keyword alternative, so the agent can distinguish the two tools without opening either schema.

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

Usage Guidelines4/5

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

It gives an explicit exclusion: use vault_search for semantic/keyword search instead. What is missing is positive guidance on when literal grep is the right choice (exact string, regex-ish matching) and any mention of prerequisites such as vault path or indexing state.

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