mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-04-10 04:52:40 +00:00
TextFiles passed via input_files incorrectly triggered a 'Model does not support multimodal input' error for non-vision-capable models. Text files are now inlined as text content in the message instead of being rejected. Changes: - base_llm.py: Rewrite _process_message_files to distinguish text files from binary files; add _is_text_file helper - llm.py: Apply same text-file inlining logic in both sync and async _process_message_files methods - crew.py: Recognize text file MIME types as auto-injectable so they don't require the read_file tool - task.py: Same text-file auto-injection logic in prompt method - tests: Add 17 tests covering text file inlining, image rejection, mixed files, _is_text_file helper, and edge cases Co-Authored-By: João <joao@crewai.com>