Skip to main content

A flask web API for translating between traditional English spellings and alternative spellings

Project description

Altspell

Flask web app for translating traditional English to respelled English and vice versa.

Quick Start

Execute the following commands to get the web API up and running:

# Activate virtual environment
python3 -m venv venv
source venv/bin/activate

# Install main program
pip install git+https://github.com/Inglish-Respelling-Project/altspell

# Install main program dependency
pip install git+https://github.com/Inglish-Respelling-Project/altspell-plugins

# Install a few plugins
pip install git+https://github.com/Inglish-Respelling-Project/altspell-lytspel  \
            git+https://github.com/Inglish-Respelling-Project/altspell-portul  \
            git+https://github.com/Inglish-Respelling-Project/altspell-universal-lojikl-inglish

# Install plugin dependency
pip install git+https://github.com/Inglish-Respelling-Project/nlp-provider

# Start web API
flask --app altspell run

Example HTTP requests:

# List available spelling systems
curl -X GET -H "Accept: application/json" http://127.0.0.1:5000/api/spelling-systems

# Perform forward translation and save the result in the database
curl -X POST -H "Accept: application/json" -H "Content-Type: application/json" -d  '{
    "text": "Hello, world!",
    "spellingSystem": "lytspel",
    "forward": true,
    "save": true
}' http://127.0.0.1:5000/api/translations

# Retrieve the saved result from the database
# translation_id comes from the HTTP response of the previous command
curl -X GET -H "Accept: application/json" http://127.0.0.1:5000/api/translations/{translation_id}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

altspell-0.2.0.tar.gz (10.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

altspell-0.2.0-py3-none-any.whl (17.9 kB view details)

Uploaded Python 3

File details

Details for the file altspell-0.2.0.tar.gz.

File metadata

  • Download URL: altspell-0.2.0.tar.gz
  • Upload date:
  • Size: 10.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for altspell-0.2.0.tar.gz
Algorithm Hash digest
SHA256 46919d1359b28abc1380edf72fa9d8283c8a82a086084a1fa917fbfe5e5194ff
MD5 0f44d27ed8f85042b92fd4bf6085b83f
BLAKE2b-256 3e8296a366fcedafe0bf72cb0af38c6733800e08fbdafd98dbe25898981de8b6

See more details on using hashes here.

File details

Details for the file altspell-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: altspell-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 17.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.1

File hashes

Hashes for altspell-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6f545fcbaf58b8f98dd01ac2a2e5cd5f71334ac04dce10004300ba464866ecd3
MD5 7344ed154d7e078dc12b5d2f56798566
BLAKE2b-256 cd7587b22de32266f8790ab6b51e531ac9ab77f45cc988a9679a329601159921

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page