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.7.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 248b8d253984c8fb6f17631d3b40f276fcafa3bc679211a4c5c8f1235f19b8d1 |
|
MD5 | f338c51e040affdb20cb25ad2b109b2c |
|
BLAKE2b-256 | d210d26733a89673385a716ab5179d429f77ea09a3e7b48cb1c2fabaeadd87af |
Close
Hashes for wiktionary_translate-0.0.7-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb0a25160afc5cb9ab72ebebed0658e93a96cbad3ed6d36e96f4a17c38ea4dd7 |
|
MD5 | 317a3c0d0f614ce1a6f4ca1aec067999 |
|
BLAKE2b-256 | 7c24602eab2d14e1994e1dd8342a2bf34c175e25ed094a1783db3b80c79831bd |