Commit Graph

2066 Commits

Author SHA1 Message Date
lorenzejay
e9ca6e89d8 regen again placeholder for cassette matching 2026-01-22 14:49:07 -08:00
lorenzejay
11c96d6e3c regen all azure cassettes 2026-01-22 14:14:21 -08:00
lorenzejay
f1bad9c748 regen 2026-01-22 14:09:16 -08:00
lorenzejay
73963b8e65 better tests 2026-01-22 14:08:02 -08:00
lorenzejay
249b118e9e drop logs 2026-01-22 13:54:27 -08:00
lorenzejay
51c5973033 fix test 2026-01-22 13:52:38 -08:00
lorenzejay
c7a83c8c36 fix other test 2026-01-22 13:47:52 -08:00
lorenzejay
ba15fbf8ea Implement max usage count tracking for tools in agent executors
- Added functionality to check if a tool has reached its maximum usage count before execution in both crew_agent_executor.py and agent_executor.py.
- Enhanced error handling to return a message when a tool's usage limit is reached.
- Updated tool usage logic in tool_usage.py to increment usage counts and print current usage status.
- Introduced tests to validate max usage count behavior for native tool calling, ensuring proper enforcement and tracking.

This update improves tool management by preventing overuse and providing clear feedback when limits are reached.
2026-01-22 13:47:36 -08:00
lorenzejay
90ab4d2527 regen azure cassettes 2026-01-22 13:40:10 -08:00
lorenzejay
65746137fe supporting bedrock 2026-01-22 13:31:56 -08:00
lorenzejay
89e961e08e ensure we support bedrock 2026-01-22 13:29:49 -08:00
lorenzejay
a61cfb258f regen gemini 2026-01-22 13:02:14 -08:00
Greyson LaLonde
ca07114bcf refactor: centralize multimodal formatting in crewai_files 2026-01-22 15:59:55 -05:00
lorenzejay
2f300bf86e regen cassettes 2026-01-22 12:49:56 -08:00
lorenzejay
f3951cb09d fix 2026-01-22 12:36:05 -08:00
Greyson LaLonde
b95a3a9bc8 refactor: extract files module to standalone crewai-files package 2026-01-22 15:06:20 -05:00
lorenzejay
77697c3ad9 fix cassettes 2026-01-22 11:43:07 -08:00
lorenzejay
a0fad289c5 Enhance tool handling and delegation tracking in agent executors
- Implemented immediate return for tools with result_as_answer=True in crew_agent_executor.py.
- Added delegation tracking functionality in agent_utils.py to increment delegations when specific tools are used.
- Updated tool usage logic to handle caching more effectively in tool_usage.py.
- Enhanced test cases to validate new delegation features and tool caching behavior.

This update improves the efficiency of tool execution and enhances the delegation capabilities of agents.
2026-01-22 11:42:52 -08:00
lorenzejay
458f6867f0 Enhance tool handling and delegation tracking in agent executors
- Implemented immediate return for tools with result_as_answer=True in crew_agent_executor.py.
- Added delegation tracking functionality in agent_utils.py to increment delegations when specific tools are used.
- Updated tool usage logic to handle caching more effectively in tool_usage.py.
- Enhanced test cases to validate new delegation features and tool caching behavior.

