Update README.md
Browse files
README.md
CHANGED
|
@@ -1,3 +1,45 @@
|
|
| 1 |
-
---
|
| 2 |
-
|
| 3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
language:
|
| 3 |
+
- it
|
| 4 |
+
- en
|
| 5 |
+
library_name: transformers
|
| 6 |
+
license: apache-2.0
|
| 7 |
+
tags:
|
| 8 |
+
- veronica
|
| 9 |
+
- decoder-only
|
| 10 |
+
- causal-lm
|
| 11 |
+
- gqa
|
| 12 |
+
- rope
|
| 13 |
+
- yarn
|
| 14 |
+
- flash-attn2
|
| 15 |
+
pipeline_tag: text-generation
|
| 16 |
+
model-index:
|
| 17 |
+
- name: Veronica-Core 450M (prototype)
|
| 18 |
+
results: []
|
| 19 |
+
---
|
| 20 |
+
|
| 21 |
+
# Veronica — Custom Causal LM (decoder-only)
|
| 22 |
+
|
| 23 |
+
**Veronica** è un modello *decoder-only* custom, progettato per massimizzare la **profondità effettiva** e la qualità per token con risorse contenute.
|
| 24 |
+
Architettura: **32 layer × 1024 hidden × 16 heads, GQA=4**, **RoPE (θ=1e6) + YaRN scaling** per contesto lungo **32k**.
|
| 25 |
+
Attenzione: **DuoAttention** (stream vs full window) + **SEAL** scaling sulle retrieval-heads. **RMSNorm** + **SwiGLU**.
|
| 26 |
+
|
| 27 |
+
> **Stato**: prototipo in pretraining. Questa repo pubblica **codice + config + tokenizer** per il caricamento via `trust_remote_code=True`. I pesi saranno pubblicati successivamente.
|
| 28 |
+
|
| 29 |
+
## Quickstart
|
| 30 |
+
|
| 31 |
+
```python
|
| 32 |
+
from transformers import AutoTokenizer, AutoModelForCausalLM
|
| 33 |
+
|
| 34 |
+
name = "MhaWay/veronica"
|
| 35 |
+
tok = AutoTokenizer.from_pretrained(name, trust_remote_code=True)
|
| 36 |
+
model = AutoModelForCausalLM.from_pretrained(
|
| 37 |
+
name,
|
| 38 |
+
trust_remote_code=True,
|
| 39 |
+
torch_dtype="auto",
|
| 40 |
+
device_map="auto",
|
| 41 |
+
)
|
| 42 |
+
|
| 43 |
+
prompt = "Spiega in modo semplice cos'è Veronica:"
|
| 44 |
+
out = model.generate(**tok(prompt, return_tensors="pt").to(model.device))
|
| 45 |
+
print(tok.decode(out[0], skip_special_tokens=True))
|