---
title: 'aLLoyM: LLM for Alloy Phase Diagrams'
url: https://www.emergentmind.com/topics/alloym
type: topic
---

# aLLoyM: LLM for Alloy Phase Diagrams

aLLoyM is a large language model specialized for alloy phase diagrams. It was introduced as a fine-tuned Mistral-based system trained on alloy compositions, temperatures, and corresponding phase information derived from the Computational Phase Diagram Database (CPDDB), with the explicit aim of treating phase-diagram reasoning as a question–answer problem over composition and temperature rather than as a narrowly defined regression task [2507.22558]. In subsequent work, aLLoyM was used as a domain-specific prior inside a closed-loop experimental framework for phase diagram construction, where its principal value was not exact phase-name correctness but guidance toward composition regions where complicated multiphase equilibria were likely [2604.20304].

## 1. Definition and domain role

aLLoyM is a domain-specific large language model for alloy phase diagram prediction. In the 2025 formulation, it is described as a large language model specialized for alloy phase diagrams and trained on CALPHAD-derived question-and-answer pairs; in the 2026 experimental-planning study, it is described as a domain-specific LLM trained specifically to predict equilibrium phases in alloy systems, in contrast to a general-purpose LLM such as Claude [2507.22558].

Its operational premise is that phase diagrams can be represented as structured Q&A mappings. The model is intended to learn associations of the form composition plus temperature to phase name(s), composition plus temperature to full phase information, and element set plus phase domain to plausible composition and temperature. This formulation makes aLLoyM usable both as a predictor and as a generative tool. A central implication is that the model occupies an intermediate position between thermodynamic databases and open-ended LLM reasoning: it is not a replacement for CALPHAD assessment, but a fine-tuned assistant that can answer phase-diagram queries and propose hypotheses in unexplored chemical spaces [2507.22558].

The later experimental study further narrows this role. There, aLLoyM is not treated as a full autonomous planner. Instead, it serves as a specialized prior that supplies approximate prior information about likely phase equilibria at a given composition and temperature, while a general-purpose LLM acts as the experimental planner in the closed loop [2604.20304].

## 2. Training corpus and task construction

The training corpus for aLLoyM was built from the open-source CPDDB repository from NIMS. The authors extracted thermodynamic database files for **389 binary phase diagrams** and **38 ternary phase diagrams**, then used **Pandat** to perform CALPHAD calculations on systematic grids. For binary systems, compositions were sampled from **0% to 100% in 2% increments** and temperatures from **200 K to 5000 K in 50 K steps**. For ternary systems, temperature was fixed at **800 K**. This produced **837,475 data points** linking elemental composition, temperature, and phase information [2507.22558].

These data were then converted into question-and-answer examples in a unified framework with three tasks. The first task, **full phase information**, uses composition and temperature as input and returns full phase description, including phase names, fractions, and phase compositions. The second task, **phase name**, uses the same input but returns only the phase names. The third task, **experimental condition**, inverts the direction: it uses element set plus phase domain as input and returns plausible composition and temperature. Training examples were formatted with a structured prompt template containing **Instruction**, **Input**, and **Output** [2507.22558].

This task formulation is significant because it extends phase-diagram modeling beyond direct forward prediction. The model is trained not only to recognize equilibrium phase outputs, but also to infer experimental conditions from desired phase domains. This suggests a bidirectional use of phase-diagram information, albeit within the limits of CALPHAD-derived supervision rather than experimentally complete thermodynamic truth [2507.22558].

## 3. Base model, fine-tuning, and output conventions

The base model for the 2025 system was **Mistral-Nemo-Instruct-2407-bnb-4bit** from Hugging Face. aLLoyM was fine-tuned using **LoRA (Low-Rank Adaptation)** with **rank = 16**, **alpha = 16**, and target modules in the **attention and feed-forward projections**. The reported training hyperparameters were **15,000 steps**, **learning rate = \(2 \times 10^{-4}\)**, **batch size = 16 per device**, **4 gradient accumulation steps**, **optimizer = AdamW**, and **precision = bfloat16**. The 2026 study characterizes the deployed model as a **Mistral-Nemo-Instruct (12B parameter) model fine-tuned with LoRA adapters on the Computational Phase Diagram Database (CPDDB)**, which is consistent with the original description of a Mistral-based LoRA-adapted system [2507.22558].

