[Bugfix] Register axk1 config to fix A.X-K1 init (#49727)
Signed-off-by: Djordje Ramic <djoramic@amd.com>
This commit is contained in:
@@ -72,6 +72,7 @@ class LazyConfigDict(dict):
|
|||||||
_CONFIG_REGISTRY: dict[str, type[PretrainedConfig]] = LazyConfigDict(
|
_CONFIG_REGISTRY: dict[str, type[PretrainedConfig]] = LazyConfigDict(
|
||||||
afmoe="AfmoeConfig",
|
afmoe="AfmoeConfig",
|
||||||
arctic="ArcticConfig",
|
arctic="ArcticConfig",
|
||||||
|
axk1="AXK1Config",
|
||||||
bagel="BagelConfig",
|
bagel="BagelConfig",
|
||||||
umm="CheersConfig",
|
umm="CheersConfig",
|
||||||
chatglm="ChatGLMConfig",
|
chatglm="ChatGLMConfig",
|
||||||
|
|||||||
@@ -114,7 +114,7 @@ class AXK1Config(PretrainedConfig):
|
|||||||
The dropout ratio for the attention probabilities.
|
The dropout ratio for the attention probabilities.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
model_type = "AXK1"
|
model_type = "axk1"
|
||||||
keys_to_ignore_at_inference = ["past_key_values"]
|
keys_to_ignore_at_inference = ["past_key_values"]
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
|||||||
@@ -261,7 +261,7 @@ class ModelArchConfigConvertorBase:
|
|||||||
if not hasattr(self.hf_text_config, "model_type"):
|
if not hasattr(self.hf_text_config, "model_type"):
|
||||||
return False
|
return False
|
||||||
elif self.hf_text_config.model_type in (
|
elif self.hf_text_config.model_type in (
|
||||||
"AXK1",
|
"axk1",
|
||||||
"deepseek_v2",
|
"deepseek_v2",
|
||||||
"deepseek_v3",
|
"deepseek_v3",
|
||||||
"deepseek_v32",
|
"deepseek_v32",
|
||||||
@@ -290,7 +290,7 @@ class ModelArchConfigConvertorBase:
|
|||||||
return (
|
return (
|
||||||
self.hf_text_config.model.model_type
|
self.hf_text_config.model.model_type
|
||||||
in (
|
in (
|
||||||
"AXK1",
|
"axk1",
|
||||||
"deepseek_v2",
|
"deepseek_v2",
|
||||||
"deepseek_v3",
|
"deepseek_v3",
|
||||||
"deepseek_v32",
|
"deepseek_v32",
|
||||||
|
|||||||
Reference in New Issue
Block a user