Gemma-3-Gaia-PT-BR-4b-it GGUF Models
Model Generation Details
This model was generated using llama.cpp at commit 7f4fbe51
.
Quantization Beyond the IMatrix
I've been experimenting with a new quantization approach that selectively elevates the precision of key layers beyond what the default IMatrix configuration provides.
In my testing, standard IMatrix quantization underperforms at lower bit depths, especially with Mixture of Experts (MoE) models. To address this, I'm using the --tensor-type
option in llama.cpp
to manually "bump" important layers to higher precision. You can see the implementation here:
👉 Layer bumping with llama.cpp
While this does increase model file size, it significantly improves precision for a given quantization level.
I'd love your feedback—have you tried this? How does it perform for you?
Click here to get info on choosing the right GGUF model format
Model Card for GAIA (Gemma-3-Gaia-PT-BR-4b-it)
GAIA is an open, state-of-the-art language model for Brazilian Portuguese. It was developed by continuously pre-training the google/gemma-3-4b-pt
model on an extensive, high-quality corpus of Portuguese data.
The goal of GAIA is to democratize access to cutting-edge AI technology in Brazil, enabling developers, researchers, and organizations to build innovative solutions on a robust and reliable technological foundation.
Model Details
Model Description
GAIA was developed through a partnership between The Brazilian Association of AI (ABRIA), the Center of Excellence in Artificial Intelligence (CEIA) at the Federal University of Goiás (UFG), startups Nama and Amadeus AI, and Google DeepMind.
The development process started with the base model google/gemma-3-4b-pt
and involved two main stages:
- Continuous Pre-training: The model was trained on a large, high-quality Portuguese dataset totaling approximately 13 billion tokens. This corpus includes a variety of domains, such as scientific articles and Wikipedia data in Portuguese, ensuring a deep understanding of the language and its contexts.
- Instruction-Following Capability Restoration: To enable the model to follow instructions without traditional supervised fine-tuning (SFT), a weight merging operation was applied. This technique, described in the paper “Balancing Continuous Pre-Training and Instruction Fine-Tuning: Optimizing Instruction-Following in LLMs”, allows the model to integrate the knowledge acquired during continuous pre-training with the ability to interact in a chat format and follow instructions.
- Developed by: The Brazilian Association of AI (ABRIA), the Center of Excellence in Artificial Intelligence (CEIA-UFG), Nama, Amadeus AI, and Google DeepMind.
- Model: GAIA
- Model type: Causal decoder-only Transformer-based language model.
- Language(s): Brazilian Portuguese (pt-BR)
- License: Gemma
- Based on:
google/gemma-3-4b-pt
Team
This project was made possible by the contributions of the following individuals:
- Dr. Celso Gonçalves Camilo-Junior
- Dr. Sávio Salvarino Teles de Oliveira
- Me. Lucas Araujo Pereira
- Marcellus Amadeus
- Daniel Fazzioni
- Artur Matos Andrade Novais
- Salatiel Abraão Avelar Jordão
Model Sources
- Repository: CEIA-UFG/Gemma-3-Gaia-PT-BR-4b-it
- Paper (Merge Methodology): Balancing Continuous Pre-Training and Instruction Fine-Tuning: Optimizing Instruction-Following in LLMs
Uses
The model is designed for text generation and conversational tasks in Portuguese.
Direct Use
GAIA can be used directly for chat, question answering, summarization, creative content generation, and other tasks requiring natural language understanding and generation in Portuguese.
Downstream Use
GAIA serves as an excellent base model for fine-tuning on specific tasks, such as:
- Sentiment analysis in Portuguese.
- Retrieval-Augmented Generation (RAG) systems for corporate knowledge bases.
- Document classification.
- Specialized customer service chatbots.
Out-of-Scope Use
This model should not be used for high-stakes, critical decisions without human oversight. Its use for generating malicious, offensive, or illegal content, or for deceptively impersonating a human, is outside the intended scope. The model's performance in languages other than Portuguese will be significantly degraded.
Bias, Risks, and Limitations
Like any language model, GAIA reflects the biases present in its training data. Although the training corpus was curated with a focus on high quality, it may contain social and cultural biases from sources like Wikipedia and scientific articles. Therefore, the model may generate content that perpetuates existing stereotypes.
Furthermore, the model can "hallucinate," meaning it can generate information that appears factual but is not true. We strongly recommend verifying critical facts generated by the model before any use.
Recommendations
Users (both direct and downstream) should be aware of the model's risks, biases, and limitations. Implementing safeguards and content moderation is recommended, especially in public-facing applications. Human supervision is crucial for sensitive use cases.
Training Details
Training Data
The continuous pre-training was performed on a corpus of approximately 13 billion tokens in Portuguese. The data selection prioritized high quality and diversity, including sources such as:
- Scientific Articles in Portuguese: To provide the model with more formal and technical knowledge.
- Portuguese Wikipedia: To cover a wide range of general knowledge.
A rigorous cleaning and filtering process was applied to ensure the highest possible data quality.
Training Procedure
The training was conducted on a DGX infrastructure with NVIDIA H100 GPUs, using between 3 and 5 GPUs in parallel.
Training Hyperparameters
- Training regime: Mixed Precision (bf16)
- Global Batch Size: 4 million tokens
Evaluation
The model was evaluated on a set of multiple-choice benchmarks in Portuguese, comparing its performance against the base model, google/gemma-3-4b-it
. The benchmarks include BlueX (a compilation of multiple-choice questions), and questions from the ENEM (Brazilian High School National Exam) and OAB (Brazilian Bar Exam).
Results
Benchmark | google/gemma-3-4b-it (Baseline) |
GAIA (Our Model) |
---|---|---|
BlueX | 0.6630 | 0.6575 |
ENEM 2024 | 0.6556 | 0.7000 |
ENEM (General) | 0.7416 | 0.7486I |
OAB (Bar Exam) | 0.4502 | 0.4416 |
Summary
The results indicate that continuous pre-training on Portuguese data had a notable impact on the model's performance. GAIA showed a significant improvement on the ENEM 2024 benchmark, outperforming the Google base model. On other benchmarks like BlueX and OAB, its performance is competitive and very close to the original model's, suggesting that the additional training process maintained the model's general capabilities while enhancing its knowledge in specific Portuguese-language domains.
Citation
If you use this model in your research or application, please cite our work.
BibTeX:
@misc{gaia-gemma-3-4b-2025,
title={GAIA: An Open Language Model for Brazilian Portuguese},
author={CAMILO-JUNIOR, C. G.; OLIVEIRA, S. S. T.; PEREIRA, L. A.; AMADEUS, M.; FAZZIONI, D.; NOVAIS, A. M. A.; JORDÃO, S. A. A.},
year={2025},
publisher={Hugging Face},
journal={Hugging Face repository},
howpublished={\url{[https://huggingface.co/CEIA-UFG/Gemma-3-Gaia-PT-BR-4b-it](https://huggingface.co/CEIA-UFG/Gemma-3-Gaia-PT-BR-4b-it)}}
}
<!--End Original Model Card-->
---
# <span id="testllm" style="color: #7F7FFF;">🚀 If you find these models useful</span>
Help me test my **AI-Powered Quantum Network Monitor Assistant** with **quantum-ready security checks**:
👉 [Quantum Network Monitor](https://readyforquantum.com/?assistant=open&utm_source=huggingface&utm_medium=referral&utm_campaign=huggingface_repo_readme)
The full Open Source Code for the Quantum Network Monitor Service available at my github repos ( repos with NetworkMonitor in the name) : [Source Code Quantum Network Monitor](https://github.com/Mungert69). You will also find the code I use to quantize the models if you want to do it yourself [GGUFModelBuilder](https://github.com/Mungert69/GGUFModelBuilder)
💬 **How to test**:
Choose an **AI assistant type**:
- `TurboLLM` (GPT-4.1-mini)
- `HugLLM` (Hugginface Open-source models)
- `TestLLM` (Experimental CPU-only)
### **What I’m Testing**
I’m pushing the limits of **small open-source models for AI network monitoring**, specifically:
- **Function calling** against live network services
- **How small can a model go** while still handling:
- Automated **Nmap security scans**
- **Quantum-readiness checks**
- **Network Monitoring tasks**
🟡 **TestLLM** – Current experimental model (llama.cpp on 2 CPU threads on huggingface docker space):
- ✅ **Zero-configuration setup**
- ⏳ 30s load time (slow inference but **no API costs**) . No token limited as the cost is low.
- 🔧 **Help wanted!** If you’re into **edge-device AI**, let’s collaborate!
### **Other Assistants**
🟢 **TurboLLM** – Uses **gpt-4.1-mini** :
- **It performs very well but unfortunatly OpenAI charges per token. For this reason tokens usage is limited.
- **Create custom cmd processors to run .net code on Quantum Network Monitor Agents**
- **Real-time network diagnostics and monitoring**
- **Security Audits**
- **Penetration testing** (Nmap/Metasploit)
🔵 **HugLLM** – Latest Open-source models:
- 🌐 Runs on Hugging Face Inference API. Performs pretty well using the lastest models hosted on Novita.
### 💡 **Example commands you could test**:
1. `"Give me info on my websites SSL certificate"`
2. `"Check if my server is using quantum safe encyption for communication"`
3. `"Run a comprehensive security audit on my server"`
4. '"Create a cmd processor to .. (what ever you want)" Note you need to install a [Quantum Network Monitor Agent](https://readyforquantum.com/Download/?utm_source=huggingface&utm_medium=referral&utm_campaign=huggingface_repo_readme) to run the .net code on. This is a very flexible and powerful feature. Use with caution!
### Final Word
I fund the servers used to create these model files, run the Quantum Network Monitor service, and pay for inference from Novita and OpenAI—all out of my own pocket. All the code behind the model creation and the Quantum Network Monitor project is [open source](https://github.com/Mungert69). Feel free to use whatever you find helpful.
If you appreciate the work, please consider [buying me a coffee](https://www.buymeacoffee.com/mahadeva) ☕. Your support helps cover service costs and allows me to raise token limits for everyone.
I'm also open to job opportunities or sponsorship.
Thank you! 😊
- Downloads last month
- 2,037
2-bit
3-bit
4-bit
5-bit
6-bit
8-bit
16-bit
Model tree for Mungert/Gemma-3-Gaia-PT-BR-4b-it-GGUF
Base model
google/gemma-3-4b-pt