From ff3793fdffb10b0e0b9a9b02e0c0d592e641bc4c Mon Sep 17 00:00:00 2001 From: Adolanium <94890352+Adolanium@users.noreply.github.com> Date: Thu, 6 Aug 2026 07:44:07 +0300 Subject: [PATCH] fix(read_file): stop promising anydoc conversion in the tool schema The read_file description added in #79781 states that PDF, legacy Office, OpenDocument, RTF, and EPUB convert via the optional anydoc converter, unconditionally. Conversion actually depends on the lazy install succeeding, security.allow_lazy_installs, and the file being readable from the Hermes host, so the schema overpromises and the model learns to expect conversion in environments that can never provide it. The description now says these formats convert when the optional anydoc converter is available, and that the auto-install applies where installs are permitted. --- tools/file_tools.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/file_tools.py b/tools/file_tools.py index a5d001d7fb948..db3bad64b5913 100644 --- a/tools/file_tools.py +++ b/tools/file_tools.py @@ -2158,7 +2158,7 @@ def _check_file_reqs(): READ_FILE_SCHEMA = { "name": "read_file", - "description": "Read a text file with line numbers and pagination. Use this instead of cat/head/tail in terminal. Output format: 'LINE_NUM|CONTENT'. Suggests similar filenames if not found. Use offset and limit for large files. Reads exceeding ~100K characters are truncated on a line boundary and return a next_offset; continue with offset to read the rest. Jupyter notebooks (.ipynb), Word documents (.docx), and Excel workbooks (.xlsx) are auto-extracted to readable text; PDF, legacy Office (.doc/.ppt/.xls), OpenDocument, RTF, and EPUB convert too via the optional anydoc converter (auto-installed on first use). NOTE: Cannot read images or other binary files — use vision_analyze for images.", + "description": "Read a text file with line numbers and pagination. Use this instead of cat/head/tail in terminal. Output format: 'LINE_NUM|CONTENT'. Suggests similar filenames if not found. Use offset and limit for large files. Reads exceeding ~100K characters are truncated on a line boundary and return a next_offset; continue with offset to read the rest. Jupyter notebooks (.ipynb), Word documents (.docx), and Excel workbooks (.xlsx) are auto-extracted to readable text; PDF, legacy Office (.doc/.ppt/.xls), OpenDocument, RTF, and EPUB convert too when the optional anydoc converter is available (auto-installed on first use where installs are permitted). NOTE: Cannot read images or other binary files — use vision_analyze for images.", "parameters": { "type": "object", "properties": {