Skip to content

The platform for continuously improving AI agents.

2.0 KB
Raw Blame
/* 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';
/**
 *
 * @export
 * @interface RetainedCheckpoint
 */
export interface RetainedCheckpoint {
    /**
     *
     * @type {number}
     * @memberof RetainedCheckpoint
     */
    step: number;
    /**
     *
     * @type {number}
     * @memberof RetainedCheckpoint
     */
    evalLoss: number | null;
    /**
     *
     * @type {boolean}
     * @memberof RetainedCheckpoint
     */
    selected: boolean;
}

/**
 * Check if a given object implements the RetainedCheckpoint interface.
 */
export function instanceOfRetainedCheckpoint(value: object): value is RetainedCheckpoint {
    if (!('step' in value) || value['step'] === undefined) return false;
    if (!('evalLoss' in value) || value['evalLoss'] === undefined) return false;
    if (!('selected' in value) || value['selected'] === undefined) return false;
    return true;
}

export function RetainedCheckpointFromJSON(json: any): RetainedCheckpoint {
    return RetainedCheckpointFromJSONTyped(json, false);
}

export function RetainedCheckpointFromJSONTyped(json: any, ignoreDiscriminator: boolean): RetainedCheckpoint {
    if (json == null) {
        return json;
    }
    return {

        'step': json['step'],
        'evalLoss': json['eval_loss'],
        'selected': json['selected'],
    };
}

export function RetainedCheckpointToJSON(json: any): RetainedCheckpoint {
    return RetainedCheckpointToJSONTyped(json, false);
}

export function RetainedCheckpointToJSONTyped(value?: RetainedCheckpoint | null, ignoreDiscriminator: boolean = false): any {
    if (value == null) {
        return value;
    }

    return {

        'step': value['step'],
        'eval_loss': value['evalLoss'],
        'selected': value['selected'],
    };
}