HandoffWorkflowBuilderCore<TBuilder>.WithHandoffs Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| WithHandoffs(AIAgent, IEnumerable<AIAgent>) |
Adds handoff relationships from a source agent to one or more target agents. |
| WithHandoffs(IEnumerable<AIAgent>, AIAgent, String) |
Adds handoff relationships from one or more sources agent to a target agent. |
WithHandoffs(AIAgent, IEnumerable<AIAgent>)
Adds handoff relationships from a source agent to one or more target agents.
public TBuilder WithHandoffs(Microsoft.Agents.AI.AIAgent from, System.Collections.Generic.IEnumerable<Microsoft.Agents.AI.AIAgent> to);
member this.WithHandoffs : Microsoft.Agents.AI.AIAgent * seq<Microsoft.Agents.AI.AIAgent> -> 'Builder
Public Function WithHandoffs (from As AIAgent, to As IEnumerable(Of AIAgent)) As TBuilder
Parameters
- from
- AIAgent
The source agent.
- to
- IEnumerable<AIAgent>
The target agents to add as handoff targets for the source agent.
Returns
The updated HandoffsWorkflowBuilder instance.
Remarks
The handoff reason for each target in to is derived from that agent's description or name.
Applies to
WithHandoffs(IEnumerable<AIAgent>, AIAgent, String)
Adds handoff relationships from one or more sources agent to a target agent.
public TBuilder WithHandoffs(System.Collections.Generic.IEnumerable<Microsoft.Agents.AI.AIAgent> from, Microsoft.Agents.AI.AIAgent to, string? handoffReason = default);
member this.WithHandoffs : seq<Microsoft.Agents.AI.AIAgent> * Microsoft.Agents.AI.AIAgent * string -> 'Builder
Public Function WithHandoffs (from As IEnumerable(Of AIAgent), to As AIAgent, Optional handoffReason As String = Nothing) As TBuilder
Parameters
- from
- IEnumerable<AIAgent>
The source agents.
- to
- AIAgent
The target agent to add as a handoff target for each source agent.
- handoffReason
- String
The reason the from should hand off to the to.
If null, the reason is derived from to's description or name.
Returns
The updated HandoffsWorkflowBuilder instance.