diff --git a/.github/workflows/deploy-agents.yaml b/.github/workflows/deploy-agents.yaml index ce5e156..45a440c 100644 --- a/.github/workflows/deploy-agents.yaml +++ b/.github/workflows/deploy-agents.yaml @@ -1,80 +1,80 @@ name: Deploy Agents on: - push: - branches: - - main - paths: - - '1-uagents/finance/**' - - '1-uagents/geo/**' - - '1-uagents/knowledge-base/**' - - '1-uagents/search/**' - - '1-uagents/travel/**' - - '1-uagents/utility/**' - - '1-uagents/communication/**' - - 'scripts/deploy-all-agents.sh' - - '.github/workflows/deploy-agents.yaml' + push: + branches: + - main + paths: + - "1-uagents/finance/**" + - "1-uagents/geo/**" + - "1-uagents/knowledge-base/**" + - "1-uagents/search/**" + - "1-uagents/travel/**" + - "1-uagents/utility/**" + - "1-uagents/communication/**" + - "scripts/deploy-all-agents.sh" + - ".github/workflows/deploy-agents.yaml" jobs: - deploy: - runs-on: ubuntu-latest + deploy: + runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - - name: Download latest AVCTL release binary - run: | - LATEST_RELEASE_URL=$(curl -s https://api.github.com/repos/fetchai/avctl/releases/latest \ - | grep browser_download_url \ - | grep avctl_Linux_x86_64.tar.gz \ - | cut -d '"' -f 4) - - curl -L -o avctl_Linux_x86_64.tar.gz $LATEST_RELEASE_URL - - - name: Extract binary and install - run: | - tar -xvf avctl_Linux_x86_64.tar.gz - chmod +x avctl - mv avctl /usr/local/bin/avctl + steps: + - name: Checkout code + uses: actions/checkout@v4 - - name: Authenticate with Agentverse - run: avctl auth token ${{ secrets.AGENTVERSE_API_KEY }} + - name: Download latest AVCTL release binary + run: | + LATEST_RELEASE_URL=$(curl -s https://api.github.com/repos/fetchai/avctl/releases/latest \ + | grep browser_download_url \ + | grep avctl_Linux_x86_64.tar.gz \ + | cut -d '"' -f 4) - - name: Deploy all agents - run: ./scripts/deploy-all-agents.sh - env: - ALPHAVANTAGE_API_KEY: ${{ secrets.ALPHAVANTAGE_API_KEY }} - ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} - GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} - GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }} - OCM_API_KEY: ${{ secrets.OCM_API_KEY }} - OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} - OPENCAGE_API_KEY: ${{ secrets.OPENCAGE_API_KEY }} - WEATHERAPI_KEY: ${{ secrets.WEATHERAPI_KEY }} - HUGGINGFACE_API_KEY: ${{ secrets.HUGGINGFACE_API_KEY }} - GEOAPIFY_API_KEY: ${{ secrets.GEOAPIFY_API_KEY }} - TAVILY_API_KEY: ${{ secrets.TAVILY_API_KEY }} - RAPIDAPI_API_KEY: ${{ secrets.RAPIDAPI_API_KEY }} - SAPLING_API_KEY: ${{ secrets.SAPLING_API_KEY }} + curl -L -o avctl_Linux_x86_64.tar.gz $LATEST_RELEASE_URL - - name: Check for newly deployed agents - id: check-new-agents - run: | - if git diff --quiet 1-uagents/**.avctl**; then - echo "new=true" >> "$GITHUB_OUTPUT" - else - echo "new=false" >> "$GITHUB_OUTPUT" - fi + - name: Extract binary and install + run: | + tar -xvf avctl_Linux_x86_64.tar.gz + chmod +x avctl + mv avctl /usr/local/bin/avctl - - name: Create Pull Request - uses: peter-evans/create-pull-request@v7 - with: - token: ${{ secrets.GITHUB_TOKEN }} - commit-message: "deploy: add .avctl files for new agents" - title: "deploy: add deployment configuration files for new agents" - body: "This PR adds AVCTL deployment configuration files for new agents." - base: "main" - branch: "chore/deploy-production-agents-${{ github.run_number }}" - add-paths: "1-uagents/**.avctl**" - if: steps.check-new-agents.outputs.new == 'true' + - name: Authenticate with Agentverse + run: avctl auth token ${{ secrets.AGENTVERSE_API_KEY }} + + - name: Deploy all agents + run: ./scripts/deploy-all-agents.sh + env: + ALPHAVANTAGE_API_KEY: ${{ secrets.ALPHAVANTAGE_API_KEY }} + ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }} + GEMINI_API_KEY: ${{ secrets.GEMINI_API_KEY }} + GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }} + OCM_API_KEY: ${{ secrets.OCM_API_KEY }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} + OPENCAGE_API_KEY: ${{ secrets.OPENCAGE_API_KEY }} + WEATHERAPI_KEY: ${{ secrets.WEATHERAPI_KEY }} + HUGGINGFACE_API_KEY: ${{ secrets.HUGGINGFACE_API_KEY }} + GEOAPIFY_API_KEY: ${{ secrets.GEOAPIFY_API_KEY }} + TAVILY_API_KEY: ${{ secrets.TAVILY_API_KEY }} + RAPIDAPI_API_KEY: ${{ secrets.RAPIDAPI_API_KEY }} + SAPLING_API_KEY: ${{ secrets.SAPLING_API_KEY }} + + - name: Check for newly deployed agents + id: check-new-agents + run: | + if git diff --quiet 1-uagents/**.avctl**; then + echo "new=true" >> "$GITHUB_OUTPUT" + else + echo "new=false" >> "$GITHUB_OUTPUT" + fi + + - name: Create Pull Request + uses: peter-evans/create-pull-request@v7 + with: + token: ${{ secrets.GITHUB_TOKEN }} + commit-message: "deploy: add .avctl files for new agents" + title: "deploy: add deployment configuration files for new agents" + body: "This PR adds AVCTL deployment configuration files for new agents." + base: "main" + branch: "chore/deploy-production-agents-${{ github.run_number }}" + add-paths: "1-uagents/**.avctl**" + if: steps.check-new-agents.outputs.new == 'true' diff --git a/6-helpers/jupyter-notebook/agent.py b/3-applications/jupyter-notebook/agent.py similarity index 100% rename from 6-helpers/jupyter-notebook/agent.py rename to 3-applications/jupyter-notebook/agent.py diff --git a/6-helpers/jupyter-notebook/agent_in_notebook.ipynb b/3-applications/jupyter-notebook/agent_in_notebook.ipynb similarity index 100% rename from 6-helpers/jupyter-notebook/agent_in_notebook.ipynb rename to 3-applications/jupyter-notebook/agent_in_notebook.ipynb diff --git a/6-helpers/jupyter-notebook/poetry.lock b/3-applications/jupyter-notebook/poetry.lock similarity index 100% rename from 6-helpers/jupyter-notebook/poetry.lock rename to 3-applications/jupyter-notebook/poetry.lock diff --git a/6-helpers/jupyter-notebook/pyproject.toml b/3-applications/jupyter-notebook/pyproject.toml similarity index 100% rename from 6-helpers/jupyter-notebook/pyproject.toml rename to 3-applications/jupyter-notebook/pyproject.toml diff --git a/6-helpers/postgres-database/.dockerignore b/3-applications/postgres-database/.dockerignore similarity index 100% rename from 6-helpers/postgres-database/.dockerignore rename to 3-applications/postgres-database/.dockerignore diff --git a/6-helpers/postgres-database/.env.example b/3-applications/postgres-database/.env.example similarity index 100% rename from 6-helpers/postgres-database/.env.example rename to 3-applications/postgres-database/.env.example diff --git a/6-helpers/postgres-database/Dockerfile b/3-applications/postgres-database/Dockerfile similarity index 100% rename from 6-helpers/postgres-database/Dockerfile rename to 3-applications/postgres-database/Dockerfile diff --git a/6-helpers/postgres-database/README.md b/3-applications/postgres-database/README.md similarity index 100% rename from 6-helpers/postgres-database/README.md rename to 3-applications/postgres-database/README.md diff --git a/6-helpers/postgres-database/docker-compose.yml b/3-applications/postgres-database/docker-compose.yml similarity index 100% rename from 6-helpers/postgres-database/docker-compose.yml rename to 3-applications/postgres-database/docker-compose.yml diff --git a/6-helpers/postgres-database/poetry.lock b/3-applications/postgres-database/poetry.lock similarity index 100% rename from 6-helpers/postgres-database/poetry.lock rename to 3-applications/postgres-database/poetry.lock diff --git a/6-helpers/postgres-database/pyproject.toml b/3-applications/postgres-database/pyproject.toml similarity index 100% rename from 6-helpers/postgres-database/pyproject.toml rename to 3-applications/postgres-database/pyproject.toml diff --git a/6-helpers/postgres-database/src/constants.py b/3-applications/postgres-database/src/constants.py similarity index 100% rename from 6-helpers/postgres-database/src/constants.py rename to 3-applications/postgres-database/src/constants.py diff --git a/6-helpers/postgres-database/src/db/__init__.py b/3-applications/postgres-database/src/db/__init__.py similarity index 100% rename from 6-helpers/postgres-database/src/db/__init__.py rename to 3-applications/postgres-database/src/db/__init__.py diff --git a/6-helpers/postgres-database/src/db/db_connection.py b/3-applications/postgres-database/src/db/db_connection.py similarity index 100% rename from 6-helpers/postgres-database/src/db/db_connection.py rename to 3-applications/postgres-database/src/db/db_connection.py diff --git a/6-helpers/postgres-database/src/db/models/models.py b/3-applications/postgres-database/src/db/models/models.py similarity index 100% rename from 6-helpers/postgres-database/src/db/models/models.py rename to 3-applications/postgres-database/src/db/models/models.py diff --git a/6-helpers/postgres-database/src/db/schemas/employees.sql b/3-applications/postgres-database/src/db/schemas/employees.sql similarity index 100% rename from 6-helpers/postgres-database/src/db/schemas/employees.sql rename to 3-applications/postgres-database/src/db/schemas/employees.sql diff --git a/6-helpers/postgres-database/src/main.py b/3-applications/postgres-database/src/main.py similarity index 100% rename from 6-helpers/postgres-database/src/main.py rename to 3-applications/postgres-database/src/main.py diff --git a/README.md b/README.md index 616c72c..63e181d 100644 --- a/README.md +++ b/README.md @@ -25,4 +25,3 @@ Read our [development guidelines](https://github.com/fetchai/uAgent-Examples/blo ## ❓ Issues, Questions, and Discussions We use [GitHub Issues](https://github.com/fetchai/uAgent-Examples/issues) for tracking requests and bugs, and [GitHub Discussions](https://github.com/fetchai/uAgent-Examples/discussions) for general questions and discussion. -