search_text
Locate specific text patterns within PDF files using regular expressions. Specify search range, case sensitivity, and retrieve matches with page numbers and context for precise results.
Instructions
Search for text pattern in a PDF file
Args:
pdf_path: Path to the PDF file
pattern: Regular expression pattern to search for
case_sensitive: Whether to perform case-sensitive matching
start_page: Page number to start search (0-indexed). If None, starts from first page.
end_page: Page number to end search (0-indexed, inclusive). If None, searches all pages.
Returns:
List of matches with page number, match text, and context
Input Schema
Name | Required | Description | Default |
---|---|---|---|
case_sensitive | No | ||
end_page | No | ||
pattern | Yes | ||
pdf_path | Yes | ||
start_page | No |
Input Schema (JSON Schema)
{
"properties": {
"case_sensitive": {
"default": false,
"title": "Case Sensitive",
"type": "boolean"
},
"end_page": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "End Page"
},
"pattern": {
"title": "Pattern",
"type": "string"
},
"pdf_path": {
"title": "Pdf Path",
"type": "string"
},
"start_page": {
"anyOf": [
{
"type": "integer"
},
{
"type": "null"
}
],
"default": null,
"title": "Start Page"
}
},
"required": [
"pdf_path",
"pattern"
],
"title": "search_textArguments",
"type": "object"
}