Edit model card

Modello Italia 9B

HF-compatible version of Modello Italia 9B, developed by iGenius.

import torch
import transformers as tr

tokenizer = tr.AutoTokenizer.from_pretrained("riccorl/Modello-Italia-9B-hf")
model = tr.AutoModelForCausalLM.from_pretrained(
  "riccorl/Modello-Italia-9B-hf",
  device_map="auto",
  torch_dtype=torch.bfloat16
)

MY_SYSTEM_PROMPT_SHORT = (
  "Tu sei Modello Italia, un modello di linguaggio naturale addestrato da iGenius."
)
prompt = "Ciao, chi sei?"
messages = [
  {"role": "system", "content": MY_SYSTEM_PROMPT_SHORT},
  {"role": "user", "content": prompt},
]
tokenized_chat = tokenizer.apply_chat_template(
  messages, tokenize=True, add_generation_prompt=True, return_tensors="pt"
)
out = model.generate(tokenized_chat.to("cuda"), max_new_tokens=200)

License: MIT(?)

License PDF: https://secure.igenius.ai/legal/italia_terms_and_conditions.pdf

Downloads last month
63
Safetensors
Model size
8.54B params
Tensor type
BF16
·
Inference API
Input a message to start chatting with riccorl/Modello-Italia-9B-hf.
Model is too large to load in Inference API (serverless). To try the model, launch it on Inference Endpoints (dedicated) instead.