--- license: gemma language: - mi - en base_model: google/gemma-3-12b-pt tags: - byol - low-resource - māori - gemma3 library_name: transformers pipeline_tag: text-generation --- # BYOL Māori 12B This model was produced by the [BYOL framework](https://github.com/microsoft/byol) for extending LLMs to low-resource languages. - **Base model:** [google/gemma-3-12b-pt](https://huggingface.co/google/gemma-3-12b-pt) - **Language:** Māori (mri) - **Training stage:** Merged (CPT + IT via model merging) - **License:** [Gemma Terms of Use](https://ai.google.dev/gemma/terms) (derived from Gemma 3) - **Paper:** [BYOL: Bring Your Own Language Into LLMs](https://arxiv.org/abs/2601.10804) - **Code:** [github.com/microsoft/byol](https://github.com/microsoft/byol) ## Model Description This is a **merged** language model for Māori (mri) that combines the language knowledge acquired during continual pre-training with the instruction-following capabilities from supervised fine-tuning. It was produced by merging [BYOL Māori 12b CPT](https://huggingface.co/ai-for-good-lab/byol-mri-12b-cpt) and [BYOL Māori 12b IT](https://huggingface.co/ai-for-good-lab/byol-mri-12b-it) checkpoints back into the original Gemma 3 instruction model, using the [BYOL framework](https://github.com/microsoft/byol). **This is the recommended model for most users.** It supports chat/instruction-following and has the strongest overall performance on Māori benchmarks (see the [paper](https://arxiv.org/abs/2601.10804) for evaluation results). ## Usage ```bash pip install -U transformers ``` ```python from transformers import AutoModelForCausalLM, AutoTokenizer import torch model_id = "ai-for-good-lab/byol-mri-12b-merged" tokenizer = AutoTokenizer.from_pretrained(model_id) model = AutoModelForCausalLM.from_pretrained(model_id, device_map="auto", dtype=torch.bfloat16) # Chat inference messages = [{"role": "user", "content": "Kōrerotia mai mō Aotearoa."}] inputs = tokenizer.apply_chat_template(messages, return_tensors="pt", add_generation_prompt=True, return_dict=True).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0], skip_special_tokens=True)) ``` ## Citation ```bibtex @article{zamir2026byolbringlanguagellms, title={BYOL: Bring Your Own Language Into LLMs}, author={Syed Waqas Zamir and Wassim Hamidouche and Boulbaba Ben Amor and Luana Marotti and Inbal Becker-Reshef and Juan Lavista Ferres}, year={2026}, journal={arXiv:2601.10804}, url={https://arxiv.org/abs/2601.10804}, } ```