Exploring edict: An AI Multi‑Agent Framework Inspired by Ancient Chinese Three‑Ministry Six‑Department System

The article introduces edict, an open‑source AI multi‑agent collaboration framework modeled on the ancient Chinese three‑ministry six‑department system, outlines its architecture, key features, installation steps, and shares hands‑on experience and pitfalls.

Black & White Path
Black & White Path
Black & White Path
Exploring edict: An AI Multi‑Agent Framework Inspired by Ancient Chinese Three‑Ministry Six‑Department System

Project Overview

edict is an open‑source AI multi‑agent collaboration framework that adopts the structure of the ancient Chinese three‑province six‑department system. The framework defines twelve agents – eleven business roles and one compatibility role – each with a clearly assigned responsibility.

taizi : message sorting and requirement organization

zhongshu : receives directives, plans, and decomposes tasks

menxia : conducts institutional review, can reject unsatisfactory outputs

shangshu : dispatches, coordinates, and aggregates results

hubu / libu / bingbu / xingbu / gongbu : specialized execution of assigned duties

Key Advantages

Institutional Review : a dedicated review department (menxia) audits each directive and can block non‑conforming results.

Real‑time Kanban : a Kanban board with timeline visualizes task status.

Task Intervention : supports stopping, canceling, and resuming tasks.

Full Audit Trail : every directive is archived as a complete record.

Agent Health Monitoring : heartbeat and activity checks keep agents healthy.

Hot Model Switching : one‑click LLM swapping directly from the dashboard.

Installation

Docker Quick Start

docker run -p 7891:7891 cft0808/sansheng-demo

Open http://localhost:7891 to view the full dashboard demo with pre‑loaded mock data.

If an exec format error occurs on x86/amd64 machines, add the platform flag:

docker run --platform linux/amd64 -p 7891:7891 cft0808/sansheng-demo

Local Installation

git clone https://github.com/cft0808/edict.git
cd edict
chmod +x install.sh && ./install.sh

Before the first run, configure the API key and register the "taizi" agent: openclaw agents add taizi Then re‑execute ./install.sh to sync the key to all agents.

Running the Services

# Terminal 1: data refresh loop
bash scripts/run_loop.sh

# Terminal 2: dashboard server
python3 dashboard/server.py

# Open the dashboard
open http://127.0.0.1:7891

Common Pitfalls

Docker image architecture : on x86/amd64 hosts the --platform linux/amd64 flag is required.

API key configuration : the key must be set before the first installation to enable agent synchronization.

Data refresh process : the run_loop.sh script must remain running to keep the dashboard updated in real time.

Dashboard Capabilities

Directive Board : Kanban view with filtering and search.

Department Scheduling : visual statistics of task counts.

Archive Vault : completed directives are archived and can be exported as Markdown.

Official Overview : token consumption ranking and activity statistics.

Daily News : automatic collection of technology and finance news.

Conclusion

edict combines the ancient Chinese three‑province six‑department governance model with modern AI techniques to create a decentralized multi‑agent framework that provides systematic audit, real‑time visualization, and health monitoring of AI agents.

Repository: https://github.com/cft0808/edict

DockerAIopen-sourceFrameworkMulti-agentEdict
Black & White Path
Written by

Black & White Path

We are the beacon of the cyber world, a stepping stone on the road to security.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.