Skip to content

Commit

Permalink
Merge branch 'main' into activate_deactivate_agents
Browse files Browse the repository at this point in the history
  • Loading branch information
peterychang committed Jan 2, 2025
2 parents 6235a94 + a1d782d commit de89455
Show file tree
Hide file tree
Showing 144 changed files with 5,573 additions and 4,015 deletions.
74 changes: 66 additions & 8 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand All @@ -33,7 +33,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand Down Expand Up @@ -61,7 +61,7 @@ jobs:
]
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand Down Expand Up @@ -89,7 +89,7 @@ jobs:
]
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand All @@ -102,6 +102,7 @@ jobs:
source ${{ github.workspace }}/python/.venv/bin/activate
poe --directory ${{ matrix.package }} pyright
working-directory: ./python

test:
runs-on: ubuntu-latest
strategy:
Expand All @@ -115,7 +116,7 @@ jobs:
]
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand All @@ -131,6 +132,45 @@ jobs:
source ${{ github.workspace }}/python/.venv/bin/activate
poe --directory ${{ matrix.package }} test
working-directory: ./python

codecov:
runs-on: ubuntu-latest
strategy:
matrix:
package:
[
"./packages/autogen-core",
"./packages/autogen-magentic-one",
"./packages/autogen-ext",
"./packages/autogen-agentchat",
]
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Run uv sync
run: |
uv sync --locked --all-extras
working-directory: ./python
- name: Run task
run: |
source ${{ github.workspace }}/python/.venv/bin/activate
poe --directory ${{ matrix.package }} coverage
working-directory: ./python
- name: Upload coverage
uses: codecov/codecov-action@v5
with:
fail_ci_if_error: true # optional (default = false)
files: ${{ matrix.package }}/coverage.xml # optional
flags: unittests # optional
name: codecov-umbrella # optional
verbose: true # optional (default = false)
token: ${{ secrets.CODECOV_TOKEN }}

docs:
runs-on: ubuntu-latest
Expand All @@ -139,7 +179,7 @@ jobs:
package: ["./packages/autogen-core"]
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand All @@ -160,7 +200,7 @@ jobs:
package: ["./packages/autogen-core"]
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand All @@ -173,12 +213,30 @@ jobs:
source ${{ github.workspace }}/python/.venv/bin/activate
poe --directory ${{ matrix.package }} docs-check-examples
working-directory: ./python

markdown-code-lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
with:
enable-cache: true
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: uv sync --locked --all-extras
working-directory: ./python
- name: Run task
run: |
source ${{ github.workspace }}/python/.venv/bin/activate
poe markdown-code-lint
working-directory: ./python

