WorkflowHostingExtensions.AsAIAgent 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.
Convert a workflow with the appropriate primary input type to an AIAgent.
public static Microsoft.Agents.AI.AIAgent AsAIAgent(this Microsoft.Agents.AI.Workflows.Workflow workflow, string? id = default, string? name = default, string? description = default, Microsoft.Agents.AI.Workflows.IWorkflowExecutionEnvironment? executionEnvironment = default, bool includeExceptionDetails = false, bool includeWorkflowOutputsInResponse = false);
static member AsAIAgent : Microsoft.Agents.AI.Workflows.Workflow * string * string * string * Microsoft.Agents.AI.Workflows.IWorkflowExecutionEnvironment * bool * bool -> Microsoft.Agents.AI.AIAgent
<Extension()>
Public Function AsAIAgent (workflow As Workflow, Optional id As String = Nothing, Optional name As String = Nothing, Optional description As String = Nothing, Optional executionEnvironment As IWorkflowExecutionEnvironment = Nothing, Optional includeExceptionDetails As Boolean = false, Optional includeWorkflowOutputsInResponse As Boolean = false) As AIAgent
Parameters
- executionEnvironment
- IWorkflowExecutionEnvironment
Specify the execution environment to use when running the workflows. See OffThread, Concurrent and Lockstep for the in-process environments.
- includeExceptionDetails
- Boolean
If true, will include Message
in the ErrorContent representing the workflow error.
- includeWorkflowOutputsInResponse
- Boolean
If true, will transform outgoing workflow outputs
into into content in AgentResponseUpdates or the AgentResponse as appropriate.