Open Source Project

Multi-Agent Research System

A production-ready platform that orchestrates Claude, GPT-4, and Perplexity using the A2A (Agent-to-Agent) Protocol to deliver comprehensive, cited research reports in real time.

Python 3.12 FastAPI A2A Protocol SSE Streaming Claude API OpenAI API Perplexity API

System Architecture

Three specialized AI agents coordinated through a central orchestrator via the A2A protocol.

User Query Research UI / API
Orchestrator Task Planning & Routing
P
Perplexity Web Search & Sources
Real-time search Citations
C
Claude Analysis & Synthesis
Deep reasoning Writing
O
OpenAI GPT-4 Validation & QA
Cross-check Multimodal
Final Report PDF / DOCX / Markdown / JSON
1

Planning

Orchestrator parses the query, identifies sub-topics, and creates a research plan

2

Discovery

Perplexity searches the web for relevant sources and citations

3

Analysis

Claude performs deep analysis and synthesizes findings into structured output

4

Validation

OpenAI cross-validates claims, checks for inconsistencies, and verifies accuracy

5

Synthesis

Final report assembled with citations, confidence scores, and follow-up questions

Key Features

A2A Protocol

JSON-RPC 2.0 based agent-to-agent communication with discoverable agent cards and typed skill schemas.

Real-Time Streaming

Server-Sent Events deliver live progress updates as agents collaborate. Watch the research unfold in real time.

Provider Fallbacks

Configurable priority chains with automatic failover. Local Ollama integration for offline operation.

Multi-Format Export

Download research as PDF, DOCX, Markdown, HTML, or JSON. Server-side rendering with fpdf2 and python-docx.

Admin Panel

Web-based admin interface to configure agents, set provider priorities, and manage the system.

REST + JSON-RPC API

Full REST API for programmatic access plus standards-compliant A2A JSON-RPC endpoint for agent interop.

Interactive Demo

See the multi-agent workflow in action. This is a simulated demo — no API keys required.

Try:
P
Perplexity Web Search
C
Claude Analysis
O
OpenAI Validation

Research in Progress

0%

Initializing agents...

Agent Communication

Research Results

Simulated

Code Showcase

Key implementation details from the codebase.

src/a2a/protocol.py
class TaskStatus(str, Enum):
    """Task execution status states."""
    PENDING     = "pending"
    IN_PROGRESS = "in_progress"
    COMPLETED   = "completed"
    FAILED      = "failed"
    CANCELLED   = "cancelled"
    WAITING     = "waiting"


class AgentSkill(BaseModel):
    """Definition of a capability that an agent can perform."""
    id: str           = Field(..., description="Unique skill identifier")
    name: str         = Field(..., description="Human-readable name")
    description: str  = Field(..., description="What this skill does")
    input_schema: Optional[dict]  = Field(None, alias="inputSchema")
    output_schema: Optional[dict] = Field(None, alias="outputSchema")
    tags: list[str]   = Field(default_factory=list)


class AgentCard(BaseModel):
    """Discoverable manifest describing an agent's identity and skills."""
    name: str
    description: str
    url: Optional[HttpUrl]   = None
    version: str              = "1.0.0"
    skills: list[AgentSkill] = Field(default_factory=list)
    capabilities: AgentCapabilities = Field(default_factory=AgentCapabilities)

API Reference

Endpoint Method Description
/researchPOSTExecute a multi-agent research workflow
/a2aPOSTA2A Protocol JSON-RPC endpoint
/agentsGETList all registered agents
/agents/{id}/cardGETGet agent card (A2A discovery)
/export/pdfPOSTDownload report as PDF
/export/docxPOSTDownload report as DOCX
/healthGETSystem health check
/api/infoGETSystem information

Technical Stack

Backend

  • Python 3.12 + asyncio
  • FastAPI + Pydantic
  • SSE via sse-starlette
  • Uvicorn ASGI server

AI Providers

  • Anthropic Claude (Analysis)
  • OpenAI GPT-4 (Validation)
  • Perplexity (Web Search)
  • Ollama (Local Fallback)

Protocol

  • A2A Agent-to-Agent
  • JSON-RPC 2.0
  • Agent Cards (Discovery)
  • Typed Skill Schemas

Frontend & Export

  • Vanilla JS, CSS3
  • marked.js (Markdown)
  • fpdf2 (PDF generation)
  • python-docx (DOCX)
Success!