Model reference · open weights
salamandra is an open-weight language model from BSC-LT. salamandra-7b-instruct (BF16) weighs 15.5 GB; the smallest configuration that runs it is 2× RTX 3060 12 GB.
For self-hosting, compare this build's requirements below with the GPU you plan to rent.
Summary of the BSC-LT/salamandra-7b-instruct model card, 2026-10-01
What it is
| Released by | BSC-LT |
|---|---|
| Released | 2024-09-30 |
| Parameters | 7.8B |
| VRAM | 15.5 GB for the weights |
What it runs on
| Card | Requests at once | Context max | Memory |
|---|---|---|---|
| 8K each | |||
| RTX 3060 12 GB … RTX 4060 Ti 16 GB 2 smaller cards | |||
| RTX 3090 24 GB | 6 | all 8K | 23.4 GB |
| RTX 4090 24 GB | 6 | all 8K | 23.4 GB |
| RTX 5090 32 GB | 13 | all 8K | 31.0 GB |
| L40S 48 GB | 25 | all 8K | 44.0 GB |
| A100 80 GB | 57 | all 8K | 78.2 GB |
| H100 80 GB | 52 | all 8K | 78.1 GB |
| RTX PRO 6000 Blackwell 96 GB | 67 | all 8K | 93.8 GB |
| DGX Spark (GB10) 128 GB unified | 79 | all 8K | 107 GB |
| H200 141 GB | 108 | all 8K | 138 GB |
| B200 180 GB | 143 | all 8K | 176 GB |
| 2× RTX 3060 12 GB tensor parallel | 5 | all 8K | 11.6 GB a card |
| 2× RTX 4060 Ti 16 GB tensor parallel | 12 | all 8K | 15.4 GB a card |
| 2× RTX 4090 24 GB tensor parallel | 27 | all 8K | 23.4 GB a card |
| 2× RTX 3090 24 GB tensor parallel | 27 | all 8K | 23.4 GB a card |
| Requests at once | 8K tokens each |
|---|---|
| 1 | 17.5 GB |
| 5 | 21.8 GB |
| 8 | 25.0 GB |
| 16 | 33.6 GB |
| 32 | 50.7 GB |
| 64 | 85.1 GB |
One card, with vLLM's small-card settings.
From the model card
This repository contains the model described in Salamandra Technical Report.
Salamandra is a highly multilingual model pre-trained from scratch that comes in three different sizes — 2B, 7B and 40B parameters — with their respective base and instruction-tuned variants. This model card corresponds to the 7B instructed version.
To visit the model cards of other Salamandra versions, please refer to the Model Index.
The entire Salamandra family is released under a permissive Apache 2.0 license. Along with the open weights, all training scripts and configuration files are made publicly available in this GitHub repository.
[!WARNING] DISCLAIMER: This model is a first proof-of-concept designed to demonstrate the instruction-following capabilities of recently released base models. It has been optimized to engage in conversation but has NOT been aligned through RLHF to filter or avoid sensitive topics. As a result, it may generate harmful or inappropriate content. The team is actively working to enhance its performance through further instruction and alignment with RL techniques.
Transformer-based decoder-only language model that has been pre-trained from scratch on 12.875 trillion tokens of highly curated data. The pre-training corpus contains text in 35 European languages and code.
The full list of hyperparameters for each model can be found here.
| Total Parameters | 7,768,117,248 |
| Embedding Parameters | 1,048,576,000 |
| Layers | 32 |
| Hidden size | 4,096 |
| Attention heads | 32 |
| Context length | 8,192 |
| Vocabulary size | 256,000 |
| Precision | bfloat16 |
| Embedding type | RoPE |
| Activation Function | SwiGLU |
| Layer normalization | RMS Norm |
| Flash attention | ✅ |
| Grouped Query Attention | ✅ |
| Num. query groups | 8 |
The models are intended for both research and commercial use in any of the languages included in the training data. The base models are intended either for language generation or to be further fine-tuned for specific use-cases. The instruction-tuned variants can be used as general-purpose assistants, as long as the user is fully aware of the model’s limitations.
The model is not intended for malicious activities, such as harming others or violating human rights. Any downstream application must comply with current laws and regulations. Irresponsible usage in production environments without proper risk assessment and mitigation is also discouraged.
Pre-training was conducted using NVIDIA’s NeMo Framework, which leverages PyTorch Lightning for efficient model training in highly distributed settings.
The instruction-tuned versions were produced with FastChat.
All models were trained on MareNostrum 5, a pre-exascale EuroHPC supercomputer hosted and operated by Barcelona Supercomputing Center.
The accelerated partition is composed of 1,120 nodes with the following specifications:
| Model | Nodes | GPUs |
|---|---|---|
| 2B | 64 | 256 |
| 7B | 128 | 512 |
| 40B | 256 / 512 | 1,024 / 2,048 |
The instruction-following models use the commonly adopted ChatML template:
{%- if messages[0]['role'] == 'system' %}{%- set system_message = messages[0]['content'] %}{%- set loop_messages = messages[1:] %}{%- else %}{%- set system_message = 'SYSTEM MESSAGE' %}{%- set loop_messages = messages %}{%- endif %}{%- if not date_string is defined %}{%- set date_string = '2024-09-30' %}{%- endif %}{{ 'system\n' + system_message + '\n' }}{% for message in loop_messages %}{%- if (message['role'] != 'user') and (message['role'] != 'assistant')%}{{ raise_exception('Only user and assitant roles are suported after the initial optional system message.') }}{% endif %}{% if (message['role'] == 'user') != (loop.index0 % 2 == 0) %}{{ raise_exception('After the optional system message, conversation roles must alternate user/assistant/user/assistant/...') }}{% endif %}{{'' + message['role'] + '\n' + message['content'] + '' + '\n'}}{% endfor %}{% if add_generation_prompt %}{{ 'assistant\n' }}{% endif %}
Where system_message is used to guide the model during generation and date_string can be set to allow the model to respond with the current date.
The exact same chat template should be used for an enhanced conversational experience. The easiest way to apply it is by using the tokenizer's built-in functions, as shown in the following snippet.
from datetime import datetime
from transformers import AutoTokenizer, AutoModelForCausalLM
import transformers
import torch
model_id = "BSC-LT/salamandra-7b-instruct"
text = "At what temperature does water boil?"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
device_map="auto",
torch_dtype=torch.bfloat16
)
message = [ { "role": "user", "content": text } ]
date_string = datetime.today().strftime('%Y-%m-%d')
prompt = tokenizer.apply_chat_template(
Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.