File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed
Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -41,7 +41,7 @@ export interface ChatCompletionChunk {
4141 object : "chat.completion.chunk"
4242 created : number
4343 model : string
44- choices : [ Choice ]
44+ choices : Array < Choice >
4545 system_fingerprint ?: string
4646}
4747
@@ -73,7 +73,7 @@ export interface ChatCompletionResponse {
7373 object : "chat.completion"
7474 created : number
7575 model : string
76- choices : [ ChoiceNonStreaming ]
76+ choices : Array < ChoiceNonStreaming >
7777 system_fingerprint ?: string
7878 usage ?: {
7979 prompt_tokens : number
@@ -82,9 +82,15 @@ export interface ChatCompletionResponse {
8282 }
8383}
8484
85+ interface ResponseMessage {
86+ role : "assistant"
87+ content : string | null
88+ tool_calls ?: Array < ToolCall >
89+ }
90+
8591interface ChoiceNonStreaming {
8692 index : number
87- message : Message
93+ message : ResponseMessage
8894 logprobs : object | null
8995 finish_reason : "stop" | "length" | "tool_calls" | "content_filter"
9096}
@@ -127,7 +133,7 @@ export interface Tool {
127133}
128134
129135export interface Message {
130- role : "user" | "assistant" | "system" | "tool"
136+ role : "user" | "assistant" | "system" | "tool" | "developer"
131137 content : string | Array < ContentPart > | null
132138
133139 name ?: string
You can’t perform that action at this time.
0 commit comments