A noteworthy feature of aLLoyM in experimental deployment is its output vocabulary. Its outputs are not system-specific phase names, but a **standardized phase nomenclature** based on structural prototypes and generic labels such as **B2, C36, FCC_A1, SOLID, and LIQUID**. This means that the model does not attempt to name the exact experimental phase that will appear. Instead, it provides approximate prior information about what kinds of phase equilibria are likely at a given composition and temperature. In that sense, aLLoyM is optimized for phase-domain guidance rather than for direct reproduction of experimental naming conventions [2604.20304].

This output design matters methodologically. Because the labels are standardized and CALPHAD-derived, the model’s predictions are best interpreted as structurally typed phase-diagram priors. A plausible implication is that this nomenclature stabilizes training across many systems while also constraining how literally predictions should be mapped onto experimentally resolved phase identities [2604.20304].

## 4. Evaluation protocols and quantitative scoring

aLLoyM was evaluated in two formats: **multiple-choice Q&A** and **short-answer Q&A**. In the multiple-choice setting, each question had **four options**, comprising **1 correct answer** and **3 distractors randomly chosen from answers related to the same systems**. The dataset was split **8:2** into training and test sets under two regimes: an **interpolation split**, where points were randomly distributed across all systems, and an **extrapolation split**, where entire systems were held out from training. These evaluations covered the same three task types: full phase information, phase name, and experimental condition [2507.22558].

The baseline was the untuned **Mistral-Nemo-Instruct-2407-bnb-4bit** model. The reported result is qualitative but unambiguous: the baseline performed **near random guessing** in both interpolation and extrapolation settings, whereas fine-tuning substantially improved performance across all tasks. Performance was better on interpolation than extrapolation, better on binary than ternary systems, and showed only minor differences among the three task types in the multiple-choice setting. For short-answer generation, the model again performed better on interpolation than extrapolation, with stronger results for phase-name prediction than for full phase information and robust phase-name prediction even on extrapolated systems [2507.22558].

The short-answer evaluation used task-specific metrics. For **full phase information**, the score was exact-match only:
$$
\text{Score} =
\begin{cases}
100\% & \text{if the generated answer exactly matches the ground truth} \\
0\% & \text{otherwise}
\end{cases}
$$

For **phase name**, predicted and true phase-domain lists \(A\) and \(B\) were scored by Jaccard similarity:
$$
\text{Score} =
\begin{cases}
|A \cap B| / |A \cup B| \times 100\% & \text{if } |A \cup B| > 0 \\
0\% & \text{otherwise}
\end{cases}
$$
with
$$
A = [\text{phase name }1, \ldots, \text{phase name }k], \quad
B = [\text{phase name }1, \ldots, \text{phase name }l].
$$

For **experimental condition**, the paper defined
$$
A_{\rm c} = \frac{1}{N} \sum_{n = 1}^{N} \left( 1 - \frac{|x_n^* - x_n|}{100} \right),
$$
$$
A_{\rm t} = 1 - \frac{|T^* - T|}{\Delta T},
$$
and
$$
\text{Score} = \left( \frac{1}{2} A_{\rm c} + \frac{1}{2} A_{\rm t} \right) \times 100\%.
$$
If multiple ground truths existed, the score was computed against each and the maximum retained. These scoring rules are important because they formalize partial correctness for free-form phase and condition generation rather than requiring only categorical exact matches [2507.22558].

## 5. Generative behavior, extrapolation, and limitations

A central claim of the 2025 paper is that the short-answer model can generate **novel phase diagrams from its components alone**. The authors report examples for **Th–Ac**, **U–Nh**, **W–Ta–Os**, and **Nh–U–Ac**. These examples include partially known and completely hypothetical systems. For **Th–Ac**, actinium was not in the training data, but the model predicted a melting point roughly consistent with experiment while mispredicting the stable crystal structure. For **U–Nh**, neither element was in training data, yet the model produced a plausible phase diagram and a moderate estimate of uranium’s melting point, again with structural errors. For **W–Ta–Os**, no ternary diagram was known experimentally, but the model generated an **800 K ternary isothermal section** and predicted phases with **“WOLF” nomenclature** absent from training data. For **Nh–U–Ac**, it produced a hypothetical ternary diagram for a system that cannot be experimentally realized [2507.22558].

