Skip to content

Update tictactoe

Update tictactoe #29

Workflow file for this run

name: Main Validation
on:
push:
branches:
- 'main' # Run on main
- '*release*' # Run on release
jobs:
style-check:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9"]
fail-fast: true # Stop all matrix jobs if one fails
defaults:
run:
working-directory: libs/agno
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade \
pip setuptools wheel \
ruff mypy pytest types-pyyaml
pip install --no-deps -r requirements.txt
- name: Ruff format
run: |
ruff format .
- name: Ruff check
run: |
ruff check .
- name: Mypy
run: |
mypy .
# Run tests for OpenAI
test-openai:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true # Stop all matrix jobs if one fails
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run OpenAI tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/openai') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/openai') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/openai
# Run tests for Google
test-google:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true # Stop all matrix jobs if one fails
env:
GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}
GOOGLE_CLOUD_PROJECT: ${{ secrets.GOOGLE_CLOUD_PROJECT }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Google tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/google') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/google') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/google
# Run tests for Anthropic
test-anthropic:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true # Stop all matrix jobs if one fails
env:
ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Anthropic tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/anthropic') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/anthropic') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/anthropic
# Run tests for AWS
test-aws:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
AWS_ACCESS_KEY_ID: ${{ secrets.BEDROCK_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.BEDROCK_AWS_SECRET_ACCESS_KEY }}
AWS_REGION: "us-east-1"
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run AWS tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/aws') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/aws') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/aws
# Run tests for Cohere
test-cohere:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
CO_API_KEY: ${{ secrets.CO_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Cohere tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/cohere') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/cohere') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/cohere
# Run tests for Deepseek
test-deepseek:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
DEEPSEEK_API_KEY: ${{ secrets.DEEPSEEK_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Deepseek tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/deepseek') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/deepseek') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/deepseek
# Run tests for Fireworks
test-fireworks:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
FIREWORKS_API_KEY: ${{ secrets.FIREWORKS_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Fireworks tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/fireworks') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/fireworks') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/fireworks
# Run tests for Groq
test-groq:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Groq tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/groq') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/groq') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/groq
# Run tests for Mistral
test-mistral:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Mistral tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/mistral') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/mistral') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/mistral
# Run tests for Nvidia
test-nvidia:
if: false # Disable nvidia tests until we get a test account
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
NVIDIA_API_KEY: ${{ secrets.NVIDIA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Nvidia tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/nvidia') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/nvidia') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/nvidia
# Run tests for OpenRouter
test-openrouter:
if: false # Disable openrouter tests until we get a test account
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
OPENROUTER_API_KEY: ${{ secrets.OPENROUTER_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run OpenRouter tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/openrouter') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/openrouter') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/openrouter
# Run tests for Perplexity
test-perplexity:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
PERPLEXITY_API_KEY: ${{ secrets.PERPLEXITY_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Perplexity tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/perplexity') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/perplexity') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/perplexity
# Run tests for SambaNova
test-sambanova:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
SAMBANOVA_API_KEY: ${{ secrets.SAMBANOVA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run SambaNova tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/sambanova') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/sambanova') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/sambanova
# Run tests for Together
test-together:
if: false # The tests take too long to run
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
TOGETHER_API_KEY: ${{ secrets.TOGETHER_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run Together tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/together') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/together') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/together
# Run tests for xAI
test-xai:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true
env:
XAI_API_KEY: ${{ secrets.XAI_API_KEY }}
EXA_API_KEY: ${{ secrets.EXA_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v41
- name: Run xAI tests
if: contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/models/xai') || contains(steps.changed-files.outputs.all_changed_files, 'libs/agno/tests/integration/models/xai') || contains(github.base_ref, 'release')
working-directory: .
run: |
source .venv/bin/activate
python -m pytest ./libs/agno/tests/integration/models/xai
# Run remaining integration tests
test-remaining:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.12"]
fail-fast: true # Stop all matrix jobs if one fails
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Run dev setup
working-directory: .
run: |
./scripts/dev_setup.sh
- name: Run remaining integration tests
working-directory: .
run: |
source .venv/bin/activate
python -m pytest --ignore=./libs/agno/tests/integration/models ./libs/agno/tests/integration