Skip to main content
Glama

Search Within One Filing

SearchDocument
Read-only

Search within a single SEC filing or earnings-call transcript by document ID using semantic relevance or exact substring matching to find specific passages and line numbers.

Instructions

Search one SEC filing or earnings-call transcript by document ID. semantic mode uses hybrid relevance and returns excerpts in document order with approximate line numbers. exact mode performs a literal case-insensitive substring match and returns precise matching lines. Get document IDs from SearchDocuments or ListFilings; use ReadDocumentLines for surrounding text.

Input Schema

NameRequiredDescriptionDefault
queryYesSearch query — plain keywords or a short natural-language phrase. When too few excerpts match every word, the search automatically broadens to match any of the words. In searchMode 'exact', matched as a literal case-insensitive substring.
documentIdYesDocument ID obtained from ListFilings or a SearchDocuments result header
maxResultsNoMaximum number of results to return (default: 5)
searchModeNoHow to match: 'semantic' (default — hybrid keyword and semantic relevance) or 'exact' (literal case-insensitive substring match with precise line numbers).semantic
maxExcerptCharsNoMaximum characters per excerpt (default: 0 = full excerpt). Set a small value (e.g. 400) for a compact scan across many results; truncated excerpts end with an explicit note.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already establish readOnlyHint=true, and the description adds useful behavioral detail: semantic mode returns excerpts in document order with approximate line numbers, while exact mode returns precise matching lines. It does not discuss pagination or limits, but the core retrieval behavior is transparent.

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 tightly written sentences with no waste. The core action and mode distinction are front-loaded, followed by prerequisite IDs and alternative tool guidance.

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?

For a read-only search tool with no output schema, the description is complete enough: it covers input source, mode behavior, result ordering, line-number behavior, and the alternative for surrounding context. Nothing critical is missing for correct invocation.

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 baseline is 3, but the description adds meaningful interpretation of searchMode and source of documentId beyond the schema text. It does not elaborate every parameter, such as maxResults, but improves mode selection semantics.

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 and resource: searching one SEC filing or earnings-call transcript by document ID. It clearly distinguishes itself from SearchDocuments and ReadDocumentLines, so an agent can route among them without opening schemas.

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?

Explicitly explains where to get document IDs (SearchDocuments or ListFilings) and when to use ReadDocumentLines for surrounding text. It also distinguishes semantic versus exact mode use, leaving little to inference.

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