Free and Open Source Machine Translation API. Self-hosted, offline capable and easy to setup.
49 matches across 7 categories. Click a row to expand file-level details.
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | libretranslate/suggestions.py | 16 | except Exception as e: |
| LOW | libretranslate/cache.py | 35 | except Exception as e: |
| LOW | libretranslate/cache.py | 47 | except Exception as e: |
| MEDIUM | libretranslate/cache.py | 40 | def cache(self, cache_key, content): |
| LOW | libretranslate/language.py | 88 | except Exception as e: |
| LOW | libretranslate/locales.py | 26 | except Exception as e: |
| LOW | libretranslate/app.py | 65 | except Exception: |
| LOW | libretranslate/app.py | 877 | except Exception as e: |
| LOW | libretranslate/app.py | 1026 | except Exception as e: |
| MEDIUM | libretranslate/app.py | 55 | def get_version(): |
| LOW | libretranslate/api_keys.py | 20 | except Exception as e: |
| LOW | libretranslate/api_keys.py | 100 | except Exception as e: |
| LOW | libretranslate/init.py | 14 | except Exception as e: |
| MEDIUM | libretranslate/init.py | 8 | def boot(load_only=None, update_models=False, install_models=False): |
| MEDIUM | scripts/update_locales.py | 25 | print("Error: English model not found. You need it to run this script.") |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | libretranslate/secret.py | 25 | |
| LOW | libretranslate/language.py | 70 | |
| LOW | libretranslate/language.py | 128 | |
| LOW | libretranslate/locales.py | 11 | |
| LOW | libretranslate/locales.py | 77 | |
| LOW | libretranslate/app.py | 132 | |
| LOW | libretranslate/app.py | 194 | |
| LOW | libretranslate/app.py | 333 | |
| LOW | libretranslate/app.py | 577 | |
| LOW | libretranslate/app.py | 335 | |
| LOW | libretranslate/manage.py | 8 | |
| LOW | libretranslate/init.py | 18 | |
| LOW | scripts/gunicorn_conf.py | 10 |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | libretranslate/language.py | 50 | def get_language_with_fallback(lang_code, languages): |
| LOW | libretranslate/language.py | 128 | def improve_translation_formatting(source, translation, improve_punctuation=True, remove_single_word_duplicates=True): |
| LOW | libretranslate/locales.py | 39 | def get_available_locale_codes(only_reviewed=True): |
| LOW | libretranslate/locales.py | 43 | def get_alternate_locale_links(): |
| LOW | libretranslate/tests/test_api/test_api_translate.py | 35 | def test_api_translate_unsupported_language(client): |
| LOW | libretranslate/tests/test_api/test_api_translate.py | 50 | def test_api_translate_missing_parameter(client): |
| LOW | …translate/tests/test_api/test_api_frontend_settings.py | 1 | def test_api_get_frontend_settings(client): |
| LOW | libretranslate/tests/test_api/test_api_health.py | 8 | def test_api_health_must_fail_bad_request_type(client): |
| LOW | libretranslate/tests/test_api/test_api_get_languages.py | 13 | def test_api_get_languages_must_fail_bad_request_type(client): |
| LOW | libretranslate/tests/test_api/test_api_spec.py | 7 | def test_api_get_spec_must_fail_bad_request_type(client): |
| LOW | …retranslate/tests/test_api/test_api_detect_language.py | 15 | def test_api_detect_language_must_fail_without_parameters(client): |
| LOW | …retranslate/tests/test_api/test_api_detect_language.py | 23 | def test_api_detect_language_must_fail_bad_request_type(client): |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | libretranslate/__init__.py | 1 | |
| LOW | libretranslate/__init__.py | 2 | |
| LOW | libretranslate/__init__.py | 3 | |
| LOW | libretranslate/app.py | 8 | |
| LOW | libretranslate/main.py | 4 |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | docker-compose.cuda.yml | 21 | reservations: |
| LOW | docker-compose.yml | 21 | # - LT_API_KEYS=true |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | libretranslate/language.py | 113 | # otherwise just add it to the temporary list |
| Severity | File | Line | Snippet |
|---|---|---|---|
| LOW | scripts/entrypoint.sh | 51 | # Set ARGOS_CHUNK_TYPE to MINISBD if not already defined |