Skip to main content

Find the Kashmiri meaning of given English word.

Project description

Kaeshir Dictionary

A free, open source database of Kashmiri words which is my own work and I'm opening it for everyone. You can use, modify and distribute it for any purpose.

pip install kashmiri

You can check my app Kaeshir Dictionary

Use the find() fucntion to get the Kashmiri meaning of corresponding English word as a python dictionary.

>>> from kashmiri import find
>>> from pprint import pprint
>>>
>>> find("admire")
{'title': 'Admire', 'pos': '/ əd-ˈmī(-ə)r/, verb', 'englishMeaning': 'Khosh karun ', 'kashmiriMeaning': 'خۄش کران', 'englishExample': 'I admire Manika.', 'kashmiriExample': 'Winni chai kaem chalan'}
>>>
>>> x = find('about')
>>> pprint(x)
{'englishExample': 'What do you think about me?',
 'englishMeaning': 'Mutalik',
 'kashmiriExample': 'Tsai kya ba:sa:n mai mutalik?',
 'kashmiriMeaning': 'مُتعلِق',
 'pos': '/ ə-ˈbau̇t/, adverb',
 'title': 'About'}
>>> 
  • If the given word is not found, a string saying Not Found will be displayed.
>>> find('grep')
Not Found
>>> 
  • Search is Case Insensitive
>>> find('account')
{'title': 'Account', 'pos': '/ ə-ˈkau̇nt/, noun', 'englishMeaning': 'Hisa:b', 'kashmiriMeaning': 'حِساب', 'englishExample': 'She was asked to give an account of her actions.', 'kashmiriExample': 'Winni chai kaem chalan'}
>>> 
>>> find('aCcOuNt')
{'title': 'Account', 'pos': '/ ə-ˈkau̇nt/, noun', 'englishMeaning': 'Hisa:b', 'kashmiriMeaning': 'حِساب', 'englishExample': 'She was asked to give an account of her actions.', 'kashmiriExample': 'Winni chai kaem chalan'}
>>> 
  • AssertionError will be thrown if you search for some gibberish
>>> find("osama bin laden")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/izan/Documents/Kaeshir-Database/kashmiri/kashmiri.py", line 5, in find
    assert word.isalpha(), "You might be a Haput, else you could have entered a correct word."
AssertionError: You might be a Haput, else you could have entered a correct word.
>>> 
  • Get access to whole database in the form of tuple using data variable in database file
>>> from kashmiri.database import data
>>> data[0]
{'title': 'Abandoned', 'pos': '/ ə-ˈban-dənd/, adjective', 'englishMeaning': 'Trovmut (m.)', 'kashmiriMeaning': 'ترٛومُت', 'englishExample': 'An abandoned factory.', 'kashmiriExample': 'Akh traivmich factry.'}
>>> 

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

kashmiri-0.0.2.tar.gz (233.7 kB view hashes)

Uploaded Source

Supported by

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