Skip to content
lingyuanliPublic

About

Multi-agent end-to-end application - General-purpose artificial intelligence agent for multimodal agent collaboration

Topics

Resources

Stars

402 stars

Watchers

0 watching

Forks

Latest commit

ย 

History

69 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐Ÿš€ MultiGen

A General-Purpose AI Agent System for Fully Private Deployment

Planner + ReAct multi-agent architecture ยท A2A & MCP native ยท Sandboxed execution ยท One-command deploy

License: MIT Python 3.11+ Next.js FastAPI Docker PRs Welcome

English ยท ็ฎ€ไฝ“ไธญๆ–‡

MultiGen Home Page


โœจ What is MultiGen?

MultiGen is an open-source, general-purpose AI Agent platform designed for fully private, on-premise deployment. It pairs a Planner agent (decomposes user goals into steps) with a ReAct agent (executes each step using tools), and runs every action inside an isolated Docker sandbox โ€” so your data never leaves your infrastructure.

Out of the box, MultiGen can browse the web, run shell commands, generate images / videos / 3D models / TTS audio, build slide decks and reports, and orchestrate other agents via A2A and external tools via MCP.

๐Ÿ’ก Think of it as your private, self-hosted alternative to Manus / Claude Agent / GPT Agent โ€” but you own the data, the model, and the stack.


๐Ÿšจ Pick the Right Branch for Your Deployment

MultiGen ships two long-lived branches โ€” pick the one that matches your scenario:

Scenario Branch Use it for
๐Ÿ–ฅ๏ธ Local Docker deployment master Local one-command Docker stack, evaluation, development, contributing
๐ŸŒ Online / production deployment online Public / production environments โ€” battle-tested, with hotfixes & deployment configs verified online

Local Docker (this branch โ€” master):

# ๐Ÿ–ฅ๏ธ Local Docker deployment โ€” use master
git clone https://github.com/LiXiaoYaoCareFree/MultiGen.git
cd MultiGen
docker compose up -d --build

Online / production:

# ๐ŸŒ Online / production deployment โ€” use online
git clone -b online https://github.com/LiXiaoYaoCareFree/MultiGen.git
cd MultiGen
docker compose up -d --build

โš ๏ธ Never deploy master to a public / production environment โ€” only online is verified for that. Keep production in sync by pulling from online only.


๐ŸŽฏ Key Features

๐Ÿง  Planner + ReAct architecture A two-stage agent: the Planner breaks down the goal into JSON sub-steps, the ReAct agent iteratively reasons & acts on each step.
๐Ÿ”Œ MCP & A2A native Plug in any MCP server (search, maps, code, custom tools) and delegate sub-tasks to peer agents via Agent-to-Agent protocol.
๐Ÿ›ก๏ธ Sandboxed execution Every shell / browser / file action runs inside an isolated Ubuntu + Chrome + VNC container. The model can't touch your host.
๐ŸŽจ Multimodal generation Built-in tools for image (Volcengine / SD), video, 3D models, TTS (Qwen / podcasts), virtual anchors, audio mixing, slide decks.
๐ŸŒ Any OpenAI-compatible LLM Works with DeepSeek, Volcengine, SiliconFlow, Qwen, OpenAI, vLLM, Ollama, etc. โ€” just edit config.yaml.
๐Ÿšข One-command deploy docker compose up -d --build brings up the full stack: UI, API, sandbox, Postgres, Redis, Nginx.
๐Ÿ“ก Real-time streaming UI SSE-driven Next.js frontend renders plans, tool calls, intermediate results, and final answers live.
๐Ÿ” Replayable sessions Full session state in PostgreSQL; generated files mirrored locally and to Tencent COS for replay & sharing.

๐Ÿ“ธ Showcase

๐Ÿ”ฌ End-to-End Research Workflow โ€” Plan ยท Execute ยท Watch

MultiGen research workflow โ€” session history, live plan execution, and sandbox preview
One screen, three layers of MultiGen at work: persistent session history, a live Planner+ReAct execution stream, and the agent's sandbox computer rendering the paper in real time.

The screenshot above captures MultiGen tackling a real task โ€” "Analyze the AI-Researcher: Autonomous Scientific Innovation paper at alphaxiv.org/abs/2505.18705" โ€” and showcases three of the platform's most distinctive capabilities in a single view:

๐Ÿ—‚๏ธ ย 1. Persistent multi-session workspace (left sidebar)

Every conversation is a fully replayable session, stored in PostgreSQL and synced to Tencent COS. The sidebar in the screenshot shows the breadth of tasks MultiGen handles out of the box:

