All Projects → bl0cknumber → idnaive

bl0cknumber / idnaive

Licence: MIT License
🧠 A Simple Node.js Naive Bayes Library.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to idnaive

text-classification-cn
中文文本分类实践,基于搜狗新闻语料库,采用传统机器学习方法以及预训练模型等方法
Stars: ✭ 81 (+211.54%)
Mutual labels:  naive-bayes
Amazon-Fine-Food-Review
Machine learning algorithm such as KNN,Naive Bayes,Logistic Regression,SVM,Decision Trees,Random Forest,k means and Truncated SVD on amazon fine food review
Stars: ✭ 28 (+7.69%)
Mutual labels:  naive-bayes
LMPHP
Multi-language management and support on the site.
Stars: ✭ 19 (-26.92%)
Mutual labels:  multi-language
beagle
Beagle helps you identify keywords, phrases, regexes, and complex search queries of interest in streams of text documents.
Stars: ✭ 46 (+76.92%)
Mutual labels:  stemming
Onion Rime Files
電腦 Rime 洋蔥方案(注音、雙拼、拼音、形碼、行列30)
Stars: ✭ 88 (+238.46%)
Mutual labels:  multi-language
ml
经典机器学习算法的极简实现
Stars: ✭ 130 (+400%)
Mutual labels:  naive-bayes
cazary
jQuery plugin of WYSIWYG editor that aims for fast, lightweight, stylish, customizable, cross-browser, and multi-language.
Stars: ✭ 12 (-53.85%)
Mutual labels:  multi-language
lancaster-stemmer
Lancaster stemming algorithm
Stars: ✭ 22 (-15.38%)
Mutual labels:  stemming
morphir
A universal language for business and technology
Stars: ✭ 70 (+169.23%)
Mutual labels:  multi-language
jekyll-skeleton
Scaffolding to start with a Jekyll website
Stars: ✭ 27 (+3.85%)
Mutual labels:  multi-language
lisan
🌈i18n, Reimagined! 🚀A blazing fast and super small i18n library for Javascript
Stars: ✭ 85 (+226.92%)
Mutual labels:  multi-language
sjm
Sancho McCann's PhD Thesis Research Code
Stars: ✭ 24 (-7.69%)
Mutual labels:  naive-bayes
CODER
CODER: Knowledge infused cross-lingual medical term embedding for term normalization. [JBI, ACL-BioNLP 2022]
Stars: ✭ 24 (-7.69%)
Mutual labels:  multi-language
scoruby
Ruby Scoring API for PMML
Stars: ✭ 69 (+165.38%)
Mutual labels:  naive-bayes
create-bazel-workspace
Generate a new polyglot Bazel workspace with minimal configuration
Stars: ✭ 16 (-38.46%)
Mutual labels:  multi-language
sentiment-analysis-using-python
Large Data Analysis Course Project
Stars: ✭ 23 (-11.54%)
Mutual labels:  naive-bayes
react-native-multi-language-app
Multi Language example app with react native
Stars: ✭ 26 (+0%)
Mutual labels:  multi-language
CISTEM
Stemmer for German
Stars: ✭ 33 (+26.92%)
Mutual labels:  stemming
rippletagger
RippleTagger identifies part-of-speech tags (Nouns, Verbs, and so on...). You give it a sentence, it gives you a list of tags back.
Stars: ✭ 12 (-53.85%)
Mutual labels:  multi-language
textstem
Tools for fast text stemming & lemmatization
Stars: ✭ 36 (+38.46%)
Mutual labels:  stemming

Idnaive

idnaive - A Simple Node.js Naive Bayes Library

Idnaive is A Simple Node.js Naive Bayes Library.

Multilanguage Stemming (Indonesia + English)
Out String Filter
Punctuation Filter
Fix Zero-Frequency Problem

Installation

npm install idnaive

Usage

const NaiveBayes = require("idnaive");

const naiveBayes = new NaiveBayes("en");

const datasets = [
  ["You're doing good and expressive", "positive"],
  ["You're doing wow and nice", "positive"],
  ["What is this? very waste of time, and bad", "negative"],
];

naiveBayes.learn(...datasets);

let result = naiveBayes.classify(
  "This is bad, and you should try better because it waste my time"
);
console.log(result);

Datasets example :

Data Label
Hello World Inggris
Hello World Inggris
Hello World Arab
Kun Fayakun Arab

Input Data : Aku suka makan hello world

Calculation

Label | Inggris = 2/4
Label | Arab = 2/4

Hello World | Inggris = 2/2
Hello World | Arab = 1/2

P | Inggris = 2/4 x 2/2 = 0.5
P | Arab = 2/4 X 1/2 = 0.25

Parameters

  • new NaiveBayes(languageCode)
    • languageCode: languageCode determines what language used for stemming by the language code. currently idnaive supports id (Indonesia) and en (English).

License

Idnaive licensed by MIT License

Contribute

Before contributing, please read the following CODE_OF_CONDUCT.md and CONTRIBUTING.md.

Credits

Credits to their amazing open source:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].