docs: improve formatting and clarity in CLI and Composio Tool docs (#1946)

* docs: improve formatting and clarity in CLI and Composio Tool docs

- Add Terminal label to shell code blocks in CLI docs
- Update Composio Tool title and fix tip formatting

* docs: improve installation guide with virtual environment details

- Update Python version requirements and commands
- Add detailed virtual environment setup instructions
- Clarify project-specific environment activation steps
- Streamline additional tools installation with UV

* docs: simplify installation guide

- Remove redundant virtual environment instructions
- Simplify project creation steps
- Update UV package manager description
This commit is contained in:
Tony Kipkemboi
2025-01-22 10:30:16 -05:00
committed by GitHub
parent a21e310d78
commit c642ebf97e
3 changed files with 75 additions and 24 deletions

View File

@@ -12,7 +12,7 @@ The CrewAI CLI provides a set of commands to interact with CrewAI, allowing you
To use the CrewAI CLI, make sure you have CrewAI installed: To use the CrewAI CLI, make sure you have CrewAI installed:
```shell ```shell Terminal
pip install crewai pip install crewai
``` ```
@@ -20,7 +20,7 @@ pip install crewai
The basic structure of a CrewAI CLI command is: The basic structure of a CrewAI CLI command is:
```shell ```shell Terminal
crewai [COMMAND] [OPTIONS] [ARGUMENTS] crewai [COMMAND] [OPTIONS] [ARGUMENTS]
``` ```
@@ -30,7 +30,7 @@ crewai [COMMAND] [OPTIONS] [ARGUMENTS]
Create a new crew or flow. Create a new crew or flow.
```shell ```shell Terminal
crewai create [OPTIONS] TYPE NAME crewai create [OPTIONS] TYPE NAME
``` ```
@@ -38,7 +38,7 @@ crewai create [OPTIONS] TYPE NAME
- `NAME`: Name of the crew or flow - `NAME`: Name of the crew or flow
Example: Example:
```shell ```shell Terminal
crewai create crew my_new_crew crewai create crew my_new_crew
crewai create flow my_new_flow crewai create flow my_new_flow
``` ```
@@ -47,14 +47,14 @@ crewai create flow my_new_flow
Show the installed version of CrewAI. Show the installed version of CrewAI.
```shell ```shell Terminal
crewai version [OPTIONS] crewai version [OPTIONS]
``` ```
- `--tools`: (Optional) Show the installed version of CrewAI tools - `--tools`: (Optional) Show the installed version of CrewAI tools
Example: Example:
```shell ```shell Terminal
crewai version crewai version
crewai version --tools crewai version --tools
``` ```
@@ -63,7 +63,7 @@ crewai version --tools
Train the crew for a specified number of iterations. Train the crew for a specified number of iterations.
```shell ```shell Terminal
crewai train [OPTIONS] crewai train [OPTIONS]
``` ```
@@ -71,7 +71,7 @@ crewai train [OPTIONS]
- `-f, --filename TEXT`: Path to a custom file for training (default: "trained_agents_data.pkl") - `-f, --filename TEXT`: Path to a custom file for training (default: "trained_agents_data.pkl")
Example: Example:
```shell ```shell Terminal
crewai train -n 10 -f my_training_data.pkl crewai train -n 10 -f my_training_data.pkl
``` ```
@@ -79,14 +79,14 @@ crewai train -n 10 -f my_training_data.pkl
Replay the crew execution from a specific task. Replay the crew execution from a specific task.
```shell ```shell Terminal
crewai replay [OPTIONS] crewai replay [OPTIONS]
``` ```
- `-t, --task_id TEXT`: Replay the crew from this task ID, including all subsequent tasks - `-t, --task_id TEXT`: Replay the crew from this task ID, including all subsequent tasks
Example: Example:
```shell ```shell Terminal
crewai replay -t task_123456 crewai replay -t task_123456
``` ```
@@ -94,7 +94,7 @@ crewai replay -t task_123456
Retrieve your latest crew.kickoff() task outputs. Retrieve your latest crew.kickoff() task outputs.
```shell ```shell Terminal
crewai log-tasks-outputs crewai log-tasks-outputs
``` ```
@@ -102,7 +102,7 @@ crewai log-tasks-outputs
Reset the crew memories (long, short, entity, latest_crew_kickoff_outputs). Reset the crew memories (long, short, entity, latest_crew_kickoff_outputs).
```shell ```shell Terminal
crewai reset-memories [OPTIONS] crewai reset-memories [OPTIONS]
``` ```
@@ -113,7 +113,7 @@ crewai reset-memories [OPTIONS]
- `-a, --all`: Reset ALL memories - `-a, --all`: Reset ALL memories
Example: Example:
```shell ```shell Terminal
crewai reset-memories --long --short crewai reset-memories --long --short
crewai reset-memories --all crewai reset-memories --all
``` ```
@@ -122,7 +122,7 @@ crewai reset-memories --all
Test the crew and evaluate the results. Test the crew and evaluate the results.
```shell ```shell Terminal
crewai test [OPTIONS] crewai test [OPTIONS]
``` ```
@@ -130,7 +130,7 @@ crewai test [OPTIONS]
- `-m, --model TEXT`: LLM Model to run the tests on the Crew (default: "gpt-4o-mini") - `-m, --model TEXT`: LLM Model to run the tests on the Crew (default: "gpt-4o-mini")
Example: Example:
```shell ```shell Terminal
crewai test -n 5 -m gpt-3.5-turbo crewai test -n 5 -m gpt-3.5-turbo
``` ```
@@ -138,7 +138,7 @@ crewai test -n 5 -m gpt-3.5-turbo
Run the crew. Run the crew.
```shell ```shell Terminal
crewai run crewai run
``` ```
<Note> <Note>
@@ -153,7 +153,7 @@ Starting in version `0.98.0`, when you run the `crewai chat` command, you start
After receiving the results, you can continue interacting with the assistant for further instructions or questions. After receiving the results, you can continue interacting with the assistant for further instructions or questions.
```shell ```shell Terminal
crewai chat crewai chat
``` ```
<Note> <Note>

View File

@@ -15,10 +15,48 @@ icon: wrench
If you need to update Python, visit [python.org/downloads](https://python.org/downloads) If you need to update Python, visit [python.org/downloads](https://python.org/downloads)
</Note> </Note>
# Setting Up Your Environment
Before installing CrewAI, it's recommended to set up a virtual environment. This helps isolate your project dependencies and avoid conflicts.
<Steps>
<Step title="Create a Virtual Environment">
Choose your preferred method to create a virtual environment:
**Using venv (Python's built-in tool):**
```shell Terminal
python3 -m venv .venv
```
**Using conda:**
```shell Terminal
conda create -n crewai-env python=3.12
```
</Step>
<Step title="Activate the Virtual Environment">
Activate your virtual environment based on your platform:
**On macOS/Linux (venv):**
```shell Terminal
source .venv/bin/activate
```
**On Windows (venv):**
```shell Terminal
.venv\Scripts\activate
```
**Using conda (all platforms):**
```shell Terminal
conda activate crewai-env
```
</Step>
</Steps>
# Installing CrewAI # Installing CrewAI
CrewAI is a flexible and powerful AI framework that enables you to create and manage AI agents, tools, and tasks efficiently. Now let's get you set up! 🚀
Let's get you set up! 🚀
<Steps> <Steps>
<Step title="Install CrewAI"> <Step title="Install CrewAI">
@@ -72,9 +110,9 @@ Let's get you set up! 🚀
# Creating a New Project # Creating a New Project
<Info> <Tip>
We recommend using the YAML Template scaffolding for a structured approach to defining agents and tasks. We recommend using the YAML Template scaffolding for a structured approach to defining agents and tasks.
</Info> </Tip>
<Steps> <Steps>
<Step title="Generate Project Structure"> <Step title="Generate Project Structure">
@@ -101,11 +139,23 @@ Let's get you set up! 🚀
│ └── __init__.py │ └── __init__.py
└── config/ └── config/
├── agents.yaml ├── agents.yaml
├── config.yaml
└── tasks.yaml └── tasks.yaml
``` ```
</Frame> </Frame>
</Step> </Step>
<Step title="Install Additional Tools">
You can install additional tools using UV:
```shell Terminal
uv add <tool-name>
```
<Tip>
UV is our preferred package manager as it's significantly faster than pip and provides better dependency resolution.
</Tip>
</Step>
<Step title="Customize Your Project"> <Step title="Customize Your Project">
Your project will contain these essential files: Your project will contain these essential files:

View File

@@ -1,5 +1,5 @@
--- ---
title: Composio title: Composio Tool
description: Composio provides 250+ production-ready tools for AI agents with flexible authentication management. description: Composio provides 250+ production-ready tools for AI agents with flexible authentication management.
icon: gear-code icon: gear-code
--- ---
@@ -75,7 +75,8 @@ filtered_action_enums = toolset.find_actions_by_use_case(
) )
tools = toolset.get_tools(actions=filtered_action_enums) tools = toolset.get_tools(actions=filtered_action_enums)
```<Tip>Set `advanced` to True to get actions for complex use cases</Tip> ```
<Tip>Set `advanced` to True to get actions for complex use cases</Tip>
- Using specific tools: - Using specific tools: