An accelerated machine learning framework for Go, offering a PyTorch/Jax/TensorFlow-like experience with support for CPUs, GPUs, TPUs, and WASM.
GoMLX is an accelerated machine learning framework for the Go programming language, providing a PyTorch/Jax/TensorFlow-like experience. It enables developers to build, train, and deploy ML models entirely in Go, with support for CPUs, GPUs, TPUs, and even browser-based execution via WASM. The framework solves the problem of bringing high-performance ML to Go's ecosystem without relying on Python.
Go developers who want to integrate machine learning into their applications, researchers experimenting with ML ideas in a Go environment, and teams seeking production-ready ML models with Go's deployment benefits.
Developers choose GoMLX for its native Go integration, multiple backend support (including high-performance XLA and portable pure Go), ability to run models anywhere Go runs, and its emphasis on simplicity, transparency, and extensibility.
GoMLX: An Accelerated Machine Learning Framework For Go
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Supports OpenXLA for CPU/GPU/TPU acceleration with state-of-the-art speed comparable to Jax and TensorFlow, as noted in the README, while also offering a pure Go backend for portability.
Runs almost everywhere Go runs, including browsers via WASM, enabling ML in web applications without C++ dependencies, as demonstrated in the Hive game demo.
Can convert and run ONNX models from HuggingFace using the onnx-gomlx package, facilitating easy use of pre-trained models like Gemma 3 and BERT for inference or fine-tuning.
Includes autodiff, common layers (FFN, convolutions, transformers, KANs), training tools, optimizers, and loss functions, providing a full-featured platform for building and experimenting with models.
Emphasizes transparency and simplicity at the cost of more typing, which can slow down development compared to more concise frameworks like PyTorch or Jax.
Only supports static shapes currently, with dynamic shape support planned for mid-2026, restricting model types that require variable input sizes.
Multi-GPU/TPU training is labeled as experimental and still being improved, which may lead to instability or bugs for production-scale distributed workloads.
Compared to established Python ML frameworks, GoMLX has fewer pre-built models, limited third-party integrations, and a smaller community for support and resources.
GoMLX is an open-source alternative to the following products:
Jax is a high-performance numerical computing library for Python that provides automatic differentiation and accelerated linear algebra operations.
TensorFlow is an open-source machine learning framework developed by Google for building and deploying ML models across various platforms.
PyTorch is an open-source machine learning framework that provides tensor computation with strong GPU acceleration and deep neural networks built on a tape-based autograd system.