tldrtranslate
ikks/tldrtranslate
A helper on tldrtranslation that uses argos
ikks/tldrtranslate
A helper on tldrtranslation that uses argos
This is a helper to translate tldr pages, the list of supported languages is:
https://github.com/user-attachments/assets/b81b3895-aa8d-443b-84d5-057d9ecc4041
The workflow is:
tldrtranslate
translates from English to the language you desire.If you are having problems getting the API and argos-translate to run, please ask in https://app.element.io/#/room/#tldr-pages:matrix.org , maybe there is someone that can put a server for your use.
Suppose you aim to translate pages/common/argos-translate.md
to it
, you will run:
tldrtranslate -l it pages/common/argos-translate.md
tldrtranslate
will output the translation to pages.it/common/argos-translate.md
, overwriting the file if it existed
You can use relative or absolute paths, as soon as you include the hierarchy from pages
directory.
You can set the following ENV_VARS to change the default configurations:
es
(spanish) localhost
8000
each one of them is superseeded by the option of the command line
And issue
zig build
Under zig-out/bin/
should be present tldrtranslate
for your use.
Feel free to clone and modify to suit your needs.
You will need to have python, argos-translate and api argos-translate or Docker and some Gigas of space for the models and the needed infrastructure.
Have an Argos-API locally. To run it, with your language pairs you can issue on your virtualenv:
fastapi dev main
If your language is in the list of supported languages by Argos-translate, just download the required package to your running environment. For example for portuguese argospm install translate-en_pt
, is the same for PT or BR.
If your language is not supported by Argos-translate, you can open an issue in Argos-translate.
If you want to have consistent translations, there are some words that can be replaced befor the translation process, please look here.