This update improves the efficiency of tool execution and enhances the delegation capabilities of agents.
2026-01-22 11:35:27 -08:00
Greyson LaLonde
a064b84ead feat: add URL file source support for multimodal content 2026-01-22 14:18:16 -05:00
Greyson LaLonde
4d0b6d834c test: add real video file tests for duration detection 2026-01-22 14:08:40 -05:00
Greyson LaLonde
9be88e05ee feat: add format hints to audio/video duration detection 2026-01-22 14:02:55 -05:00
lorenzejay
d0af4c6331 ensure we properly fail tools and emit their events 2026-01-22 10:36:11 -08:00
lorenzejay
0d4ff5d80c adjust 2026-01-22 10:18:35 -08:00
lorenzejay
a6a0bf6412 adjust cassettes and dropped tests due to native tool implementation 2026-01-22 10:15:18 -08:00
lorenzejay
bffe5aa877 revert crew agent executor 2026-01-22 09:28:00 -08:00
Greyson LaLonde
9fec81f976 refactor: improve factory typing with specific provider and uploader types 2026-01-22 12:22:28 -05:00
lorenzejay
85096ca086 regen cassette 2026-01-22 09:17:21 -08:00
lorenzejay
0d62d8dc0c updated cassette 2026-01-22 09:07:37 -08:00
lorenzejay
21911d2de5 linted 2026-01-22 08:49:03 -08:00
Greyson LaLonde
6147d4eb2e refactor: reorganize files module with centralized constants and utilities 2026-01-22 11:46:17 -05:00
lorenzejay
b40780f220 Merge branch 'main' of github.com:crewAIInc/crewAI into lorenze/imp/native-tool-calling 2026-01-22 08:38:57 -08:00
Vini Brasil
06d953bf46 Add model field to LLM failed events (#4267)
Some checks failed
CodeQL Advanced / Analyze (actions) (push) Has been cancelled
CodeQL Advanced / Analyze (python) (push) Has been cancelled
Notify Downstream / notify-downstream (push) Has been cancelled
Move the `model` field from `LLMCallStartedEvent` and
`LLMCallCompletedEvent` to the base `LLMEventBase` class.
2026-01-22 16:19:18 +01:00
Greyson LaLonde
e2a5177da2 refactor: consolidate FileInput and MIME type definitions 2026-01-22 10:15:32 -05:00
Greyson LaLonde
da930fa1df refactor: extract helper functions to reduce code duplication 2026-01-22 09:52:23 -05:00
Greyson LaLonde
0a250a45ce refactor: fix IDE warnings and add Literal types to constraints
- Add Literal types for ImageFormat, AudioFormat, VideoFormat, ProviderName
- Convert methods to @staticmethod where appropriate
- Remove redundant default parameter values
- Fix variable shadowing in nested functions
- Make magic import optional with mimetypes fallback
- Add docstrings to inner functions
2026-01-22 02:54:29 -05:00
Greyson LaLonde
1353cb2a33 feat: add streaming uploads for large files
- OpenAI: Use Uploads API for files > 512MB with chunked streaming
- Gemini: Pass file path directly to SDK for FilePath sources
- Bedrock: Use upload_fileobj with TransferConfig for automatic multipart
2026-01-22 02:10:15 -05:00
Greyson LaLonde
5550c6df7e feat: promote files to first-class crewai.files package 2026-01-22 01:39:04 -05:00
lorenzejay
d9e4a2345b Remove debug print statements from AgentExecutor to clean up the code and improve readability. This change enhances the overall performance of the agent execution flow by eliminating unnecessary console output during LLM calls and iterations. 2026-01-21 17:53:35 -08:00
Greyson LaLonde
204a1cece7 chore: move file processing deps to optional dependencies 2026-01-21 20:52:15 -05:00
Greyson LaLonde
4c0d99601c chore: remove unnecessary comments and fix type errors
- Remove unnecessary block and inline comments from file utilities
- Fix mypy errors by using file.read() instead of file.source.read()
2026-01-21 20:40:13 -05:00
Greyson LaLonde
e2c517d0a2 feat: export file types and deprecate agent multimodal flag
- Export File type classes from crewai package
- Mark Agent.multimodal field as deprecated (use input_files instead)
2026-01-21 20:14:43 -05:00
Greyson LaLonde
af4523b2a1 chore: add file processing dependencies
- Add python-magic and aiocache to core dependencies
- Add optional image-processing group (Pillow)
- Add optional pdf-processing group (pypdf)
- Add optional file-processing group (both)
2026-01-21 20:13:26 -05:00
Greyson LaLonde
1fe020fa6f test: add file utilities tests
- Add tests for file processing constraints and validators
- Add tests for FileProcessor and FileResolver
- Add tests for resolved file types
- Add tests for file store operations
- Add unit tests for multimodal LLM support
2026-01-21 20:12:57 -05:00
Greyson LaLonde
b035aa8947 feat: add ReadFileTool for agent file access
- Create read_file tool for agents to access attached files
- Support reading by file name from crew/task file store
- Add unit tests for ReadFileTool
2026-01-21 20:12:11 -05:00
Greyson LaLonde
4ed5e4ca0e feat: add input_files support to Task and Crew
- Add input_files parameter to Task for file attachments
- Add file_handling mode to Crew for processing behavior
- Integrate file injection in CrewAgentExecutor
- Update prepare_kickoff to handle KickoffInputs type
2026-01-21 20:11:05 -05:00
Greyson LaLonde
771eccfcdf feat: add multimodal support to LLM providers
- Add format_multimodal_content() to all LLM providers
- Support inline base64 and file reference formats
- Add FileResolver integration for upload caching
- Add module exports for files package
2026-01-21 20:05:33 -05:00
Greyson LaLonde
50728b10e8 fix: resolve mypy type errors in file utilities 2026-01-21 19:43:46 -05:00
Greyson LaLonde
42ca4eacff feat: upgrade upload cache to aiocache with atexit cleanup 2026-01-21 19:35:56 -05:00
Greyson LaLonde
d8ebfe7ee0 feat: add module exports and file store 2026-01-21 19:28:40 -05:00