Skip to content

Latest commit

 

History

History
164 lines (99 loc) · 4.3 KB

AIHordeRatings.md

File metadata and controls

164 lines (99 loc) · 4.3 KB

@zeldafan0225/ai_horde / Exports / AIHordeRatings

Class: AIHordeRatings

Table of contents

Constructors

Methods

Constructors

constructor

new AIHordeRatings(options)

Parameters

Name Type
options AIHordeRatingsInitOptions

Defined in

index.ts:3037

Methods

getDatasets

getDatasets<T>(options?): Promise<Pick<DatasetGetResponse, T>[]>

Display all datasets

Type parameters

Name Type
T extends keyof DatasetGetResponse

Parameters

Name Type Description
options? Object -
options.fields? T[] Array of fields that will be included in the returned data

Returns

Promise<Pick<DatasetGetResponse, T>[]>

RatingsDatasetResponse - The datasets

Defined in

index.ts:3075


getNewRating

getNewRating<T>(image_options?, options?): Promise<Pick<DatasetImagePopResponse, T>>

Retrieve an image to rate from the default dataset

Type parameters

Name Type
T extends keyof DatasetImagePopResponse

Parameters

Name Type Description
image_options? Object -
image_options.dataset_id string The ID of the dataset to get an image from
image_options.model_name? string The model name to get an image from
options? Object -
options.fields? T[] Array of fields that will be included in the returned data
options.token? string The token of the requesting user

Returns

Promise<Pick<DatasetImagePopResponse, T>>

DatasetImagePopResponse - An images data to rate

Defined in

index.ts:3106


getTeams

getTeams<T>(options?): Promise<Pick<TeamsGetResponse, T>[]>

Display all public teams

Type parameters

Name Type
T extends keyof TeamsGetResponse

Parameters

Name Type Description
options? Object -
options.fields? T[] Array of fields that will be included in the returned data

Returns

Promise<Pick<TeamsGetResponse, T>[]>

RatingsTeamsResponse - The datasets

Defined in

index.ts:3089


postRating

postRating<T>(image_id, rating, options?): Promise<Pick<RatePostResponse, T>>

Check if there are interrogation requests queued for fulfillment This endpoint is used by registered workers only

Type parameters

Name Type
T extends keyof RatePostResponse

Parameters

Name Type Description
image_id string The ID if the Image you want to rate
rating RatePostInput
options? Object -
options.fields? T[] Array of fields that will be included in the returned data
options.token? string The token of the requesting user

Returns

Promise<Pick<RatePostResponse, T>>

InterrogationPopPayload

Defined in

index.ts:3130