source
stringclasses
1 value
repository
stringclasses
1 value
file
stringlengths
17
99
label
stringclasses
1 value
text
stringlengths
11
14.2k
GitHub
autogen
autogen/samples/apps/auto-anny/README.md
autogen
<div align="center"> <img src="images/icon.png" alt="Repo Icon" width="100" height="100"> </div> # AutoAnny AutoAnny is a Discord bot built using AutoGen to help with AutoGen's Discord server. Actually Anny can help with any OSS GitHub project (set `ANNY_GH_REPO` below).
GitHub
autogen
autogen/samples/apps/auto-anny/README.md
autogen
Features - **`/heyanny help`**: Lists commands. - **`/heyanny ghstatus`**: Summarizes GitHub activity. - **`/heyanny ghgrowth`**: Shows GitHub repo growth indicators. - **`/heyanny ghunattended`**: Lists unattended issues and PRs.
GitHub
autogen
autogen/samples/apps/auto-anny/README.md
autogen
Installation 1. Clone the AutoGen repository and `cd samples/apps/auto-anny` 2. Install dependencies: `pip install -r requirements.txt` 3. Export Discord token and GitHub API token, ``` export OAI_CONFIG_LIST=your-autogen-config-list export DISCORD_TOKEN=your-bot-token export GH_TOKEN=your-gh-token export ANNY_GH_REPO=microsoft/autogen # you may choose a different repo name ``` To get a Discord token, you will need to set up your Discord bot using these [instructions](https://discordpy.readthedocs.io/en/stable/discord.html). 4. Start the bot: `python bot.py` Note: By default Anny will log data to `autoanny.log`.
GitHub
autogen
autogen/samples/apps/auto-anny/README.md
autogen
Roadmap - Enable access control - Enable a richer set of commands - Enrich agents with tool use
GitHub
autogen
autogen/samples/apps/auto-anny/README.md
autogen
Contributing Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
GitHub
autogen
autogen/samples/apps/websockets/README.md
autogen
# Using websockets with FastAPI and AutoGen
GitHub
autogen
autogen/samples/apps/websockets/README.md
autogen
Running the example 1. Navigate to the directory containing the example: ``` cd samples/apps/websockets ``` 2. Install the necessary dependencies: ``` ./setup.py ``` 3. Run the application: ``` uvicorn application:app --reload ``` You should now be able to access the application in your web browser at `http://localhost:8000`.
GitHub
autogen
autogen/samples/apps/autogen-studio/README.md
autogen
# AutoGen Studio [![PyPI version](https://badge.fury.io/py/autogenstudio.svg)](https://badge.fury.io/py/autogenstudio) [![Downloads](https://static.pepy.tech/badge/autogenstudio/week)](https://pepy.tech/project/autogenstudio) ![ARA](./docs/ara_stockprices.png) AutoGen Studio is an AutoGen-powered AI app (user interface) to help you rapidly prototype AI agents, enhance them with skills, compose them into workflows and interact with them to accomplish tasks. It is built on top of the [AutoGen](https://microsoft.github.io/autogen) framework, which is a toolkit for building AI agents. Code for AutoGen Studio is on GitHub at [microsoft/autogen](https://github.com/microsoft/autogen/tree/main/samples/apps/autogen-studio) > **Note**: AutoGen Studio is meant to help you rapidly prototype multi-agent workflows and demonstrate an example of end user interfaces built with AutoGen. It is not meant to be a production-ready app. > [!WARNING] > AutoGen Studio is currently under active development and we are iterating quickly. Kindly consider that we may introduce breaking changes in the releases during the upcoming weeks, and also the `README` might be outdated. Please see the AutoGen Studio [docs](https://microsoft.github.io/autogen/docs/autogen-studio/getting-started) page for the most up-to-date information. **Updates** > April 17: AutoGen Studio database layer is now rewritten to use [SQLModel](https://sqlmodel.tiangolo.com/) (Pydantic + SQLAlchemy). This provides entity linking (skills, models, agents and workflows are linked via association tables) and supports multiple [database backend dialects](https://docs.sqlalchemy.org/en/20/dialects/) supported in SQLAlchemy (SQLite, PostgreSQL, MySQL, Oracle, Microsoft SQL Server). The backend database can be specified a `--database-uri` argument when running the application. For example, `autogenstudio ui --database-uri sqlite:///database.sqlite` for SQLite and `autogenstudio ui --database-uri postgresql+psycopg://user:password@localhost/dbname` for PostgreSQL. > March 12: Default directory for AutoGen Studio is now /home/<user>/.autogenstudio. You can also specify this directory using the `--appdir` argument when running the application. For example, `autogenstudio ui --appdir /path/to/folder`. This will store the database and other files in the specified directory e.g. `/path/to/folder/database.sqlite`. `.env` files in that directory will be used to set environment variables for the app. Project Structure: - _autogenstudio/_ code for the backend classes and web api (FastAPI) - _frontend/_ code for the webui, built with Gatsby and TailwindCSS ### Installation There are two ways to install AutoGen Studio - from PyPi or from source. We **recommend installing from PyPi** unless you plan to modify the source code. 1. **Install from PyPi** We recommend using a virtual environment (e.g., conda) to avoid conflicts with existing Python packages. With Python 3.10 or newer active in your virtual environment, use pip to install AutoGen Studio: ```bash pip install autogenstudio ``` 2. **Install from Source** > Note: This approach requires some familiarity with building interfaces in React. If you prefer to install from source, ensure you have Python 3.10+ and Node.js (version above 14.15.0) installed. Here's how you get started: - Clone the AutoGen Studio repository and install its Python dependencies: ```bash pip install -e . ``` - Navigate to the `samples/apps/autogen-studio/frontend` directory, install dependencies, and build the UI: ```bash npm install -g gatsby-cli npm install --global yarn cd frontend yarn install yarn build ``` For Windows users, to build the frontend, you may need alternative commands to build the frontend. ```bash gatsby clean && rmdir /s /q ..\\autogenstudio\\web\\ui 2>nul & (set \"PREFIX_PATH_VALUE=\" || ver>nul) && gatsby build --prefix-paths && xcopy /E /I /Y public ..\\autogenstudio\\web\\ui ``` ### Running the Application Once installed, run the web UI by entering the following in your terminal: ```bash autogenstudio ui --port 8081 ``` This will start the application on the specified port. Open your web browser and go to `http://localhost:8081/` to begin using AutoGen Studio. AutoGen Studio also takes several parameters to customize the application: - `--host <host>` argument to specify the host address. By default, it is set to `localhost`. Y - `--appdir <appdir>` argument to specify the directory where the app files (e.g., database and generated user files) are stored. By default, it is set to the a `.autogenstudio` directory in the user's home directory. - `--port <port>` argument to specify the port number. By default, it is set to `8080`. - `--reload` argument to enable auto-reloading of the server when changes are made to the code. By default, it is set to `False`. - `--database-uri` argument to specify the database URI. Example values include `sqlite:///database.sqlite` for SQLite and `postgresql+psycopg://user:password@localhost/dbname` for PostgreSQL. If this is not specified, the database URIL defaults to a `database.sqlite` file in the `--appdir` directory. Now that you have AutoGen Studio installed and running, you are ready to explore its capabilities, including defining and modifying agent workflows, interacting with agents and sessions, and expanding agent skills. #### If running from source When running from source, you need to separately bring up the frontend server. 1. Open a separate terminal and change directory to the frontend ```bash cd frontend ``` 3. Create a `.env.development` file. ```bash cp .env.default .env.development ``` 3. Launch frontend server ```bash npm run start ```
GitHub
autogen
autogen/samples/apps/autogen-studio/README.md
autogen
Contribution Guide We welcome contributions to AutoGen Studio. We recommend the following general steps to contribute to the project: - Review the overall AutoGen project [contribution guide](https://github.com/microsoft/autogen?tab=readme-ov-file#contributing) - Please review the AutoGen Studio [roadmap](https://github.com/microsoft/autogen/issues/737) to get a sense of the current priorities for the project. Help is appreciated especially with Studio issues tagged with `help-wanted` - Please initiate a discussion on the roadmap issue or a new issue to discuss your proposed contribution. - Please review the autogenstudio dev branch here [dev branch](https://github.com/microsoft/autogen/tree/autogenstudio) and use as a base for your contribution. This way, your contribution will be aligned with the latest changes in the AutoGen Studio project. - Submit a pull request with your contribution! - If you are modifying AutoGen Studio, it has its own devcontainer. See instructions in `.devcontainer/README.md` to use it - Please use the tag `studio` for any issues, questions, and PRs related to Studio
GitHub
autogen
autogen/samples/apps/autogen-studio/README.md
autogen
FAQ Please refer to the AutoGen Studio [FAQs](https://microsoft.github.io/autogen/docs/autogen-studio/faqs) page for more information.
GitHub
autogen
autogen/samples/apps/autogen-studio/README.md
autogen
Acknowledgements AutoGen Studio is Based on the [AutoGen](https://microsoft.github.io/autogen) project. It was adapted from a research prototype built in October 2023 (original credits: Gagan Bansal, Adam Fourney, Victor Dibia, Piali Choudhury, Saleema Amershi, Ahmed Awadallah, Chi Wang).
GitHub
autogen
autogen/samples/apps/autogen-studio/frontend/README.md
autogen
## 🚀 Running UI in Dev Mode Run the UI in dev mode (make changes and see them reflected in the browser with hotreloading): - npm install - npm run start This should start the server on port 8000.
GitHub
autogen
autogen/samples/apps/autogen-studio/frontend/README.md
autogen
Design Elements - **Gatsby**: The app is created in Gatsby. A guide on bootstrapping a Gatsby app can be found here - https://www.gatsbyjs.com/docs/quick-start/. This provides an overview of the project file structure include functionality of files like `gatsby-config.js`, `gatsby-node.js`, `gatsby-browser.js` and `gatsby-ssr.js`. - **TailwindCSS**: The app uses TailwindCSS for styling. A guide on using TailwindCSS with Gatsby can be found here - https://tailwindcss.com/docs/guides/gatsby.https://tailwindcss.com/docs/guides/gatsby . This will explain the functionality in tailwind.config.js and postcss.config.js.
GitHub
autogen
autogen/samples/apps/autogen-studio/frontend/README.md
autogen
Modifying the UI, Adding Pages The core of the app can be found in the `src` folder. To add pages, add a new folder in `src/pages` and add a `index.js` file. This will be the entry point for the page. For example to add a route in the app like `/about`, add a folder `about` in `src/pages` and add a `index.tsx` file. You can follow the content style in `src/pages/index.tsx` to add content to the page. Core logic for each component should be written in the `src/components` folder and then imported in pages as needed.
GitHub
autogen
autogen/samples/apps/autogen-studio/frontend/README.md
autogen
connecting to front end the front end makes request to the backend api and expects it at /api on localhost port 8081
GitHub
autogen
autogen/samples/apps/autogen-studio/frontend/README.md
autogen
setting env variables for the UI - please look at `.env.default` - make a copy of this file and name it `.env.development` - set the values for the variables in this file - The main variable here is `GATSBY_API_URL` which should be set to `http://localhost:8081/api` for local development. This tells the UI where to make requests to the backend.