All Projects → rajveermalviya → language-modeling

rajveermalviya / language-modeling

Licence: MIT license
This is machine learning model that is trained to predict next word in the sequence. Model is defined in keras and then converted to tensorflow-js model for the web, check the web implementation at

Programming Languages

python
139335 projects - #7 most used programming language
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to language-modeling

Nsfwjs
NSFW detection on the client-side via TensorFlow.js
Stars: ✭ 5,223 (+11012.77%)
Mutual labels:  tensorflowjs
anomagram
Interactive Visualization to Build, Train and Test an Autoencoder with Tensorflow.js
Stars: ✭ 152 (+223.4%)
Mutual labels:  tensorflowjs
js-gym
Reinforcement learning in JavaScript & Node.js
Stars: ✭ 50 (+6.38%)
Mutual labels:  tensorflowjs
handwritten-digit-recognition-tensorflowjs
In-Browser Digit recognition with Tensorflow.js and React using Mnist dataset
Stars: ✭ 40 (-14.89%)
Mutual labels:  tensorflowjs
ml gallery
This is a master project of some experiments with Neural Networks. Every project here is runnable, visualized and explained clearly.
Stars: ✭ 18 (-61.7%)
Mutual labels:  tensorflowjs
poseparty
A social exercise game you can play while social distancing.
Stars: ✭ 25 (-46.81%)
Mutual labels:  tensorflowjs
time-series-forecasting-tensorflowjs
Pull stock prices from online API and perform predictions using Long Short Term Memory (LSTM) with TensorFlow.js framework
Stars: ✭ 96 (+104.26%)
Mutual labels:  tensorflowjs
tensorflow-wxapp
在微信小程序中运行TensorFlow模型
Stars: ✭ 61 (+29.79%)
Mutual labels:  tensorflowjs
ai-lab
Library of components for TensorFlow.js in web frameworks.
Stars: ✭ 41 (-12.77%)
Mutual labels:  tensorflowjs
StyleSight
Browser based 'real-time' AR 'fast' neural style transfer using tensorflowjs
Stars: ✭ 15 (-68.09%)
Mutual labels:  tensorflowjs
teachablemachine-node
Using Teachable Machine Models in Node.js
Stars: ✭ 45 (-4.26%)
Mutual labels:  tensorflowjs
Wisty.js
🧚‍♀️ Chatbot library turning conversations into actions, locally, in the browser.
Stars: ✭ 24 (-48.94%)
Mutual labels:  tensorflowjs
Threepio
A multi-language library for translating commands between PyTorch, TensorFlow, and TensorFlow.js
Stars: ✭ 56 (+19.15%)
Mutual labels:  tensorflowjs
Face Api.js
JavaScript API for face detection and face recognition in the browser and nodejs with tensorflow.js
Stars: ✭ 13,258 (+28108.51%)
Mutual labels:  tensorflowjs
stackml-js
Machine Learning platform in-browser for creators
Stars: ✭ 34 (-27.66%)
Mutual labels:  tensorflowjs
angular-tensorflowjs-example
Using TensorflowJS detection models in Angular
Stars: ✭ 24 (-48.94%)
Mutual labels:  tensorflowjs
tensorflowjs-remove-background
Remove Background from the picture using WebAssembly & TensorFlow.js
Stars: ✭ 79 (+68.09%)
Mutual labels:  tensorflowjs
aio-rek
Face recognition based attendance system
Stars: ✭ 19 (-59.57%)
Mutual labels:  tensorflowjs
nanodet
NanoDet: Tiny Object Detection for TFJS and NodeJS
Stars: ✭ 19 (-59.57%)
Mutual labels:  tensorflowjs
intenseye-boun-workshop
Code for the workshop in BOUN Tech Summit (03.03.2019)
Stars: ✭ 32 (-31.91%)
Mutual labels:  tensorflowjs

Language Modeling

This is machine learning model that is trained to predict next word in the sequence. Model is defined in keras and then converted to tensorflowjs model using tfjs_converter.

See it working!

Dependencies

To install all dependencies at once use:

pip3 install -r requirements.txt

Usage

First create necessary directories or else you will get an error.

mkdir model/checkpoint
mkdir web/dist/web_model

Once you have your dependencies installed via pip, train the model by running :

python3 train.py

After training you can either use the model by running :

python3 test.py

After running test.py your output should be :

Enter atleast 3 words:
welcome to new

indexes of last  3 words        : [4402, 5, 35]

prediction indexes      : [92, 1, 2645, 1491, 189, 1762, 207, 362, 2261, 1727]


1 - welcome to new york
2 - welcome to new <unk>
3 - welcome to new york-based
4 - welcome to new england
5 - welcome to new products
6 - welcome to new jersey
7 - welcome to new debt
8 - welcome to new loans
9 - welcome to new hampshire
10 - welcome to new ventures

or by converting the model to tensorflow js model by running :

tensorflowjs_converter --input_format=keras /model/model.h5 /web/dist/web_model

Then Read the README.md in /web directory

License MIT © Rajveer Malviya

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].