Update modeling_internlm3.py
Browse files- modeling_internlm3.py +2 -1
modeling_internlm3.py
CHANGED
|
@@ -793,7 +793,7 @@ class InternLM3Model(InternLM3PreTrainedModel):
|
|
| 793 |
Args:
|
| 794 |
config: InternLM3Config
|
| 795 |
"""
|
| 796 |
-
|
| 797 |
def __init__(self, config: InternLM3Config):
|
| 798 |
super().__init__(config)
|
| 799 |
self.padding_idx = config.pad_token_id
|
|
@@ -1070,6 +1070,7 @@ class KwargsForCausalLM(FlashAttentionKwargs, LossKwargs): ...
|
|
| 1070 |
|
| 1071 |
|
| 1072 |
class InternLM3ForCausalLM(InternLM3PreTrainedModel, GenerationMixin):
|
|
|
|
| 1073 |
_tied_weights_keys = ["lm_head.weight"]
|
| 1074 |
_tp_plan = {"lm_head": "colwise_rep"}
|
| 1075 |
|
|
|
|
| 793 |
Args:
|
| 794 |
config: InternLM3Config
|
| 795 |
"""
|
| 796 |
+
_auto_class = "AutoModel"
|
| 797 |
def __init__(self, config: InternLM3Config):
|
| 798 |
super().__init__(config)
|
| 799 |
self.padding_idx = config.pad_token_id
|
|
|
|
| 1070 |
|
| 1071 |
|
| 1072 |
class InternLM3ForCausalLM(InternLM3PreTrainedModel, GenerationMixin):
|
| 1073 |
+
_auto_class = "AutoModelForCausalLM"
|
| 1074 |
_tied_weights_keys = ["lm_head.weight"]
|
| 1075 |
_tp_plan = {"lm_head": "colwise_rep"}
|
| 1076 |
|