Skip to content

Commit 20be8e7

Browse files
authored
Merge pull request #10 from kojira/feature/public_chat
gpt4o miniに修正
2 parents ca25fc6 + 4a165eb commit 20be8e7

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/gpt.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,14 @@ use std::env;
77
use tokio::time::timeout;
88
use openai_api_rs::v1::api::Client;
99
use openai_api_rs::v1::chat_completion::{self, ChatCompletionRequest};
10-
use openai_api_rs::v1::common::GPT3_5_TURBO;
1110

1211

1312
pub async fn call_gpt(prompt: &str, user_text: &str) -> Result<String, Box<dyn Error>> {
1413
dotenv().ok();
1514
let api_key = env::var("OPEN_AI_API_KEY").expect("OPEN_AI_API_KEY is not set");
1615
let client = Client::new(api_key);
1716
let req = ChatCompletionRequest::new(
18-
GPT3_5_TURBO.to_string(),
17+
"gpt-4o-mini".to_string(),
1918
vec![
2019
chat_completion::ChatCompletionMessage {
2120
role: chat_completion::MessageRole::system,

0 commit comments

Comments
 (0)