Downloads · 30 days
19
4% of all-time downloads
hishab/titulm-gemma-2-2b-v1.0
titulm-gemma-2-2b-v1.0 is a text generation model from hishab. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as gemma.
This model is a continually pretrained version of the google/gemma-2-2b architecture, fine-tuned on extensive Bangla datasets. The primary goal of the continual pretraining was to enhance the model's ability to genera…
Downloads · 30 days
19
4% of all-time downloads
All-time downloads
454
Public
Parameters
2.6B
52.3 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors5.2 GB · 100%
From the Hugging Face model README
This model is a continually pretrained version of the google/gemma-2-2b architecture, fine-tuned on extensive Bangla datasets. The primary goal of the continual pretraining was to enhance the model's ability to generate high-quality Bangla text. By extending the pretraining process specifically on Bangla data, the model has demonstrated superior performance in Bangla language understanding evaluation benchmarks and text generation tasks.
Model Architecture: Gemma 2 is an auto-regressive language model with optimized transformer architecture.
| Training Data | Params | Input modalities | Output modalities | Context Length | Token count | |
|---|---|---|---|---|---|---|
| Gemma 2 | Hishab curated Bangla text corpus | 2B | Monolingual Text(Bangla) | Monolingual Text(Bangla) | 4096 | 3B tokens |
Below we share some code snippets on how to get quickly started with running the model. First, install the Transformers library with:
pip install -U transformers
Then, copy the snippet from the section that is relevant to your use case.
pipeline APIimport torch
from transformers import pipeline
pipe = pipeline(
"text-generation",
model="titulm-gemma-2-2b-v1.0",
device="cuda",
)
text = "আমাদের দেশের নাম"
outputs = pipe(text, max_new_tokens=2048)
response = outputs[0]["generated_text"]
print(response)
Training Factors: We used llama-factory training library, cloud GPU cluster, and production infrastructure for pretraining. Fine-tuning, annotation, and evaluation were also performed on cloud infrastructure.
Overview: We have collected a large Bangla raw dataset of text data from a wide variety of sources. Our collected data so far includes a mix of web documents, books, translated text, transliterated text, transcribed text, code-mixed text, conversations, and open-source raw data. The dataset is cleaned and filtered by different filtering criteria to ensure the quality of the data. Our collected data size is roughly around 268 GB. We separated 22GB data from that using a ratio of the actual data size. Total trained tokens are 3B tokens.
Data sources summary:
In this section, we report the results for titulm-gemma-2-2b-v1.0 models on standard automatic benchmarks. For all these evaluations, we used lm-evaluation-harness evaluations library.
We evaluated our pre-trained models on both Bangla and English benchmark datasets. Although the model is trained on Bangla data, its English capability is also evaluated on English benchmark datasets. The evaluation datasets are as follows:
We evaluated the models on the following datasets:
| Model | Shots | Bangla MMLU | BoolQ BN | Commonsense QA BN | OpenBook QA BN | PIQA BN |
|---|---|---|---|---|---|---|
| gemma-2-2b | 0-shot | 0.32 | 0.63 | 0.26 | 0.34 | 0.56 |
| 5-shot | 0.35 | 0.46 | 0.28 | 0.33 | 0.56 | |
| titulm-gemma-2-2b-v1.0 | 0-shot | 0.31 | 0.59 | 0.31 | 0.36 | 0.63 |
| 5-shot | 0.35 | 0.59 | 0.41 | 0.37 | 0.62 |
| Model | Shots | MMLU | BoolQ | Commonsense QA | OpenBook QA | PIQA |
|---|---|---|---|---|---|---|
| gemma-2-2b | 0-shot | 0.50 | 0.74 | 0.52 | 0.42 | 0.79 |
| 5-shot | 0.53 | 0.78 | 0.66 | 0.42 | 0.80 | |
| titulm-gemma-2-2b-v1.0 | 0-shot | 0.39 | 0.70 | 0.35 | 0.39 | 0.76 |
| 5-shot | 0.44 | 0.75 | 0.52 | 0.39 | 0.77 |