File tree Expand file tree Collapse file tree 6 files changed +4
-81
lines changed Expand file tree Collapse file tree 6 files changed +4
-81
lines changed Original file line number Diff line number Diff line change @@ -6,8 +6,8 @@ pyarrow # Required for Ray data.
6
6
sentencepiece # Required for LLaMA tokenizer.
7
7
numpy
8
8
torch == 2.0.1
9
- transformers >= 4.33.1 # Required for Code Llama .
10
- xformers == 0.0.22
9
+ transformers >= 4.34.0 # Required for Mistral .
10
+ xformers == 0.0.22 # Required for Mistral.
11
11
fastapi
12
12
uvicorn [standard ]
13
13
pydantic < 2 # Required for OpenAI server.
Original file line number Diff line number Diff line change 9
9
from vllm .model_executor .models .gpt_neox import GPTNeoXForCausalLM
10
10
from vllm .model_executor .models .internlm import InternLMForCausalLM
11
11
from vllm .model_executor .models .llama import LlamaForCausalLM
12
+ from vllm .model_executor .models .mistral import MistralForCausalLM
12
13
from vllm .model_executor .models .mpt import MPTForCausalLM
13
14
from vllm .model_executor .models .opt import OPTForCausalLM
14
15
from vllm .model_executor .models .qwen import QWenLMHeadModel
15
- from vllm .model_executor .models .mistral import MistralForCausalLM
16
16
17
17
__all__ = [
18
18
"AquilaForCausalLM" ,
Original file line number Diff line number Diff line change 29
29
30
30
import torch
31
31
from torch import nn
32
+ from transformers import MistralConfig
32
33
33
34
from vllm .model_executor .input_metadata import InputMetadata
34
35
from vllm .model_executor .layers .activation import SiluAndMul
44
45
convert_pyslice_to_tensor , hf_model_weights_iterator ,
45
46
load_tensor_parallel_weights , load_padded_tensor_parallel_vocab )
46
47
from vllm .sequence import SamplerOutput
47
- from vllm .transformers_utils .configs .mistral import MistralConfig
48
48
49
49
KVCache = Tuple [torch .Tensor , torch .Tensor ]
50
50
Original file line number Diff line number Diff line change 17
17
def get_config (model : str ,
18
18
trust_remote_code : bool ,
19
19
revision : Optional [str ] = None ) -> PretrainedConfig :
20
- # NOTE: Because the Mistral model in HF hub does not have
21
- # `configuration_mistral.py`, we cannot use `AutoConfig` to load the
22
- # config. Instead, we use `MistralConfig` directly.
23
- # NOTE: This is a hack. This does not work for local models.
24
- # FIXME: Remove this once the Mistral model is available in the stable
25
- # version of HF transformers.
26
- if "mistral" in model .lower ():
27
- return MistralConfig .from_pretrained (model , revision = revision )
28
-
29
20
try :
30
21
config = AutoConfig .from_pretrained (
31
22
model , trust_remote_code = trust_remote_code , revision = revision )
Original file line number Diff line number Diff line change 6
6
# tiiuae/falcon-7b(-instruct) models. Newer Falcon models will use the
7
7
# `FalconConfig` class from the official HuggingFace transformers library.
8
8
from vllm .transformers_utils .configs .falcon import RWConfig
9
- from vllm .transformers_utils .configs .mistral import MistralConfig
10
9
11
10
__all__ = [
12
11
"MPTConfig" ,
13
12
"BaiChuanConfig" ,
14
13
"AquilaConfig" ,
15
14
"QWenConfig" ,
16
15
"RWConfig" ,
17
- "MistralConfig" ,
18
16
]
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments