[Sync] Update to latest code (#2679)

* [Sync] Update to latest code

* Add new code files

* Add new code files

* update code

* Try to fix build.sh

* Try to fix build.sh

* Update code

* Update requirements.txt

* Update code

---------

Co-authored-by: Jiang-Jia-Jun <jiangjiajun@baidu.com>
This commit is contained in:
Jiang-Jia-Jun
2025-07-03 15:43:53 +08:00
committed by GitHub
parent d222248d00
commit 05c670e593
95 changed files with 9916 additions and 1312 deletions

View File

@@ -16,6 +16,7 @@
from functools import cache
from fastdeploy import envs
from fastdeploy.platforms import _Backend, current_platform
from fastdeploy.utils import resolve_obj_from_strname
@@ -40,6 +41,7 @@ def _get_attn_backend(selected_backend: str) -> object:
return resolve_obj_from_strname(attention_cls)
def get_attention_backend(selected_backend):
"""Selects which attention backend ."""
return _get_attn_backend(selected_backend)
def get_attention_backend() -> object:
"""Selects which attention backend."""
attention_backend = envs.FD_ATTENTION_BACKEND
return _get_attn_backend(attention_backend)