Python module for NAVER English-Korean and Korean-English dictionaries
Python package for NAVER English-Korean and Korean-English dictionaries
Search of both English-Korean and Korean-English dictionaries is provided.
Therefore, you should use it in Internet Environments.
Ndic supports Python 2.6–2.7 & 3.3–3.5 because Requests officially supports these versions.
Install via pip:
$ pip install ndic
The usage is very simple.
Begin by importing the Ndic module:
>>> import ndic
Entering an English word as the search function argument will return the corresponding Korean word(s).
>>> ndic.search('apple') '사과'
Conversely, entering a Korean word as the search function argument will return the corresponding English word(s).
>>> ndic.search('안녕하세요') 'Hi!'
Phrases may also be searched.
>>> ndic.search('in order to') '(목적) 위하여'
Entering a nonexistent word as the search function argument will return the empty string.
>>> ndic.search("aslkjfwe") '' >>> ndic.search("아댜리야") ''
If your network connection is lost, you will get below error message.
>>> ndic.search('...') NdicConnectionError: Network connection is lost. Please check the connection to the Internet.
Furthermore, Ndic supports CLI(Command Line System).
So you can use it in command line and get the return value of the search fuction in terminals. It works by Click.
$ ndic love (특히 가족・친구에 대한) 사랑