Search Doc
search_docSearch indexed documentation with full-text keyword queries, using phrases, OR/AND, and filters to find relevant chunks with snippets.
Instructions
Full-text keyword search over indexed document chunks.
Matching is case-insensitive and word-based: punctuation splits words, so MP-BGP is indexed as the two words "mp" and "bgp". Unquoted, a '-' is query syntax and fails, so write "MP-BGP" in double quotes (a phrase). Space-separated terms are implicitly ANDed; there are no synonyms, so widen a search with OR ('L3Out OR "external routing"').
Each result carries a short snippet around the hits and a score; use read_doc with the result's chunk_number for the full chunk text.
Returns:
Up to max_search_results matching chunks (see config.yaml), best
match first, plus next_offset when more matches exist.
Raises: ValueError: pattern is not valid FTS5 query syntax.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| offset | No | Skip this many best matches, for paging | |
| pattern | Yes | SQLite FTS5 MATCH query. Examples: 'BGP AND OSPF', '"MP-BGP"', 'L3Out OR "external routing"', 'NEAR(bgp ospf, 10)', 'config*'. Quote any term containing punctuation such as '-'. | |
| category | No | Only search this category, or null for all | |
| file_name | No | Only search the document with this extension-stripped filename, or null for all | |
| subcategory | No | Only search this subcategory, including those nested below it ('cisco' also matches 'cisco/aci'), or null for all |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| results | No | ||
| next_offset | No | Pass as offset to get the next page, or null when there are no more matches |