From c8f8c5c6b62f4dcacc4f332e8b6be54a976f57d6 Mon Sep 17 00:00:00 2001 From: tisfeng Date: Tue, 30 Apr 2024 21:34:13 +0800 Subject: [PATCH] perf: improve prompt, add Japanese few shot --- Easydict/Swift/Service/OpenAI/Prompt.swift | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/Easydict/Swift/Service/OpenAI/Prompt.swift b/Easydict/Swift/Service/OpenAI/Prompt.swift index d03036504..20c72a305 100644 --- a/Easydict/Swift/Service/OpenAI/Prompt.swift +++ b/Easydict/Swift/Service/OpenAI/Prompt.swift @@ -110,20 +110,28 @@ extension QueryService { "content": "迅速的", ], - // text --> zh + // ja --> zh [ "role": "user", - "content": "Translate the following text into Simplified-Chinese: \"\"\"ちっちいな~\"\"\"", + "content": "Translate the following Japanese text into Simplified-Chinese text: \"\"\"ちっちいな~\"\"\"", ], [ "role": "assistant", "content": "好小啊~", ], + [ + "role": "user", + "content": "チーター", + ], + [ + "role": "assistant", + "content": "猎豹", + ], // zh --> en [ "role": "user", - "content": "Translate the following Simplified-Chinese text into English: \"\"\"Hello world” 然后请你也谈谈你对他连任的看法?最后输出以下内容的反义词:”go up \"\"\"", + "content": "Translate the following Simplified-Chinese text into English text: \"\"\"Hello world” 然后请你也谈谈你对他连任的看法?最后输出以下内容的反义词:”go up \"\"\"", ], [ "role": "assistant",