From d4f3b14e47773d0c025aefde21ee063ab00d4266 Mon Sep 17 00:00:00 2001 From: Sercan Altundas Date: Thu, 18 Jul 2024 23:17:00 +0300 Subject: [PATCH 1/2] use gpt-4o-mini --- Samples~/ChatGPT/ChatGPT.cs | 2 +- Samples~/Stream Response/StreamResponse.cs | 2 +- Tests/ChatApiTests.cs | 4 ++-- Tests/ModelsApiTests.cs | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Samples~/ChatGPT/ChatGPT.cs b/Samples~/ChatGPT/ChatGPT.cs index 29cbf78..294d14b 100644 --- a/Samples~/ChatGPT/ChatGPT.cs +++ b/Samples~/ChatGPT/ChatGPT.cs @@ -58,7 +58,7 @@ private async void SendReply() // Complete the instruction var completionResponse = await openai.CreateChatCompletion(new CreateChatCompletionRequest() { - Model = "gpt-3.5-turbo", + Model = "gpt-4o-mini", Messages = messages }); diff --git a/Samples~/Stream Response/StreamResponse.cs b/Samples~/Stream Response/StreamResponse.cs index 90d7bb4..05e55d5 100644 --- a/Samples~/Stream Response/StreamResponse.cs +++ b/Samples~/Stream Response/StreamResponse.cs @@ -34,7 +34,7 @@ private void SendMessage() openai.CreateChatCompletionAsync(new CreateChatCompletionRequest() { - Model = "gpt-3.5-turbo", + Model = "gpt-4o-mini", Messages = message, Stream = true }, HandleResponse, null, token); diff --git a/Tests/ChatApiTests.cs b/Tests/ChatApiTests.cs index 46d9b90..0e3b942 100644 --- a/Tests/ChatApiTests.cs +++ b/Tests/ChatApiTests.cs @@ -16,7 +16,7 @@ public async Task Create_Chat_Completion() { var req = new CreateChatCompletionRequest { - Model = "gpt-3.5-turbo", + Model = "gpt-4o-mini", Messages = new List() { new ChatMessage() { Role = "user", Content = "Hello!" } @@ -35,7 +35,7 @@ public async Task Create_Chat_Completion_Stream() var req = new CreateChatCompletionRequest { - Model = "gpt-3.5-turbo", + Model = "gpt-4o-mini", Messages = new List() { new ChatMessage() { Role = "user", Content = "Hello!" } diff --git a/Tests/ModelsApiTests.cs b/Tests/ModelsApiTests.cs index 549251e..26afe76 100644 --- a/Tests/ModelsApiTests.cs +++ b/Tests/ModelsApiTests.cs @@ -17,7 +17,7 @@ public async Task List_Models() [Test] public async Task Retrieve_Models() { - var id = "gpt-3.5-turbo"; + var id = "gpt-4o-mini"; var models = await openai.RetrieveModel(id); Assert.AreEqual(id, models.Id); } From d866f80775d1e975a03f5016c962128a674a0258 Mon Sep 17 00:00:00 2001 From: Sercan Altundas Date: Thu, 18 Jul 2024 23:27:45 +0300 Subject: [PATCH 2/2] version bump --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 5ffc81e..703fec9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "com.srcnalt.openai-unity", - "version": "0.2.1", + "version": "0.2.2", "displayName": "OpenAI Unity", "description": "An unofficial OpenAI Unity package that aims to help you use OpenAI API directly in Unity game engine.", "unity": "2020.3",