> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/nemo/automodel/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/nemo/automodel/_mcp/server.

# GLM-5.2

> Use NeMo AutoModel to fine-tune GLM-5.2 for LLM workflows with checked-in text generation recipes and documented distributed settings.

[GLM-5.2](https://huggingface.co/zai-org/GLM-5.2) has a checked-in NeMo AutoModel recipe for text generation.
The Hugging Face configuration declares the `GlmMoeDsaForCausalLM` architecture.

## Fine-Tune GLM-5.2

Follow the [installation instructions](/get-started/installation), then run the recipe from the repository root:

```bash
automodel examples/llm_finetune/glm/glm_5.2_lora.yaml --nproc-per-node 8
```

Use the [Slurm launcher guide](/job-launchers/slurm-cluster) for the multi-node run.

## Choose a Workflow

| Goal                                         | Start Here                                                                                                                          |
| -------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| Run the primary recipe for this model        | Use the [recipe configuration](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_finetune/glm/glm_5.2_lora.yaml).     |
| Try another checked-in recipe for this model | Use the [alternate recipe](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_finetune/glm/glm_5.2_hellaswag_pp.yaml). |

### Configuration

| Setting  | Configuration                                                                                                                                   |
| -------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |
| Hardware | -                                                                                                                                               |
| Strategy | FSDP2; tp\_size=1, pp\_size=1, cp\_size=1, ep\_size=128                                                                                         |
| Nodes    | 16                                                                                                                                              |
| Features | Activation checkpointing (activation\_checkpointing=true), Packed sequences (packed\_sequence\_size=4096), LoRA, HybridEP (dispatcher=hybridep) |
| Advanced | attention=tilelang, linear=torch, experts=torch\_mm, dispatcher=hybridep, sequence length 4096                                                  |

### More Recipes for This Model

* [`glm_5.2_hellaswag_pp.yaml`](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_finetune/glm/glm_5.2_hellaswag_pp.yaml)
* [`glm_5.2_tulu3_32k_tilelang_cp8.yaml`](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_finetune/glm/glm_5.2_tulu3_32k_tilelang_cp8.yaml)
* [`glm_5.2_tulu3_4k_cudnn_100k.yaml`](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_finetune/glm/glm_5.2_tulu3_4k_cudnn_100k.yaml)
* [`glm_5.2_tulu3_4k_tilelang_100k.yaml`](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_finetune/glm/glm_5.2_tulu3_4k_tilelang_100k.yaml)
* [`glm_5.2_mok_mxfp8_fineweb_8k.yaml`](https://github.com/NVIDIA-NeMo/Automodel/blob/main/examples/llm_pretrain/glm/glm_5.2_mok_mxfp8_fineweb_8k.yaml)

## Model Reference

### Model Architecture

| Property     | Value                  |
| ------------ | ---------------------- |
| Task         | Text generation        |
| Architecture | `GlmMoeDsaForCausalLM` |

### Available Models

* [`zai-org/GLM-5.2`](https://huggingface.co/zai-org/GLM-5.2)

## Related Resources

* [LLM fine-tuning guide](/recipes-e2e-examples/sft-peft)