Nx is the Numerical Elixir project, a tensor library and JIT-compiled numerical computing stack for the BEAM virtual machine. It originated when Elixir creator Jose Valim reached out to Sean Moriarity, author of Genetic Algorithms in Elixir, and the two co-developed a numerical foundation comparable in role to NumPy for Python. The project is maintained under the elixir-nx GitHub organization, with significant ongoing contribution from DockYard, the consultancy that employed Moriarity and that received the Mozilla award on the project's behalf.
Architecturally Nx defines a multi-dimensional Tensor type and a set of numerical definitions (`defn`) that are not interpreted as ordinary Elixir but compiled to an intermediate representation and lowered onto pluggable backends. The two production backends are EXLA, which targets Google's XLA compiler for CPU, GPU, and TPU acceleration, and Torchx, which targets LibTorch. The repository is roughly 94% Elixir and 6% C++, with the C++ being the bindings to the foreign compilers.
Above Nx sits a small set of higher-level libraries that together form the BEAM-native ML stack. Axon is Moriarity's neural-network library, designed with PyTorch-Ignite-style training loops. Bumblebee loads pretrained Hugging Face Transformers models directly into Elixir, lowering the barrier to use in production. Explorer wraps the Rust Polars library for DataFrame work. Livebook is the interactive notebook environment Valim built to host the whole stack and was the channel through which much of the early ML adoption happened. The elixir-nx organization now hosts roughly 18 projects.
The Mozilla Builders Accelerator selected Nx from nearly 200 applications in the September 23, 2024 cohort with funding of up to $100K. In the stack Nx sits at the training and runtime layers, with the broader thesis that a fault-tolerant, concurrency-first runtime (BEAM) can host serious numerical workloads when paired with appropriate compiler backends, and that Phoenix-class Elixir applications can serve ML inline rather than calling out to a Python service.
Recipient
Nx project / DockYard
Funder
Mozilla Foundation / Builders / Mozilla.ai · foundation · US
Open-source AI tooling, developer-facing AI applications, democratic AI. Three audience-segmented sites (Builders, Mozilla.ai, AI Guide).
Primary source
Additional sources
More from Mozilla Foundation / Builders / Mozilla.ai
- Democracy x AI Cohort 2026 2026-02 · $1M / 10 teams + $250K Sustain Track
10 teams at $50K each plus a $250K Sustain Track top-up. Focus on civic AI infrastructure.
- Ente Photos 2024-09-23 · Up to $100K
Open-source on-device semantic search and image recognition for private photo storage. Mozilla Builders Accelerator cohort 1 (local AI theme); avoids cloud dependency for personal photo libraries.
- Transformer Lab 2024-09-23 · Up to $100K
Cross-platform desktop application for building, training, fine-tuning, evaluating, and exporting local LLMs on Windows, macOS, and Linux. Ships in Mozilla's first Builders Accelerator local-AI cohort.
- Sartify (Swahili LLM) 2024-09-23 · Up to $100K
Foundation-model and tooling work for Swahili-speaking regions. Creates general and domain-specific AI capabilities for a language poorly served by major commercial models.
- Ersilia Model Hub 2024-09-23 · Up to $100K
Curated catalog of AI/ML drug-discovery models that operate locally. Targets researchers in low- and middle-income countries who cannot rely on US cloud platforms.