sd_get_document_passages
Get full text passages from a specific document to read sections or gather quotes. Filter by search term, division, or page for targeted retrieval.
Instructions
Retrieve text passages from a specific document.
PURPOSE: Get actual text content from a document found via search
WHEN TO USE:
After search returns relevant document IDs
User wants to read specific sections
Need actual quotes for citations
WHEN NOT TO USE:
For discovery → use search_documents_direct()
For full document → use get_document_by_id()
Args: document_id: The xml:id of the document query: Optional search term to highlight/filter passages division: Filter to specific div by @n value page: Filter to specific page by pb/@n context_size: Characters of context around matches max_passages: Maximum passages to return ctx: FastMCP Context
Returns: List of Passage objects with text and location info
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page | No | ||
| query | No | ||
| division | No | ||
| document_id | Yes | ||
| context_size | No | ||
| max_passages | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |