Get English translations of foreign word with Wiktionary
Project description
wiktionary_translate
Get English translations of foreign word with Wiktionary
Usage
You can only get the English definitions of foreign words
from src.wiktionary_translate.wiktionary_translate import WiktionaryResult
if __name__ == "__main__":
wr = WiktionaryResult()
if wr.query(word="essen", lang="de"):
print(wr.definitions) # ['to eat']
print(wr.partOfSpeech) # Verb
print(wr.definitionList[0].parsedExamples) # {'Er isst gern Schokolade.': 'He likes eating chocolate.', '...}
print(wr.definitionList[0].examples) # ['Er isst gern Schokolade.', 'Ich esse einen Apfel.']
print(wr.definitionList[0].definition) # to eat
print(wr.rawResult) # {'other': [{'partOfSpeech': 'Verb', 'language': 'Alemannic German', ...
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for wiktionary_translate-0.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 184970ed81ef3953d051f5cac408e383e082d91ea60a2bef941c278559ce4060 |
|
MD5 | f1bb1e5144f156e5ed3a249e945cb7c9 |
|
BLAKE2b-256 | 2d731aa8821f83ae44ad49d5c3fb28aef39c1e30db7fe9e9e5e2adad3bc289c9 |
Close
Hashes for wiktionary_translate-0.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f0827dd4b2df9e2a6c4a5608b9e249914623579d1997f020b61dc0ccea92723a |
|
MD5 | 422b933d600bba40cccbcc617a1ffed3 |
|
BLAKE2b-256 | 5e48e1fdd0fa2d4f0075b7988762f5b76f7cd26eeac0c6104688e993514c5791 |