Upload folder using huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,82 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
datasets:
|
| 4 |
+
- faur-ai/fulg
|
| 5 |
+
language:
|
| 6 |
+
- ro
|
| 7 |
+
---
|
| 8 |
+
|
| 9 |
+
# LLMic Model Card
|
| 10 |
+
|
| 11 |
+
[LLMic: Romanian Foundation Language Model](https://arxiv.org/abs/2501.07721)
|
| 12 |
+
|
| 13 |
+
## Model Summary
|
| 14 |
+
|
| 15 |
+
LLMic is a bilingual Romanian-English foundation model. LLmic is a 3B
|
| 16 |
+
parameters dense decoder-only Transformer model based on Llama2.
|
| 17 |
+
|
| 18 |
+
This is the v2 of the model, with **casing** and **diacritics**.
|
| 19 |
+
|
| 20 |
+
## Architecture
|
| 21 |
+
|
| 22 |
+
| Parameter | Value |
|
| 23 |
+
|-----------|---------|
|
| 24 |
+
| Sequence Length | 2048 |
|
| 25 |
+
| Number of Layers | 24 |
|
| 26 |
+
| Embedding Size | 2,560 |
|
| 27 |
+
| FFN Hidden Size | 10,240 |
|
| 28 |
+
| Number of Heads | 20 |
|
| 29 |
+
| Number of KV Heads | 5 |
|
| 30 |
+
| Activation Function | SiLU |
|
| 31 |
+
| Position Encodings | RoPE (Θ=500,000) |
|
| 32 |
+
| Layer Norm | RMSNorm (ε=10⁻⁵) |
|
| 33 |
+
| Tied Embeddings | No |
|
| 34 |
+
|
| 35 |
+
## Intended Use
|
| 36 |
+
|
| 37 |
+
Our model is designed to accelerate research on Romanian language models, serving as a building block for generative AI applications.
|
| 38 |
+
|
| 39 |
+
## Use with transformers
|
| 40 |
+
|
| 41 |
+
```python
|
| 42 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM, TextStreamer
|
| 43 |
+
|
| 44 |
+
device = "cuda"
|
| 45 |
+
model_id = "faur-ai/LLMic_v2"
|
| 46 |
+
prompt = "Capitala României este"
|
| 47 |
+
|
| 48 |
+
model = AutoModelForCausalLM.from_pretrained(model_id).to(device)
|
| 49 |
+
tokenizer = AutoTokenizer.from_pretrained(model_id)
|
| 50 |
+
streamer = TextStreamer(tokenizer)
|
| 51 |
+
|
| 52 |
+
inputs = tokenizer.encode(
|
| 53 |
+
prompt,
|
| 54 |
+
add_special_tokens=False,
|
| 55 |
+
return_tensors='pt',
|
| 56 |
+
).to(device)
|
| 57 |
+
|
| 58 |
+
outputs = model.generate(
|
| 59 |
+
streamer=streamer,
|
| 60 |
+
input_ids=inputs,
|
| 61 |
+
temperature=0.8,
|
| 62 |
+
do_sample=True
|
| 63 |
+
)
|
| 64 |
+
```
|
| 65 |
+
|
| 66 |
+
|
| 67 |
+
## Citation
|
| 68 |
+
|
| 69 |
+
**BibTeX:**
|
| 70 |
+
|
| 71 |
+
```
|
| 72 |
+
@misc{bădoiu2025llmicromanianfoundationlanguage,
|
| 73 |
+
title={LLMic: Romanian Foundation Language Model},
|
| 74 |
+
author={Vlad-Andrei Bădoiu and Mihai-Valentin Dumitru and Alexandru M. Gherghescu and Alexandru Agache and Costin Raiciu},
|
| 75 |
+
year={2025},
|
| 76 |
+
eprint={2501.07721},
|
| 77 |
+
archivePrefix={arXiv},
|
| 78 |
+
primaryClass={cs.CL},
|
| 79 |
+
url={https://arxiv.org/abs/2501.07721},
|
| 80 |
+
}
|
| 81 |
+
```
|
| 82 |
+
|