check-proto-changes-python:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Python
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.11
Expand All @@ -73,7 +73,7 @@ jobs:
- name: list available kernels
run: |
python -m jupyter kernelspec list
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- run: uv sync --locked --all-extras
Expand Down
59 changes: 44 additions & 15 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,29 +31,33 @@ jobs:
matrix:
version:
[
{ ref: main, dest-dir: dev },
{ ref: "v0.4.0.dev0", dest-dir: "0.4.0.dev0" },
{ ref: "v0.4.0.dev1", dest-dir: "0.4.0.dev1" },
{ ref: "v0.4.0.dev2", dest-dir: "0.4.0.dev2" },
{ ref: "v0.4.0.dev3", dest-dir: "0.4.0.dev3" },
{ ref: "v0.4.0.dev4", dest-dir: "0.4.0.dev4" },
{ ref: "v0.4.0.dev5", dest-dir: "0.4.0.dev5" },
{ ref: "v0.4.0.dev6", dest-dir: "0.4.0.dev6" },
{ ref: "v0.4.0.dev7", dest-dir: "0.4.0.dev7" },
{ ref: "v0.4.0.dev8", dest-dir: "0.4.0.dev8" },
{ ref: "v0.4.0.dev9", dest-dir: "0.4.0.dev9" },
{ ref: "v0.4.0.dev10", dest-dir: "0.4.0.dev10" },
{ ref: "v0.4.0.dev11", dest-dir: "0.4.0.dev11" },
# For main use the workflow target
{ ref: "${{github.ref}}", dest-dir: dev, uv-version: "0.5.13" },
{ ref: "v0.4.0.dev0", dest-dir: "0.4.0.dev0", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev1", dest-dir: "0.4.0.dev1", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev2", dest-dir: "0.4.0.dev2", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev3", dest-dir: "0.4.0.dev3", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev4", dest-dir: "0.4.0.dev4", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev5", dest-dir: "0.4.0.dev5", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev6", dest-dir: "0.4.0.dev6", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev7", dest-dir: "0.4.0.dev7", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev8", dest-dir: "0.4.0.dev8", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev9", dest-dir: "0.4.0.dev9", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev10", dest-dir: "0.4.0.dev10", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev11", dest-dir: "0.4.0.dev11", uv-version: "0.5.11" },
{ ref: "v0.4.0.dev12", dest-dir: "0.4.0.dev12", uv-version: "0.5.13" },
{ ref: "v0.4.0.dev13", dest-dir: "0.4.0.dev13", uv-version: "0.5.13" },
]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: "true"
ref: ${{ matrix.version.ref }}
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
version: ${{ matrix.version.uv-version }}
- uses: actions/setup-python@v5
with:
python-version: "3.11"
Expand Down Expand Up @@ -91,6 +95,31 @@ jobs:
path: "./python/docs-staging"
name: "redirects"

gen-component-schema:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
lfs: "true"
ref: ${{ matrix.version.ref }}
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
with:
python-version: "3.11"
- run: |
uv sync --locked --all-extras
source .venv/bin/activate
mkdir -p docs-staging/schemas/
gen-component-schema > docs-staging/schemas/component-schema-latest.json
working-directory: ./python
- uses: actions/upload-artifact@v4
with:
path: "./python/docs-staging"
name: "component-schema"

build-02:
runs-on: ubuntu-latest
defaults:
Expand Down Expand Up @@ -153,7 +182,7 @@ jobs:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: [build-02, build-04, gen-redirects]
needs: [build-02, build-04, gen-redirects, gen-component-schema]
if: ${{ needs.build-02.result == 'success' && needs.build-04.result == 'success' && needs.gen-redirects.result == 'success' && github.ref == 'refs/heads/main' }}
steps:
- uses: actions/download-artifact@v4
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/dotnet-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ jobs:
- name: list available kernels
run: |
python -m jupyter kernelspec list
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- run: uv sync --locked --all-extras
Expand All @@ -103,10 +103,10 @@ jobs:
dotnet build --no-restore --configuration Release -bl /p:SignAssembly=true
- name: Unit Test
run: dotnet test --no-build -bl --configuration Release --filter type=!integration

integration-test:
strategy:
fail-fast: true
fail-fast: true
matrix:
os: [ ubuntu-latest]
version: [ net8.0 ]
Expand All @@ -119,7 +119,7 @@ jobs:
- uses: actions/checkout@v4
with:
lfs: true
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand Down Expand Up @@ -203,7 +203,7 @@ jobs:
- name: list available kernels
run: |
python -m jupyter kernelspec list
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
Expand Down Expand Up @@ -299,4 +299,4 @@ jobs:
env:
MYGET_TOKEN: ${{ secrets.MYGET_TOKEN }}
continue-on-error: true

2 changes: 1 addition & 1 deletion .github/workflows/single-python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
ref: ${{ github.event.inputs.ref }}
# Require ref to be a tag
- run: git show-ref --verify refs/tags/${{ github.event.inputs.ref }}
- uses: astral-sh/setup-uv@v3
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- run: uv build --package ${{ github.event.inputs.package }} --out-dir dist/
Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ We will update verion numbers according to the following rules:

1. Create a PR that updates the version numbers across the codebase ([example](https://github.com/microsoft/autogen/pull/4359))
2. The docs CI will fail for the PR, but this is expected and will be resolved in the next step
2. After merging the PR, create and push a tag that corresponds to the new verion. For example, for `0.4.0.dev11`:
- `git tag 0.4.0.dev11 && git push origin 0.4.0.dev11`
2. After merging the PR, create and push a tag that corresponds to the new verion. For example, for `0.4.0.dev13`:
- `git tag v0.4.0.dev13 && git push origin v0.4.0.dev13`
3. Restart the docs CI by finding the failed [job corresponding to the `push` event](https://github.com/microsoft/autogen/actions/workflows/docs.yml) and restarting all jobs
4. Run [this](https://github.com/microsoft/autogen/actions/workflows/single-python-package.yml) workflow for each of the packages that need to be released and get an approval for the release for it to run

Expand Down
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,21 @@

[![Twitter](https://img.shields.io/twitter/url/https/twitter.com/cloudposse.svg?style=social&label=Follow%20%40pyautogen)](https://twitter.com/pyautogen) [![LinkedIn](https://img.shields.io/badge/LinkedIn-Company?style=flat&logo=linkedin&logoColor=white)](https://www.linkedin.com/company/105812540) [![Discord](https://img.shields.io/badge/discord-chat-green?logo=discord)](https://aka.ms/autogen-discord) [![GitHub Discussions](https://img.shields.io/badge/Discussions-Q%26A-green?logo=github)](https://github.com/microsoft/autogen/discussions) [![0.2 Docs](https://img.shields.io/badge/Docs-0.2-blue)](https://microsoft.github.io/autogen/0.2/) [![0.4 Docs](https://img.shields.io/badge/Docs-0.4-blue)](https://microsoft.github.io/autogen/dev/)

[![PyPi autogen-core](https://img.shields.io/badge/PyPi-autogen--core-blue?logo=pypi)](https://pypi.org/project/autogen-core/0.4.0.dev11/) [![PyPi autogen-agentchat](https://img.shields.io/badge/PyPi-autogen--agentchat-blue?logo=pypi)](https://pypi.org/project/autogen-agentchat/0.4.0.dev11/) [![PyPi autogen-ext](https://img.shields.io/badge/PyPi-autogen--ext-blue?logo=pypi)](https://pypi.org/project/autogen-ext/0.4.0.dev11/)
[![PyPi autogen-core](https://img.shields.io/badge/PyPi-autogen--core-blue?logo=pypi)](https://pypi.org/project/autogen-core/0.4.0.dev13/) [![PyPi autogen-agentchat](https://img.shields.io/badge/PyPi-autogen--agentchat-blue?logo=pypi)](https://pypi.org/project/autogen-agentchat/0.4.0.dev13/) [![PyPi autogen-ext](https://img.shields.io/badge/PyPi-autogen--ext-blue?logo=pypi)](https://pypi.org/project/autogen-ext/0.4.0.dev13/)
</div>

# AutoGen

> [!IMPORTANT]
>
> - (12/19/24) Hello!
> - (12/19/24) Hello!
The majority of the AutoGen Team members will be resting and recharging with family and friends over the holiday period. Activity/responses on the project may be delayed during the period of Dec 20-Jan 06. We will be excited to engage with you in the new year!
> - (12/11/24) We have created a new Discord server for the AutoGen community. Join us at [aka.ms/autogen-discord](https://aka.ms/autogen-discord).
> - (11/14/24) ⚠️ In response to a number of asks to clarify and distinguish between official AutoGen and its forks that created confusion, we issued a [clarification statement](https://github.com/microsoft/autogen/discussions/4217).
> - (10/13/24) Interested in the standard AutoGen as a prior user? Find it at the actively-maintained *AutoGen* [0.2 branch](https://github.com/microsoft/autogen/tree/0.2) and `autogen-agentchat~=0.2` PyPi package.
> - (10/02/24) [AutoGen 0.4](https://microsoft.github.io/autogen/dev) is a from-the-ground-up rewrite of AutoGen. Learn more about the history, goals and future at [this blog post](https://microsoft.github.io/autogen/blog). We’re excited to work with the community to gather feedback, refine, and improve the project before we officially release 0.4. This is a big change, so AutoGen 0.2 is still available, maintained, and developed in the [0.2 branch](https://github.com/microsoft/autogen/tree/0.2).
> - *[Join us for Community Office Hours](https://github.com/microsoft/autogen/discussions/4059)* We will host a weekly open discussion to answer questions, talk about Roadmap, etc.

AutoGen is an open-source framework for building AI agent systems.
It simplifies the creation of event-driven, distributed, scalable, and resilient agentic applications.
It allows you to quickly build systems where AI agents collaborate and perform tasks autonomously
Expand Down Expand Up @@ -108,7 +107,7 @@ We look forward to your contributions!
First install the packages:

```bash
pip install "autogen-agentchat==0.4.0.dev11" "autogen-ext[openai]==0.4.0.dev11"
pip install "autogen-agentchat==0.4.0.dev13" "autogen-ext[openai]==0.4.0.dev13"
```

The following code uses OpenAI's GPT-4o model and you need to provide your
Expand Down
12 changes: 11 additions & 1 deletion docs/switcher.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,17 @@
{
"name": "0.4.0.dev11",
"version": "0.4.0.dev11",
"url": "/autogen/0.4.0.dev11/",
"url": "/autogen/0.4.0.dev11/"
},
{
"name": "0.4.0.dev12",
"version": "0.4.0.dev12",
"url": "/autogen/0.4.0.dev12/"
},
{
"name": "0.4.0.dev13",
"version": "0.4.0.dev13",
"url": "/autogen/0.4.0.dev13/",
"preferred": true
}
]
Loading

0 comments on commit de89455

Please sign in to comment.