Git Product home page Git Product logo

bashkirtagger's Introduction

A Python LSTM-based POS-tagger for Bashkir language

This module contains a utility for part-of-speech tagging of Bashkir text. The tool based on LSTM neural network and takes a word order into account.

Installation

The tool could be installed with pip

pip3 install bashkirtagger

Note: the model for the utility must be downloaded separately. Due to limitations on the size of the project, I could not place it on a github or PiPy. After launching the program it will download and unpack the model. No action is necessary on your part. But you will need an Internet connection and about 150 megabytes of incoming traffic.

Usage example

Tagging one sentence at a time

>>> from bashkirtagger import Tagger
>>> t = Tagger()
>>> sentence = "Бер кеше йәшәй."
>>> tagged_sentence = t.predict_pos(sentence)
>>> print(tagged_sentence)
[('бер', 'NUM'), ('кеше', 'S'), ('йәшәй', 'V')]

Tagging a text of several sentences

>>> from bashkirtagger import Tagger
>>> t = Tagger()
>>> text = "Бер кеше йәшәй. Кем белә."
>>> tagged_text = t.text_prc(text)
>>> print(tagged_text)
[[('бер', 'NUM'), ('кеше', 'S'), ('йәшәй', 'V')], [("кем", "SPRO"), ("белә", "V")]]

Tagset

Tagset based on Bashmorph morphological analyzer for Bashkir language by Boris Orekhov.

  • S: substantive
  • V: verb
  • ADJ: adjective
  • NUM: numeral
  • SPRO: pronoun
  • PART: particle
  • INTJ: interjunction
  • POST: postposition
  • CONJ: conjunction

See the paper for the details.

Data

The model trained on collected from the web Bashkir text corpus which was marked up by Bashmorph.

This tool can be used for disambiguation of rule-based markup.

You can make your own wrap of the trained model.

Model's evaluation: loss: 0.0015 - acc: 0.9996 - val_loss: 0.0975 - val_acc: 0.9847.

Contacts

You can contact the contriutor of the project via email:

Boris Orekhov (nevmenandr)

@ gmail

bashkirtagger's People

Contributors

nevmenandr avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.