Multi-Agent System in Practice: Building Agent Collaboration and Kanban-Style Task Scheduling
This article explains why single-agent systems often struggle with complex workflows and how multi-agent collaboration can address those limits. It introduces three core concepts—Agent, Profile, and Kanban board—and walks through a practical setup for task decomposition, dependency management, state transitions, and observability. It also provides engineering recommendations for building reliable multi-agent systems.
1. From Single Agent to Multi-Agent: Why Collaboration Is Needed
As large language models mature, a single agent can already handle tasks such as question answering, summarization, and code generation. However, when facing complex business workflows, a single-agent architecture often reveals clear limitations:
- Responsibility overload: One agent may be responsible for requirement analysis, coding, testing, and documentation at the same time. Its system prompt keeps expanding, which can cause conflicting instructions and unstable behavior.
- Context pollution: All tasks share the same conversation memory. Irrelevant information gets mixed in, diluting critical context and reducing output quality.
- No parallelism: Tasks can only be processed serially, which limits efficiency.
For these reasons, multi-agent collaboration is commonly used: a complex task is broken down into subtasks, assigned to agents with different roles and skills, and then connected through a unified scheduling mechanism. This kind of system usually consists of three parts: the agent itself, the Profile configuration, and the task board. Each part is described below.
2. Three Core Concepts: Agent, Profile, and Kanban Board
2.1 Agent: An Execution Unit with an Independent Identity
An agent can be understood as a small assistant with its own role, skills, and memory. Each agent should meet the following conditions:
- Independent role: It has a specific role definition, such as “code reviewer,” “documentation writer,” or “test engineer,” and follows different behavior rules.
- Clear skills: It is bound to a specific set of tools or capabilities, such as code execution, file reading and writing, or retrieval queries, avoiding overly broad permissions.
- Isolated memory: It maintains its own conversation history and long-term memory, without interfering with other agents.
2.2 Profile: The Identity Card and Instruction Manual for an Agent
A Profile is a configuration file that describes all metadata of an agent. It usually contains the following fields:
name: code-reviewerdescription: An agent focused on code quality reviewsystem_prompt: |You are a senior code reviewer responsible for checking codereadability, boundary conditions, and potential defects.Output only review comments.tools:- code_read- static_checkmemory:type: sessionretention: 30d
The key point to understand is: creating a Profile is semantically equivalent to creating an agent, and switching a Profile is equivalent to switching the agent currently at work. This “configuration as instance” design brings three benefits:
- Versionable: A Profile is essentially a text configuration. It can be managed in a code repository, allowing agent role evolution to be maintained like code.
- Reusable: A well-tuned Profile can be loaded repeatedly across different sessions and tasks.
- Auditable: Each agent’s permission boundaries and behavior rules are explicitly written in the Profile, making issues traceable.
2.3 Kanban Board: A Visual Scheduling Console for Multi-Agent Collaboration
The Kanban board comes from the “Kanban” method in lean production. In multi-agent systems, it is used for visual management of task flow. A typical board has three columns: To Do — In Progress — Done.
It solves a core problem: when multiple agents work in parallel, there must be a globally trusted state center that shows who is doing what, how far each task has progressed, and who should receive the next task. A Kanban board usually provides the following capabilities:
- Task assignment: Assign task cards to specific agents.
- State transitions: Move tasks between columns so progress is visible in real time.
- Dependency management: If task B depends on the output of task A, task B will not be triggered until task A is completed.
- Persistence: Store state persistently so that task context is not lost after a service restart.
3. Practice: Building a Multi-Agent Collaboration Workflow
The following example uses “developing a new feature” to demonstrate typical setup steps.
Step 1: Split Agents by Responsibility
First, plan the role division and avoid relying on one agent to do everything:
- Planning agent: Receives the original requirement and outputs a task list with dependencies.
- Development agent: Takes coding tasks and produces code.
- Review agent: Takes review tasks and checks code quality.
- Documentation agent: Generates documentation after the feature is completed.
Create a Profile for each role with its own system prompt and tool permissions. Pay special attention to least privilege: the review agent does not need write-file permission, and the documentation agent does not need code-execution permission.
Step 2: Define Task Cards and Dependencies
When creating tasks on the board, each card should contain structured information:
{"task_id": "T-002","title": "Implement the user registration API","assignee": "developer","status": "todo","depends_on": ["T-001"],"output": "Registration API code and self-test results"}
The depends_on field declares dependencies. Before T-001, which is database schema design, is completed, T-002 remains in the To Do column and will not be picked up by the development agent.
Step 3: Drive State Transitions
Task transitions are usually triggered by two mechanisms:
- Event-driven: When an agent marks a task as complete, the scheduler checks the dependency table, automatically moves tasks whose prerequisites are satisfied into the To Do column, and notifies the corresponding agent to pick them up.
- Human intervention: For high-risk nodes, such as production release operations, a manual checkpoint can be added. The workflow continues only after a person confirms it on the board.
A simplified transition pseudocode is shown below:
def on_task_done(task):board.move(task, to="done")for child in registry.dependents_of(task.id):if all(dep.status == "done" for dep in child.depends_on):board.move(child, to="todo")notify(agent_of(child.assignee), child)
Step 4: Observability and Retrospective
Another value of the Kanban board is observability: managers can see each agent’s workload, task bottlenecks, and average duration on a single view. After tasks are completed, intermediate artifacts accumulated on the cards, such as review comments and document drafts, can be used for retrospectives. These artifacts can then be used to iterate on each agent’s Profile prompt, forming a loop of “execution — feedback — tuning.”
4. Engineering Recommendations
- Keep the number of roles moderate: More agents are not always better. Too many fine-grained roles increase scheduling overhead and communication costs. Usually, 3 to 5 core roles are enough to cover most scenarios.
- Define clear handoff contracts: Agents pass results through the
outputfield of task cards. The clearer the input and output formats, the more stable the collaboration. - Set timeouts and retries: Define timeout policies for each task to prevent one agent from getting stuck in a loop and blocking the entire pipeline.
- Persist state: Board data should be written to reliable storage, such as a database or object storage, so that task context can be recovered after a process restart.
- Keep human checkpoints: Retaining manual confirmation on critical paths is an important way to ensure the safety of multi-agent systems at the current stage.
5. Summary
The essence of multi-agent collaboration is “divide and conquer plus unified scheduling”: use Profiles to define clear roles, skills, and permission boundaries for each agent, and use the Kanban board as a global state center for task assignment, dependency transitions, and progress observation. With this approach, developers can break complex business workflows into tasks handled by agents with focused responsibilities, improving parallel efficiency while making the system more maintainable and explainable.
