Skip to content

DEUS-AI/multi-agent-systems-examples

Repository files navigation

Multi-Agent Systems Examples 🤖✨

Hands-on notebooks to learn the main LangGraph agent patterns, with support for:

  • 🔑 OpenAI API (OPENAI_API_KEY)
  • ☁️ Azure OpenAI (AZURE_OPENAI_*)

🚀 Quick Start

1) Create a virtual environment (recommended)

python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip

2) Install dependencies

pip install -r requirements.txt

3) Configure environment variables

Copy the template:

cp .env.example .env

Option A: OpenAI (default and easiest)

LLM_PROVIDER=openai
OPENAI_API_KEY=sk-your-openai-api-key-here
OPENAI_MODEL=gpt-4o

Option B: Azure OpenAI

LLM_PROVIDER=azure
AZURE_OPENAI_ENDPOINT=https://your-resource-name.openai.azure.com/
AZURE_OPENAI_DEPLOYMENT=gpt-4o
AZURE_OPENAI_API_VERSION=2024-12-01-preview
AZURE_OPENAI_API_KEY=your-azure-openai-api-key

✅ Notes:

  • LLM_PROVIDER=openai keeps the standard OpenAI flow.
  • LLM_PROVIDER=azure switches notebooks to Azure deployment-based calls.
  • In Azure mode, notebooks use AZURE_OPENAI_API_KEY or fallback to OPENAI_API_KEY.

4) Run notebooks

jupyter lab

Then open and run:

  • 01-chain.ipynb
  • 02-re-act.ipynb
  • 03-router.ipynb
  • 04-supervisor.ipynb
  • 05-plan-and-execute.ipynb

📚 Notebook Roadmap

  • 01-chain.ipynb → Linear chain pattern with messages, one LLM call, and tool binding.
  • 02-re-act.ipynb → ReAct loop (reason -> act -> observe) with iterative tool use.
  • 03-router.ipynb → Routing pattern: direct answer vs tool execution.
  • 04-supervisor.ipynb → Multi-agent supervisor that delegates to specialist agents.
  • 05-plan-and-execute.ipynb → Planner + executor workflow with replanning until completion.

🎞️ Presentation

🌟 Explore the full presentation

👉 Open the slides on Google Drive


👥 Authors

  • Pablo Posada (Deus)
  • Bruno Cabado (Deus)

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors