@types/node-replicate
TypeScript icon, indicating that this package has built-in type declarations

2.0.4 • Public • Published

Installation

npm install --save @types/node-replicate

Summary

This package contains type definitions for node-replicate (https://github.com/oelin/node-replicate#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node-replicate.

index.d.ts

export interface Prediction {
    uuid: string;
    version_id: string;
    created_at: string;
    updated_at: string;
    complete_at: string | null;
    status: "starting" | "processing" | "canceled" | "succeeded" | "failed";
    inputs: any;
    output: unknown;
    output_files?: string[];
    error: string | null;
    run_logs: string | null;
    version: {
        config: {
            build: Record<string, string>;
            predict: string;
        };
        docker_image_id: string;
        docker_image_name: string;
        openapi_schema: {
            info: Record<string, string>;
            paths: Record<string, string>;
            openapi: string;
            components: Record<string, string>;
        };
        model: {
            absolute_url: string;
            username: string;
            name: string;
            description: string;
            visibility: string;
            is_run_only: boolean;
            github_url: string;
            paper_url: string;
            arxiv_paper_id: string;
            cover_image: Record<string, string>;
            latest_version_created_at: string | null;
            default_example_uuid: string;
            display_output_as_json: boolean;
        };
    };
    user: string | null;
}

export interface Replicate {
    run(model: string, inputs: any): Promise<unknown>;
    get(prediction: Prediction): Promise<Prediction>;
    create(model: string, inputs: any): Promise<Prediction>;
}

export const replicate: Replicate;

export default replicate;

Additional Details

  • Last updated: Tue, 07 Nov 2023 09:09:39 GMT
  • Dependencies: none

Credits

These definitions were written by Ankan Bhattacharya.

Readme

Keywords

none

Package Sidebar

Install

npm i @types/node-replicate

Weekly Downloads

14

Version

2.0.4

License

MIT

Unpacked Size

5.69 kB

Total Files

5

Last publish

Collaborators

  • types