HandoffWorkflowBuilderCore<TBuilder>.AddParticipants Method

Definition

Adds the specified agents as participants in the handoff workflow without defining handoff relationships for them.

public TBuilder AddParticipants(System.Collections.Generic.IEnumerable<Microsoft.Agents.AI.AIAgent> agents);
member this.AddParticipants : seq<Microsoft.Agents.AI.AIAgent> -> 'Builder
Public Function AddParticipants (agents As IEnumerable(Of AIAgent)) As TBuilder

Parameters

agents
IEnumerable<AIAgent>

The agents to add as participants.

Returns

TBuilder

The updated builder instance.

Remarks

Use this method when you want a participant to be part of the workflow but you have not explicitly defined handoff edges via WithHandoff(AIAgent, AIAgent, String). When no handoffs are explicitly defined (default handoffs), all registered participants are automatically wired so that every agent can hand off to every other agent.

Applies to