Skip to main content
Glama

search_by_frontmatter

Find notes whose frontmatter matches specified key-value criteria using case-insensitive comparison, enabling targeted retrieval from an Obsidian vault.

Instructions

Find notes whose frontmatter matches the given key-value criteria (case-insensitive string comparison).

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": {
      "criteria": "<criteria>"
    },
    "name": "search_by_frontmatter"
  }
}

Input Schema

NameRequiredDescriptionDefault
criteriaYesKey-value pairs that must match the note's frontmatter.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.0.0

TDQS

B3.4/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It discloses case-insensitive string comparison, which is genuinely useful, but says nothing about multi-criteria semantics (AND vs OR), how non-string frontmatter values are compared, result limits, or ordering.

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?

A single, front-loaded sentence with no filler; purpose and matching rule are stated immediately in the order an agent needs them.

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

Completeness3/5

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

For a tools-with-no-annotations and no output schema case, the description should say more: whether all criteria must match, what a result looks like, and whether there are limits on result count. It covers the core matching rule but leaves mutation-adjacent and return-shape questions unanswered.

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% for the single criteria object, so the baseline is 3. The description adds real meaning beyond the schema by specifying case-insensitive string comparison, though it leaves a gap for non-string values (numbers, booleans, dates, arrays) that a frontmatter search will inevitably encounter.

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?

States a specific verb ('Find') and resource ('notes') plus the matching mechanism ('frontmatter matches key-value criteria'). It is distinguishable from metadata siblings like search_by_tag or get_frontmatter, though the description never names or contrasts them explicitly.

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?

Usage is implied: search by metadata fields rather than by tag or full text. There is no explicit guidance on when to prefer this over search_notes or get_frontmatter, and no stated exclusions or prerequisites.

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