Skip to content

RunErrorClass

Namespace AgentPrism · Assembly AgentPrism.Abstractions.dll

A run error’s class.

[JsonConverter(typeof(JsonStringEnumConverter<RunErrorClass>))]
public enum RunErrorClass

BudgetExceeded = 9

The tree or context budget was exceeded.

Canceled = 10

Cancelled.

CompilationFailed = 8

The agent definition failed to compile.

ContentBlocked = 11

The content was blocked by AgentPrism’s own IContentGuard policy (AgentPrismContentBlockedException).

Separate from RunErrorClass.ContentFiltered: the cause is not the provider but the installation’s own rule set. The corresponding action is also different — one calls for loosening provider settings, the other for reviewing the policy.

ContentFiltered = 5

The model response was cut off by the provider’s safety/content filter.

This is not the class for a decision made by AgentPrism’s own guard; see RunErrorClass.ContentBlocked. Merging the two would make the operator lose the distinction between “the model refused” and “our policy refused.”

Infrastructure = 12

The process running the run disappeared without ever talking to the provider (example: an agent.RunAsync crash with no retry).

Only orphaned-run reconciliation falls into this class. Every other class relies on a response from the provider/tool/quota; this one requires a separate class because no response was ever received.

ProviderError = 1

The model provider returned an error (5xx, connection, non-timeout).

ProviderUnavailable = 2

The circuit breaker is open (AgentPrismProviderUnavailableException).

QuotaExceeded = 4

An AgentPrism quota was exhausted.

RateLimited = 3

The provider returned 429.

Timeout = 7

The run exceeded its time limit.

ToolError = 6

A tool threw an exception.

ToolTimeout = 13

A tool call did not settle within its configured timeout (AgentPrismToolTimeoutException).

Separate from RunErrorClass.Canceled: the wrapper’s own linked cancellation looks identical to a user cancellation at the exception type level (OperationCanceledException), and merging the two would hide the reason for every tool timeout behind “the user canceled”. This class does not fail a run — the run continues with a tool error — but the taxonomy applies wherever this exception’s stable identity is classified.

Unknown = 0

Matched no rule. Not a failure, a measurement tool.

The taxonomy is kept small and stable. RunErrorClass.Unknown is not a failure but a measurement tool: a classifier that finds no matching rule does not GUESS an error’s class, it writes into this bucket. A high proportion here shows the taxonomy is incomplete.

Written as a name in JSON; stored as smallint in the database (the same pattern as every other runs enum, for example RunKind). Once assigned, numeric values are never renumbered: they are stored permanently in past rows. A new class is added to the end of the list, not inserted in order.