mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-01-02 12:48:30 +00:00
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
Update Test Durations / update-durations (3.10) (push) Has been cancelled
Update Test Durations / update-durations (3.11) (push) Has been cancelled
Update Test Durations / update-durations (3.12) (push) Has been cancelled
Update Test Durations / update-durations (3.13) (push) Has been cancelled
* feat: enhance knowledge event handling in Agent class - Updated the Agent class to include task context in knowledge retrieval events. - Emitted new events for knowledge retrieval and query processes, capturing task and agent details. - Refactored knowledge event classes to inherit from a base class for better structure and maintainability. - Added tracing for knowledge events in the TraceCollectionListener to improve observability. This change improves the tracking and management of knowledge queries and retrievals, facilitating better debugging and performance monitoring. * refactor: remove task_id from knowledge event emissions in Agent class - Removed the task_id parameter from various knowledge event emissions in the Agent class to streamline event handling. - This change simplifies the event structure and focuses on the essential context of knowledge retrieval and query processes. This refactor enhances the clarity of knowledge events and aligns with the recent improvements in event handling. * surface association for guardrail events * fix: improve LLM selection logic in converter - Updated the logic for selecting the LLM in the convert_with_instructions function to handle cases where the agent may not have a function_calling_llm attribute. - This change ensures that the converter can still function correctly by falling back to the standard LLM if necessary, enhancing robustness and preventing potential errors. This fix improves the reliability of the conversion process when working with different agent configurations. * fix test * fix: enforce valid LLM instance requirement in converter - Updated the convert_with_instructions function to ensure that a valid LLM instance is provided by the agent. - If neither function_calling_llm nor the standard llm is available, a ValueError is raised, enhancing error handling and robustness. - Improved error messaging for conversion failures to provide clearer feedback on issues encountered during the conversion process. This change strengthens the reliability of the conversion process by ensuring that agents are properly configured with a valid LLM.