UNPKG

xinghuo-test

Version:

xinghuo

53 lines (52 loc) 1.07 kB
export declare enum ModelVersion { V2 = "V2"; } export declare const ModelVersionUrl: { V2: string; }; export declare const ChatDomain: { V2: string; }; export declare enum MessageRole { user = "user", assistant = "assistant" } export interface IChatMessage { role: MessageRole; content: string; } export interface IChatResponse { text: string; uasge: IChatUasgeResponse; } interface IChatUasgeResponse { completion_tokens: number; prompt_tokens: number; question_tokens: number; total_tokens: number; } export interface ISparkChatResponse { header: { code: number; message: string; sid: string; status: number; }; payload: { choices: { status: number; seq: number; text: [ { content: string; role: string; index: number; } ]; }; usage?: { text: IChatUasgeResponse; }; }; } export {};