These results are presented with explicit caveats. The paper states that many outputs remain beyond experimental validation and that some predictions are chemically incorrect, so the short-answer model is best seen as a **generative hypothesis engine** rather than a validated predictor. The model tends to perform better near pure elements and worse in intermediate composition regions, especially where phase behavior is complex. It also often **misidentifies crystal structures**, and generated “novel” diagrams tend to reuse **phase names seen during training**, which indicates limited novelty in phase vocabulary. Ternary performance is weaker than binary performance because there is less ternary training data, and the authors identify more ternary and higher-order training data, better prompt engineering, thermodynamics-aware prompting, and better control over generated phase names as future directions [2507.22558].

The paper also emphasizes reproducibility and reuse. It states that the **short-answer fine-tuned aLLoyM** and the **complete benchmarking Q&A dataset** are publicly released on Hugging Face, and that code is available on GitHub. This release is positioned as enabling reproducibility, benchmarking, reuse of the dataset for further model development, and community-driven improvements for phase-diagram prediction [2507.22558].

## 6. Experimental use in LLM-guided phase diagram construction

aLLoyM’s most concrete downstream use, within the provided literature, is in the 2026 framework for **LLM-guided phase diagram construction through high-throughput experimentation**. The overall workflow was a closed loop: the AI planner selected compositions, samples were synthesized by high-throughput methods, X-ray diffraction identified the phases, and the new results were fed back into the planner for the next cycle. This loop was repeated for **six cycles**, with **eight compositions per cycle** for a total of **48 measurements per strategy**. The experimental system was the **Co-Al-Ge ternary at 900 °C (1173.15 K)** with **231 candidate compositions on a 5 at.% grid** [2604.20304].

Two strategies were compared:

| Strategy | Initial planning | Subsequent planning |
|---|---|---|
| **Strategy A** | aLLoyM-guided initial cycle | general-purpose LLM from cycle 2 onward |
| **Strategy B** | general-purpose LLM only | general-purpose LLM only |

In both strategies, the general-purpose LLM was run as an agent via **Claude Code**, and each cycle used **10 independent selection runs**, with the final **8 points** chosen by **majority vote**. The difference between the strategies was therefore mainly in the starting bias. Strategy A used aLLoyM predictions as reference information in the first cycle, which pushed selections toward the **interior of the ternary triangle**; Strategy B followed a more **textbook-like** exploration that sampled the corners and binary edges before moving inward [2604.20304].

This distinction had experimentally measurable consequences. aLLoyM-guided points tended to target compositionally complex interior regions, and this enabled the earliest discovery of all three novel ternary-only phases. Specifically, **B20. Co(Al/Ge)** was found in **cycle 1** by Strategy A but only in **cycle 3** by Strategy B; **X** was found in **cycle 2** by Strategy A but only in **cycle 4** by Strategy B; **Co2(Al/Ge)3** was found by both strategies in **cycle 1**. Most importantly, Strategy A discovered **all three ternary-only novel phases within 16 measurements (cycle 2)**, whereas Strategy B needed **32 measurements (cycle 4)**. The paper gives examples of aLLoyM-predicted labels that nonetheless led to discovery: a point predicted as **C36** led to **Co2(Al/Ge)3**; a point predicted as **C30 + FCC_A1** led to **B20. Co(Al/Ge)**; a point predicted as **CQG_B2** again led to **Co2(Al/Ge)3**; and a point predicted only as **SOLID** was selected because of its ambiguity and yielded **B20. Co(Al/Ge)** [2604.20304].

The complementary strength of the general-purpose LLM also remained clear. Strategy B was faster at broad phase coverage, discovering **9 phases by cycle 2** and **all 11 phases by cycle 4**, whereas Strategy A reached **11 phases only by cycle 6**. The paper therefore does not frame the result as a narrow “aLLoyM vs Claude” comparison. Instead, it argues that **aLLoyM = domain-specialized phase predictor** and **general-purpose LLM = flexible experimental planner**, with the combination being particularly effective when the objective is novelty discovery rather than exhaustive mapping. The “phase diagram” constructed in that study is explicitly not a thermodynamic equilibrium phase diagram in the strict sense; it is the experimentally obtained **primary phase assemblage map** after heating powders at **900 °C** and cooling. Within that experimental framing, aLLoyM’s distinctive contribution was to identify regions of high phase complexity rather than to supply exact phase identities [2604.20304].

Source: https://www.emergentmind.com/topics/alloym