A2A-Demo: Cross-Departmental AI Agent Integration
July 22, 2025 Β· View on GitHub
A demonstration project showcasing the integration between AG-UI and A2A protocols, enabling seamless communication between AI agents across different departments and systems.
π― Overview
This demo features an HR Agent as the primary interface that can intelligently delegate tasks to specialized departmental agents:
- π° Finance Agent - Handles budgets, expenses, payroll, and financial queries
- π» IT Agent - Manages technical requests, system access, and IT support
- π’ Buildings Management Agent - Oversees facilities, maintenance, and office resources
The HR agent acts as a central coordinator, automatically routing complex requests to the appropriate specialists and orchestrating multi-departmental workflows.
π¬ Demo
π Try the Live Demo

See the A2A protocol in action as agents seamlessly communicate across departments
π Protocol Integration
AG-UI Protocol
Provides the user interface and conversation management, enabling natural language interactions with the agent system.
A2A (Agent-to-Agent) Protocol
Enables secure, structured communication between different AI agents, allowing them to:
- Share context and information
- Delegate specialized tasks
- Coordinate complex, cross-departmental workflows
- Maintain conversation continuity across agent handoffs
π Key Features
- π€ Cross-Departmental Coordination: HR agent seamlessly communicates with specialized agents
- π Intelligent Task Routing: Automatically determines which agent(s) can best handle specific requests
- π Context Preservation: Maintains conversation context across agent interactions
- β‘ Real-time Communication: Live streaming of agent responses and tool calls
- ποΈ Multi-Agent Orchestration: Handles complex workflows requiring multiple departments
π οΈ Example Use Cases
Employee Onboarding
User: "Set up a new employee John Doe starting Monday"
HR Agent β IT Agent: "Create user account and email for John Doe"
HR Agent β Buildings: "Assign desk and access card for new hire"
HR Agent β Finance: "Add John Doe to payroll system"
Budget Request with IT Requirements
User: "I need approval for a \$5000 software license and server setup"
HR Agent β Finance: "Review budget availability for \$5000 expense"
HR Agent β IT: "Assess technical requirements for software deployment"
Facility Issue with Security Implications
User: "The keycard reader is broken in the secure server room"
HR Agent β Buildings: "Schedule repair for keycard reader"
HR Agent β IT: "Implement temporary security measures for server room"
ποΈ Architecture
βββββββββββββββββββ βββββββββββββββββββ
β Web Frontend β β AG-UI Client β
β (Next.js) βββββΊβ Integration β
βββββββββββββββββββ βββββββββββββββββββ
β β
βΌ βΌ
βββββββββββββββββββββββββββββββββββββββββββ
β HR Agent β
β (Central Coordinator) β
βββββββββββββββββββββββββββββββββββββββββββ
β β β
βΌ βΌ βΌ
βββββββββββ βββββββββββ βββββββββββ
βFinance β β IT β βBuildingsβ
β Agent β β Agent β β Agent β
βββββββββββ βββββββββββ βββββββββββ
π¦ Getting Started
Prerequisites
- Node.js 18+ and pnpm
- Python 3.12+
- OpenAI API Key
1. Start the Web Application
# Install dependencies
pnpm install
# Set your OpenAI API key
export OPENAI_API_KEY=your_openai_api_key_here
# Start the development server
pnpm dev
The application will be available at http://localhost:3000
2. Setup and Run the Agents
# Navigate to agents directory
cd agents
# Create virtual environment (one-time setup)
uv venv .venv --python 3.12
source .venv/bin/activate
# Install dependencies (one-time setup)
uv pip install -r pyproject.toml --all-extras
# Set your OpenAI API key
export OPENAI_API_KEY=your_openai_api_key_here
# Start all agents
./run_agents.sh
This will start all three departmental agents simultaneously:
- Finance Agent on
http://localhost:8001 - IT Agent on
http://localhost:8002 - Buildings Management Agent on
http://localhost:8003
Press Ctrl+C to stop all agents.
3. Try It Out
- Open the web application at
http://localhost:3000 - Start a conversation with the HR agent
- Try cross-departmental requests like:
- "Help me onboard a new employee"
- "I need to request a budget for new office equipment"
- "Set up IT access for our new intern"
π§ͺ Development
Adding New Agents
- Create a new agent in the
agents/directory - Update
run_agents.shto include the new agent - Configure the agent URL in the frontend integration
Customizing Agent Capabilities
Each agent's capabilities are defined in their respective Python files in the agents/ directory. You can modify or extend their tool definitions to add new functionality.
π Learn More
π€ Contributing
This is a demonstration project showcasing protocol integration. Feel free to explore the code and adapt it for your own agent communication needs.
π License
MIT License - See LICENSE file for details.