This is a simple NLP project providing a ngram model package.
Project description
Ngram Model
This is a basic python module that provides basic nlp algorithms. This is meant for instructional purposes, but my also be used for smaller projects.
Python Requirements
Any Python version 3.8 and above is supported.
Install
Install this pip package by typing the following into the command prompt:
pip install SinLP
Nmodels
To import the module function, proceed as follows:
>>> import ngrams
>>> from nmodels.gram import simple_bigram
>>> string = "Hello world, how are you"
>>> [('<START>', 'Hello'), ('Hello', 'world,'), ('world,', 'how'),
('how', 'are'), ('are', 'you'), ('you', '<END>')]
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
SiNLP-0.0.1.tar.gz
(2.6 kB
view hashes)