Skip to content

bonk1t/oauth-testing-agency

Repository files navigation

Agency Swarm GitHub Template

A production-ready template for deploying Agency Swarm agencies with Docker containerization and automated deployment to the Agencii cloud platform.

🌐 Agencii - The official cloud platform for Agency Swarm deployments
πŸ”— GitHub App - Automated deployment integration


πŸš€ Quick Start

1. Use This Template

Click "Use this template" to create your own repository, or:

git clone https://github.com/your-username/agency-github-template.git
cd agency-github-template

🌐 For Production: Sign up at agencii.ai and use this template for automated cloud deployment

2. Install Dependencies

pip install -r requirements.txt

3. Set Up Environment Variables

Create a .env file in the root directory:

# Required
OPENAI_API_KEY=your_openai_api_key_here

# Optional - Add any additional API keys your agents need
# EXAMPLE_API_KEY=your_api_key_here

4. Test the Example Agency

python agency.py

This runs the example agency in terminal mode for testing.

πŸ’‘ Pro Tip: For creating your own agency, open this template in Cursor IDE and use the AI assistant with the .cursor/rules/workflow.mdc file for automated agency creation!


πŸ—οΈ Project Structure

agency-github-template/
β”œβ”€β”€ agency.py                 # Main entry point
β”œβ”€β”€ requirements.txt          # Python dependencies
β”œβ”€β”€ Dockerfile               # Container configuration
β”œβ”€β”€ .env                     # Environment variables (create this)
β”œβ”€β”€ example_agent/           # Your agency folder
    β”œβ”€β”€ __init__.py
    β”œβ”€β”€ example_agent.py
    β”œβ”€β”€ instructions.md
    β”œβ”€β”€ files/               # Local files accessible to the agent (via files_folder)
    └── tools/
        └── ExampleTool.py
β”œβ”€β”€ example_agent2/
β”œβ”€β”€ agency_manifesto.md  # Shared instructions
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ .env
└──...

πŸ”§ Creating Your Own Agency

πŸ€– AI-Assisted Agency Creation with Cursor

This template includes AI-powered agency creation using Cursor IDE:

  1. Open this project in Cursor IDE

  2. Use the AI Assistant to create your agency by referencing:

    πŸ“ .cursor/rules/workflow.mdc
    
  3. Simply ask the AI:

    "Create a new agency using the .cursor workflow"

    The AI will guide you through the complete 7-step process:

    • βœ… PRD Creation
    • βœ… Folder Structure Setup
    • βœ… Tool Development
    • βœ… Agent Creation
    • βœ… Agency Configuration
    • βœ… Testing & Validation
    • βœ… Iteration & Refinement

πŸ“‹ What the AI Will Do For You

The AI assistant will automatically:

  • Create proper folder structures
  • Generate agent classes and instructions
  • Build custom tools with full functionality
  • Set up communication flows
  • Create the main agency file
  • Test everything to ensure it works

πŸš€ Manual Alternative (Advanced Users)

If you prefer manual setup, replace the ExampleAgency/ folder with your own agency structure following the Agency Swarm conventions.

Agency Structure Requirements

Your agency must follow this structure:

  • Agency Folder: Contains all agents and manifesto
  • Agent Folders: Each agent has its own folder with:
    • AgentName.py - Agent class definition
    • instructions.md - Agent-specific instructions
    • tools/ - Folder containing agent tools
  • agency_manifesto.md - Shared instructions for all agents

πŸš€ Production Deployment with Agencii

🌐 Deploy to Agencii Cloud Platform

For production deployment, use the Agencii platform:

Step 1: Create Account & Use Template

  1. Sign up at agencii.ai
  2. Use this template to create your repository
  3. Develop your agency using Cursor IDE with .cursor workflow

Step 2: Install GitHub App

  1. Install the Agencii GitHub App
  2. Grant permissions to your repository
  3. Configure environment variables in Agencii dashboard

Step 3: Deploy

  1. Push to main branch - Agencii automatically detects and deploys
  2. Monitor deployment in your Agencii dashboard
  3. Access your live agency via provided endpoints

πŸ”„ Automatic Deployments

  • Auto-deploy on every push to main branch
  • Zero-downtime deployments with rollback capability
  • Environment management through Agencii dashboard

πŸ”¨ Development Workflow

🎯 Recommended: AI-Assisted Development

  1. Open Cursor IDE with this template
  2. Ask the AI: "Create a new agency using the .cursor workflow"
  3. Follow the guided process - the AI handles everything automatically
  4. Test your agency: python agency.py
  5. Deploy to production: Install Agencii GitHub App and push to main

βš™οΈ Manual Development (Advanced)

If you prefer hands-on development:

  1. Create Tools: Build agent tools in tools/ folders
  2. Configure Agents: Write instructions.md and agent classes
  3. Test Locally: Run python agency.py
  4. Deploy: Push to your preferred platform

The .cursor/rules/workflow.mdc file contains the complete development specifications for manual implementation.


πŸ“š Key Features

  • 🌐 Agencii Cloud Deploy: One-click deployment to Agencii platform
  • πŸ€– AI-Assisted Creation: Built-in Cursor IDE workflow for automated agency development
  • πŸ”„ Auto-Deploy: Automatic deployment on push to main branch
  • πŸš€ Ready-to-Deploy: Dockerfile and requirements included
  • πŸ”§ Modular Structure: Easy to customize and extend
  • πŸ› οΈ Example Implementation: Complete working example
  • πŸ“¦ Container Ready: Docker configuration for any platform
  • πŸ”’ Environment Management: Secure API key handling via Agencii dashboard
  • πŸ§ͺ Local Testing: Terminal demo for development
  • πŸ“‹ Guided Workflow: 7-step process with AI assistance

πŸ“– Learn More


🀝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Submit a pull request

⚑ Quick Tips

  • Start Small: Begin with 1-2 agents and expand
  • Test Tools: Each tool should work independently
  • Clear Instructions: Write detailed agent instructions
  • Environment Setup: Always use .env for API keys
  • Documentation: Update instructions as you develop

Ready to build your AI agency? πŸ€–βœ¨

🌐 Production Route (Recommended)

  1. Sign up at agencii.ai
  2. Use this template to create your repository
  3. Install Agencii GitHub App
  4. Push to main β†’ Automatic deployment!

πŸ› οΈ Development Route

Open this template in Cursor IDE and ask the AI to create your agency using the .cursor workflow. The AI will handle everything from setup to testing automatically!

For manual development, replace the ExampleAgency with your own implementation and start deploying intelligent agent systems!

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published