NIV: Neural Axis Variations for Variable Font Generation

Nadav Benedek, Ariel Shamir, Ohad Fried

TL;DR

NIV (Neural Axis Variations) is the first deep learning method that automatically converts a standard static font into a fully functional OpenType variable font. By operating directly on vector geometry and predicting per-point displacements across continuous design axes (like weight or width), NIV eliminates the labor-intensive manual design process traditionally required for variable typography.

What Problem Does This Paper Address?

Variable fonts are an extension of the OpenType format that allow a single font file to dynamically change its appearance—such as becoming bolder, wider, or more slanted—using continuous sliders. This is incredibly useful for responsive web design and digital typography.

However, creating them is a nightmare for type designers. It requires manually designing multiple "master" outlines and specifying exactly how every single control point moves across different design axes (stored in the font's gvar table). Because of this immense manual effort, the vast majority of existing fonts remain static. While previous AI approaches have tried to automate font generation, they typically output static raster images or independent vector outlines rather than a unified, interactive variable font file.

Methods

NIV tackles this with a two-stage sequence-to-sequence geometric model that predicts outline deformations as delta vectors on glyph control points.

The NIV model and font generation method.
  1. Vector-Based Architecture: Instead of pixels, the model processes the ordered sequence of coordinates $(x, y)$ that define a glyph's outline, along with indicators for whether a point is on or off-curve. It uses a stack of interaction blocks with multi-head self-attention to capture geometric dependencies across the entire character simultaneously.
  2. Property Embedding: To handle multiple variation axes at once, the authors introduce a novel conditioning mechanism. It learns positive and negative embedding vectors for each axis, weights them by the user's desired axis values, and sums them into a single conditioning vector. This vector modulates the network's layers via Adaptive Layer Normalization (AdaLN).
  3. Hierarchical Font Construction: To build the actual .ttf file, the model progressively samples the extremes of the design space. It injects lower-order single-axis variations first, and then calculates higher-order multi-axis interactions as residual corrections, perfectly mirroring the standard OpenType variable font structure.

Datasets

The authors introduced a newly constructed dataset derived from public variable Google Fonts.

  • Scale: Over 1 million variation tuples across 733 variable fonts, totaling nearly 1 million glyphs.
  • Format: Released in a structured, human-readable XML format with fully densified per-point variation deltas.
  • Evaluation Splits: The dataset was evaluated using two distinct strategies: a Font split (testing on entirely unseen font styles) and a Unicode split (testing on entirely unseen characters).

Key Insights and Ideas

  • Pure Geometry Over Identity: NIV does not receive any explicit glyph identity or Unicode information during training. It operates purely on the input shape. This allows the model to generalize deformation rules to entirely unseen characters based solely on their geometric structure.
  • Cross-Axis Interactions Matter: The authors proved that design axes cannot simply be treated independently. For example, making a font both bold and wide requires non-linear, joint processing; treating them as purely additive independent transformations significantly degrades quality.
  • Semantic Awareness vs. Naive Rules: Traditional programmatic shortcuts (like stretching a font horizontally to make it wider) introduce ugly artifacts, such as accidentally thickening vertical stems. NIV learns semantic rules from data, widening the proportions while preserving the correct structural thickness of the font lines.

Key Results

  • High Fidelity Reconstruction: When tested by stripping the variation data from existing variable fonts and asking NIV to reconstruct them, the model achieved a remarkably low Root Mean Squared Error (RMSE) of ~0.052 compared to a null baseline of ~0.144.
Reconstructing variable fonts from the test set.
  • Cross-Language Robustness: Despite being trained primarily on Western scripts, NIV successfully generalized to highly complex, multi-stroke CJK (Chinese, Japanese, Korean) fonts like Meiryo and PingFang.
Rendered CJK text using novel variable fonts generated by NIV.
  • Out-of-Distribution Generalization: The model successfully added variable weight, width, and slant sliders to unique, hand-drawn handwriting fonts that shared no structural resemblance to the training data.
  • Efficiency: The average inference latency is just 8.3 ms per tuple on an NVIDIA RTX 3090 GPU, making font generation incredibly fast.

Limitations and Future Work

While NIV excels at geometric outline deformation, it currently ignores other critical typographic components. It does not explicitly predict font-level metadata such as kerning pairs (the spacing between specific letter combinations), global spacing rules, or hinting instructions (which optimize rendering on low-resolution screens).

Additionally, the training data is currently limited to the Google Fonts ecosystem. The authors suggest that expanding the dataset to more diverse licensed sources and extending this axis-conditioned deformation framework to general vector graphics (beyond typography) are promising directions for future research.

Summary updated

BibTeX
@inproceedings{benedek2026niv,
  author = {Nadav Benedek and Ariel Shamir and Ohad Fried},
  title = {{NIV: Neural Axis Variations for Variable Font Generation}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=F4kv6kdkQw},
}
Figure