Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Add support for Arabic as a source/target language #48

Merged
merged 1 commit into from
May 19, 2024

Conversation

kill9zombie
Copy link
Contributor

Description

Deepl now supports Arabic for text translation:

https://developers.deepl.com/docs/resources/supported-languages#target-languages

While Arabic isn't supported for document translation, it is supported for text translation now.

Type of change

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

  • With the following .exs script (and an appropriate Deepl API key in ~/.deepl.apikey):
# scripts/arabic-test.exs
key = File.read!("#{System.get_env("HOME")}/.deepl.apikey")
Application.put_env(:deepl_ex, :api_key, String.trim(key))

DeeplEx.translate("hello", :EN, :AR) |> IO.inspect()
DeeplEx.translate("مرحباً", :AR, :EN) |> IO.inspect()
  • Run using mix run
mix run scripts/arabic-test.exs

{:ok, "مرحباً"}
{:ok, "Hey there."}

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • My changes generate no new warnings

@dustessavdh dustessavdh changed the title Add support for Arabic as a source/target language [Feature]: Add support for Arabic as a source/target language May 19, 2024
Copy link
Member

@dustessavdh dustessavdh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@dustessavdh
Copy link
Member

Thank you for your PR, I'll merge it soon and make a new release!

@dustessavdh dustessavdh merged commit d25c2e2 into hergetto:development May 19, 2024
5 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants