mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-01-03 21:28:29 +00:00
Compare commits
3 Commits
devin/1745
...
devin/1745
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5d4ab49153 | ||
|
|
d3223a5aa1 | ||
|
|
2e4c97661a |
14
README.md
14
README.md
@@ -129,12 +129,24 @@ First, install CrewAI:
|
||||
```shell
|
||||
pip install crewai
|
||||
```
|
||||
|
||||
If you want to install the 'crewai' package along with its optional features that include additional tools for agents, you can do so by using the following command:
|
||||
|
||||
```shell
|
||||
pip install 'crewai[tools]'
|
||||
```
|
||||
The command above installs the basic package and also adds extra components which require more dependencies to function.
|
||||
|
||||
### Using conda
|
||||
|
||||
You can also install CrewAI using conda:
|
||||
|
||||
```shell
|
||||
conda install -c conda-forge crewai
|
||||
```
|
||||
|
||||
Note: If you're using Python 3.10, make sure you have `typing_extensions` installed to resolve any 'Self' import issues.
|
||||
|
||||
The commands above install the basic package and also add extra components which require more dependencies to function.
|
||||
|
||||
### Troubleshooting Dependencies
|
||||
|
||||
|
||||
47
conda/README.md
Normal file
47
conda/README.md
Normal file
@@ -0,0 +1,47 @@
|
||||
# Conda Package for CrewAI
|
||||
|
||||
This directory contains the necessary files to build a conda package for CrewAI.
|
||||
|
||||
## Files
|
||||
|
||||
- `meta.yaml`: The main conda recipe file that defines package metadata, dependencies, and build requirements
|
||||
- `build.sh`: Build script for Unix-like systems (Linux, macOS)
|
||||
- `bld.bat`: Build script for Windows
|
||||
|
||||
## Building the Package
|
||||
|
||||
To build the package, you need to have conda-build installed:
|
||||
|
||||
```bash
|
||||
conda install conda-build
|
||||
```
|
||||
|
||||
Then, from the repository root directory:
|
||||
|
||||
```bash
|
||||
conda build conda
|
||||
```
|
||||
|
||||
## Testing the Package
|
||||
|
||||
After building, you can install and test the package:
|
||||
|
||||
```bash
|
||||
conda install --use-local crewai
|
||||
```
|
||||
|
||||
## Uploading to Anaconda
|
||||
|
||||
To upload the package to Anaconda, you need to have anaconda-client installed:
|
||||
|
||||
```bash
|
||||
conda install anaconda-client
|
||||
anaconda login
|
||||
anaconda upload /path/to/conda-bld/noarch/crewai-*.tar.bz2
|
||||
```
|
||||
|
||||
## Compatibility Notes
|
||||
|
||||
This package addresses compatibility issues with:
|
||||
- Python 3.10: Adds typing_extensions as a dependency to provide the Self type
|
||||
- Python 3.12: Ensures compatibility with the tokenizers package
|
||||
2
conda/bld.bat
Normal file
2
conda/bld.bat
Normal file
@@ -0,0 +1,2 @@
|
||||
"%PYTHON%" -m pip install . --no-deps -vv
|
||||
if errorlevel 1 exit 1
|
||||
3
conda/build.sh
Executable file
3
conda/build.sh
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/bin/bash
|
||||
|
||||
$PYTHON -m pip install . --no-deps -vv
|
||||
66
conda/meta.yaml
Normal file
66
conda/meta.yaml
Normal file
@@ -0,0 +1,66 @@
|
||||
{% set name = "crewai" %}
|
||||
{% set version = "0.86.0" %}
|
||||
|
||||
package:
|
||||
name: {{ name|lower }}
|
||||
version: {{ version }}
|
||||
|
||||
source:
|
||||
path: ..
|
||||
|
||||
build:
|
||||
noarch: python
|
||||
number: 0
|
||||
script: {{ PYTHON }} -m pip install . -vv
|
||||
entry_points:
|
||||
- crewai = crewai.cli.cli:crewai
|
||||
|
||||
requirements:
|
||||
host:
|
||||
- python >=3.10,<3.13
|
||||
- pip
|
||||
- hatchling
|
||||
run:
|
||||
- python >=3.10,<3.13
|
||||
- pydantic >=2.4.2
|
||||
- openai >=1.13.3
|
||||
- opentelemetry-api >=1.22.0
|
||||
- opentelemetry-sdk >=1.22.0
|
||||
- opentelemetry-exporter-otlp-proto-http >=1.22.0
|
||||
- instructor >=1.3.3
|
||||
- regex >=2024.9.11
|
||||
- click >=8.1.7
|
||||
- python-dotenv >=1.0.0
|
||||
- appdirs >=1.4.4
|
||||
- jsonref >=1.1.0
|
||||
- json-repair >=0.25.2
|
||||
- auth0-python >=4.7.1
|
||||
- litellm >=1.44.22
|
||||
- pyvis >=0.3.2
|
||||
- uv >=0.4.25
|
||||
- tomli-w >=1.1.0
|
||||
- tomli >=2.0.2
|
||||
- chromadb >=0.5.23
|
||||
- pdfplumber >=0.11.4
|
||||
- openpyxl >=3.1.5
|
||||
- blinker >=1.9.0
|
||||
|
||||
test:
|
||||
imports:
|
||||
- crewai
|
||||
commands:
|
||||
- pip check
|
||||
- crewai --help
|
||||
|
||||
about:
|
||||
home: https://crewai.com
|
||||
doc_url: https://docs.crewai.com
|
||||
dev_url: https://github.com/crewAIInc/crewAI
|
||||
summary: Cutting-edge framework for orchestrating role-playing, autonomous AI agents
|
||||
license: MIT
|
||||
|
||||
extra:
|
||||
recipe-maintainers:
|
||||
- joaomoura
|
||||
# For Python 3.10 compatibility (Self type)
|
||||
- typing_extensions >=4.0.0
|
||||
@@ -179,7 +179,78 @@ def crew(self) -> Crew:
|
||||
```
|
||||
</Note>
|
||||
|
||||
### 10. API Keys
|
||||
### 10. Deploy
|
||||
|
||||
Deploy the crew or flow to [CrewAI Enterprise](https://app.crewai.com).
|
||||
|
||||
- **Authentication**: You need to be authenticated to deploy to CrewAI Enterprise.
|
||||
```shell Terminal
|
||||
crewai signup
|
||||
```
|
||||
If you already have an account, you can login with:
|
||||
```shell Terminal
|
||||
crewai login
|
||||
```
|
||||
|
||||
- **Create a deployment**: Once you are authenticated, you can create a deployment for your crew or flow from the root of your localproject.
|
||||
```shell Terminal
|
||||
crewai deploy create
|
||||
```
|
||||
- Reads your local project configuration.
|
||||
- Prompts you to confirm the environment variables (like `OPENAI_API_KEY`, `SERPER_API_KEY`) found locally. These will be securely stored with the deployment on the Enterprise platform. Ensure your sensitive keys are correctly configured locally (e.g., in a `.env` file) before running this.
|
||||
- Links the deployment to the corresponding remote GitHub repository (it usually detects this automatically).
|
||||
|
||||
- **Deploy the Crew**: Once you are authenticated, you can deploy your crew or flow to CrewAI Enterprise.
|
||||
```shell Terminal
|
||||
crewai deploy push
|
||||
```
|
||||
- Initiates the deployment process on the CrewAI Enterprise platform.
|
||||
- Upon successful initiation, it will output the Deployment created successfully! message along with the Deployment Name and a unique Deployment ID (UUID).
|
||||
|
||||
- **Deployment Status**: You can check the status of your deployment with:
|
||||
```shell Terminal
|
||||
crewai deploy status
|
||||
```
|
||||
This fetches the latest deployment status of your most recent deployment attempt (e.g., `Building Images for Crew`, `Deploy Enqueued`, `Online`).
|
||||
|
||||
- **Deployment Logs**: You can check the logs of your deployment with:
|
||||
```shell Terminal
|
||||
crewai deploy logs
|
||||
```
|
||||
This streams the deployment logs to your terminal.
|
||||
|
||||
- **List deployments**: You can list all your deployments with:
|
||||
```shell Terminal
|
||||
crewai deploy list
|
||||
```
|
||||
This lists all your deployments.
|
||||
|
||||
- **Delete a deployment**: You can delete a deployment with:
|
||||
```shell Terminal
|
||||
crewai deploy remove
|
||||
```
|
||||
This deletes the deployment from the CrewAI Enterprise platform.
|
||||
|
||||
- **Help Command**: You can get help with the CLI with:
|
||||
```shell Terminal
|
||||
crewai deploy --help
|
||||
```
|
||||
This shows the help message for the CrewAI Deploy CLI.
|
||||
|
||||
Watch this video tutorial for a step-by-step demonstration of deploying your crew to [CrewAI Enterprise](http://app.crewai.com) using the CLI.
|
||||
|
||||
<iframe
|
||||
width="100%"
|
||||
height="400"
|
||||
src="https://www.youtube.com/embed/3EqSV-CYDZA"
|
||||
title="CrewAI Deployment Guide"
|
||||
frameborder="0"
|
||||
style={{ borderRadius: '10px' }}
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
||||
allowfullscreen
|
||||
></iframe>
|
||||
|
||||
### 11. API Keys
|
||||
|
||||
When running ```crewai create crew``` command, the CLI will first show you the top 5 most common LLM providers and ask you to select one.
|
||||
|
||||
|
||||
@@ -32,6 +32,22 @@ Watch this video tutorial for a step-by-step demonstration of the installation p
|
||||
|
||||
CrewAI uses the `uv` as its dependency management and package handling tool. It simplifies project setup and execution, offering a seamless experience.
|
||||
|
||||
### Installation Options
|
||||
|
||||
You can install CrewAI using either pip or conda:
|
||||
|
||||
#### Using pip (recommended)
|
||||
```shell
|
||||
pip install crewai
|
||||
```
|
||||
|
||||
#### Using conda
|
||||
```shell
|
||||
conda install -c conda-forge crewai
|
||||
```
|
||||
|
||||
Note: If you're using Python 3.10 with conda, make sure you have `typing_extensions` installed to resolve any 'Self' import issues.
|
||||
|
||||
If you haven't installed `uv` yet, follow **step 1** to quickly get it set up on your system, else you can skip to **step 2**.
|
||||
|
||||
<Steps>
|
||||
|
||||
0
tests/conda/__init__.py
Normal file
0
tests/conda/__init__.py
Normal file
45
tests/conda/test_conda_compatibility.py
Normal file
45
tests/conda/test_conda_compatibility.py
Normal file
@@ -0,0 +1,45 @@
|
||||
"""Tests for conda compatibility."""
|
||||
import sys
|
||||
import unittest
|
||||
|
||||
|
||||
class TestCondaCompatibility(unittest.TestCase):
|
||||
"""Test conda compatibility."""
|
||||
|
||||
def test_python_version_compatibility(self):
|
||||
"""Test Python version compatibility."""
|
||||
version = sys.version_info
|
||||
self.assertGreaterEqual(version.major, 3)
|
||||
self.assertGreaterEqual(version.minor, 10)
|
||||
self.assertLess(version.minor, 13)
|
||||
|
||||
def test_typing_self_import(self):
|
||||
"""Test that Self can be imported from typing."""
|
||||
try:
|
||||
from typing import Self
|
||||
self.assertTrue(True)
|
||||
except ImportError:
|
||||
if sys.version_info.minor == 10:
|
||||
# In Python 3.10, Self might not be available directly from typing
|
||||
try:
|
||||
from typing_extensions import Self
|
||||
self.assertTrue(True)
|
||||
except ImportError:
|
||||
self.fail("Self not available from typing or typing_extensions in Python 3.10")
|
||||
else:
|
||||
self.fail("Self not available from typing")
|
||||
|
||||
def test_tokenizers_import(self):
|
||||
"""Test tokenizers import if it's installed."""
|
||||
try:
|
||||
import tokenizers
|
||||
# Only test if tokenizers is installed
|
||||
if sys.version_info.minor == 12:
|
||||
self.assertTrue(True, "tokenizers successfully imported in Python 3.12")
|
||||
except ImportError:
|
||||
# Skip test if tokenizers is not installed
|
||||
self.skipTest("tokenizers package not installed")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
Reference in New Issue
Block a user