fix(i18n): sync zh protocol documentation with english source (#542) - #719
fix(i18n): sync zh protocol documentation with english source (#542)#719ApurveKaranwal wants to merge 2 commits into
Conversation
…t-HAMi#542) Signed-off-by: ApurveKaranwal <apurvekaranwal282@gmail.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: ApurveKaranwal The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
✅ Deploy Preview for project-hami ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Welcome @ApurveKaranwal! It looks like this is your first PR to Project-HAMi/website 🎉 |
📝 WalkthroughWalkthrough中文协议文档统一描述按设备类型维护的节点握手和注册注解。内容补充设备字段、NVIDIA/MLU 示例、30 秒更新周期、5 分钟失效规则及调度器时间戳同步机制,并删除旧调度决策协议。 Changes设备注册协议文档
Estimated code review effort: 2 (Simple) | ~10 minutes Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🧹 Nitpick comments (1)
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md (1)
19-25: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win补充代码围栏前的空行。
两个版本文档的字段定义和示例代码块前缺少空行。请修复 MD031 警告。
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md#L19-L25: 在 Lines 20 和 25 前添加空行。i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md#L19-L25: 在 Lines 20 和 25 前添加空行。🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md` around lines 19 - 25, 在 i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md 的 19-25 行范围内,在字段定义代码围栏和示例代码围栏前分别添加空行;对 i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md 的 19-25 行执行相同调整,以消除 MD031 警告。Source: Linters/SAST tools
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@i18n/zh/docusaurus-plugin-content-docs/current/developers/protocol.md`:
- Line 28: The second MLU device record in the hami.io/node-mlu-register
annotation is incomplete and missing the device type, device numa, and healthy
fields. Complete the second MLU record with all seven required fields using
appropriate values that match the pattern shown in the first MLU record. Apply
this same fix at all five affected file locations:
i18n/zh/docusaurus-plugin-content-docs/current/developers/protocol.md line 28,
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md
line 28,
i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md
line 28,
i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md
line 28, and
i18n/zh/docusaurus-plugin-content-docs/version-v2.9.0/developers/protocol.md
line 28.
In
`@i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md`:
- Around line 39-41: Close the final text code fence by adding the missing
closing fence at the end of the protocol snippet in
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md
lines 39-41,
i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md
lines 39-41, and
i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md
lines 39-41.
In
`@i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md`:
- Line 6: 将协议文档中的“设备注册”章节标题从三级标题调整为二级标题,使用与 v2.9.0 及文档层级一致的标题级别,并保持标题文本不变。
---
Nitpick comments:
In
`@i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md`:
- Around line 19-25: 在
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md 的
19-25 行范围内,在字段定义代码围栏和示例代码围栏前分别添加空行;对
i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md 的
19-25 行执行相同调整,以消除 MD031 警告。
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 5ef0036a-8858-49e2-8eca-8d92a181e5f5
📒 Files selected for processing (5)
i18n/zh/docusaurus-plugin-content-docs/current/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.9.0/developers/protocol.md
| ```text | ||
| hami.io/node-handshake-\{device-type\}: Requesting_{scheduler_node_current_timestamp} | ||
| ``` |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟠 Major | ⚡ Quick win
关闭三个版本文档中的最后一个代码围栏。
这些文件打开了最后一个 text 代码块,但没有显示关闭围栏。请在每个文件的 Line 41 添加 `````。
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md#L39-L41: 添加关闭围栏。i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md#L39-L41: 添加关闭围栏。i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md#L39-L41: 添加关闭围栏。
📍 Affects 3 files
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md#L39-L41(this comment)i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md#L39-L41i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md#L39-L41
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md`
around lines 39 - 41, Close the final text code fence by adding the missing
closing fence at the end of the protocol snippet in
i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md
lines 39-41,
i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md
lines 39-41, and
i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md
lines 39-41.
…ng levels, and lint errors Signed-off-by: ApurveKaranwal <apurvekaranwal282@gmail.com>
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@versioned_docs/version-v2.6.0/developers/protocol.md`:
- Line 11: Update the v2.6.0 English wording in the device-registration
description: change “each AI devices” to grammatically correct singular/plural
wording, then revise the sentence at the later annotation-history passage to
remove the comma splice and include “the” before “last 5 minutes” and
“scheduler,” matching the current source wording.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 1cdaa7b5-68bd-4369-a14f-da27245c0051
📒 Files selected for processing (10)
docs/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/current/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.mdi18n/zh/docusaurus-plugin-content-docs/version-v2.9.0/developers/protocol.mdversioned_docs/version-v2.6.0/developers/protocol.mdversioned_docs/version-v2.7.0/developers/protocol.mdversioned_docs/version-v2.8.0/developers/protocol.mdversioned_docs/version-v2.9.0/developers/protocol.md
🚧 Files skipped from review as they are similar to previous changes (3)
- i18n/zh/docusaurus-plugin-content-docs/version-v2.8.0/developers/protocol.md
- i18n/zh/docusaurus-plugin-content-docs/version-v2.7.0/developers/protocol.md
- i18n/zh/docusaurus-plugin-content-docs/version-v2.6.0/developers/protocol.md
|
|
||
| <img src="/img/docs/common/developers/protocol/protocol-register.png" width="600px" alt="HAMi project diagram" /> | ||
|
|
||
| HAMi needs to know the spec of each AI devices in the cluster in order to schedule properly. During device registration, device-plugin needs to keep patching the spec of each device into node annotations every 30 seconds, in the format of the following: |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Fix the v2.6.0 English wording.
each AI devices is grammatically incorrect. Line 36 is a comma splice and omits the before last 5 minutes and scheduler. Align both sentences with the current source wording.
Proposed fix
-HAMi needs to know the spec of each AI devices in the cluster in order to schedule properly.
+HAMi needs to know the specifications of each AI device in the cluster to schedule properly.
-A device node may become unavailable due to hardware or network failure, if a node hasn't registered in last 5 minutes, scheduler will mark that node as 'unavailable'.
+A device node may become unavailable due to hardware or network failure. If a node hasn't registered in the last 5 minutes, the scheduler marks that node as 'unavailable'.Also applies to: 36-36
🧰 Tools
🪛 LanguageTool
[style] ~11-~11: Consider a more concise word here.
Context: ... spec of each AI devices in the cluster in order to schedule properly. During device regist...
(IN_ORDER_TO_PREMIUM)
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@versioned_docs/version-v2.6.0/developers/protocol.md` at line 11, Update the
v2.6.0 English wording in the device-registration description: change “each AI
devices” to grammatically correct singular/plural wording, then revise the
sentence at the later annotation-history passage to remove the comma splice and
include “the” before “last 5 minutes” and “scheduler,” matching the current
source wording.
Source: Linters/SAST tools
What type of PR is this?
/kind documentation
What this PR does / why we need it:
This PR syncs the Chinese translation of
developers/protocol.mdwith the English source specification across current dev docs (docs/next) and historical release snapshots (v2.9.0,v2.8.0,v2.7.0,v2.6.0).Summary of Changes:
developers/protocol.mdto describe the correct device registration protocol (hami.io/node-handshake-{device-type}andhami.io/node-{device-type}-register).device-registration.pngwithprotocol-register.png.### 调度决策) and references to legacy annotations (bind-time,vgpu-devices-allocated,task-dispatch.png) that are no longer present in the English source.##vs###) and code block line formatting to their respective English version sources.Which issue(s) this PR fixes:
Fixes #542
Checklist:
npm run lintandnpm run format:checkpassnpm run buildsucceeds for bothenandzhgit commit -s)Summary by CodeRabbit