fix: Expose FileTools directory parameter - #9078
Merged
harshsinha03 merged 3 commits intoJul 21, 2026
Merged
Conversation
harshsinha03
approved these changes
Jul 21, 2026
harshsinha03
left a comment
Contributor
There was a problem hiding this comment.
LGTM! Thanks for contributing
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
FileTools.list_filesdeclaredirectoryas an explicit optional parameterdirectoryin the generated LLM tool schema instead of a required emptykwargsobjectFixes #9075.
Type of change
Checklist
libs/agno/scripts/format.batandlibs/agno/scripts/validate.bat)Duplicate and AI-Generated PR Check
Verification
libs\agno\.venv\Scripts\python.exe -m pytest libs/agno/tests/unit/tools/test_filetools.py -qâ 21 passed, 2 platform-specific skipslibs\agno\scripts\format.batâ 1954 files already formatted; import checks passedcall libs\agno\.venv\Scripts\activate.bat && call libs\agno\scripts\validate.batâ Ruff passed; mypy found no issues in 937 source filesgit diff --checkAdditional Notes
Before the fix, the generated schema was a required empty
kwargsobject. It now contains an optional stringdirectoryproperty, while direct calls such aslist_files(directory="sub")retain their existing behavior.