Socket
Socket
Sign inDemoInstall

qaznltk

Package Overview
Dependencies
0
Maintainers
1
Alerts
File Explorer

Install Socket

Detect and block malicious and high-risk dependencies

Install

    qaznltk

A package for working with Kazakh language text processing.


Maintainers
1

Readme



QazNLTK: a package for working with Kazakh language text processing.

PyPI Latest Release PyPI Downloads

What is it?

QazNLTK provides developers with a fast and convenient tool for processing text in the Kazakh language. Tailored for the unique linguistic characteristics of Kazakh, this library offers a comprehensive set of tools for natural language processing, like: tokenization, sentence segmentation, evaluation similarity score and tranliteration of kazakh language cyrillic-latin.

Table of Contents

Main Features

Here are just a few of the things that qaznltk does well:

  1. Kazakh language Text Tokenizing by keyword frequencies:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

text = input("Enter text: ")
tokens = qn.tokenize(text)
print(tokens)

# Input: Біздің өміріміз үлкен өзен іспетті. Сіздің қайығыңыздың қиындықтардан жеңіл өтіп, махаббат иірімінде басқаруын жоғалтпай, бақыт сарқырамасына жетуін тілеймін!
# Output: [('өміріміз', 1), ('үлкен', 1), ('өзен', 1), ('іспетті', 1), ('сіздің', 1), ('қайығыңыздың', 1), ('қиындықтардан', 1), ('жеңіл', 1), ('өтіп', 1), ('махаббат', 1), ('иірімінде', 1), ('басқаруын', 1), ('жоғалтпай', 1), ('бақыт', 1), ('сарқырамасына', 1), ('жетуін', 1), ('тілеймін', 1)]
  1. Kazakh language Text Segmentation into sentences:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

text = input("Enter text: ")
sent_tokens = qn.sent_tokenize(text)
print(sent_tokens)

# Input: Біздің өміріміз үлкен өзен іспетті. Сіздің қайығыңыздың қиындықтардан жеңіл өтіп, махаббат иірімінде басқаруын жоғалтпай, бақыт сарқырамасына жетуін тілеймін!
# Output: ['Біздің өміріміз үлкен өзен іспетті.', 'Сіздің қайығыңыздың қиындықтардан жеңіл өтіп, махаббат иірімінде басқаруын жоғалтпай, бақыт сарқырамасына жетуін тілеймін!']
  1. Evaluate Difference score between 2 text:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

textA = input("Enter text A: ")
textB = input("Enter text B: ")
similarity_score = qn.calc_similarity(textA, textB)
print(similarity_score)

# Input: textA = "Еңбегіне қарай — құрмет, Жасына қарай — ізет.", textB = "Еңбегіне қарай табысы, Ерлігіне қарай дабысы."
# Output: 0.2222222222222222
  1. Convert Kazakh language Text from Cyrillic to Latin using ISO-9 Standard:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

text = input("Enter text: ")
latin_text = qn.convert2latin(text)
print(latin_text)

# Input: Бүгін қандай керемет күн! 
# Output: Bùgìn k̦andaj keremet kùn!
  1. Convert Kazakh language Text from Latin to Cyrillic using ISO-9 Standard:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

text = input("Enter text: ")
cyrillic_text = qn.convert2cyrillic(text)
print(cyrillic_text)

# Input: Bùgìn k̦andaj keremet kùn!
# Output: Бүгін қандай керемет күн!
  1. Sentiment Analysis of Kazakh language text [negative: -1, neutral: 0, positive: 1]:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

text = input("Enter text: ")
sentimize_score = qnltk.sentimize(text)
print(sentimize_score)

# Input: Бұл мақала өте нашар жазылған.
# Output: -1 (negative)
  1. Converting any number N into kazakh language number words [N <= 10^31]:
from qaznltk import qaznltk as qnltk
qn = qnltk.QazNLTK()

n = int(input())
print(qnltk.num2word(n))

# Input: N = 1465
# Output: бір мың төрт жүз алпыс бес

Where to get it

The source code is currently hosted on GitHub at: https://github.com/silvermete0r/QazNLTK.git

Binary installers for the latest released version are available at the Python Package Index (PyPI).

pip install qaznltk

image

The list of changes to pandas between each release can be found here. For full details, see the commit logs at https://github.com/pandas-dev/pandas.

Dependencies

  • Package was developed on built-in python functions;

License

License: MIT

Getting Help

📧 supwithproject@gmail.com

Contributing to qaznltk

All contributions, bug reports, bug fixes, documentation improvements, enhancements, and ideas are welcome.


Go to Top

FAQs


Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc