Skip to content

Graphorin API reference v0.15.1


Graphorin API reference / @graphorin/core / / EvalScorer

Interface: EvalScorer<TInput, TOutput> ​

Defined in: packages/core/src/contracts/eval-scorer.ts:14

Stable

Pluggable evaluation scorer. Generic over the input / output types carried by the eval dataset. Concrete implementations live in the separate @graphorin/evals package (post-MVP); the interface lives here so that:

  • The minimal inline runner shipped with @graphorin/observability can type-check against it.
  • Custom application-level scorers can be defined without taking an evals dependency.

Type Parameters ​

Type ParameterDefault type
TInputunknown
TOutputunknown

Properties ​

PropertyModifierTypeDefined in
description?readonlystringpackages/core/src/contracts/eval-scorer.ts:16
idreadonlystringpackages/core/src/contracts/eval-scorer.ts:15

Methods ​

score() ​

ts
score(sample): Promise<EvalScore>;

Defined in: packages/core/src/contracts/eval-scorer.ts:17

Parameters ​

ParameterType
sampleEvalSample&lt;TInput, TOutput&gt;

Returns ​

Promise&lt;EvalScore&gt;