[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

@@ -13,15 +13,13 @@
# See the License for the specific language governing permissions and
# limitations under the License.
"""
import os
from abc import abstractmethod
from collections.abc import Sequence
from functools import cached_property
from typing import Callable, Optional, Union
from fastdeploy.entrypoints.openai.protocol import (ChatCompletionRequest,
DeltaMessage)
from fastdeploy.utils import data_processor_logger
DeltaMessage)
from fastdeploy.utils import is_list_of
@@ -120,7 +118,8 @@ class ReasoningParserManager:
reasoning_parsers: dict[str, type] = {}
@classmethod
def get_reasoning_parser(cls, name: str | None) -> type[ReasoningParser]:
def get_reasoning_parser(cls,
name: Optional[str]) -> type[ReasoningParser]:
"""
Get reasoning parser by name which is registered by `register_module`.
@@ -185,4 +184,4 @@ class ReasoningParserManager:
cls._register_module(module=module, module_name=name, force=force)
return module
return _register
return _register