Skip to content
This repository has been archived by the owner on Oct 25, 2024. It is now read-only.

[NeuralChat] Support Mixtral-8x7B-v0.1 model #972

Merged
merged 7 commits into from
Dec 25, 2023
1 change: 1 addition & 0 deletions intel_extension_for_transformers/neural_chat/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ The table below displays the validated model list in NeuralChat for both inferen
|LLaMA2 series| ✅| ✅|✅| ✅ |
|MPT series| ✅| ✅|✅| ✅ |
|Mistral| ✅| ✅|✅| ✅ |
|Mixtral-8x7b-v0.1| ✅| ✅|✅| ✅ |
|ChatGLM series| ✅| ✅|✅| ✅ |
|Qwen series| ✅| ✅|✅| ✅ |
|StarCoder series| | | | ✅ |
Expand Down
1 change: 1 addition & 0 deletions intel_extension_for_transformers/neural_chat/chatbot.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ def build_chatbot(config: PipelineConfig=None):
"flan-t5" in config.model_name_or_path.lower() or \
"bloom" in config.model_name_or_path.lower() or \
"starcoder" in config.model_name_or_path.lower() or \
"mixtral" in config.model_name_or_path.lower() or \
"codegen" in config.model_name_or_path.lower():
from .models.base_model import BaseModel
adapter = BaseModel()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -489,6 +489,7 @@ def load_model(
or re.search("starcoder", model_name, re.IGNORECASE)
or re.search("codellama", model_name, re.IGNORECASE)
or re.search("mistral", model_name, re.IGNORECASE)
or re.search("mixtral", model_name, re.IGNORECASE)
or re.search("codegen", model_name, re.IGNORECASE)
) and not ipex_int8) or re.search("opt", model_name, re.IGNORECASE):
with smart_context_manager(use_deepspeed=use_deepspeed):
Expand Down Expand Up @@ -545,7 +546,7 @@ def load_model(
)
else:
raise ValueError(f"unsupported model name or path {model_name}, \
only supports FLAN-T5/LLAMA/MPT/GPT/BLOOM/OPT/QWEN/NEURAL-CHAT/MISTRAL/CODELLAMA/STARCODER/CODEGEN now.")
only supports t5/llama/mpt/gptj/bloom/opt/qwen/mistral/mixtral/gpt_bigcode model type now.")
except EnvironmentError as e:
if "not a local folder and is not a valid model identifier" in str(e):
raise ValueError("load_model: model name or path is not found")
Expand Down
Loading