Skip to main content
Glama

papercortex_search

Read-only

Search the local Paperless index by meaning to retrieve ranked document IDs, titles, tags, similarity scores, and excerpts for receipt extraction or classification.

Instructions

Find matching documents in the local Paperless search index. Returns ranked IDs, titles, tags, similarity scores and short excerpts as text. Use the IDs for receipt extraction or classification. Use papercortex_query for a synthesized answer. Only indexed documents are searched.

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": "papercortex_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
tagsNoMatch any of these exact, case-sensitive tag names in the index. An empty list leaves results unfiltered.
limitNoMaximum number of matching documents to return, highest similarity first.
queryYesWords or a phrase to embed with Ollama and match by meaning.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changed
    • addedInput schema / properties / limit / default
      Added value: +10
    • changedInput schema / properties / limit / description
      Previous value: -"Maximum number of results (default: 10)"New value: +"Maximum number of matching documents to return, highest similarity first."
    • addedInput schema / properties / limit / minimum
      Added value: +1
    • changedInput schema / properties / limit / type
      Previous value: -"number"New value: +"integer"
    • changedInput schema / properties / query / description
      Previous value: -"Natural language search query"New value: +"Words or a phrase to embed with Ollama and match by meaning."
    • addedInput schema / properties / query / minLength
      Added value: +1
    • changedInput schema / properties / tags / description
      Previous value: -"Filter by tag names"New value: +"Match any of these exact, case-sensitive tag names in the index. An empty list leaves results unfiltered."
  2. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true and openWorldHint=true, so safety is covered; the description goes further by disclosing the return payload (ranked IDs, titles, tags, similarity scores, excerpts) and the important limitation that unindexed documents are invisible to this search. It stops short of describing ordering/pagination edge cases or how excerpts are chosen, keeping it below a 5.

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?

Five short sentences, purpose front-loaded, followed by return shape, downstream usage, the sibling alternative, and the indexing caveat. No sentence is filler and nothing is buried.

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

Completeness5/5

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

With only three parameters, no output schema, and simple annotations, the description supplies everything needed to call it correctly: what it returns, what the IDs are for, which sibling to prefer, and the indexing blind spot.

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 query, tags, and limit are already fully documented, including the case-sensitive tag matching and highest-similarity-first ordering. The description adds no parameter-level meaning beyond that, so the baseline 3 applies.

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?

Names a specific verb and resource ("Find matching documents in the local Paperless search index") and explicitly separates itself from papercortex_query by contrasting ranked hits against a "synthesized answer." An agent can pick between the two 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 Guidelines5/5

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

Gives an affirmative use case ("Use the IDs for receipt extraction or classification") and names the alternative with the condition that selects it (papercortex_query for a synthesized answer). The scope caveat "Only indexed documents are searched" further tells the agent when results will silently miss data.

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