grep
Search paragraphs in DOCX, ODT, or Google Docs using regular expressions. Supports single and multiple files with options like case sensitivity and context.
Instructions
Search paragraphs with regex. Use file_path for session-based search, file_paths for stateless multi-file search, or google_doc_id for Google Docs. ODT supported via file_path (single-file) only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| pattern | No | ||
| patterns | No | ||
| file_path | No | Path to the DOCX or ODT file. | |
| file_paths | No | Multiple file paths for stateless multi-file search. No session created. | |
| search_xml | No | When true, search raw XML (word/document.xml) instead of paragraph text. | |
| whole_word | No | ||
| max_results | No | ||
| context_chars | No | ||
| google_doc_id | No | Google Doc ID or URL (alternative to file_path). Extract from URL: docs.google.com/document/d/{ID}/edit | |
| case_sensitive | No | ||
| include_context | No | When false, skip document view context (list labels, headers) for faster results. Default: true. | |
| dedupe_by_paragraph | No |