Metadata-Version: 2.3
Name: allianceauth-translate-tool
Version: 0.0.1
Summary: Alliance Auth LibreTranslate tool
Keywords: allianceauth,eveonline
Author-email: AaronKable <aaronkable@gmail.com>
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Classifier: Environment :: Web Environment
Classifier: Framework :: Celery
Classifier: Framework :: Django
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3 :: Only
Requires-Dist: allianceauth<5.0.0,>=4
Requires-Dist: allianceauth-discordbot<5.0.0,>=3.7.3
Requires-Dist: libretranslatepy<3.0.0,>=2.1.4
Project-URL: Home, https://github.com/Solar-Helix-Independent-Transport/allianceauth-translate-tool
Project-URL: Source, https://github.com/Solar-Helix-Independent-Transport/allianceauth-translate-tool
Project-URL: Tracker, https://github.com/Solar-Helix-Independent-Transport/allianceauth-translate-tool/issues

# AA-Translate-Tool

LibreTranslate Helpers for Alliance Auth.

https://github.com/LibreTranslate/LibreTranslate

## Features

- AA-Discordbot Cog for translation of messages on discord.

## Installation

- Install and setup LibreTranslate from its docs, configure as required.

- Install the app with your venv active or add it to your requirements.txt for Docker

```bash
pip install allianceauth-translate-tool
```
or 
```
allianceauth-translate-tool==version
```

- Add `'aatranslate',` to your INSTALLED_APPS list in local.py.

- Add the below lines to your `local.py` settings file, Changing the contexts to yours.

```python
## Settings for AA-Translate-Tool
# URL of the self hosted libretranslate instance
AA_TRANSLATIONS_URL = "http://URL_to_api:5000"
# Optional Api Key
AA_TRANSLATIONS_API_KEY= "i was generated from libretranslate"
# Languages we allow in the tool. list of ("Display Name", "language code https://libretranslate.com/languages") or leave as is for defaults
# AA_TRANSLATIONS_LANGUAGES = []
```

## Usage

![discord context menu showing app usage](docs/app_usage.png)

![bot response to clicking the app in the context menu](docs/message.png)

![bot response ](docs/translated.png)

## Libretranslate System Requirements

Seems to be CPU bound using around 2gb of memory. On a 2 core, 4gb instance it takes around a minute to translate 60 words. 

