Skip to main content

No project description provided

Project description

client.marian

A client for interacting with Marian-NMT websocket server (see MarianNMT).

Usage

from marian_client import MarianClient

host = "0.0.0.0" 
port = "5000"

mc = MarianClient(PORT=port, HOST=host)

tokenized_sentence = "Alice like cats ."

success, corrected_sentence, error_info = mc(tokenized_sentence)

if success:
    print(corrected_sentence)
else:
    print(f"Call to MarianClient failed with error code {error_info[0]} and message {error_info[1]}")

Installation

pip install marian-client

License

Unlicensed.

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

marian-client-0.8.0.tar.gz (2.3 kB view details)

Uploaded Source

File details

Details for the file marian-client-0.8.0.tar.gz.

File metadata

  • Download URL: marian-client-0.8.0.tar.gz
  • Upload date:
  • Size: 2.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/42.0.1 requests-toolbelt/0.9.1 tqdm/4.39.0 CPython/3.6.8

File hashes

Hashes for marian-client-0.8.0.tar.gz
Algorithm Hash digest
SHA256 c24996c8d400078eb7937a1767e9b34a21fce025d3ec9a0f9ca22a9df3f68aab
MD5 8f2282565492319153ce1ca71c1a9eb5
BLAKE2b-256 75140272b1ec3d0e87c3ed58c3c505b7aa6654491d8a91dafb8a3133d3d09440

See more details on using hashes here.

Supported by

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