Table of Contents

Class AgentDecisionStep

Namespace
JD.AI.Workflows.Steps
Assembly
JD.AI.Workflows.dll

A scoped LLM decision step. Invokes the chat model with a tailored prompt and only the specified subset of tools (plugins/functions) available. Use for agentic workflow steps that need LLM reasoning with a controlled tool loadout.

public sealed class AgentDecisionStep : IStep<AgentWorkflowData>
Inheritance
AgentDecisionStep
Implements
Inherited Members

Constructors

AgentDecisionStep(string, string, IEnumerable<string>?)

public AgentDecisionStep(string name, string promptTemplate, IEnumerable<string>? allowedPlugins = null)

Parameters

name string

Human-readable step name.

promptTemplate string

Prompt template. Use {prompt} for the original request and {previous} for the prior step's output.

allowedPlugins IEnumerable<string>

Plugin names to expose to the LLM. If empty, no tools are available.

Properties

Name

Gets the name of this step.

public string Name { get; }

Property Value

string

Methods

ExecuteAsync(IWorkflowContext<AgentWorkflowData>)

Executes this step with the given typed context.

public Task ExecuteAsync(IWorkflowContext<AgentWorkflowData> context)

Parameters

context IWorkflowContext<AgentWorkflowData>

The workflow context.

Returns

Task

A task representing the asynchronous operation.