Commit Graph

9 Commits

Author SHA1 Message Date
Lorenze Jay
773da3f994 Remove unused stream method from BaseLLM class to enhance code clarity and maintainability. 2025-03-24 14:07:10 -07:00
Lorenze Jay
e659c352df Refactor Crew class and LLM hierarchy for improved type handling and code clarity
- Update Crew class methods to enhance readability with consistent formatting and type hints.
- Change LLM class to inherit from BaseLLM for better structure.
- Remove unnecessary type checks and streamline tool handling in CrewAgentExecutor.
- Adjust BaseLLM to provide default implementations for stop words and context window size methods.
- Clean up AISuiteLLM by removing unused methods related to stop words and context window size.
2025-03-24 13:56:23 -07:00
Lorenze Jay
7cae76a631 Remove unused tool_calls handling in AISuiteLLM chat completion method for cleaner code. 2025-03-13 11:59:20 -07:00
Lorenze Jay
144b96986e Refactor AISuiteLLM to include tools parameter in completion methods
- Update the _prepare_completion_params method to accept an optional tools parameter
- Modify the chat completion method to utilize the new tools parameter for enhanced functionality
- Clean up print statements for better code clarity
2025-03-13 08:10:33 -07:00
Lorenze Jay
b305ef8f48 Remove abstract method set_callbacks from BaseLLM class 2025-03-12 08:16:35 -07:00
Lorenze Jay
7cb3c8bb4b Update LLM imports and type hints across multiple files
- Modify imports in crew_chat.py to use LLM instead of BaseLLM
- Update type hints in llm_utils.py to use LLM type
- Add optional `stop` parameter to BaseLLM initialization
- Refactor type handling for LLM creation and usage
2025-03-11 16:01:10 -07:00
Lorenze Jay
a40abbf490 Update AISuiteLLM and LLM utility type handling
- Modify AISuiteLLM to support more flexible input types for messages
- Update type hints in AISuiteLLM to allow string or list of message dictionaries
- Enhance LLM utility function to support broader LLM type annotations
- Remove default `self.stop` attribute from BaseLLM initialization
2025-03-11 15:57:08 -07:00
Lorenze Jay
25c64ae86d Add AISuite LLM support and update dependencies
- Integrate AISuite as a new third-party LLM option
- Update pyproject.toml and uv.lock to include aisuite package
- Modify BaseLLM to support more flexible initialization
- Remove unnecessary LLM imports across multiple files
- Implement AISuiteLLM with basic chat completion functionality
2025-03-11 15:48:49 -07:00
Lorenze Jay
709941c4c7 Refactor LLM module by extracting BaseLLM to a separate file
This commit moves the BaseLLM abstract base class from llm.py to a new file llms/base_llm.py to improve code organization. The changes include:

- Creating a new file src/crewai/llms/base_llm.py
- Moving the BaseLLM class to the new file
- Updating imports in __init__.py and llm.py to reflect the new location
- Updating test cases to use the new import path

The refactoring maintains the existing functionality while improving the project's module structure.
2025-03-04 15:54:46 -08:00