Skip to content

Commit

Permalink
op code
Browse files Browse the repository at this point in the history
  • Loading branch information
xqdoo00o committed May 9, 2024
1 parent f791ab8 commit 6f1eb40
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions internal/chatgpt/request.go
Original file line number Diff line number Diff line change
Expand Up @@ -741,10 +741,15 @@ func Handler(c *gin.Context, response *http.Response, secret *tokens.Secret, pro
}
}
}
respText := strings.Join(imgSource, "")
if respText != "" {
respText += "\n"
}
respText += previous_text.Text
if !max_tokens {
return strings.Join(imgSource, "") + "\n" + previous_text.Text, nil
return respText, nil
}
return strings.Join(imgSource, "") + "\n" + previous_text.Text, &ContinueInfo{
return respText, &ContinueInfo{
ConversationID: original_response.ConversationID,
ParentID: original_response.Message.ID,
}
Expand Down

0 comments on commit 6f1eb40

Please sign in to comment.