Skip to main content
Glama

Find media references

find-media-references
Read-onlyIdempotent

Scans Anki note fields, card template HTML, and note-type CSS to find exact references to a media filename, returning a fingerprint for safe deletion when the scan is complete.

Instructions

Scans note fields, Card Template HTML, and note-type CSS for exact references to one Anki media filename. Complete scans return a fingerprint for safe deletion. CSS parsing failures are reported separately and make counts incomplete; no fingerprint is issued.

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": {
      "filename": "<filename>"
    },
    "name": "find-media-references"
  }
}

Input Schema

NameRequiredDescriptionDefault
filenameYesPortable filename inside Anki's flat collection.media folder

Output Schema

NameRequiredDescriptionDefault
usageYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive), yet the description still adds real behavioral detail: scans cover three distinct sources, complete scans emit a fingerprint, and CSS parsing failures are surfaced separately as partial results that suppress the fingerprint. That partial-failure semantics is exactly the kind of thing annotations cannot express.

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

Conciseness4/5

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

Three tight sentences with zero filler: scope first, then the success output, then the failure mode. Well front-loaded, though the third sentence is dense and slightly elliptical ("reported separately" — reported where?).

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?

A read-only single-parameter tool with an output schema, so return-format explanation is unnecessary, and the description still covers scan coverage, the fingerprint contract, and degraded-CSS behavior. Minor gap: it does not say whether the scan is limited to specific note types or the whole collection.

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

Parameters5/5

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

Schema coverage is 100% with a documented filename parameter, so the baseline is 3; the description earns more by specifying "exact references to one Anki media filename," clarifying match semantics (exact, not substring/prefix) and single-file scope, which the schema does not state.

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?

States a specific verb ("scans") plus the exact resource set inspected (note fields, Card Template HTML, note-type CSS) and the target (exact references to one Anki media filename). An agent can distinguish this reference-lookup from generic media search or file-retrieval siblings without opening the 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?

The phrase "fingerprint for safe deletion" establishes the operating context: run this before removing a media file. However, it never names the alternative tools (e.g., search-media-files, delete-media-file) or states when-not to use it, so guidance is contextual rather than explicit routing.

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