Props
| Prop | Type | Default | Description |
|---|---|---|---|
id | string | "panel" | ID prefix for generated task ids. |
panelists | PanelistConfig[] | AgentLike[] | (required) | Specialist agents. Each entry is { agent, role?, label? } or a bare AgentLike. |
moderator | AgentLike | (required) | Agent that synthesizes all panelist outputs into a final result. |
panelistOutput | OutputTarget | (required) | Output schema for each panelist task. |
moderatorOutput | OutputTarget | (required) | Output schema for the moderator synthesis task. |
strategy | "synthesize" | "vote" | "consensus" | "synthesize" | How the moderator combines results. "synthesize" merges freely; "vote" counts agreement; "consensus" requires convergence. |
minAgree | number | undefined | Minimum panelists that must agree (used with "vote" and "consensus" strategies). |
maxConcurrency | number | Infinity | Maximum panelists running in parallel. |
skipIf | boolean | false | Skip the entire panel. Returns null. |
children | string | ReactNode | (required) | Prompt or input sent to every panelist. |
Basic usage
- Three panelist tasks run in parallel, each receiving the same prompt.
- A moderator task runs after all panelists complete, receiving their outputs via
needs.
Voting strategy
Usestrategy="vote" with minAgree to require quorum:
Consensus strategy
Usestrategy="consensus" to require panelists to converge on a shared answer. The moderator checks whether panelists agree and, if minAgree is set, enforces a minimum threshold:
Bare agent shorthand
When you don’t need per-panelist roles, pass an array of agents directly:panelist-0, panelist-1, etc.
Limiting concurrency
Generated structure
<Panel> is a composite component. It does not create a new host element type. Internally it renders:
Notes
- Each panelist task id is
{prefix}-{label|role|panelist-N}. The moderator task id is{prefix}-moderator. - The moderator task uses
needsto depend on all panelist tasks, so it runs only after every panelist completes. strategyandminAgreeare passed as prompt context to the moderator. The moderator agent is responsible for interpreting and applying the strategy.- Panelist outputs all write to the same
panelistOutputschema, differentiated by their task id.