Skip to content

Commit

Permalink
🐛 fix: fix minimax streaming request without calculating token (lobeh…
Browse files Browse the repository at this point in the history
  • Loading branch information
MartialBE committed Mar 13, 2024
1 parent d941faa commit 3d60f94
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions providers/minimax/chat.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,9 @@ func (h *minimaxStreamHandler) convertToOpenaiStream(miniResponse *MiniMaxChatRe
streamResponse.ID = miniResponse.ID
openaiChoice.FinishReason = convertFinishReason(miniChoice.FinishReason)
dataChan <- h.getResponseString(&streamResponse, &openaiChoice)
if miniResponse.Usage != nil {
h.handleUsage(miniResponse)
}
return
}

Expand Down

0 comments on commit 3d60f94

Please sign in to comment.