Visible session Tools exercised
๐Ÿ“Š Baidu tech-ops weekly charts browser ยท file ยท shell
๐Ÿ’ป GitHub Java project discovery search ยท browser
๐Ÿงฎ SQLite + FAISS data vectorization shell ยท file
๐Ÿ“š PDF batch download & merge from GitHub browser ยท file ยท shell
๐Ÿฏ Late-autumn Hangzhou Faming Temple image search search ยท image_generation
๐Ÿ“„ AI-Researcher paper reading (active) browser ยท file ยท mcp
๐ŸŽ™๏ธ Article voice-over + song audio mixing qwen_tts ยท audio_mixing
๐ŸงŠ 3D pet model retrieval & rendering model_3d ยท browser
๐Ÿงช autoresearcher / AI-Scientist / sibyl-research-system paper deep-dives browser ยท file ยท a2a
๐ŸŽฌ Automated cute-video generation pipeline volcano_image ยท volcano_video ยท video_concatenation ยท virtual_anchor

Sessions persist across restarts and can be reopened, branched, or replayed step-by-step โ€” powered by SQLAlchemy async + Alembic migrations.

๐Ÿง  ย 2. Live Planner+ReAct execution stream (center)

The center column streams the agent's reasoning in real time over SSE. For this task you can see the two-stage architecture cleanly:

  1. PlannerAgent parses the user goal and emits a JSON plan โ€” fetch URL โ†’ browse page โ†’ download PDF โ†’ extract content โ†’ summarize.
  2. ReActAgent picks up each step and iteratively reasons โ†’ calls a tool โ†’ observes the result โ†’ continues:
    • โœ… ่ฎฟ้—ฎ่ฎบๆ–‡้“พๆŽฅ โ€” browser.goto(https://www.alphaxiv.org/abs/2505.18705)
    • โœ… ๆญฃๅœจๆ‰“ๅผ€็ฝ‘้กต โ€” browser.snapshot() returning the page DOM
    • โœ… ๆญฃๅœจๆต่งˆ็ฝ‘้กต โ€” extracting title, abstract, sections
    • โœ… ๆญฃๅœจไธ‹่ฝฝๆ–‡ไปถ โ€” browser.download() of the PDF
    • โœ… ๆญฃๅœจๆ‰“ๅผ€ๆ–‡ไปถ โ€” file.read(.../2505.18705.pdf) to ingest content
    • ๐Ÿ”„ ...continues until the ReAct loop summarizes the paper

Every green check is a discriminated event (plan ยท step ยท tool ยท message ยท done) flowing through /api/sessions/{id}/chat โ€” defined in api/app/domain/models/event.py and produced by PlannerReActFlow in api/app/domain/services/flows/planner_react.py.

๐Ÿ–ฅ๏ธ ย 3. The Agent's Computer โ€” live sandbox preview (right pane: "limpps ็š„็”ต่„‘")

The right pane is not a static screenshot โ€” it's a live window into the agent's isolated Docker sandbox. As the ReAct loop drives the headless Chrome inside the sandbox (Ubuntu + Chrome + VNC, port 8080), you see exactly what the agent sees:

  • ๐ŸŒ The alphaxiv.org paper rendered inside the sandbox browser
  • ๐Ÿ“‘ The PDF preview with "Highlight of Key Insights" section in view
  • ๐Ÿ” Scroll / click / extract events mirrored frame-by-frame

This is full "computer use" transparency โ€” your model can browse, click, type, and download, but it's all firewalled inside a disposable container. Your host machine is never touched, and every action is observable and auditable.

๐Ÿ›ก๏ธ Why this matters for private deployment: the model never gets a shell on your infrastructure. Every shell, browser, and file tool call is proxied to the sandbox container, which can be destroyed and rebuilt at will.


๐ŸŒ Web Search & Knowledge Retrieval

Web search workflow
Agent plans the search, calls the right tool, and synthesizes a sourced answer.

Image search
Image search and ranking, with live previews streamed back to the UI.

โš™๏ธ Settings & Configuration

LLM provider settings
LLM provider โ€” connect any OpenAI-compatible endpoint
Agent settings
Agent behavior โ€” iterations, retries, search depth
MCP server settings
MCP servers โ€” plug in external tools live
A2A settings
A2A agents โ€” federate with peer agents

๐Ÿ–ผ๏ธ Multimodal Generation

Generation workflow
End-to-end creative workflow โ€” from prompt, to plan, to rendered assets.


Generated portrait #1

Generated portrait #2

Generated portrait #3

๐ŸŽ™๏ธ Podcasts & TTS

TTS Podcast generation
Generate full multi-speaker podcasts with Qwen-TTS, automatically mixed with background music.


๐Ÿ—๏ธ Architecture

              โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚              Next.js UI  (3000)             โ”‚
              โ”‚   Plans ยท Steps ยท Tool calls ยท SSE stream   โ”‚
              โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                                   โ”‚  /api  (SSE)
                                   โ–ผ
              โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚              FastAPI  (8000)                โ”‚
              โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚
              โ”‚  โ”‚ AgentService โ”‚ โ†’  โ”‚ AgentTaskRunner   โ”‚  โ”‚
              โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚
              โ”‚                               โ–ผ              โ”‚
              โ”‚              โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚
              โ”‚              โ”‚   PlannerReAct Flow        โ”‚  โ”‚
              โ”‚              โ”‚  Planner โ”€โ–บ ReAct (loop)   โ”‚  โ”‚
              โ”‚              โ””โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚
              โ”‚                    โ”‚ tools                   โ”‚
              โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚
              โ”‚  โ”‚ file ยท shell ยท browser ยท search ยท MCP  โ”‚  โ”‚
              โ”‚  โ”‚ image ยท video ยท 3D ยท TTS ยท A2A ยท ...   โ”‚  โ”‚
              โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚
              โ””โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”˜
                    โ–ผ             โ–ผ                   โ–ผ
              โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚PostgreSQLโ”‚  โ”‚  Redis   โ”‚     โ”‚  Docker Sandbox  โ”‚
              โ”‚ sessions โ”‚  โ”‚ streams  โ”‚     โ”‚  Ubuntu + Chrome โ”‚
              โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”‚     + VNC (8080) โ”‚
                                             โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Agent execution flow:

  1. AgentService receives a chat message โ†’ dispatches it to an AgentTaskRunner via Redis Streams.
  2. AgentTaskRunner runs PlannerReActFlow:
    • PlannerAgent โ€” decomposes the request into a JSON plan of sub-steps.
    • ReActAgent โ€” for each step, iteratively reasons โ†’ calls a tool โ†’ observes โ†’ continues, then summarizes.
  3. Events stream back via SSE (plan ยท title ยท step ยท message ยท tool ยท wait ยท error ยท done).

๐Ÿš€ Quick Start

Prerequisites

  • ๐Ÿณ Docker >= 20.10
  • ๐Ÿ™ Docker Compose >= 2.0
  • ๐Ÿ”‘ An API key for any OpenAI-compatible LLM (DeepSeek / Volcengine / OpenAI / vLLM / Ollamaโ€ฆ)

1. Clone

๐Ÿ’ก Pick the right branch for your deployment scenario:

  • ๐Ÿ–ฅ๏ธ Local Docker deployment โ†’ use master (this branch)
  • ๐ŸŒ Online / production deployment โ†’ use online
# ๐Ÿ–ฅ๏ธ Local Docker deployment โ€” use master (default branch)
git clone https://github.com/LiXiaoYaoCareFree/MultiGen.git
cd MultiGen

# ๐ŸŒ Online / production deployment โ€” use online instead
# git clone -b online https://github.com/LiXiaoYaoCareFree/MultiGen.git
# cd MultiGen

2. Configure environment

Create a .env file in the project root:

# โ”€โ”€ Required โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
COS_SECRET_ID=your_cos_secret_id_here       # Tencent COS SecretId
COS_SECRET_KEY=your_cos_secret_key_here     # Tencent COS SecretKey
COS_BUCKET=your_cos_bucket_here             # COS bucket name
OPENAI_API_KEY=your_llm_api_key_here        # LLM API key

# โ”€โ”€ Optional โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€
NGINX_PORT=8088                             # public port
ADMIN_API_KEY=your_admin_api_key_here       # admin auth key
LLM_PROVIDER=volcano                        # deepseek / openai / volcano
TENCENT_AI3D_API_KEY=...                    # for 3D model generation
DASHSCOPE_API_KEY=...                       # for Qwen-TTS

3. Configure the LLM

Edit api/config.yaml:

llm_config:
  base_url: https://api.deepseek.com/
  api_key: YOUR_DEEPSEEK_API_KEY
  model_name: deepseek-reasoner
  temperature: 0.7
  max_tokens: 8192

agent_config:
  max_iterations: 100
  max_retries: 3
  max_search_results: 10

mcp_config:
  mcpServers:
    amap-maps-streamableHTTP:
      transport: streamable_http
      enabled: true
      url: https://mcp.amap.com/mcp?key=YOUR_AMAP_API_KEY
    jina-mcp-server:
      transport: streamable_http
      enabled: true
      url: https://mcp.jina.ai/v1
      headers:
        Authorization: Bearer YOUR_JINA_API_KEY

4. Launch

docker compose up -d --build

5. Open

Visit http://localhost:8088 (or whichever NGINX_PORT you set). The API health probe lives at /api/status.


๐Ÿงฉ Built-in Tools

Tool Purpose
file Read / write / patch files inside the sandbox
shell Run shell commands in the sandbox
browser Headless Chrome โ€” navigate, click, extract, screenshot
search Web search (Bing / Google / Jina)
message Ask the user a clarifying question mid-task
image_generation ยท volcano_image Text-to-image generation
volcano_video ยท video_concatenation Text-to-video & post-processing
model_3d Text/image-to-3D via Tencent AI3D
virtual_anchor Avatar / digital-human video
qwen_tts ยท audio_mixing TTS + multi-track audio mixing
mcp Call any registered MCP server
a2a Delegate a sub-task to a peer agent

๐Ÿ“š To add your own tool, see CLAUDE.md โ†’ Adding a New Tool.


๐Ÿ“ฆ Project Layout

MultiGen/
โ”œโ”€โ”€ api/              # Backend API service (FastAPI)
โ”‚   โ”œโ”€โ”€ app/          # Domain / application / infrastructure layers
โ”‚   โ”œโ”€โ”€ tests/        # Pytest suite
โ”‚   โ””โ”€โ”€ config.yaml   # Runtime LLM / MCP / A2A config
โ”œโ”€โ”€ ui/               # Frontend (Next.js 14, App Router)
โ”œโ”€โ”€ sandbox/          # Sandbox runtime (Ubuntu + Chrome + VNC)
โ”œโ”€โ”€ nginx/            # Reverse-proxy gateway
โ”‚   โ”œโ”€โ”€ nginx.conf
โ”‚   โ””โ”€โ”€ conf.d/default.conf
โ”œโ”€โ”€ assets/           # Screenshots used in this README
โ”œโ”€โ”€ docker-compose.yml
โ”œโ”€โ”€ .env              # Environment variables (create your own)
โ””โ”€โ”€ README.md

๐Ÿณ Container Reference

Container Service Description
manus-nginx Nginx Reverse-proxy gateway, the only exposed entrypoint
manus-ui Next.js Frontend UI
manus-api FastAPI Backend API
manus-postgres PostgreSQL Session & message store
manus-redis Redis Task streams & cache
manus-sandbox Sandbox Ubuntu + Chrome + VNC isolated runtime

๐Ÿ› ๏ธ Common Commands

# Start everything (detached) + rebuild images
docker compose up -d --build

# Check service status
docker compose ps

# Follow logs
docker compose logs -f
docker compose logs -f manus-api
docker compose logs -f manus-ui

# Restart a single service
docker compose restart manus-api

# Stop everything
docker compose down

# Stop and wipe data volumes (DANGEROUS โ€” deletes the database)
docker compose down -v

๐Ÿ”’ Enable HTTPS

  1. Place your TLS files in nginx/ssl/:
    • fullchain.pem
    • privkey.pem
  2. In nginx/conf.d/default.conf, add/enable a listen 443 ssl server block pointing at those files.
  3. In docker-compose.yml, enable the 443:443 port mapping (and mount nginx/ssl if needed).
  4. Apply changes:
    docker compose restart manus-nginx

๐Ÿ’ป Local Development

Each sub-project has its own dev guide:

  • ๐Ÿ”ง API service โ€” FastAPI, SQLAlchemy async, Alembic, Pytest
  • ๐ŸŽจ UI service โ€” Next.js 14, App Router, SSE streaming
  • ๐Ÿ“ฆ Sandbox service โ€” Ubuntu + Chrome + VNC runtime

Quickstart for the API:

cd api
python -m venv .venv && source .venv/bin/activate
pip install uv && uv pip install -r requirements.txt
playwright install
uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload

๐Ÿ—บ๏ธ Roadmap

  • Planner + ReAct dual-agent flow
  • MCP & A2A integrations
  • Multimodal tools (image / video / 3D / TTS)
  • DeepSeek reasoning-model (v4) compatibility
  • Long-term memory / RAG plugin
  • Multi-user workspace permissions
  • Plugin marketplace for tools & MCP servers
  • Mobile-friendly UI

๐Ÿค Contributing

Contributions are warmly welcomed โ€” issues, PRs, tool plugins, and translations alike.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feat/amazing-thing)
  3. Commit your changes (git commit -m 'feat: add amazing thing')
  4. Push to the branch (git push origin feat/amazing-thing)
  5. Open a Pull Request

Please read CLAUDE.md first โ€” it documents the architecture, the agent contracts, and how to add new tools / LLM providers safely.


๐Ÿ™ Acknowledgements

MultiGen stands on the shoulders of these excellent projects:


๐Ÿ“„ License

Released under the MIT License.

If MultiGen is useful to you, please consider giving it a โญ โ€” it really helps!

Made with โค๏ธ for builders of private AI agents.

About

Multi-agent end-to-end application - General-purpose artificial intelligence agent for multimodal agent collaboration

Topics

Resources

Stars

402 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages