Add translation module for Argos Translate #351
No reviewers
Labels
No labels
approved, awaiting change
bug
configuration
documentation
duplicate
enhancement
extremely low priority
feature request
Fix it yourself
help wanted
invalid
mastodon_api
needs docs
needs tests
not a bug
planned
pleroma_api
privacy
question
static_fe
triage
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: AkkomaGang/akkoma#351
Loading…
Reference in a new issue
No description provided.
Delete branch "ilja/akkoma:add_translator_argos_translate"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Argos Translate is a Python module for translation and can be used as a command line tool.
This is also the engine for LibreTranslate, for which we already have a module.
Here we can use the engine directly from our server without doing requests to a third party or having to install our own LibreTranslate webservice (obviously you do have to install Argos Translate).
One thing that's currently still missing from Argos Translate is auto-detection of languages (see https://github.com/argosopentech/argos-translate/issues/9). For now, when no source language is provided, we just return the text unchanged, supposedly translated from the target language. That way you get a near immediate response in pleroma-fe when clicking Translate, after which you can select the source language from a dropdown.
Argos Translate also doesn't seem to handle html very well. Therefore we give admins the option to strip the html before translating. I made this an option because I'm unsure if/how this will change in the future.
Add translation module for Argos Translateto WIP: Add translation module for Argos Translate6b9bdb3c64
to6aceeb7220
WIP: Add translation module for Argos Translateto Add translation module for Argos Translateseems to work!
any chance you can update config/description.exs for admin-fe stuff and add a changelog entry?
444833fde2
toeee77a1727
eee77a1727
tod5b3d9104d
you've got a linting issue
but i'll fix that, thanks!