Crystal-GFN: sampling crystals with desirable properties and constraints

This paper introduces Crystal-GFN, a multi-environment, continuous-discrete GFlowNet that sequentially samples crystal structural attributes to efficiently generate diverse, valid materials with specific desirable properties and hard constraints, thereby accelerating the discovery of novel solid-state materials.

Mila AI4Science, :, Alex Hernandez-Garcia, Alexandre Duval, Alexandra Volokhova, Yoshua Bengio, Divya Sharma, Pierre Luc Carrier, Yasmine Benabed, Michał Koziarski, Victor Schmidt, Gian-Marco Rignanese, Pierre-Paul De Breuck, Paulette Clancy

Published 2026-03-05
📖 4 min read☕ Coffee break read

Imagine you are an architect trying to design the perfect building. But instead of bricks and mortar, you are building with atoms. Your goal is to create a new material—maybe one that stores solar energy perfectly, or one that conducts electricity without losing any power.

The problem? There are more possible combinations of atoms than there are grains of sand on all the beaches on Earth. Trying to find the "perfect" material by guessing and checking is like trying to find a specific needle in a haystack the size of a galaxy.

This is where Crystal-GFN comes in. Think of it as a super-smart, intuition-driven architect that doesn't just guess randomly, but "feels" its way toward the best designs.

Here is how it works, broken down into simple concepts:

1. The Recipe: Building a Crystal Step-by-Step

Usually, computer programs try to build a crystal all at once, which often leads to messy, impossible structures (like a building with no foundation).

Crystal-GFN is different. It builds a crystal like a chef following a strict recipe, step-by-step:

  1. Pick the Blueprint (Space Group): First, it chooses the "symmetry" of the building. Is it a cube? A hexagon? This sets the rules for how the atoms can arrange themselves.
  2. Pick the Ingredients (Composition): Next, it decides which elements to use (like Iron, Oxygen, or Lithium) and how many of each. It has a strict rule: the "electric charge" of the ingredients must balance out to zero, just like a balanced budget.
  3. Set the Dimensions (Lattice Parameters): Finally, it decides the size and angles of the unit cell (the smallest repeating block of the crystal).

By building it in this order, the AI ensures that every single crystal it creates is physically possible and follows the laws of chemistry. It never wastes time on "impossible" buildings.

2. The Magic Compass: GFlowNets

The secret sauce behind this AI is something called a GFlowNet.

Imagine you are in a giant, dark maze looking for treasure.

  • Old AI methods are like a blindfolded person throwing darts. They might hit the treasure by luck, but they usually hit the walls.
  • Crystal-GFN is like a person with a magnetic compass. The compass points toward "good" materials.

But here is the cool part: The compass doesn't just point to one treasure. It points to many different treasures. This is crucial because in science, we don't just want one solution; we want a diverse list of candidates to test in the lab. Crystal-GFN explores the whole maze, finding many different paths to high-quality materials, not just the single "best" one it thinks it found.

3. The "Desire" (The Reward)

The AI needs to know what it's looking for. The researchers taught it to "desire" specific properties by giving it a score (a reward):

  • The "Heavy" Goal: If you want a material that is very dense (heavy for its size), the AI learns to pack atoms tightly together.
  • The "Stable" Goal: If you want a material that won't fall apart (low energy), the AI learns to find stable atomic arrangements.
  • The "Solar" Goal: If you want a material for solar panels, the AI learns to find crystals with a specific "band gap" (the right amount of energy to let electrons flow).

4. The Results: Fast and Diverse

The researchers tested this system and found it incredibly effective:

  • Speed: It learned to find these materials in under 30 hours on a standard computer (no supercomputers needed!).
  • Quality: It found crystals with very low energy (meaning they are stable and likely to exist in the real world).
  • Variety: It didn't just find one type of crystal; it found thousands of different types, giving scientists a huge menu of options to choose from.

Why This Matters

In the past, discovering new materials was slow, expensive, and relied on trial and error. Crystal-GFN acts like a high-speed filter. It takes the infinite possibilities of the universe and narrows them down to a shortlist of the most promising candidates.

Instead of a scientist spending years guessing, they can now say, "AI, give me 100 stable crystals that are good for batteries," and get a list of valid, diverse options in minutes. This accelerates the discovery of clean energy technologies, better batteries, and stronger materials, helping us solve big global challenges like climate change.

In short: Crystal-GFN is a smart, rule-following architect that uses a magnetic compass to rapidly sketch out thousands of perfect crystal blueprints, saving us years of trial and error.

Get papers like this in your inbox

Personalized daily or weekly digests matching your interests. Gists or technical summaries, in your language.

Try Digest →