mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-01-08 23:58:34 +00:00
docs: Update training feature/code interpreter docs (#852)
* docs: remove training docs from README * docs: add CodeinterpreterTool to docs and update docs * docs: fix name of tool
This commit is contained in:
committed by
GitHub
parent
5ad3712810
commit
cd77aeebb9
40
README.md
40
README.md
@@ -197,46 +197,6 @@ Please refer to the [Connect crewAI to LLMs](https://docs.crewai.com/how-to/LLM-
|
|||||||
**CrewAI's Advantage**: CrewAI is built with production in mind. It offers the flexibility of Autogen's conversational agents and the structured process approach of ChatDev, but without the rigidity. CrewAI's processes are designed to be dynamic and adaptable, fitting seamlessly into both development and production workflows.
|
**CrewAI's Advantage**: CrewAI is built with production in mind. It offers the flexibility of Autogen's conversational agents and the structured process approach of ChatDev, but without the rigidity. CrewAI's processes are designed to be dynamic and adaptable, fitting seamlessly into both development and production workflows.
|
||||||
|
|
||||||
|
|
||||||
## Training
|
|
||||||
|
|
||||||
The training feature in CrewAI allows you to train your AI agents using the command-line interface (CLI). By running the command `crewai train -n <n_iterations>`, you can specify the number of iterations for the training process.
|
|
||||||
|
|
||||||
During training, CrewAI utilizes techniques to optimize the performance of your agents along with human feedback. This helps the agents improve their understanding, decision-making, and problem-solving abilities.
|
|
||||||
|
|
||||||
To use the training feature, follow these steps:
|
|
||||||
|
|
||||||
1. Open your terminal or command prompt.
|
|
||||||
2. Navigate to the directory where your CrewAI project is located.
|
|
||||||
3. Run the following command:
|
|
||||||
|
|
||||||
```shell
|
|
||||||
crewai train -n <n_iterations>
|
|
||||||
```
|
|
||||||
|
|
||||||
Replace `<n_iterations>` with the desired number of training iterations. This determines how many times the agents will go through the training process.
|
|
||||||
|
|
||||||
Remember to also replace the placeholder inputs with the actual values you want to use on the main.py file in the `train` function.
|
|
||||||
|
|
||||||
```python
|
|
||||||
def train():
|
|
||||||
"""
|
|
||||||
Train the crew for a given number of iterations.
|
|
||||||
"""
|
|
||||||
inputs = {"topic": "AI LLMs"}
|
|
||||||
try:
|
|
||||||
ProjectCreationCrew().crew().train(n_iterations=int(sys.argv[1]), inputs=inputs)
|
|
||||||
...
|
|
||||||
```
|
|
||||||
|
|
||||||
It is important to note that the training process may take some time, depending on the complexity of your agents and will also require your feedback on each iteration.
|
|
||||||
|
|
||||||
Once the training is complete, your agents will be equipped with enhanced capabilities and knowledge, ready to tackle complex tasks and provide more consistent and valuable insights.
|
|
||||||
|
|
||||||
Remember to regularly update and retrain your agents to ensure they stay up-to-date with the latest information and advancements in the field.
|
|
||||||
|
|
||||||
Happy training with CrewAI!
|
|
||||||
|
|
||||||
|
|
||||||
## Contribution
|
## Contribution
|
||||||
|
|
||||||
CrewAI is open-source and we welcome contributions. If you're looking to contribute, please:
|
CrewAI is open-source and we welcome contributions. If you're looking to contribute, please:
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ pip install 'crewai[tools]'
|
|||||||
Remember that when using this tool, the code must be generated by the Agent itself. The code must be a Python3 code. And it will take some time for the first time to run because it needs to build the Docker image.
|
Remember that when using this tool, the code must be generated by the Agent itself. The code must be a Python3 code. And it will take some time for the first time to run because it needs to build the Docker image.
|
||||||
|
|
||||||
```python
|
```python
|
||||||
|
from crewai import Agent
|
||||||
from crewai_tools import CodeInterpreterTool
|
from crewai_tools import CodeInterpreterTool
|
||||||
|
|
||||||
Agent(
|
Agent(
|
||||||
@@ -27,3 +28,14 @@ Agent(
|
|||||||
tools=[CodeInterpreterTool()],
|
tools=[CodeInterpreterTool()],
|
||||||
)
|
)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
We also provide a simple way to use it directly from the Agent.
|
||||||
|
|
||||||
|
```python
|
||||||
|
from crewai import Agent
|
||||||
|
|
||||||
|
agent = Agent(
|
||||||
|
...
|
||||||
|
allow_code_execution=True,
|
||||||
|
)
|
||||||
|
```
|
||||||
|
|||||||
@@ -149,6 +149,7 @@ nav:
|
|||||||
- Google Serper Search: 'tools/SerperDevTool.md'
|
- Google Serper Search: 'tools/SerperDevTool.md'
|
||||||
- Browserbase Web Loader: 'tools/BrowserbaseLoadTool.md'
|
- Browserbase Web Loader: 'tools/BrowserbaseLoadTool.md'
|
||||||
- Composio Tools: 'tools/ComposioTool.md'
|
- Composio Tools: 'tools/ComposioTool.md'
|
||||||
|
- Code Interpreter: 'tools/CodeInterpreterTool.md'
|
||||||
- Scrape Website: 'tools/ScrapeWebsiteTool.md'
|
- Scrape Website: 'tools/ScrapeWebsiteTool.md'
|
||||||
- Directory Read: 'tools/DirectoryReadTool.md'
|
- Directory Read: 'tools/DirectoryReadTool.md'
|
||||||
- Exa Serch Web Loader: 'tools/EXASearchTool.md'
|
- Exa Serch Web Loader: 'tools/EXASearchTool.md'
|
||||||
|
|||||||
Reference in New Issue
Block a user