-
Notifications
You must be signed in to change notification settings - Fork 699
Fix typos: Correct minor spelling errors in codebase (threashold, Triger , tokenzier , tansfer)
#6446
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…e files, excluding _typos.toml and todo.md.
|
Thanks for your contribution! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
该 PR 旨在统一并修正若干拼写错误(如 tokenzier→tokenizer、threashold→threshold、tansfer→transfer、Triger→Trigger),以减少错误引用与不一致命名带来的维护成本;同时新增/引入了 fastdeploy/input/tokenizer_client.py 以提供异步 tokenizer 编解码客户端能力,并同步更新了 OpenAI serving 与测试用例的引用路径。
Changes:
- 将
fastdeploy.input.tokenzier_client的引用统一修正为fastdeploy.input.tokenizer_client(含 serving、demo、tests)。 - 将健康检查相关关键字参数
time_interval_threashold统一更正为time_interval_threshold(含 engine/entrypoints/cache_manager 与 tests)。 - 在 IPC 队列管理中将
tansfer_done_queue/get_tansfer_done_queue更正为transfer_done_queue/get_transfer_done_queue。
Reviewed changes
Copilot reviewed 16 out of 17 changed files in this pull request and generated 8 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/input/v1/test_tokenizer_client.py | 修正 tokenizer client import 路径拼写 |
| tests/input/test_tokenizer_client.py | 修正 tokenizer client import 路径拼写 |
| tests/entrypoints/test_engine_client.py | 更新健康检查参数名为 time_interval_threshold |
| tests/engine/test_common_engine.py | 更新健康检查参数名为 time_interval_threshold |
| tests/cache_manager/test_cache_transfer_manager.py | 更新 cache manager 健康检查参数名为 time_interval_threshold |
| fastdeploy/worker/hpu_worker.py | 修正注释中的拼写(但仍残留 grpah) |
| fastdeploy/inter_communicator/engine_cache_queue.py | 更正 transfer done 队列相关命名与 IPC register 名称 |
| fastdeploy/input/tokenizer_client.py | 新增异步 tokenizer 编解码客户端与请求模型定义 |
| fastdeploy/entrypoints/openai/v1/serving_chat.py | 修正 tokenizer client import 路径拼写 |
| fastdeploy/entrypoints/openai/serving_completion.py | 更新健康检查参数名为 time_interval_threshold |
| fastdeploy/entrypoints/openai/serving_chat.py | 更新健康检查参数名为 time_interval_threshold |
| fastdeploy/entrypoints/openai/response_processors.py | 修正 tokenizer client import 路径拼写 |
| fastdeploy/entrypoints/engine_client.py | 更正 check_health 参数名为 time_interval_threshold |
| fastdeploy/engine/engine.py | 更正 check_health 参数名为 time_interval_threshold |
| fastdeploy/engine/common_engine.py | 更正 check_health 参数名为 time_interval_threshold |
| fastdeploy/demo/tokenzier_client_demo.py | 修正 tokenizer client import 路径拼写(文件名仍含 typo) |
| fastdeploy/cache_manager/cache_transfer_manager.py | 更正 check_work_status 参数名为 time_interval_threshold |
| def check_health(self, time_interval_threshold=30): | ||
| """ | ||
| Check the health of the model server by checking whether all workers are alive. | ||
| """ |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check_health 参数名更改会导致外部关键字调用不兼容。建议增加对旧参数 time_interval_threashold 的兼容处理(同时逐步弃用),避免升级后运行时直接失败。
| def check_health(self, time_interval_threshold=30): | |
| """ | |
| Check the health of the model server by checking whether all workers are alive. | |
| """ | |
| def check_health(self, time_interval_threshold=30, **kwargs): | |
| """ | |
| Check the health of the model server by checking whether all workers are alive. | |
| """ | |
| # Backward compatibility for deprecated argument name `time_interval_threashold` | |
| if "time_interval_threashold" in kwargs: | |
| if "time_interval_threshold" in kwargs: | |
| raise TypeError( | |
| "check_health() got multiple values for time interval threshold: " | |
| "'time_interval_threshold' and deprecated 'time_interval_threashold'. " | |
| "Please use 'time_interval_threshold' only." | |
| ) | |
| console_logger.warning( | |
| "Argument 'time_interval_threashold' is deprecated and will be removed in a future " | |
| "release. Please use 'time_interval_threshold' instead." | |
| ) | |
| time_interval_threshold = kwargs["time_interval_threashold"] |
| import asyncio | ||
|
|
||
| from fastdeploy.input.tokenzier_client import ( | ||
| from fastdeploy.input.tokenizer_client import ( |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
虽然已把 import 改为 tokenizer_client,但文件名仍为 tokenzier_client_demo.py(tokenizer 拼写错误),与模块名不一致且容易误导。建议重命名该 demo 文件(或增加兼容说明/重定向)以保持一致性。
| import respx | ||
|
|
||
| from fastdeploy.input.tokenzier_client import ( | ||
| from fastdeploy.input.tokenizer_client import ( |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR 标题当前不符合仓库约定的“[CLASS]Title”格式(且包含引号)。建议在标题前添加合适的 tag(如 [Docs] / [BugFix] / [Others]),并去掉多余引号,以便通过仓库的 PR 规范检查。
| def check_health(self, time_interval_threshold=30): | ||
| """ | ||
| Check the health of the model server by checking whether all workers are alive. | ||
|
|
||
| """ |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check_health 的参数名更改属于对外 API 破坏(关键字参数调用会直接报错)。建议保留对 time_interval_threashold 的兼容映射一段时间,并在日志/告警中提示迁移到 time_interval_threshold。
| def check_health(self, time_interval_threshold=30): | |
| """ | |
| Check the health of the model server by checking whether all workers are alive. | |
| """ | |
| def check_health(self, time_interval_threshold=30, **kwargs): | |
| """ | |
| Check the health of the model server by checking whether all workers are alive. | |
| This method keeps backward compatibility for the deprecated keyword | |
| argument ``time_interval_threashold``. Please migrate to using | |
| ``time_interval_threshold`` instead. | |
| """ | |
| # Backward compatibility for the misspelled keyword argument | |
| if ( | |
| "time_interval_threashold" in kwargs | |
| and time_interval_threshold == 30 | |
| ): | |
| console_logger.warning( | |
| "Argument 'time_interval_threashold' is deprecated and will be " | |
| "removed in a future release. Please use 'time_interval_threshold' instead." | |
| ) | |
| time_interval_threshold = kwargs["time_interval_threashold"] |
| ) | ||
| QueueManager.register( |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
QueueManager.register 的暴露方法名从 get_tansfer_done_queue 改为 get_transfer_done_queue 属于 IPC 接口变更,可能导致已部署的 client/server 版本不一致时直接连接失败。建议在过渡期同时注册旧名字作为别名(指向同一队列)并逐步弃用。
| ) | |
| QueueManager.register( | |
| ) | |
| # Register legacy IPC name as alias for backward compatibility | |
| QueueManager.register( | |
| "get_tansfer_done_queue", | |
| callable=lambda idx: self.transfer_done_queue_init[idx], | |
| proxytype=ListProxy, | |
| ) | |
| QueueManager.register( |
| raise ValueError("top_logprobs" if is_chat else "logprobs", err_msg) | ||
|
|
||
| def check_health(self, time_interval_threashold=30): | ||
| def check_health(self, time_interval_threshold=30): |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check_health 的参数名从 time_interval_threashold 改为 time_interval_threshold 会破坏所有使用关键字参数的外部调用方。建议为旧参数名保留兼容(例如接受 **kwargs 并对旧名发出 deprecate warning),避免非必要的对外 API 破坏。
| def check_work_status(self, time_interval_threshold=envs.FD_CACHE_PROC_EXIT_TIMEOUT): | ||
| """ | ||
| Check the health of the model server by checking whether all workers are alive. | ||
|
|
||
| """ |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
check_work_status 参数名从 time_interval_threashold 改为 time_interval_threshold 同样会破坏外部关键字调用。建议在函数内部对旧参数名做兼容映射并提供弃用提示。
| def check_work_status(self, time_interval_threshold=envs.FD_CACHE_PROC_EXIT_TIMEOUT): | |
| """ | |
| Check the health of the model server by checking whether all workers are alive. | |
| """ | |
| def check_work_status(self, time_interval_threshold=envs.FD_CACHE_PROC_EXIT_TIMEOUT, **kwargs): | |
| """ | |
| Check the health of the model server by checking whether all workers are alive. | |
| This method keeps backward compatibility for the deprecated argument | |
| name `time_interval_threashold`. Use `time_interval_threshold` instead. | |
| """ | |
| if "time_interval_threashold" in kwargs: | |
| if "time_interval_threshold" in kwargs: | |
| raise TypeError( | |
| "check_work_status() got multiple values for argument " | |
| "'time_interval_threshold' (both 'time_interval_threshold' " | |
| "and deprecated 'time_interval_threashold' were provided)" | |
| ) | |
| # Backward compatibility for deprecated argument name | |
| time_interval_threshold = kwargs.pop("time_interval_threashold") | |
| logger.warning( | |
| "Argument 'time_interval_threashold' is deprecated and will be " | |
| "removed in a future release. Please use 'time_interval_threshold' instead." | |
| ) | |
| if kwargs: | |
| # Do not silently ignore unknown arguments | |
| unknown_keys = ", ".join(kwargs.keys()) | |
| raise TypeError( | |
| f"check_work_status() got unexpected keyword argument(s): {unknown_keys}" | |
| ) |
| logger.info("Skipping warmup bucket, please set HPU_WARMUP_BUCKET=1 to enable it.") | ||
|
|
||
| # 2. Triger cuda grpah capture | ||
| # 2. Trigger cuda grpah capture |
Copilot
AI
Feb 10, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
注释里仍有拼写错误:grpah 应为 graph。
| # 2. Trigger cuda grpah capture | |
| # 2. Trigger cuda graph capture |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #6446 +/- ##
==========================================
Coverage ? 67.71%
==========================================
Files ? 391
Lines ? 52747
Branches ? 8214
==========================================
Hits ? 35715
Misses ? 14423
Partials ? 2609
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This PR fixes minor spelling errors in multiple files,
correcting terms like 'threashold', 'Triger', 'tokenzier', and 'tansfer'.
Motivation
Modifications
Usage or Command
Accuracy Tests
Checklist
[FDConfig],[APIServer],[Engine],[Scheduler],[PD Disaggregation],[Executor],[Graph Optimization],[Speculative Decoding],[RL],[Models],[Quantization],[Loader],[OP],[KVCache],[DataProcessor],[BugFix],[Docs],[CI],[Optimization],[Feature],[Benchmark],[Others],[XPU],[HPU],[GCU],[DCU],[Iluvatar],[Metax]]pre-commitbefore commit.releasebranch, make sure the PR has been submitted to thedevelopbranch, then cherry-pick it to thereleasebranch with the[Cherry-Pick]PR tag.