Skip to content

Commit

Permalink
docs: Fix incomplete Gunicorn command Update faqs.mdx (#646)
Browse files Browse the repository at this point in the history
* docs: Fix incomplete Gunicorn command Update faqs.mdx

Fix incomplete Gunicorn command for AutoGen Studio launch

* Update faqs.mdx
  • Loading branch information
mdqst authored Jan 27, 2025
1 parent 496091f commit 35164f1
Showing 1 changed file with 23 additions and 4 deletions.
27 changes: 23 additions & 4 deletions website/docs/autogen-studio/faqs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,21 @@ For other OSS models, we recommend using a server such as vllm, LMStudio, Ollama

## Q: The server starts but I can't access the UI

A: If you are running the server on a remote machine (or a local machine that fails to resolve localhost correctly), you may need to specify the host address. By default, the host address is set to `localhost`. You can specify the host address using the `--host <host>` argument. For example, to start the server on port 8081 and local address such that it is accessible from other machines on the network, you can run the following command:
A: If you are running the server on a remote machine (or a local machine that fails to resolve localhost correctly), you may need to specify the host address. By default, the host address is set to `localhost`. You can specify the host address using the `--host <host>` argument. For example:

- **For Docker or cloud environments (external access required):**

```bash
gunicorn -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) --timeout 12600 -k uvicorn.workers.UvicornWorker autogenstudio.web.app:app --bind "0.0.0.0:8081"
```

- **For local development (restrict to localhost):**

```bash
autogenstudio ui --port 8081 --host 0.0.0.0
gunicorn -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) --timeout 12600 -k uvicorn.workers.UvicornWorker autogenstudio.web.app:app --bind "127.0.0.1:8081"
```

To start the server on port 8081 and make it accessible from other machines on the network, use the command for Docker/cloud environments.
```
## Q: Can I export my agent workflows for use in a python app?
Expand Down Expand Up @@ -82,8 +93,16 @@ COPY --chown=user . $HOME/app
CMD gunicorn -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) --timeout 12600 -k uvicorn.workers.UvicornWorker autogenstudio.web.app:app --bind "0.0.0.0:8081"
```

Using Gunicorn as the application server for improved performance is recommended. To run AutoGen Studio with Gunicorn, you can use the following command:
To run AutoGen Studio with Gunicorn, use one of the following commands based on your environment:

- **For Docker or cloud environments (external access required):**

```bash
gunicorn -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) --timeout 12600 -k uvicorn.workers.UvicornWorker autogenstudio.web.app:app --bind "0.0.0.0:8081"
```

- **For local development (restrict to localhost):**

```bash
gunicorn -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) --timeout 12600 -k uvicorn.workers.UvicornWorker autogenstudio.web.app:app --bind
gunicorn -w $((2 * $(getconf _NPROCESSORS_ONLN) + 1)) --timeout 12600 -k uvicorn.workers.UvicornWorker autogenstudio.web.app:app --bind "127.0.0.1:8081"
```

0 comments on commit 35164f1

Please sign in to comment.