The platform for continuously improving AI agents.
/* tslint:disable */
/* eslint-disable */
/**
* Overbae API
* Backend API for the Overclaw / Overmind platform.
*
* The version of the OpenAPI document: 2.0.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { mapValues } from '../runtime';
import type { EvalMatrixTypeEnum } from './EvalMatrixTypeEnum';
import {
EvalMatrixTypeEnumFromJSON,
EvalMatrixTypeEnumFromJSONTyped,
EvalMatrixTypeEnumToJSON,
EvalMatrixTypeEnumToJSONTyped,
} from './EvalMatrixTypeEnum';
import type { JudgeOptionRequest } from './JudgeOptionRequest';
import {
JudgeOptionRequestFromJSON,
JudgeOptionRequestFromJSONTyped,
JudgeOptionRequestToJSON,
JudgeOptionRequestToJSONTyped,
} from './JudgeOptionRequest';
import type { OutputEnum } from './OutputEnum';
import {
OutputEnumFromJSON,
OutputEnumFromJSONTyped,
OutputEnumToJSON,
OutputEnumToJSONTyped,
} from './OutputEnum';
/**
* One benchmark criterion: Python graded by ``evaluate(span)``, or a judge question
* with its own answers and their scores.
* @export
* @interface EvalCriterionRequest
*/
export interface EvalCriterionRequest {
/**
*
* @type {string}
* @memberof EvalCriterionRequest
*/
name: string;
/**
*
* @type {EvalMatrixTypeEnum}
* @memberof EvalCriterionRequest
*/
type: EvalMatrixTypeEnum;
/**
*
* @type {string}
* @memberof EvalCriterionRequest
*/
source: string;
/**
*
* @type {OutputEnum}
* @memberof EvalCriterionRequest
*/
output?: OutputEnum;
/**
*
* @type {Array<JudgeOptionRequest>}
* @memberof EvalCriterionRequest
*/
options?: Array<JudgeOptionRequest>;
}
/**
* Check if a given object implements the EvalCriterionRequest interface.
*/
export function instanceOfEvalCriterionRequest(value: object): value is EvalCriterionRequest {
if (!('name' in value) || value['name'] === undefined) return false;
if (!('type' in value) || value['type'] === undefined) return false;
if (!('source' in value) || value['source'] === undefined) return false;
return true;
}
export function EvalCriterionRequestFromJSON(json: any): EvalCriterionRequest {
return EvalCriterionRequestFromJSONTyped(json, false);
}
export function EvalCriterionRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): EvalCriterionRequest {
if (json == null) {
return json;
}
return {
'name': json['name'],
'type': EvalMatrixTypeEnumFromJSON(json['type']),
'source': json['source'],
'output': json['output'] == null ? undefined : OutputEnumFromJSON(json['output']),
'options': json['options'] == null ? undefined : ((json['options'] as Array<any>).map(JudgeOptionRequestFromJSON)),
};
}
export function EvalCriterionRequestToJSON(json: any): EvalCriterionRequest {
return EvalCriterionRequestToJSONTyped(json, false);
}
export function EvalCriterionRequestToJSONTyped(value?: EvalCriterionRequest | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'name': value['name'],
'type': EvalMatrixTypeEnumToJSON(value['type']),
'source': value['source'],
'output': OutputEnumToJSON(value['output']),
'options': value['options'] == null ? undefined : ((value['options'] as Array<any>).map(JudgeOptionRequestToJSON)),
};
}