Skip to content
Tracon

EvalExpectedToolCall

Namespace Tracon · Assembly Tracon.Abstractions.dll

A tool call an EvalCase expects the agent to make.

public sealed record EvalExpectedToolCall : IEquatable<EvalExpectedToolCall>
Inheritance
object ← EvalExpectedToolCall
Implements
IEquatable<EvalExpectedToolCall>
Inherited Members
object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

The toolCallArgsMatch check reads it. The case passes that check when, for every expected call, the run called a tool of that EvalExpectedToolCall.Name (letter case does not matter) and - when EvalExpectedToolCall.Arguments is given - one such call carried every listed argument with an equal value.

public EvalExpectedToolCall()

The arguments the call must carry, or null to check only that the tool was called.

public IReadOnlyDictionary<string, JsonElement>? Arguments { get; init; }

IReadOnlyDictionary<string, JsonElement>?

The listed arguments are a subset: the call may carry others. An argument name matches without regard to letter case. A value matches by its JSON meaning: 2 equals 2.0, an object equals an object with the same properties in any order, and white space between tokens does not matter. A nested object or array matches exactly - the subset rule applies to the top-level argument names only.

A null value expects the argument to be absent or null: the check does not see a null argument a model sent.

The tool name. Compared without regard to letter case.

public required string Name { get; init; }

string

public override bool Equals(object? obj)

obj object?

bool

public bool Equals(EvalExpectedToolCall? other)

other EvalExpectedToolCall?

bool

public override int GetHashCode()

int

public override string ToString()

string

operator ==(EvalExpectedToolCall?, EvalExpectedToolCall?)

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

left EvalExpectedToolCall?

right EvalExpectedToolCall?

bool

operator !=(EvalExpectedToolCall?, EvalExpectedToolCall?)

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

left EvalExpectedToolCall?

right EvalExpectedToolCall?

bool