2024-06-06 01:30:43 +00:00
|
|
|
AVAILABLE_ARCHES = []
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES = {}
|
2024-06-06 01:30:43 +00:00
|
|
|
|
|
|
|
try:
|
|
|
|
from .transformer import SinusoidalEmbedding, Block as TransformerBlock
|
|
|
|
AVAILABLE_ARCHES.append("transformer")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["transformer"] = e
|
2024-06-06 01:30:43 +00:00
|
|
|
pass
|
|
|
|
|
|
|
|
try:
|
|
|
|
from .retnet import RetNetDecoder, RetNetConfig
|
|
|
|
AVAILABLE_ARCHES.append("retnet")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["retnet"] = e
|
2024-06-06 01:30:43 +00:00
|
|
|
pass
|
|
|
|
|
|
|
|
try:
|
|
|
|
from .retnet_syncdoth.retnet_ts import RetNetDecoder as RetNetDecoder_TS, RetNetConfig as RetNetConfig_TS
|
|
|
|
AVAILABLE_ARCHES.append("retnet-ts")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["retnet-ts"] = e
|
2024-06-06 01:30:43 +00:00
|
|
|
pass
|
|
|
|
|
|
|
|
try:
|
|
|
|
from .retnet_syncdoth.retnet_hf import RetNetDecoder as RetNetDecoder_HF, RetNetConfig as RetNetConfig_HF, RetNetForCausalLM
|
|
|
|
AVAILABLE_ARCHES.append("retnet-hf")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["retnet-hf"] = e
|
2024-06-06 01:30:43 +00:00
|
|
|
pass
|
|
|
|
|
|
|
|
try:
|
2024-08-04 00:51:00 +00:00
|
|
|
from .llama import LlamaModel, LlamaConfig, AVAILABLE_ATTENTIONS, LlamaAttention, LlamaAttention_Adapted, LlamaForCausalLM
|
2024-06-06 01:30:43 +00:00
|
|
|
AVAILABLE_ARCHES.append("llama")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["llama"] = e
|
2024-08-27 00:13:34 +00:00
|
|
|
AVAILABLE_ATTENTIONS = []
|
2024-06-06 01:30:43 +00:00
|
|
|
pass
|
|
|
|
|
|
|
|
try:
|
|
|
|
from .bitnet import BitNetTransformer
|
|
|
|
AVAILABLE_ARCHES.append("bitnet")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["bitnet"] = e
|
2024-06-06 01:30:43 +00:00
|
|
|
pass
|
|
|
|
|
|
|
|
try:
|
2024-08-05 03:03:22 +00:00
|
|
|
from .mixtral import MixtralModel, MixtralConfig, MixtralAttention, MixtralAttention_Adapted, load_balancing_loss_func
|
2024-06-06 01:30:43 +00:00
|
|
|
AVAILABLE_ARCHES.append("mixtral")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["mixtral"] = e
|
2024-06-06 01:30:43 +00:00
|
|
|
|
|
|
|
try:
|
2024-06-14 01:08:22 +00:00
|
|
|
from .mamba import MambaMixelModel, MambaLMHeadModel, MambaConfig
|
2024-06-06 01:30:43 +00:00
|
|
|
AVAILABLE_ARCHES.append("mamba")
|
|
|
|
AVAILABLE_ARCHES.append("mamba2")
|
|
|
|
except Exception as e:
|
2024-06-15 00:42:17 +00:00
|
|
|
ERROR_ARCHES["mamba"] = e
|
|
|
|
ERROR_ARCHES["mamba2"] = e
|
2024-06-12 03:28:59 +00:00
|
|
|
|
2024-06-15 00:42:17 +00:00
|
|
|
try:
|
|
|
|
from .mamba_vasqu import Mamba2Model_HF, Mamba2Config_HF
|
|
|
|
AVAILABLE_ARCHES.append("mamba2-hf")
|
|
|
|
except Exception as e:
|
2024-08-04 00:51:00 +00:00
|
|
|
ERROR_ARCHES["mamba2-hf"] = e
|