# trekhleb/nano-neuron

🤖 NanoNeuron is 7 simple JavaScript functions that will give you a feeling of how machines can actually "learn"

Repository: https://github.com/trekhleb/nano-neuron
Canonical: https://ross.abutalabs.com/products/nano-neuron
Language: JavaScript
License: MIT
License Family: permissive
Topics: machine-learning, machine-learning-algorithms, machinelearning, javascript, artificial-intelligence
Last push: 2025-11-23T04:27:56+00:00

## Health v2 (maintenance only)
Score: 56/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 53, release rhythm 35, longevity 100
- inputs: {"age_days": 2463, "days_push": 283, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2272, forks 123 (observed 2026-08-28T04:06:33.205788+00:00)

## What it is
NanoNeuron is an educational repository containing 7 simple JavaScript functions that demonstrate how machines learn, implemented as an over-simplified neuron trained to convert Celsius to Fahrenheit. It has no third-party libraries or dependencies, covering prediction, cost calculation, forward/backward propagation, and training in pure JavaScript.

## Use cases
- learn how machine learning works from scratch
- understand forward and backward propagation with simple code
- see a minimal linear regression example in JavaScript
- teach machine learning basics without frameworks
- demystify how neural network training actually works
- find a beginner-friendly intro to gradient descent

## When to choose
- you want a dependency-free, code-first introduction to ML fundamentals
- you learn best by reading small, self-contained JavaScript examples
- you want to explain 'machine learning math' to beginners

## When to avoid
- you need a production-ready machine learning framework
- you want deep learning, neural network architectures, or real datasets
- you need GPU acceleration or high-performance training

## Facets
- artifact type: learning-resource
- maturity: stable
- function: machine-learning, developer-tools
- domain: machine-learning, education, tutorials
- platform: -
- tags: educational, neural-networks, linear-regression, from-scratch, no-dependencies, javascript, nodejs

## Member repositories
- trekhleb/nano-neuron (main) score 56

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:33.205788+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-30T02:41:43.551323+00:00, confidence not recorded.
  - readme: https://github.com/trekhleb/nano-neuron (fetched 2026-08-28T04:06:33.205788+00:00, sha 6eb15058b5ac)
- Data as of 2026-08-30T08:39:29.467469+00:00.
