Skip to main content

A fully functional dictionary module for Python to get the meanings, synonyms, antonyms and part-of-speech of a given word

Project description

word-information: A Fully Functional Dictionary Module for Python

word-information is a Dictionary Module for Python 3 to get definitions, synonyms, antonyms, and part-of-speech of words.

word-information uses requests and bs4 as dependencies

Installation

Installation is very simple through pip

pip install word-information

Usage

word-information is very easy to use

For example,

from wordInfo.word_information import WordInfo
word_info = WordInfo()

This is will create an instance of the WordInfo class and now it can be used to get meanings, translations etc.

For Meanings,

print (word_info.get_meaning("chair"))

This will return a python dictionary containing the part_of_speech of the word as a key and a list of dictionaries of the meaning and examples, as a value.

{'NOUN': [{'meaning': 'a seat, especially for one person, usually having four legs for support and a rest for the back and often having rests for the arms', 'examples': None}, {'meaning': 'something that serves as a chair or supports like a chair', 'examples': ' The two men clasped hands to make a chair for their injured companion'}, {'meaning': 'a seat of office or authority', 'examples': None}]}                                                                       

For Synonyms,

print (word_info.get_synonym("glory"))

This will return a list of synonyms of the given word

For Antonyms,

print (word_info.get_antonym("sad"))

This will return a list of antonyms of the given word

About

Current Version: 0.0.8 Created By Bayo Ade October 2022

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

word_information-0.0.9-py3-none-any.whl (17.4 kB view details)

Uploaded Python 3

File details

Details for the file word_information-0.0.9-py3-none-any.whl.

File metadata

File hashes

Hashes for word_information-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 3a56c3782036a4d6b17b5e64550d46e9dbba56787575de46a38f68c8fc704a7c
MD5 eb686dc3b0e3ac07d6a16a5052976c05
BLAKE2b-256 8e5183662a6e245fe91e501bf22fb1ec722c4fb329d962d57fb76661c1f2da75

See more details on using hashes here.

Supported by

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