pub struct ScoreReq {
pub comment: Option<String>,
pub data_type: Option<String>,
pub dataset_item_id: Option<String>,
pub dataset_name: Option<String>,
pub name: String,
pub run_name: Option<String>,
pub string_value: Option<String>,
pub trace_id: Option<String>,
pub value: Option<f64>,
}Fields§
§comment: Option<String>Comment is the grader’s reasoning, truncated at 2000 characters.
data_type: Option<String>DataType is NUMERIC, CATEGORICAL or BOOLEAN. A declared rubric overrides it — a caller cannot claim a type the org’s rubric contradicts.
dataset_item_id: Option<String>ItemID attaches the score to one graded example.
dataset_name: Option<String>Dataset attaches the score to one dataset.
name: StringName is the score name. A rubric of the same name, if the org has declared one, decides this score’s type and the values it may take.
run_name: Option<String>RunName attaches the score to one run.
string_value: Option<String>StringValue is the label of a CATEGORICAL score, which must be one the rubric allows.
trace_id: Option<String>TraceID attaches the score to one model call.
value: Option<f64>Value is the numeric score, which must be finite: NaN and Inf are refused. A BOOLEAN score takes 0 or 1.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ScoreReq
impl<'de> Deserialize<'de> for ScoreReq
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for ScoreReq
Auto Trait Implementations§
impl Freeze for ScoreReq
impl RefUnwindSafe for ScoreReq
impl Send for ScoreReq
impl Sync for ScoreReq
impl Unpin for ScoreReq
impl UnsafeUnpin for ScoreReq
impl UnwindSafe for ScoreReq
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more