Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ‰ Dragonite β€” Autonomous Multi-Agent System

A graph-based autonomous AI agent system that plans, executes, evaluates, repairs, and synthesizes complex tasks.

Python Google ADK FastAPI License


⚑ 30-Second Overview

Dragonite is not a single LLM call.

It separates an autonomous workflow into explicit engineering components:

User Request
     β”‚
     β–Ό
  Planner
     β”‚
     β–Ό
  Task DAG
     β”‚
     β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
     β–Ό              β–Ό
 Task A           Task B
     β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜
            β–Ό
        Executor
            β”‚
            β–Ό
          Critic
            β”‚
       β”Œβ”€β”€β”€β”€β”΄β”€β”€β”€β”€β”
       β”‚         β”‚
     Good      Failed
       β”‚         β”‚
       β”‚      Replanner
       β”‚         β”‚
       β””β”€β”€β”€β”€β—„β”€β”€β”€β”€β”˜
            β”‚
            β–Ό
       Synthesizer
            β”‚
            β–Ό
       Final Answer

🧠 What I built

  • πŸ—ΊοΈ LLM-powered task planning
  • πŸ•ΈοΈ Dependency-aware DAG execution
  • ⚑ Parallel execution of independent tasks
  • πŸ”§ Tool execution layer
  • πŸ”„ Retry handling
  • πŸ” Critic / quality-control stage
  • ♻️ Replanning and repair flow
  • 🧩 Shared LLM client architecture
  • πŸ’Ύ Memory layer
  • πŸ“Š Execution progress tracking
  • πŸ”­ Logging and tracing
  • πŸ”Œ Google ADK integration

πŸŽ₯ Live Terminal Demo

The repository contains an actual terminal recording of the working system.

⚑ Instant preview

Dragonite Demo

request β†’ planning β†’ task execution β†’ orchestration β†’ evaluation β†’ final output


πŸ—οΈ Architecture

Dragonite uses a modular orchestration architecture:

                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚ User Request β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚    Memory    β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚   Planner    β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚   Task DAG   β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚   Executor   β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚    Critic    β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β”‚
                 β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                 β–Ό                     β–Ό
              Accepted              Failed
                 β”‚                     β”‚
                 β”‚               β”Œβ”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”
                 β”‚               β”‚ Replanner β”‚
                 β”‚               β””β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”˜
                 β”‚                     β”‚
                 β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β—„β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                            β”‚
                            β–Ό
                    β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
                    β”‚ Synthesizer  β”‚
                    β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
                            β–Ό
                       Final Answer

Key design decision

The system intentionally separates:

planning β‰  execution β‰  evaluation β‰  recovery β‰  presentation

This makes the workflow easier to reason about, extend, debug, and test than putting the entire process into one large agent prompt.

πŸ“ Detailed design: architecture.md


πŸ”₯ Engineering Highlights

1. Dependency-aware execution

Tasks are represented as nodes with dependencies.

For example:

research_A ──────┐
                 β”œβ”€β”€β–Ί compare ──► evaluate ──► recommend
research_B β”€β”€β”€β”€β”€β”€β”˜

Independent tasks can execute concurrently while dependent tasks wait for their prerequisites.


2. Parallel execution

The executor uses Python concurrency to execute ready independent tasks in parallel.

This provides a foundation for scaling workflows beyond strictly sequential execution.


3. Retry handling

Task failures do not necessarily terminate the entire workflow.

The executor supports configurable retry attempts with backoff.

Attempt 1
   β”‚
 Failure
   β–Ό
Attempt 2
   β”‚
 Failure
   β–Ό
Attempt 3
   β”‚
 Success / Final Failure

4. Critic β†’ Repair loop

Dragonite does not blindly trust the first generated result.

The critic can identify quality problems and feed repair information into the replanning process.

Execute
  β”‚
  β–Ό
Critic
  β”‚
  β”œβ”€β”€ Good ──────────────► Continue
  β”‚
  └── Problem ─► Replan ─► Repair ─► Execute

5. Shared LLM infrastructure

Planner, executor, and synthesizer can use a shared configured LLM client.

                 Shared LLM Client
                       β”‚
          β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
          β–Ό            β–Ό            β–Ό
       Planner      Executor    Synthesizer

This avoids unnecessary model-client duplication and keeps model configuration centralized.


πŸ› οΈ Tech Stack

Technology Purpose
Python 3.11+ Core implementation
Google ADK Agent/application ecosystem
LLM providers Model execution
FastAPI API/application infrastructure
Pydantic Validation and configuration
ThreadPoolExecutor Parallel execution
OpenTelemetry Observability
python-dotenv Environment configuration

All pinned dependencies are documented in requirements.txt.


πŸš€ Run Locally

1. Clone

git clone https://github.com/kcsanjayj/Dragonite.git
cd Dragonite

2. Create environment

Windows

python -m venv .venv
.venv\Scripts\Activate.ps1

Linux / macOS

python3 -m venv .venv
source .venv/bin/activate

3. Install dependencies

pip install -r requirements.txt

4. Configure environment

Copy:

.env_example

to:

.env

Then configure your required model/provider credentials.

5. Start Dragonite

python run_agent.py

Alternative:

python -m multi_tool_agent.cli

πŸ” Security

Secrets are intentionally excluded from Git.

Use:

.env

for local credentials.

Use:

.env_example

to document required variables.

Never commit API keys, tokens, passwords, or private credentials.


🎯 Honest Project Scope

Dragonite is a hands-on autonomous-agent engineering project, not a claim of AGI or a production-ready platform.

The project demonstrates practical understanding of:

  • multi-agent orchestration
  • DAG-based workflows
  • dependency management
  • concurrent execution
  • LLM integration
  • tool execution
  • retries and failure handling
  • quality control
  • replanning
  • memory
  • observability

There are still important areas to improve before production deployment, including:

  • broader automated tests
  • stronger sandboxing
  • persistent production-grade state
  • systematic evaluation benchmarks
  • security hardening
  • CI/CD
  • production monitoring
  • stronger failure isolation

Those limitations are intentionally documented rather than hidden.

πŸ’‘ The goal of Dragonite is not to claim that the system is perfect. The goal is to demonstrate that I can design, implement, debug, and explain a non-trivial AI-agent architecture.


πŸ“š Documentation


⭐ Why this project matters

Dragonite was built to explore what happens when an LLM application is treated as a software system rather than just a prompt.

The focus is on:

architecture β†’ execution β†’ failure handling β†’ evaluation β†’ recovery β†’ observability

rather than simply generating a response from one model call.


πŸ“œ License

MIT License.

See LICENSE.


Built by Sanjay as a hands-on exploration of autonomous AI-agent systems and Python engineering.

⭐ If you find Dragonite interesting, consider starring the repository.

About

A graph-based AI Multi agent system

Resources

Stars

5 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages