# BrainJS/brain.js

🤖 GPU accelerated Neural networks in JavaScript for Browsers and Node.js

Repository: https://github.com/BrainJS/brain.js
Canonical: https://ross.abutalabs.com/products/brainjs
Homepage: https://brain.js.org
Language: TypeScript
License: MIT
License Family: permissive
Topics: neural-network, brain, recurrent-neural-networks, easy-to-use, api, web, nodejs, browser, convolutional-neural-networks, node, stream, hacktoberfest
Last push: 2024-09-26T21:51:23+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 3854, "days_push": 706, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 14861, forks 1077 (observed 2026-08-28T04:11:08.804973+00:00)

## What it is
brain.js is a GPU-accelerated neural network library written in JavaScript/TypeScript that runs in both browsers and Node.js. It supports feed-forward, recurrent (RNN, LSTM, GRU), and convolutional networks with a simple, easy-to-use API.

## Use cases
- train a neural network in the browser
- run machine learning in node.js without python
- predict time series values with LSTM in javascript
- build a simple classifier with a feed-forward network
- gpu accelerated neural network training in javascript
- forecast future values from historical data in the browser

## When to choose
- you want neural networks in JavaScript for browser or Node.js without a Python toolchain
- you need a simple, beginner-friendly API for feed-forward, RNN, LSTM, or GRU networks
- you want GPU acceleration for training in the browser via WebGL

## When to avoid
- you need large-scale deep learning with modern architectures like transformers
- you require an extensive ecosystem of ML tooling, model zoos, and research implementations
- you need production-grade training performance comparable to PyTorch or TensorFlow

## Facets
- artifact type: library
- maturity: active
- function: machine-learning, deep-learning
- domain: machine-learning, deep-learning, artificial-intelligence
- platform: browser, cross-platform
- tags: neural-networks, gpu-accelerated, lstm, rnn, time-series, javascript, typescript, nodejs

## Member repositories
- BrainJS/brain.js (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:11:08.804973+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:07:07.428948+00:00, confidence not recorded.
  - readme: https://github.com/BrainJS/brain.js (fetched 2026-08-28T04:11:08.804973+00:00, sha b6c87cd668a1)
  - homepage: https://brain.js.org (fetched 2026-08-29T08:05:20.147685+00:00, sha e6c499e06d21)
  - registry_npm: https://registry.npmjs.org/brain.js (fetched 2026-08-29T08:05:20.156853+00:00, sha bf50f4d81b4e)
- Data as of 2026-08-30T08:39:29.467469+00:00.
