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 { CapabilityStatusEnum } from './CapabilityStatusEnum';
import {
CapabilityStatusEnumFromJSON,
CapabilityStatusEnumFromJSONTyped,
CapabilityStatusEnumToJSON,
CapabilityStatusEnumToJSONTyped,
} from './CapabilityStatusEnum';
/**
*
* @export
* @interface CapabilityList
*/
export interface CapabilityList {
/**
*
* @type {string}
* @memberof CapabilityList
*/
readonly id: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
project: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
name: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
slug: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
description?: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
sourcePath?: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
model?: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
activeModel?: string | null;
/**
*
* @type {string}
* @memberof CapabilityList
*/
benchmarkModel?: string | null;
/**
*
* @type {CapabilityStatusEnum}
* @memberof CapabilityList
*/
status?: CapabilityStatusEnum;
/**
*
* @type {boolean}
* @memberof CapabilityList
*/
observed?: boolean;
/**
*
* @type {string}
* @memberof CapabilityList
*/
readonly suggestedName: string;
/**
*
* @type {string}
* @memberof CapabilityList
*/
entrypointFn?: string;
/**
*
* @type {number}
* @memberof CapabilityList
*/
readonly datasetSize: number;
/**
*
* @type {boolean}
* @memberof CapabilityList
*/
readonly datasetHasExpectedOutput: boolean;
/**
* Card / ``input_schema`` wins over capture ``dataset_input_keys``.
* @type {Array<string>}
* @memberof CapabilityList
*/
readonly datasetInputKeys: Array<string>;
/**
* Card ``tool_spec`` wins over capture ``tool_config``.
* @type {Array<string>}
* @memberof CapabilityList
*/
readonly toolNames: Array<string>;
/**
*
* @type {string}
* @memberof CapabilityList
*/
cliVersion?: string;
/**
* Capability-card modality (text/code/tabular/multimodal…), "" when unanalyzed.
* @type {string}
* @memberof CapabilityList
*/
readonly modality: string;
/**
*
* @type {Date}
* @memberof CapabilityList
*/
lastActivityAt?: Date | null;
/**
* Distinct-trace count annotated by CapabilityViewSet; null elsewhere.
* @type {number}
* @memberof CapabilityList
*/
readonly traceCount: number | null;
/**
*
* @type {Date}
* @memberof CapabilityList
*/
readonly createdAt: Date;
/**
*
* @type {Date}
* @memberof CapabilityList
*/
readonly updatedAt: Date;
}
/**
* Check if a given object implements the CapabilityList interface.
*/
export function instanceOfCapabilityList(value: object): value is CapabilityList {
if (!('id' in value) || value['id'] === undefined) return false;
if (!('project' in value) || value['project'] === undefined) return false;
if (!('name' in value) || value['name'] === undefined) return false;
if (!('slug' in value) || value['slug'] === undefined) return false;
if (!('suggestedName' in value) || value['suggestedName'] === undefined) return false;
if (!('datasetSize' in value) || value['datasetSize'] === undefined) return false;
if (!('datasetHasExpectedOutput' in value) || value['datasetHasExpectedOutput'] === undefined) return false;
if (!('datasetInputKeys' in value) || value['datasetInputKeys'] === undefined) return false;
if (!('toolNames' in value) || value['toolNames'] === undefined) return false;
if (!('modality' in value) || value['modality'] === undefined) return false;
if (!('traceCount' in value) || value['traceCount'] === undefined) return false;
if (!('createdAt' in value) || value['createdAt'] === undefined) return false;
if (!('updatedAt' in value) || value['updatedAt'] === undefined) return false;
return true;
}
export function CapabilityListFromJSON(json: any): CapabilityList {
return CapabilityListFromJSONTyped(json, false);
}
export function CapabilityListFromJSONTyped(json: any, ignoreDiscriminator: boolean): CapabilityList {
if (json == null) {
return json;
}
return {
'id': json['id'],
'project': json['project'],
'name': json['name'],
'slug': json['slug'],
'description': json['description'] == null ? undefined : json['description'],
'sourcePath': json['source_path'] == null ? undefined : json['source_path'],
'model': json['model'] == null ? undefined : json['model'],
'activeModel': json['active_model'] == null ? undefined : json['active_model'],
'benchmarkModel': json['benchmark_model'] == null ? undefined : json['benchmark_model'],
'status': json['status'] == null ? undefined : CapabilityStatusEnumFromJSON(json['status']),
'observed': json['observed'] == null ? undefined : json['observed'],
'suggestedName': json['suggested_name'],
'entrypointFn': json['entrypoint_fn'] == null ? undefined : json['entrypoint_fn'],
'datasetSize': json['dataset_size'],
'datasetHasExpectedOutput': json['dataset_has_expected_output'],
'datasetInputKeys': json['dataset_input_keys'],
'toolNames': json['tool_names'],
'cliVersion': json['cli_version'] == null ? undefined : json['cli_version'],
'modality': json['modality'],
'lastActivityAt': json['last_activity_at'] == null ? undefined : (new Date(json['last_activity_at'])),
'traceCount': json['trace_count'],
'createdAt': (new Date(json['created_at'])),
'updatedAt': (new Date(json['updated_at'])),
};
}
export function CapabilityListToJSON(json: any): CapabilityList {
return CapabilityListToJSONTyped(json, false);
}
export function CapabilityListToJSONTyped(value?: Omit<CapabilityList, 'id'|'suggested_name'|'dataset_size'|'dataset_has_expected_output'|'dataset_input_keys'|'tool_names'|'modality'|'trace_count'|'created_at'|'updated_at'> | null, ignoreDiscriminator: boolean = false): any {
if (value == null) {
return value;
}
return {
'project': value['project'],
'name': value['name'],
'slug': value['slug'],
'description': value['description'],
'source_path': value['sourcePath'],
'model': value['model'],
'active_model': value['activeModel'],
'benchmark_model': value['benchmarkModel'],
'status': CapabilityStatusEnumToJSON(value['status']),
'observed': value['observed'],
'entrypoint_fn': value['entrypointFn'],
'cli_version': value['cliVersion'],
'last_activity_at': value['lastActivityAt'] == null ? value['lastActivityAt'] : value['lastActivityAt'].toISOString(),
};
}