API Reference emily v#0.3.5

Copy Markdown View Source

Modules

Elixir bindings and Nx backend for Apple's MLX.

Nx.Backend implementation backed by Apple's MLX.

Rewrite RMSNorm, LayerNorm, RoPE, and SDPA Axon layers of a Bumblebee model so they call Emily.Fast.* instead of their stock defn implementations. When the rewritten model is then evaluated under Emily.Compiler, those Emily.Fast.* calls dispatch to fused MLX kernels via the :optional-node mechanism (see Emily.Fast's moduledoc). On any other backend the helpers fall back to defn composition and produce mathematically equivalent results, so applying the shim is safe even if the model is later evaluated on Nx.BinaryBackend or EXLA.

Nx.Defn.Compiler implementation that runs defn computations on Emily.Backend.

Fused transformer kernels as defn-callable helpers.

Mixed-precision training utilities.

Dynamic loss-scaler state for mixed-precision training.

Quantized inference primitives.

Defn-traceable quantized layer op for use inside Axon graphs.

Container for a matrix quantized via one of MLX's group-wise quantization schemes ("affine" int4/int8, plus the microscaled variants "mxfp4", "mxfp8", "nvfp4").

Per-process MLX stream management for concurrent inference.

:telemetry events emitted by Emily.

Mix Tasks

Build and run the standalone C++ microbenchmarks under bench/native/.