ab2xy: ChatGPT language translation shortcuts
Output will be a valid translation, where ab, xy are both valid 2-letter ISO 639-1 codes
Did you know that you can quickly translate between two languages using GPT-3.5+ models with a simple shortcut? By taking any two 2-character language ISO codes (such as EN, ES, FR, JP, and so on), putting a “2” in between them (short for “to”), and adding a colon prefix-suffix before the sentence you want to translate, GPT-3.5 can translate it into the other language. This is a very efficient way to save tokens and not have to provide a long natural language explanation for each translation request.
GPT-3.5's ability to flexibly understand the relationships between language-key and requested translation action correspondences is truly remarkable. I am at the GPT-4 cap, but I think it handles colloquialisms better. To give you an idea of how flexible and powerful this feature is, here are some examples of translations using different phrases across several languages:
"es2fr: ¡Hola, cómo estás!"
Translation: "Salut, comment vas-tu ?"
"ko2ja: 안녕하세요, 오늘은 날씨가 좋네요."
Translation: "こんにちは、今日は天気が良いですね。"
"ru2uk: Я люблю слушать музыку в свободное время."
Translation: "Я люблю слушати музику в вільний час."
"it2de: Mi piace mangiare la pizza italiana."
Translation: "Ich mag es, italienische Pizza zu essen."
"fr2es: Je voudrais une tasse de café s'il vous plaît."
Translation: "Me gustaría una taza de café, por favor."
"hi2te: मुझे अपनी किताबें पढ़ना बहुत पसंद है।"
Translation: "నా పుస్తకాలు చదవడం నాకు చాలా ఇష్టం."
"pt2ar: Eu gosto de comer pizza com amigos."
Translation: "أنا أحب تناول البيتزا مع الأصدقاء."
"nl2de: Ik ga morgen op vakantie naar Spanje."
Translation: "Ich werde morgen in den Urlaub nach Spanien gehen."
"fi2sv: Minä pidän lukea kirjoja vapaa-aikana."
Translation: "Jag tycker om att läsa böcker på min fritid."
You can ask it also to create more colloquial translations, which it seems to perform a little bit more poorly (with some fine-tuning, perhaps this would have better outcomes):
"es2fr: ¡Hola, ¿cómo estás?"
Translation: "Salut, comment ça va ?" (I would have expected “Salut, ça va?” or something at least non-identical to initial response)
"ko2ja: 안녕하세요, 오늘은 날씨가 좋네요."
Translation: "こんにちは、今日は天気が良いね。"
"ru2uk: Я люблю слушать музыку в свободное время."
Translation: "Я люблю слушать музыку, когда у меня есть свободное время."
"it2de: Mi piace mangiare la pizza italiana."
Translation: "Ich liebe es, italienische Pizza zu essen."
"fr2es: Je voudrais une tasse de café s'il vous plaît."
Translation: "Me pones una taza de café, por favor."
"hi2te: मुझे अपनी किताबें पढ़ना बहुत पसंद है।"
Translation: "मुझे फ्री टाइम में बुक्स पढ़ना बहुत पसंद है।"
"pt2ar: Eu gosto de comer pizza com amigos."
Translation: "Eu adoro comer pizza com os amigos."
"nl2de: Ik ga morgen op vakantie naar Spanje."
Translation: "Ich mache morgen Urlaub in Spanien."
"fi2sv: Minä pidän lukea kirjoja vapaa-aikana."
Translation: "Jag gillar att läsa böcker på min fritid."
Very useful shortcut to save tokens and not need to prime ChatGPT or whatever API you’re using each time with a long natural language explanation of your translation endeavors. If you have any knowledge of the mentioned languages or criticisms of the first vs. second version prompts, please retweet/comment or ask below 👇