### What this PR does / why we need it?
This PR pins the transformers dependency to 4.57.1.
Reason: CI tests (specifically test_completion_with_prompt_embeds.py)
are failing with an AttributeError: 'dict' object has no attribute
'model_type' when using newer versions of transformers.
The issue stems from a bug in tokenization_utils_base.py where the code
attempts to access the model_type field of a configuration dictionary
(_config) using dot notation (_config.model_type) instead of dictionary
key lookup (_config["model_type"] or _config.get("model_type")). This
occurs in the logic block checking for transformers_version <= 4.57.2.
Pinning the version to 4.57.1 bypasses this buggy code path and restores
CI stability.
Error Traceback:
``` shell
/usr/local/python3.11.13/lib/python3.11/site-packages/transformers/tokenization_utils_base.py:2419:
if _is_local and _config.model_type not in [
E AttributeError: 'dict' object has no attribute 'model_type'
```
- vLLM main:
2918c1b49c
Signed-off-by: MrZ20 <2609716663@qq.com>
33 lines
529 B
Plaintext
33 lines
529 B
Plaintext
# Should be mirrored in pyporject.toml
|
|
cmake>=3.26
|
|
decorator
|
|
einops
|
|
numpy<2.0.0
|
|
packaging
|
|
pip
|
|
pybind11
|
|
pyyaml
|
|
scipy
|
|
pandas
|
|
setuptools>=64
|
|
setuptools-scm>=8
|
|
torch==2.7.1
|
|
torchvision
|
|
wheel
|
|
pandas-stubs
|
|
opencv-python-headless<=4.11.0.86 # Required to avoid numpy version conflict with vllm
|
|
|
|
# requirements for disaggregated prefill
|
|
msgpack
|
|
quart
|
|
|
|
# Required for N-gram speculative decoding
|
|
numba
|
|
|
|
# Install torch_npu
|
|
#--pre
|
|
#--extra-index-url https://mirrors.huaweicloud.com/ascend/repos/pypi
|
|
torch-npu==2.7.1
|
|
|
|
transformers<=4.57.1
|