List of Javascript Machine Learning Libraries for 2019

Technologies like machine learning, predictive analytics, natural language processing andartificial intelligence are the most trending and innovative technologies of 21st century. Whether it is an enterprise software or a simple photo editing application, they all are backed and rooted in machine learning technology making them smart enough to be a friend to humans. Until now, the tools and frameworks that were capable of running machine learning were majorly developed in languages like Python, R and Java. However, recently the web ecosystem has picked up machine learning into its fold and is achieving transformation in web applications.

Today in this article, we will look at the most useful and popular libraries to perform machine learning in your browser without the need of softwares, compilers, installations and GPUs.


1. Keras.js

Keras.js is another trending open source framework that allows you to run machine learning models in the browser. It offers GPU mode support using WebGL. If you have models in Node.js, you’ll run them only in CPU mode. Keras.js also offers support for models trained using any backend framework, such as the Microsoft Cognitive Toolkit (CNTK).

Some of the Keras models that can be deployed on the client-side browser include Inception v3 (trained on ImageNet), 50-layer Residual Network (trained on ImageNet), and Convolutional variational auto-encoder (trained on MNIST).

2. Brain.js

Machine learning concepts are very math-heavy, which may discourage people from starting. The technicalities and jargons in this field may make beginners freak out. This is where Brain.js becomes important. It is an open source, JavaScript-powered framework that simplifies the process of defining, training, and running neural networks.

If you are a JavaScript developer who is completely new to machine learning, Brain.js could reduce your learning curve. It can be used with Node.js or in the client-side browser for training machine learning models. Some of the networks that Brain.js supports include feed-forward networks, Ellman networks, and Gated Recurrent Units networks.

3. ML-JS

ML-JS provides machine learning tools for working with NodeJS and browsers. The ML JS tool can be set up using the following code:

<script src=""></script>

The following machine learning algorithms are supported:

4. ConvNetJS

ConvNetJS is a JavaScript library for training deep learning models (neural networks) entirely in your browser. This library can also be used in NodeJS app.

In order to get started, get the minified version of ConvNetJS from the ConvNetJS minified library. This is a release page for ConvNetJS.

<script src="convnet-min.js"></script>

The following are some important pages:


5. Deeplearnjs

This popular library allows you to train neural networks in a browser or run pre-trained models in inference mode, and even claims it can be used as NumPy for the web. With an easy-to-pick-up API this library can be used for a verity for useful applications, and is actively maintained.

Deeplearnjs teachable machine web-demo



6. Synaptic

Synaptic is a well-liked machine learning library for training recurrent neural networks as it has in-built architecture-free generalized algorithm. Few of the in-built architectures include multilayer perceptronsLSTM networks and Hopfield networks. With Synaptic, you can develop various in-browser applications such as Paint an ImageLearn Image FiltersSelf-Organizing Map or Reading from Wikipedia.


7. Neurojs

Another recently developed framework especially for reinforcement learning tasks in your browser, is neurojs. It mainly focuses on Q-learning, but can be used for any type of neural network based task whether it is for building a browser game or an autonomous driving application. Some of the exciting features this library has to offer are full-stack neural network implementation, extended support to reinforcement learning tasks, import/export of weight configurations and many more. To see the complete list of features, visit the GitHub page.


8. TensorFlow.js

TensorFlow is an open-source hardware-accelerated JavaScript library for training and deploying machine learning models. It is one of the most popular libraries out there. You can use flexible and easy to pick APIs to build models from scratch using the low-level JavaScript linear algebra library or the high-level layers API.

You will find more implementations of TensorFlow rather than any other library mentioned in this article. There is a reason for that. Not only it is actively maintained, it lets you write, train, and deploy your GPU-based DL models all in JavaScript.

Check out some live use cases for Tensorflow:

It has vast variety of tutorials and guides listed officially on its website here to get you started. It also provide model converters to run pre-existing TensorFlow models right in the browser or under Node.js.


9. STDLib

To build advanced statistical models and machine learning libraries, this JavaScript library is used. IT can further be used for plotting and graphics functionality for exploratory data analysis and data visualization.

In relation to ML, the list of libraries is given below:

– Binary classification via Stochastic gradient descent

For instance: @stdlib/ml/online-binary-classification

– Linear regression via Stochastic gradient descent

For example: @stdlib/ml/online-sgd-regression

– Natural language processing

For example: @stdlib/nlp


  1. Mizanur Rahman

    i want to be a javascript programmer..

Your email address will not be published.