Pārlūkot izejas kodu

Changing chatgpt model

Karol Sokolowski 1 gadu atpakaļ
vecāks
revīzija
0e4fc3e689
1 mainītis faili ar 3 papildinājumiem un 2 dzēšanām
  1. 3 2
      chatgpt.go

+ 3 - 2
chatgpt.go

@@ -2,8 +2,9 @@ package chatgpt
 
 import (
 	"context"
-	gogpt "github.com/sashabaranov/go-gpt3"
 	"time"
+
+	gogpt "github.com/sashabaranov/go-gpt3"
 )
 
 type ChatGPT struct {
@@ -73,7 +74,7 @@ func (c *ChatGPT) Chat(question string) (answer string, err error) {
 		question = question[:c.maxText-c.maxAnswerLen]
 	}
 	req := gogpt.CompletionRequest{
-		Model:            gogpt.GPT3TextDavinci003,
+		Model:            gogpt.GPT3Dot5Turbo,
 		MaxTokens:        c.maxAnswerLen,
 		Prompt:           question,
 		Temperature:      0.9,