Skip to content

WorkflowDescriptor

Namespace AgentPrism · Assembly AgentPrism.Abstractions.dll

Represents a summary view of a workflow listed in the catalog.

public sealed record WorkflowDescriptor : IEquatable<WorkflowDescriptor>

objectWorkflowDescriptor

IEquatable<WorkflowDescriptor>

object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Workflows defined in code do not carry a declarative WorkflowDefinition: they come from a factory, and their graph is only known after compilation. For such a record, WorkflowDescriptor.Kind and WorkflowDescriptor.AgentNames stay empty; the catalog still shows the name and description.

public WorkflowDescriptor()

Gets the agent names entering the graph. Can be empty for code-defined workflows.

public IReadOnlyList<string> AgentNames { get; init; }

IReadOnlyList<string>

Gets the short description.

public string? Description { get; init; }

string?

Gets the display name shown in the UI.

public string? DisplayName { get; init; }

string?

Gets the built-in pattern. null for workflows defined by a factory in code: a free-form graph does not correspond to a pattern.

public WorkflowKind? Kind { get; init; }

WorkflowKind?

Gets the workflow’s unique name.

public required string Name { get; init; }

string

Gets the mixed agent/function node list for a Sequential workflow that uses function nodes. Empty for every other definition.

public IReadOnlyList<WorkflowNodeReference> Nodes { get; init; }

IReadOnlyList<WorkflowNodeReference>

Gets the source of the definition.

public required AgentDefinitionOrigin Origin { get; init; }

AgentDefinitionOrigin

Gets the last modification time (UTC).

public DateTimeOffset? UpdatedAt { get; init; }

DateTimeOffset?

Gets the definition version. Always 1 for code-defined workflows.

public int Version { get; init; }

int

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(WorkflowDescriptor? other)

other WorkflowDescriptor?

bool

public override int GetHashCode()

int

public override string ToString()

string

operator ==(WorkflowDescriptor?, WorkflowDescriptor?)

Section titled “ operator ==(WorkflowDescriptor?, WorkflowDescriptor?)”
public static bool operator ==(WorkflowDescriptor? left, WorkflowDescriptor? right)

left WorkflowDescriptor?

right WorkflowDescriptor?

bool

operator !=(WorkflowDescriptor?, WorkflowDescriptor?)

Section titled “ operator !=(WorkflowDescriptor?, WorkflowDescriptor?)”
public static bool operator !=(WorkflowDescriptor? left, WorkflowDescriptor? right)

left WorkflowDescriptor?

right WorkflowDescriptor?

bool