big-brain-lm / config.py
Fal7acy's picture
Upload model
5cfa59c
raw
history blame
1.53 kB
from transformers import PretrainedConfig
class BigBrainConfig(PretrainedConfig):
model_type = 'big-brain-lm'
def __init__(
self,
vocab_size=50265,
hidden_size=768,
num_hidden_layers=12,
num_attention_heads=12,
intermediate_size=3072,
hidden_act='gelu',
hidden_dropout_probability=0.1,
attention_probs_dropout_prob=0.1,
max_position_embeddings=512,
initializer_range=0.02,
layer_norm_eps=1e-6,
rope_theta=10000,
sos_token_id=0,
pad_token_id=1,
eos_token_id=2,
unk_token_id=3,
**kwargs
):
self.vocab_size = vocab_size
self.hidden_size = hidden_size
self.num_hidden_layers = num_hidden_layers
self.num_attention_heads = num_attention_heads
self.intermediate_size = intermediate_size
self.hidden_act = hidden_act
self.hidden_dropout_probability = hidden_dropout_probability
self.attention_probs_dropout_prob = attention_probs_dropout_prob
self.max_position_embeddings = max_position_embeddings
self.initializer_range = initializer_range
self.layer_norm_eps = layer_norm_eps
self.rope_theta = rope_theta
self.sos_token_id = sos_token_id
self.pad_token_id = pad_token_id
self.eos_token_id = eos_token_id
self.unk_token_id = unk_token_id
super().__init__(**kwargs)