Skip to content

RunReplayPreparation

Namespace AgentPrism · Assembly AgentPrism.Core.dll

Represents a prepared replay plan.

public sealed record RunReplayPreparation : IEquatable<RunReplayPreparation>

objectRunReplayPreparation

IEquatable<RunReplayPreparation>

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

Gets the agent to run.

public AIAgent? Agent { get; init; }

AIAgent?

Gets the definition version to use in the replay. null for a code-defined agent.

public int? AgentVersion { get; init; }

int?

Gets the human-readable reason for a failure. Empty when RunReplayOutcome.Ready.

public string? Detail { get; init; }

string?

Gets the recorded input of the source run.

public IReadOnlyList<ChatMessage> Messages { get; init; }

IReadOnlyList<ChatMessage>

Gets the model to use in the replay. null if unknown.

public string? ModelId { get; init; }

string?

Gets the outcome of the preparation.

public required RunReplayOutcome Outcome { get; init; }

RunReplayOutcome

Gets the source run.

public RunRecord? SourceRun { get; init; }

RunRecord?

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(RunReplayPreparation? other)

other RunReplayPreparation?

bool

Produces a failed preparation.

public static RunReplayPreparation Failed(RunReplayOutcome outcome, string detail)

outcome RunReplayOutcome

The outcome.

detail string

The reason.

RunReplayPreparation

The preparation.

public override int GetHashCode()

int

Ready(AIAgent, IReadOnlyList<ChatMessage>, RunRecord, int?, string?)

Section titled “ Ready(AIAgent, IReadOnlyList<ChatMessage>, RunRecord, int?, string?)”

Produces a ready plan.

public static RunReplayPreparation Ready(AIAgent agent, IReadOnlyList<ChatMessage> messages, RunRecord sourceRun, int? agentVersion, string? modelId)

agent AIAgent

The agent to run.

messages IReadOnlyList<ChatMessage>

The recorded input.

sourceRun RunRecord

The source run.

agentVersion int?

The definition version to use.

modelId string?

The model to use.

RunReplayPreparation

The preparation.

public override string ToString()

string

operator ==(RunReplayPreparation?, RunReplayPreparation?)

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

left RunReplayPreparation?

right RunReplayPreparation?

bool

operator !=(RunReplayPreparation?, RunReplayPreparation?)

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

left RunReplayPreparation?

right RunReplayPreparation?

bool