Candle is Hugging Face’s minimalist machine learning framework for Rust. It has become one of the most-starred Rust ML projects on GitHub with more than 21,000 stars, has trended repeatedly over the years, and remains actively maintained with updates in October 2026 under the Apache-2.0 license.
Rust developers historically had to leave their ecosystem to do serious machine learning. Candle changes that with a lean, PyTorch-flavored tensor framework written entirely in Rust. It focuses on inference performance and simplicity: small binaries, easy deployment, and backends for CPU, CUDA, and Apple Metal. Its example collection shows production-shaped implementations of popular models, including large language models like Llama, speech models like Whisper, and image models like Stable Diffusion, which makes Candle a practical way to ship ML features inside Rust applications and serverless functions.
The codebase is organized into focused crates: a core tensor library, neural-network building blocks, and a transformers crate with ready implementations of well-known architectures. That structure keeps the framework hackable; researchers can read a model implementation end to end in ordinary Rust instead of untangling a monolith. Candle deliberately emphasizes inference and simplicity over being a full training platform, which keeps its surface area small and its behavior predictable. It powers many of Hugging Face’s lightweight demos and has become a foundation for Rust-based ML tooling, from local LLM runners to embedded inference in larger applications.
Candle is free and open source under the Apache-2.0 license. There are no fees or paid editions; you bring your own compute.
Candle is for Rust developers and platform teams who want to embed fast ML inference directly in Rust services, CLIs, and edge deployments without depending on Python or heavyweight external runtimes.