Feature Extraction
Transformers
Safetensors
English
custom_model
multi-modal
speech-language
custom_code
Eval Results
shangeth commited on
Commit
3f65edd
1 Parent(s): 1a3d63b

Tokenizer update

Browse files
Files changed (2) hide show
  1. config.json +6 -1
  2. model.py +1 -0
config.json CHANGED
@@ -1,13 +1,18 @@
1
  {
 
 
 
2
  "audio_enc_dim": 1280,
3
  "audio_encoder_name": "facebook/hubert-xlarge-ll60k",
4
  "audio_processor_name": "facebook/hubert-large-ls960-ft",
5
  "auto_map": {
6
- "AutoConfig": "config.SpeechLLMModelConfig"
 
7
  },
8
  "llm_dim": 2048,
9
  "llm_model_checkpoint": "hf_repo/llm_model_checkpoint",
10
  "llm_model_name": "TinyLlama/TinyLlama-1.1B-Chat-v1.0",
11
  "model_type": "custom_model",
 
12
  "transformers_version": "4.38.2"
13
  }
 
1
  {
2
+ "architectures": [
3
+ "SpeechLLMModel"
4
+ ],
5
  "audio_enc_dim": 1280,
6
  "audio_encoder_name": "facebook/hubert-xlarge-ll60k",
7
  "audio_processor_name": "facebook/hubert-large-ls960-ft",
8
  "auto_map": {
9
+ "AutoConfig": "config.SpeechLLMModelConfig",
10
+ "AutoModel": "model.SpeechLLMModel"
11
  },
12
  "llm_dim": 2048,
13
  "llm_model_checkpoint": "hf_repo/llm_model_checkpoint",
14
  "llm_model_name": "TinyLlama/TinyLlama-1.1B-Chat-v1.0",
15
  "model_type": "custom_model",
16
+ "torch_dtype": "float32",
17
  "transformers_version": "4.38.2"
18
  }
model.py CHANGED
@@ -39,6 +39,7 @@ class SpeechLLMModel(PreTrainedModel):
39
  llm_config = AutoConfig.from_pretrained(config.llm_model_name)
40
  self.llm_model = AutoModelForCausalLM.from_config(llm_config)
41
  self.llm_tokenizer = AutoTokenizer.from_pretrained(config.llm_model_name)
 
42
 
43
  peft_config = LoraConfig(
44
  r=4,
 
39
  llm_config = AutoConfig.from_pretrained(config.llm_model_name)
40
  self.llm_model = AutoModelForCausalLM.from_config(llm_config)
41
  self.llm_tokenizer = AutoTokenizer.from_pretrained(config.llm_model_name)
42
+ self.llm_tokenizer.pad_token = self.llm_tokenizer.eos_token
43
 
44
  peft_config = LoraConfig(
45
  r=4,