From ff3cb991449eef0e69e99fb24a7a73d1fa260fd7 Mon Sep 17 00:00:00 2001 From: Yo'av Moshe Date: Sat, 20 Apr 2024 12:24:03 +0200 Subject: [PATCH] add docs for translations --- docs/configuration.md | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/docs/configuration.md b/docs/configuration.md index de36d149b..d42e831ea 100644 --- a/docs/configuration.md +++ b/docs/configuration.md @@ -825,6 +825,34 @@ they use underscores instead of dashes. {"deskew": true, "optimize": 3, "unpaper_args": "--pre-rotate 90"} ``` +## Translations {#translations} + +Paperless uses [Bergamot](https://browser.mt/) to automatically translate +documents locally. When this feature is used you can search in documents using +their translated version. + + !!! warning + + Translations are an optional Paperless feature and needs to be + installed using `pip install bergamot` or + `pipenv sync --categories translation` + +#### [`PAPERLESS_TRANSLATION_TARGET=`](#PAPERLESS_TRANSLATION_TARGET) {#PAPERLESS_TRANSLATION_TARGET} + +: Use this parameter to enable automatic translation of documents not already +in the target language. For example, specify `en` to translate all non-English +documents to English. + + The default is blank, which means nothing will be translated. + +#### [`PAPERLESS_TRANSLATION_MODELS=`](#PAPERLESS_TRANSLATION_MODELS) {#PAPERLESS_TRANSLATION_MODELS} + +: Use this parameter to tell Bergamot what language models to use. To see +and download models use `bergamot ls` and `bergamot download`. For example, +if you download the Ukrainian to English model using `bergamot download -m +uk-en-tiny`, you can specify `uk-en-tiny`. Use multiple models by separating +them with a comma. + ## Software tweaks {#software_tweaks} #### [`PAPERLESS_TASK_WORKERS=`](#PAPERLESS_TASK_WORKERS) {#PAPERLESS_TASK_WORKERS}