安装CAMEL-AI需要遵循以下步骤:
- 确保系统已安装64位Python 3.10、3.11或3.12版本
- 使用conda创建虚拟环境:
conda create --name camel_env python=3.10
conda activate camel_env - 克隆CAMEL仓库:
git clone https://github.com/camel-ai/camel.git
cd camel - 安装依赖项:
conda install pytorch torchvision torchaudio pytorch-cuda=11.7 -c pytorch -c nvidia
pip install -r requirements.txt
pip install -e .
对于需要使用QLoRA进行模型微调的情况,可以运行:bash scripts/train_camel_qlora.sh
最后通过运行测试命令验证安装:python -m camel_chat.serve.test_message --model-name /path/to/model
本答案来源于文章《CAMEL-AI:构建多智能体协作系统的开源框架》