autogen/website/docs/Installation.md

62 lines
2.2 KiB
Markdown
Raw Normal View History

2023-08-30 16:50:59 -04:00
# Installation
## Setup Virtual Environment
When not using a docker container, we recommend using a virtual environment to install AutoGen. This will ensure that the dependencies for AutoGen are isolated from the rest of your system.
You can create a virtual environment with `venv` as below:
```bash
python3 -m venv autogen
source autogen/bin/activate
```
Another option is with `Conda`, Conda works better at solving dependency conflicts than pip. You can install it by following [this doc](https://docs.conda.io/projects/conda/en/stable/user-guide/install/index.html),
and then create a virtual environment as below:
```bash
conda create -n autogen python=3.10 # python 3.10 is recommended as it's stable and not too old
conda activate autogen
```
Now, you're ready to install AutoGen in the virtual environment you've just created.
2023-08-30 16:50:59 -04:00
## Python
AutoGen requires **Python version >= 3.8**. It can be installed from pip:
```bash
2023-09-16 15:30:28 +00:00
pip install pyautogen
2023-08-30 16:50:59 -04:00
```
2023-09-19 12:38:26 +00:00
<!--
2023-08-30 16:50:59 -04:00
or conda:
```
2023-09-16 15:30:28 +00:00
conda install pyautogen -c conda-forge
``` -->
2023-09-16 15:30:28 +00:00
### Optional Dependencies
* docker
For the best user experience and seamless code execution, we highly recommend using Docker with AutoGen. Docker is a containerization platform that simplifies the setup and execution of your code. Developing in a docker container, such as GitHub Codespace, also makes the development convenient.
When running AutoGen out of a docker container, to use docker for code execution, you also need to install the python package `docker`:
```bash
pip install docker
```
2023-09-16 15:30:28 +00:00
* blendsearch
AutoGen offers a cost-effective hyperparameter optimization technique [EcoOptiGen](https://arxiv.org/abs/2303.04673) for tuning Large Language Models. Please install with the [blendsearch] option to use it.
2023-09-16 15:30:28 +00:00
```bash
pip install "pyautogen[blendsearch]"
```
* retrievechat
AutoGen supports retrieval-augmented generation tasks such as question answering and code generation with RAG agents. Please install with the [retrievechat] option to use it.
```bash
pip install "pyautogen[retrievechat]"
```
* mathchat
AutoGen offers an experimental agent for math problem solving. Please install with the [mathchat] option to use it.
```bash
pip install "pyautogen[mathchat]"
```