Edict
Multi-agent orchestration system based on Tang Dynasty's Three Departments and Six Ministries system. 9 specialized AI agents working together in an ancient Chinese governmental structure for modern task execution.
Tang Dynasty Multi-Agent Orchestration - 9 Specialized AI Agents
Edict is a unique multi-agent orchestration system inspired by the Tang Dynasty's Three Departments and Six Ministries governmental structure. Featuring 9 specialized AI agents organized in an ancient Chinese bureaucratic hierarchy, Edict brings historical wisdom to modern AI task execution with clear role separation and quality control. GitHub: https://github.com/cft0808/edict Developer: cft0808 (Community Open Source) License: MIT Key Innovation: Edict creatively maps the sophisticated Tang Dynasty governmental structure to modern AI agent orchestration, providing clear role specialization and built-in quality control through a hierarchical decision-making process.
Core Philosophy: "Ancient wisdom meets modern AI - structured collaboration for quality outcomes"
Why Edict?
Historical Structure: Tang Dynasty's proven organizational design.
9 Specialized Agents: Clear role separation for complex tasks.
Quality Control: Built-in review and approval workflow.
Visual Dashboard: Real-time monitoring of agent activities.
The Three Departments and Six Ministries
Three Departments (三省)
-
Zhongshu Sheng (中书省) - Policy Planning
- Task analysis and planning
- Strategy formulation
-
Menxia Sheng (门下省) - Review and Approval
- Quality review
- Output validation
-
Shangshu Sheng (尚书省) - Execution
- Task execution coordination
- Results aggregation
Six Ministries (六部)
- Ministry of Personnel (吏部) - Resource Management
- Ministry of Revenue (户部) - Data Processing
- Ministry of Rites (礼部) - Format and Style
- Ministry of War (兵部) - Problem Resolution
- Ministry of Justice (刑部) - Compliance Check
- Ministry of Works (工部) - Final Production
Key Features
$#1.
Agent Specialization
- Each agent has a specific role
- Specialized prompts and capabilities
- Clear responsibility boundaries
- Expert-level task handling
$#2.
Hierarchical Workflow
- Top-down task decomposition
- Bottom-up result aggregation
- Review gates at each level
- Escalation mechanisms
$#3.
Real-Time Dashboard
- Agent status monitoring
- Task progress visualization
- Communication logs
- Performance metrics
$#4.
Quality Control
- Multi-stage review process
- Automatic validation
- Error detection and correction
- Output consistency
$#5.
Task Routing
- Intelligent task assignment
- Load balancing
- Priority handling
- Retry mechanisms
Installation
Docker
# Pull image
docker pull cft0808/edict:latest
# Run container
docker run -d \
--name edict \
-p 8080:8080 \
-v ~/edict/data:/app/data \
cft0808/edict:latestManual Installation
# Clone repository
git clone https://github.com/cft0808/edict.git
cd edict
# Create virtual environment
python -m venv venv
source venv/bin/activate
# Install dependencies
pip install -r requirements.txt
# Configure
cp config.example.yaml config.yaml
# Run
python main.pyConfiguration
config.yaml
agents:
count: 9
model: "gpt-4o"
timeout: 120
departments:
zhongshu:
enabled: true
model: "gpt-4o"
menxia:
enabled: true
model: "gpt-4o"
shangshu:
enabled: true
model: "gpt-4o"
ministries:
personnel: { enabled: true }
revenue: { enabled: true }
rites: { enabled: true }
war: { enabled: true }
justice: { enabled: true }
works: { enabled: true }
api:
port: 8080
host: "0.0.0.0"
dashboard:
enabled: true
refresh_rate: 5Usage
Submit a Task
curl -X POST http://localhost:8080/api/task \
-H "Content-Type: application/json" \
-d '{
"title": "Market Research Report",
"description": "Research and analyze the AI agent market",
"priority": "high"
}'Dashboard Access
Open: http://localhost:8080/dashboard
View real-time agent activities
Monitor task progress
Review outputsAgent Commands
/status - Show all agent statuses
/queue - Show pending tasks
/logs - View execution logs
/metrics - Show performance metricsPricing
Free: Edict is completely free and open source under MIT license. You only pay for the AI models you use through their respective providers.
System Requirements
| Component | Minimum | Recommended |
|---|---|---|
| OS | Linux, macOS, Windows | Linux (Ubuntu 20.04+) |
| Runtime | Python 3.9+ | Python 3.11+ |
| Memory | 1GB RAM | 4GB+ RAM |
| Storage | 500MB | 2GB |
| Network | Required | Stable internet |
Use Cases
Complex Document Processing
Process documents through multiple stages of analysis, writing, and review.
Multi-Stage Workflows
Execute workflows that require sequential processing with quality gates.
Quality-Controlled Outputs
Ensure high-quality outputs through multi-stage review.
Research and Analysis
Conduct thorough research with specialized agents for different aspects.
Content Creation Pipelines
Build content creation pipelines with dedicated roles.
Educational Demonstrations
Teach multi-agent concepts using the historical metaphor.
Community and Support
- GitHub: https://github.com/cft0808/edict
- Documentation: https://github.com/cft0808/edict#readme
- Issues: GitHub Issues tab
- Discussions: GitHub Discussions tab
Quick Start Guide
Get Edict up and running quickly.
Step 1: Install
cd edict
npm install
npx edict setupStep 2: Configure
Set your AI model and API key in the configuration.
Step 3: Connect and Go
Link your messaging platform and start using your AI agent.
Full documentation: https://github.com/cft0808/edict#readme
FAQ
Is Edict free to use?
Yes, Edict is free and open source (MIT license). You only pay for AI model API costs if using external models.
What are the system requirements for Edict?
Edict requires 1GB RAM of RAM minimum. Runtime: Python. It runs on Windows, macOS, and Linux.
Can I self-host Edict?
Yes. Edict is open source (MIT) and can be self-hosted on your own hardware. Clone the repository from GitHub and follow the installation guide.
How does Edict compare to OpenClaw?
Edict offers a different approach compared to OpenClaw. While OpenClaw provides the largest ecosystem with 13,729+ skills and maximum flexibility, Edict focuses on multi-agent. Choose Edict if you prioritize its specific features; choose OpenClaw for the broadest compatibility and community support.
Is Edict suitable for beginners?
Edict requires some technical knowledge to set up (Python). If you are a beginner, consider starting with QClaw (one-click install) or MaxClaw (cloud-based, no setup) first, then graduate to Edict as you gain experience.
License
MIT License - Free for personal and commercial use.
Tags
multi-agent, orchestration, chinese-history, specialized-agents, government-structure, quality-control, tang-dynasty