Interface IEvalRunStore
Persists the outcome of a recorded evaluation run. Used by the eval harness
to track regression scores between agent / prompt / model versions.
The optional exchange parameter on every method carries the route
pipeline's current exchange; REDB-backed implementations resolve a
per-exchange through
IRouteContext.GetRedbService(name, exchange). In-memory
implementations ignore it.
Without an exchange a redb-backed implementation opens a redb scope of its own for the call. That scope joins an
ambient (a , a
route's .Transacted()) as every redb connection does, but not a transaction begun on the context's shared
IRedbService (ExecuteAtomicAsync, BeginTransaction), which it does not see: pass the exchange,
or use a TransactionScope, when the call must commit or roll back with that work. In-memory implementations
take part in no transaction.
public interface IEvalRunStore
Methods
GetAsync(string, IExchange?, CancellationToken)
Loads a single run by its identifier.
Task<EvalRunRecord?> GetAsync(string runId, IExchange? exchange = null, CancellationToken ct = default)
ListAsync(string?, int, IExchange?, CancellationToken)
Lists runs filtered by scenario name. Returns newest first.
Task<IReadOnlyList<EvalRunRecord>> ListAsync(string? scenario = null, int take = 50, IExchange? exchange = null, CancellationToken ct = default)
SaveAsync(EvalRunRecord, IExchange?, CancellationToken)
Persists a completed evaluation run.
Task SaveAsync(EvalRunRecord record, IExchange? exchange = null, CancellationToken ct = default)
SaveManyAsync(IEnumerable<EvalRunRecord>, IExchange?, CancellationToken)
Persists many evaluation runs at once. Bulk-friendly stores commit the
Task SaveManyAsync(IEnumerable<EvalRunRecord> records, IExchange? exchange = null, CancellationToken ct = default)