Skip to content

feat(docs): add interactive kubernetes manifest generator for heterogeneous devices - #744

Open
harshitnub077 wants to merge 2 commits into
Project-HAMi:masterfrom
harshitnub077:feature/interactive-manifest-generator
Open

feat(docs): add interactive kubernetes manifest generator for heterogeneous devices#744
harshitnub077 wants to merge 2 commits into
Project-HAMi:masterfrom
harshitnub077:feature/interactive-manifest-generator

Conversation

@harshitnub077

@harshitnub077 harshitnub077 commented Aug 8, 2026

Copy link
Copy Markdown

Fixes #743

Problem

Users must manually navigate various documentation pages to figure out the correct Kubernetes resources.limits annotations for their specific hardware vendor, increasing friction for new adopters.

Solution

This PR introduces a native, interactive React component (<ManifestGenerator />) directly into the Docusaurus User Guide. Users can select their target hardware vendor, memory mode, and core requirements to dynamically render a copy-pasteable, syntax-highlighted Kubernetes Pod configuration.

Architectural Considerations

To ensure this component seamlessly integrates with the existing HAMi Docusaurus architecture, the following design decisions were made:

  1. Perfect SSR (Zero Hydration Mismatches):
    The YAML state generation utilizes useMemo instead of useEffect. This ensures the exact HTML for the YAML <CodeBlock> is generated server-side during the SSG build (npm run build), preventing layout shifts and hydration errors on the client.
  2. i18n Compliant:
    All UI text strings are strictly wrapped in @docusaurus/Translate components, allowing the localization team to seamlessly extract and translate the UI for the Chinese (zh) locale using npm run write-translations.
  3. Accessibility (a11y) & Theming:
    All form inputs utilize strict id and htmlFor pairings for screen readers. The component CSS module natively uses Infima CSS variables to instantly support Light/Dark mode toggling.
  4. Input Validation:
    Memory and Core inputs are strictly sanitized using Math.max(0, parseInt(value)) to prevent invalid YAML generation.

Testing

  • Verified npm run build:fast passes with zero compilation/hydration warnings.
  • Tested Light/Dark mode contrast compliance.
  • Verified vendor constraint logic (e.g. locking Cambricon to percentage-based memory).

Signed-off-by: harshit kudhial harshitkudhial@gmail.com

Summary by CodeRabbit

  • New Features

    • Added an interactive manifest generator for creating Kubernetes GPU resource configurations across multiple vendors.
    • Added advanced device selection by type or UUID, with vendor-specific memory and core allocation options.
    • Added a new SGLang deployment lab covering GPU partitioning, inference testing, and cleanup.
  • Documentation

    • Expanded troubleshooting guidance with diagnostic flows and command references.
    • Added English and Chinese guides for the interactive manifest generator.
    • Updated documentation navigation to include the new guide and SGLang lab.

Copilot AI lite review requested due to automatic review settings August 8, 2026 18:08
@hami-robot

hami-robot Bot commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: harshitnub077
Once this PR has been reviewed and has the lgtm label, please assign windsonsea for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@hami-robot
hami-robot Bot requested a review from wawa0210 August 8, 2026 18:08
@hami-robot
hami-robot Bot requested a review from windsonsea August 8, 2026 18:08
@netlify

netlify Bot commented Aug 8, 2026

Copy link
Copy Markdown

Deploy Preview for project-hami ready!

Name Link
🔨 Latest commit 13fd930
🔍 Latest deploy log https://app.netlify.com/projects/project-hami/deploys/6a777284c18e5f0008f94a37
😎 Deploy Preview https://deploy-preview-744--project-hami.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@harshitnub077, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 52 minutes

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: e718903f-7a22-4e8a-93c3-8552a1a46d96

📥 Commits

Reviewing files that changed from the base of the PR and between 03a784f and 13fd930.

📒 Files selected for processing (3)
  • docs/userguide/interactive-manifest-generator.md
  • i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md
  • src/components/ManifestGenerator/index.js
📝 Walkthrough

Walkthrough

The PR adds an interactive multi-vendor Kubernetes manifest generator, English and Chinese usage documentation, troubleshooting guidance, and an SGLang GPU-partitioning lab tutorial with sidebar navigation entries.

Changes

Manifest Generator

Layer / File(s) Summary
Manifest generator implementation
src/components/ManifestGenerator/index.js, src/components/ManifestGenerator/styles.module.css
Adds vendor-specific resource metadata, configuration controls, YAML generation, optional annotations, YAML preview, and responsive styling.
Manifest generator documentation and navigation
docs/userguide/interactive-manifest-generator.md, i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md, sidebars.js
Documents the component in English and Chinese, including advanced device selection and vendor capability differences. Adds the page to the User Guide sidebar.

Troubleshooting Guide

Layer / File(s) Summary
Troubleshooting guide reorganization
docs/troubleshooting/troubleshooting.md
Adds installation, scheduling, and runtime sections, a diagnostic flowchart, troubleshooting commands, and guidance for device plugins, containerd, pending Pods, GPU memory, and unsupported workloads.

SGLang Lab

Layer / File(s) Summary
SGLang GPU-partitioning lab
tutorials/labs/hami-sglang.md, sidebars-tutorials.js
Adds a Lab 7 tutorial for HAMi-partitioned SGLang deployment, service access, inference testing, and cleanup. Registers it as an Intermediate 45-minute lab.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Sequence Diagram(s)

sequenceDiagram
  actor Author
  participant ManifestGenerator
  participant YAMLPreview
  Author->>ManifestGenerator: Select vendor and resource settings
  ManifestGenerator->>ManifestGenerator: Generate vendor-specific Pod YAML
  ManifestGenerator->>YAMLPreview: Render generated YAML
Loading

Possibly related PRs

Suggested labels: kind/feature

Suggested reviewers: rootsongjc

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning The troubleshooting guide, SGLang tutorial, and related sidebar changes are unrelated to the linked manifest generator issue. Move the troubleshooting and SGLang tutorial changes to separate pull requests, or link issues that explicitly require them.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the primary change: adding an interactive Kubernetes manifest generator for heterogeneous devices.
Linked Issues check ✅ Passed The component supports the requested vendors, memory and core settings, dynamic YAML generation, resource limits, and copy-pasteable output.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot added the kind/feature new function label Aug 8, 2026
…eneous devices

Signed-off-by: harshit kudhial <harshitkudhial@gmail.com>
@harshitnub077
harshitnub077 force-pushed the feature/interactive-manifest-generator branch from 03a784f to 4577338 Compare August 8, 2026 18:10
@hami-robot hami-robot Bot added size/L and removed size/XL labels Aug 8, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 11

🧹 Nitpick comments (1)
tutorials/labs/hami-sglang.md (1)

63-63: 🩺 Stability & Availability | 🔵 Trivial | ⚡ Quick win

Pin the SGLang image used by the lab.

Lines 63 and 90 use lmsysorg/sglang:latest. A mutable tag can change the SGLang and CUDA stack between runs. Replace both references with the exact tested version or digest. Official SGLang documentation uses this image family for Docker deployments. (docs.sglang.io)

Proposed manifest change
-          image: lmsysorg/sglang:latest
+          image: lmsysorg/sglang:<tested-version>`@sha256`:<tested-digest>

Also applies to: 90-90

🤖 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 `@tutorials/labs/hami-sglang.md` at line 63, Pin both SGLang image references
in the lab documentation, including the capability statement and the deployment
example, by replacing the mutable lmsysorg/sglang:latest tag with the exact
tested version or digest. Keep both references consistent.

Source: MCP 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 `@docs/troubleshooting/troubleshooting.md`:
- Around line 24-26: Make the troubleshooting guide vendor-aware: at
docs/troubleshooting/troubleshooting.md:24-26, route OOM diagnosis to the
applicable vendor-specific memory resource instead of hard-coding NVIDIA; at
docs/troubleshooting/troubleshooting.md:83-90, label NVIDIA-only checks or
provide equivalent guidance for other supported vendors; and at
docs/troubleshooting/troubleshooting.md:100-102, inspect allocatable resources
without filtering exclusively on nvidia.com.
- Around line 71-75: Update the HAMi log selectors in the troubleshooting
commands near the scheduler and device-plugin log guidance to use the chart
label key app.kubernetes.io/component with the corresponding component value,
replacing the broad component selector while keeping scheduler and device-plugin
logs distinct.
- Around line 39-43: Update the troubleshooting guidance to state that
pre-v2.3.10 device-plugin images must retain NodeName, while v2.3.10 and later
use NODE_NAME. Revise the manual kubectl edit daemonset command to specify the
DaemonSet name and include the -n kube-system namespace option.

In `@docs/userguide/interactive-manifest-generator.md`:
- Line 8: Update the introductory vendor and configuration description in
docs/userguide/interactive-manifest-generator.md at lines 8-8 to include
Iluvatar, clarify that resources.limits contains resource keys, and state that
device type and UUID constraints are rendered as metadata.annotations. Mirror
the same corrected content in
i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md
at lines 8-8.

In `@src/components/ManifestGenerator/index.js`:
- Around line 255-257: Correct the ManifestGenerator preview text so the
generated kind: Pod YAML is not presented as directly usable in a Deployment;
either add a Deployment output mode or explicitly instruct users to place the
container resources under spec.template.spec. Update the corresponding guidance
in docs/userguide/interactive-manifest-generator.md at line 10 and mirror the
correction in
i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md
at line 10.
- Around line 224-229: Replace the clickable div wrapping the advanced
configuration toggle in ManifestGenerator with a button type="button", add
aria-expanded={advanced}, and retain the existing toggle behavior and label
content. Update the associated styling so the button visually matches the
current advancedToggle and interactiveText appearance.
- Around line 148-151: Update the deviceVendor select onChange handler to reset
coreMode to none when the newly selected vendor lacks the key required by the
currently selected core allocation mode, while preserving supported modes and
the existing vendor/memory-mode updates.
- Around line 105-109: Update the annotation construction in ManifestGenerator
to serialize deviceType and deviceUuid as YAML-safe quoted strings before
interpolating them into annotations, escaping quotes, backslashes, and line
breaks while preserving the existing typeKey and uuidKey conditions.

In `@tutorials/labs/hami-sglang.md`:
- Around line 40-41: Align the SGLang architecture diagram with the Deployment
replica count: update the diagram around SVC, P1, and P2 to show one Pod when
replicas remains 1, preserving the one-virtual-GPU-per-replica description.
- Line 15: Update the SGLang hyperlink in the lab introduction to point directly
to the current HTTPS documentation destination at sgl-project.ai, replacing the
redirecting sgl-project.github.io URL while preserving the surrounding
description.
- Around line 153-163: Update the SGLang startup instructions after the pod
watch to wait for the backend to accept requests before proceeding. Add a
bounded retry against the SGLang API, or configure a readiness probe that
reflects model-loading completion, and ensure the subsequent port-forward/curl
flow runs only after readiness succeeds.

---

Nitpick comments:
In `@tutorials/labs/hami-sglang.md`:
- Line 63: Pin both SGLang image references in the lab documentation, including
the capability statement and the deployment example, by replacing the mutable
lmsysorg/sglang:latest tag with the exact tested version or digest. Keep both
references consistent.
🪄 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: aec70bf6-f465-4087-a977-d53109112434

📥 Commits

Reviewing files that changed from the base of the PR and between cdf5f73 and 03a784f.

⛔ Files ignored due to path filters (96)
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/daocloud-drun-practice.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/hami-version-evolution.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/keith-opening-keynote.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/meetup-banner.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/metax-sgpu-hami.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/networking-session.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/performance-optimization.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shanghai-2025/transwarp-technology.png is excluded by !**/*.png
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shenzhen-2026/meetup-shenzhen-video-qr.png is excluded by !**/*.png
  • static/favicons/android-chrome-192x192.png is excluded by !**/*.png
  • static/favicons/apple-touch-icon.png is excluded by !**/*.png
  • static/favicons/favicon-16x16.png is excluded by !**/*.png
  • static/favicons/favicon-32x32.png is excluded by !**/*.png
  • static/favicons/mstile-150x150.png is excluded by !**/*.png
  • static/img/adopters/ashermed.png is excluded by !**/*.png
  • static/img/adopters/baidu-cloud.png is excluded by !**/*.png
  • static/img/adopters/baihai.jpg is excluded by !**/*.jpg
  • static/img/adopters/boardware.jpg is excluded by !**/*.jpg
  • static/img/adopters/bonc.png is excluded by !**/*.png
  • static/img/adopters/cetc-zh.png is excluded by !**/*.png
  • static/img/adopters/cetc.png is excluded by !**/*.png
  • static/img/adopters/china-merchants-bank.png is excluded by !**/*.png
  • static/img/adopters/china-mobile.png is excluded by !**/*.png
  • static/img/adopters/china-unicom.png is excluded by !**/*.png
  • static/img/adopters/china-university-of-mining-and-technology.jpg is excluded by !**/*.jpg
  • static/img/adopters/coocaa.png is excluded by !**/*.png
  • static/img/adopters/cyintell.png is excluded by !**/*.png
  • static/img/adopters/deeproute.png is excluded by !**/*.png
  • static/img/adopters/dialo.png is excluded by !**/*.png
  • static/img/adopters/donghua-university.png is excluded by !**/*.png
  • static/img/adopters/ecloud.jpg is excluded by !**/*.jpg
  • static/img/adopters/empathy.png is excluded by !**/*.png
  • static/img/adopters/ghostcloud.png is excluded by !**/*.png
  • static/img/adopters/gsafety.jpg is excluded by !**/*.jpg
  • static/img/adopters/guangdong-university-of-technology.jpg is excluded by !**/*.jpg
  • static/img/adopters/guangdong-university-of-technology.png is excluded by !**/*.png
  • static/img/adopters/guangzhou-pingao.jpg is excluded by !**/*.jpg
  • static/img/adopters/h3c.png is excluded by !**/*.png
  • static/img/adopters/hangzhou-lianhui.png is excluded by !**/*.png
  • static/img/adopters/haofan.jpg is excluded by !**/*.jpg
  • static/img/adopters/harbin-institute-of-technology.png is excluded by !**/*.png
  • static/img/adopters/i-tudou.png is excluded by !**/*.png
  • static/img/adopters/infervision.png is excluded by !**/*.png
  • static/img/adopters/institute-of-information-engineering-cas.png is excluded by !**/*.png
  • static/img/adopters/kylinsoft.png is excluded by !**/*.png
  • static/img/adopters/linkedin.png is excluded by !**/*.png
  • static/img/adopters/linklogis.jpg is excluded by !**/*.jpg
  • static/img/adopters/miaoyun.png is excluded by !**/*.png
  • static/img/adopters/msxf.png is excluded by !**/*.png
  • static/img/adopters/nankai-university.png is excluded by !**/*.png
  • static/img/adopters/northsoft.png is excluded by !**/*.png
  • static/img/adopters/pingan-bank.png is excluded by !**/*.png
  • static/img/adopters/pingan-securities.png is excluded by !**/*.png
  • static/img/adopters/ppio.png is excluded by !**/*.png
  • static/img/adopters/ragehealth.png is excluded by !**/*.png
  • static/img/adopters/sangfor.jpg is excluded by !**/*.jpg
  • static/img/adopters/sap.png is excluded by !**/*.png
  • static/img/adopters/si-tech.png is excluded by !**/*.png
  • static/img/adopters/sinochem.png is excluded by !**/*.png
  • static/img/adopters/snow.png is excluded by !**/*.png
  • static/img/adopters/southeast-university.png is excluded by !**/*.png
  • static/img/adopters/szzt.png is excluded by !**/*.png
  • static/img/adopters/tongcheng-travel.png is excluded by !**/*.png
  • static/img/adopters/tum.png is excluded by !**/*.png
  • static/img/adopters/ucloud.png is excluded by !**/*.png
  • static/img/adopters/unicdata.png is excluded by !**/*.png
  • static/img/adopters/viettel.png is excluded by !**/*.png
  • static/img/adopters/weibo.png is excluded by !**/*.png
  • static/img/adopters/weidian.png is excluded by !**/*.png
  • static/img/adopters/woqu.png is excluded by !**/*.png
  • static/img/adopters/xuanyuan-network.png is excluded by !**/*.png
  • static/img/adopters/zstack.png is excluded by !**/*.png
  • static/img/architect.jpg is excluded by !**/*.jpg
  • static/img/blog-hami-at-kubecon-eu-2026-booth.png is excluded by !**/*.png
  • static/img/blog-hami-at-kubecon-eu-2026-kubecon.png is excluded by !**/*.png
  • static/img/blog/flowchart.jpeg is excluded by !**/*.jpeg
  • static/img/blog/hami-pod-scheduler-preparation.png is excluded by !**/*.png
  • static/img/case-studies/ke-holdings.png is excluded by !**/*.png
  • static/img/community/wechat-assistant-qr.jpg is excluded by !**/*.jpg
  • static/img/community/wechat-official-account-qr.jpg is excluded by !**/*.jpg
  • static/img/community/wechat-video-channel-qr.jpg is excluded by !**/*.jpg
  • static/img/contributors/alauda.jpg is excluded by !**/*.jpg
  • static/img/contributors/bit.png is excluded by !**/*.png
  • static/img/contributors/caih.png is excluded by !**/*.png
  • static/img/contributors/cncr.png is excluded by !**/*.png
  • static/img/contributors/glovo.png is excluded by !**/*.png
  • static/img/contributors/hygon.png is excluded by !**/*.png
  • static/img/contributors/iluvatar.png is excluded by !**/*.png
  • static/img/contributors/iqiy.png is excluded by !**/*.png
  • static/img/contributors/jd-zh.png is excluded by !**/*.png
  • static/img/contributors/kunlunxin.jpg is excluded by !**/*.jpg
  • static/img/contributors/memverge.png is excluded by !**/*.png
  • static/img/contributors/metax.png is excluded by !**/*.png
  • static/img/contributors/mthread.png is excluded by !**/*.png
  • static/img/contributors/phancy.png is excluded by !**/*.png
  • static/img/contributors/qxzg-ai.png is excluded by !**/*.png
📒 Files selected for processing (42)
  • docs/troubleshooting/troubleshooting.md
  • docs/userguide/interactive-manifest-generator.md
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/bagualu-intelligent-computing-stack.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/bagualu-performance-delivery.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/beike-hami-partnership.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/beike-vgpu-inference-cluster-practice.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/dcu-practice-implementation.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/dcu-virtualization-basics.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/device-plugin-architecture.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/device-plugin-new-features.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/dra-driver-practice.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/hami-community.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/hami-core-dra-architecture.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/hami-meetup-beijing-banner.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/hami-new-features-capability-matrix.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/hami-v2.7.0-domestic-compute.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/kunlunxin-xpu-adapter.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-beijing-2025/meetup-networking-session.webp
  • i18n/zh/docusaurus-plugin-content-blog/hami-meetup-shenzhen-2026/meetup-shenzhen-group-photo.webp
  • i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md
  • sidebars-tutorials.js
  • sidebars.js
  • src/components/ManifestGenerator/index.js
  • src/components/ManifestGenerator/styles.module.css
  • static/img/case-studies/snow-corp.webp
  • static/img/vllm-meetup-shanghai-2026-recap/li-mengxuan-speaking.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase0-code.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase0-overview.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase1-k8s.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase1-overview.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase2-llmd-detail.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase2-llmd.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase2-mooncake-code.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase2-mooncake.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase2-nccl.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase2-pd.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase3-architecture.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase3-overview.webp
  • static/img/vllm-meetup-shanghai-2026-recap/phase3-result.webp
  • static/img/vllm-meetup-shanghai-2026-recap/title.webp
  • static/img/vllm-meetup-shanghai-2026-recap/vllm-meetup-group-photo.webp
  • tutorials/labs/hami-sglang.md

Comment thread docs/troubleshooting/troubleshooting.md Outdated
Comment on lines +24 to +26
D --> I{Is it an OOM error?}
I -->|Yes| J[Check nvidia.com/gpumem limits]
I -->|No| K[Check libvgpu.so preload]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Make the troubleshooting guide vendor-aware.

The guide supports heterogeneous hardware, but the new diagnostics assume NVIDIA resource names and NVIDIA runtime behavior.

  • docs/troubleshooting/troubleshooting.md#L24-L26: route OOM diagnosis to the vendor-specific memory resource.
  • docs/troubleshooting/troubleshooting.md#L83-L90: label NVIDIA-only checks or add equivalent guidance for other supported vendors.
  • docs/troubleshooting/troubleshooting.md#L100-L102: inspect allocatable resources without filtering only nvidia.com.

Based on the PR objectives and the supplied vendor resource contract, these diagnostics must support more than NVIDIA.

📍 Affects 1 file
  • docs/troubleshooting/troubleshooting.md#L24-L26 (this comment)
  • docs/troubleshooting/troubleshooting.md#L83-L90
  • docs/troubleshooting/troubleshooting.md#L100-L102
🤖 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 `@docs/troubleshooting/troubleshooting.md` around lines 24 - 26, Make the
troubleshooting guide vendor-aware: at
docs/troubleshooting/troubleshooting.md:24-26, route OOM diagnosis to the
applicable vendor-specific memory resource instead of hard-coding NVIDIA; at
docs/troubleshooting/troubleshooting.md:83-90, label NVIDIA-only checks or
provide equivalent guidance for other supported vendors; and at
docs/troubleshooting/troubleshooting.md:100-102, inspect allocatable resources
without filtering exclusively on nvidia.com.

Comment thread docs/troubleshooting/troubleshooting.md Outdated
Comment on lines +39 to +43
- Since v2.3.10, HAMi has changed the `device-plugin` environment variable name from `NodeName` to `NODE_NAME`. If you are using an image version earlier than v2.3.10, the `device-plugin` may fail to start.

To resolve this issue, you have two options:
- Manually edit the DaemonSet using `kubectl edit daemonset` and update the environment variable from `NodeName` to `NODE_NAME`.
- Upgrade the `device-plugin` image to the latest version using Helm:

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Files:"
git ls-files | rg '(^|/)troubleshooting\.md$|docs/.*troubleshooting|sidebars\.js$' || true

echo
echo "Relevant docs lines:"
if [ -f docs/troubleshooting/troubleshooting.md ]; then
  nl -ba docs/troubleshooting/troubleshooting.md | sed -n '1,120p'
fi

echo
echo "Search NodeName/NODE_NAME references:"
rg -n "NodeName|NODE_NAME|v2\.3\.10|device-plugin" -S . --glob '!vendor/**' --glob '!node_modules/**' | sed -n '1,200p'

echo
echo "Helm/manifest references to DEVICE plugins env:"
fd -a '.*' . | rg '(\.yaml$|\.yml$|Chart\.yaml$|values.*\.ya?ml$|README\.md$)' | while read -r f; do
  case "$f" in
    */.git/*|*node_modules*|*/vendor/*) continue;;
  esac
  rg -n "NodeName|NODE_NAME|device-plugin" "$f" -S || true
done | sed -n '1,240p'

Repository: Project-HAMi/website

Length of output: 1594


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "docs/troubleshooting/troubleshooting.md lines 1-120:"
awk 'NR>=1 && NR<=120 { NRp+=1; print NRp":" $0 }' docs/troubleshooting/troubleshooting.md

echo
echo "Relevant environment-variable/version references:"
rg -n "NodeName|NODE_NAME|v2\.3\.10|device-plugin" -S . --glob '!website/**' --glob '!node_modules/**' | sed -n '1,240p'

echo
echo "Manifest-like references in tracked files:"
git ls-files | rg '(^|/)(manifests?|config|helm|charts?|deploy|deployment|daemonset|values.*\.ya?ml|Chart\.yaml|README\.md)$|(\.yaml|\.yml|\.md)$|(\.yaml|\.yml|\.md)$' | while read -r f; do
  case "$f" in
    */.git/*|*node_modules*|*/website/*|*/node_modules/*|*/vendor/*) continue;;
  esac
  if rg -n "NodeName|NODE_NAME|device-plugin" "$f" -S >/tmp/rg_match.$$; then
    echo "FILE $f"
    cat /tmp/rg_match.$$
  fi
done
rm -f /tmp/rg_match.$$

Repository: Project-HAMi/website

Length of output: 50377


🌐 Web query:

Project-HAMi/HAMi v2.3.10 device-plugin NodeName NODE_NAME

💡 Result:

In Project-HAMi/HAMi, the environment variable used by the device-plugin to identify the node was changed from NodeName to NODE_NAME starting in version v2.3.10 [1][2][3]. If you are running a device-plugin image version earlier than v2.3.10, the device-plugin may fail to start because it is looking for the deprecated NodeName variable [1][4]. To resolve this, you have two primary options: 1. Automatic Upgrade: Upgrade the device-plugin to the latest version using Helm, which automatically applies the correct environment variable configuration [1][5]: helm upgrade hami hami/hami -n kube-system 2. Manual Correction: If an upgrade is not immediately possible, you can manually update the DaemonSet configuration [1][6]: Execute kubectl edit daemonset to locate the device-plugin environment variable settings and change NodeName to NODE_NAME [2][7]. This change ensures the device-plugin correctly utilizes the node's information via the downward API (e.g., fieldPath: spec.nodeName) [8]. For current versions of HAMi, the configuration is explicitly set to NODE_NAME in the device-plugin DaemonSet templates [8].

Citations:


Provide the correct pre-v2.3.10 manual fix.

NodeName is correct for pre-v2.3.10 device-plugin images. The manual option should say: keep NodeName for older images and change only to NODE_NAME when using v2.3.10 or later. Also update the command to name the DaemonSet and include -n kube-system.

🤖 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 `@docs/troubleshooting/troubleshooting.md` around lines 39 - 43, Update the
troubleshooting guidance to state that pre-v2.3.10 device-plugin images must
retain NodeName, while v2.3.10 and later use NODE_NAME. Revise the manual
kubectl edit daemonset command to specify the DaemonSet name and include the -n
kube-system namespace option.

Comment thread docs/troubleshooting/troubleshooting.md Outdated
Comment on lines +71 to +75
- **Check Scheduler Logs:** Use the following command to view why the HAMi scheduler rejected a pod:

```bash
kubectl logs -n kube-system -l component=hami-scheduler
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

rg -n -C 4 'hami-scheduler|hami-device-plugin|app\.kubernetes\.io/name|component:' \
  --glob '*.{yaml,yml}' .

Repository: Project-HAMi/website

Length of output: 14568


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== README / docs quick start candidates =="
git ls-files | rg '(^README\.md$|docs/charts|charts|\.(yaml|yml)$)' | head -200

echo
echo "== locate HAMi chart manifests or docs referencing labels =="
rg -n 'app\.kubernetes\.io/name|hami-scheduler|hami-device-plugin|component:' \
  --glob '*.md' --glob '*.mdx' --glob '*.{yaml,yml}' . | head -300

echo
echo "== doc section around cited lines =="
if [ -f docs/troubleshooting/troubleshooting.md ]; then
  sed -n '60,115p' docs/troubleshooting/troubleshooting.md | cat -n
fi

echo
echo "== exact app.kubernetes.io/name=hami occurrences in repo =="
rg -n 'app\.kubernetes\.io/name: hamm|app\.kubernetes\.io/name:\s*hami' --glob '*.{yaml,yml}' . || true

Repository: Project-HAMi/website

Length of output: 50376


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== docs/verbal label usage for HAMi components =="
rg -n -C 2 'app\.kubernetes\.io/component=hami-(scheduler|device-plugin)|app\.kubernetes\.io/name=hami|kubectl logs -n kube-system -l (app|component)=hami' \
  docs i18n --glob '*.md'

echo
echo "== troubleshooting section =="
sed -n '60,115p' docs/troubleshooting/troubleshooting.md | cat -n

echo
echo "== target lab examples around app=hami/name=hami =="
sed -n '300,330p' i18n/zh/docusaurus-plugin-content-docs-tutorials/current/labs/nvml-mock.md | cat -n
sed -n '295,305p' docs/get-started/verify-hami.md | cat -n
sed -n '198,221p' docs/installation/upgrade.md | cat -n

Repository: Project-HAMi/website

Length of output: 14934


Use component labels for HAMi log selectors.

component=hami-scheduler would match any Pod with the same top-level label. Use the chart selectors used elsewhere, such as app.kubernetes.io/component=hami-scheduler and app.kubernetes.io/component=hami-device-plugin, so device-plugin logs are not included in the troubleshooting command at lines 71-75 and 104-105.

🤖 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 `@docs/troubleshooting/troubleshooting.md` around lines 71 - 75, Update the
HAMi log selectors in the troubleshooting commands near the scheduler and
device-plugin log guidance to use the chart label key
app.kubernetes.io/component with the corresponding component value, replacing
the broad component selector while keeping scheduler and device-plugin logs
distinct.

Comment thread docs/userguide/interactive-manifest-generator.md Outdated
Comment thread src/components/ManifestGenerator/index.js Outdated
Comment thread src/components/ManifestGenerator/index.js Outdated
Comment on lines +255 to +257
<p>
<Translate id="manifest.generator.previewDesc">Copy this into your Kubernetes Pod or Deployment spec.</Translate>
</p>

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Do not describe a Pod manifest as directly usable in a Deployment spec.

The generated YAML declares kind: Pod. A Deployment requires a spec.template and cannot accept this manifest unchanged. Add a workload selector that generates Deployment YAML, or state that users must move the container resources into spec.template.spec.

  • src/components/ManifestGenerator/index.js#L255-L257: Correct the preview instruction or add Deployment output.
  • docs/userguide/interactive-manifest-generator.md#L10-L10: Describe the required Deployment template conversion.
  • i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md#L10-L10: Mirror the corrected English instruction.
📍 Affects 3 files
  • src/components/ManifestGenerator/index.js#L255-L257 (this comment)
  • docs/userguide/interactive-manifest-generator.md#L10-L10
  • i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md#L10-L10
🤖 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 `@src/components/ManifestGenerator/index.js` around lines 255 - 257, Correct
the ManifestGenerator preview text so the generated kind: Pod YAML is not
presented as directly usable in a Deployment; either add a Deployment output
mode or explicitly instruct users to place the container resources under
spec.template.spec. Update the corresponding guidance in
docs/userguide/interactive-manifest-generator.md at line 10 and mirror the
correction in
i18n/zh/docusaurus-plugin-content-docs/current/userguide/interactive-manifest-generator.md
at line 10.

Comment thread tutorials/labs/hami-sglang.md Outdated
toc_max_heading_level: 2
---

This lab demonstrates how to deploy [SGLang](https://sgl-project.github.io/), a high-performance LLM serving framework optimized for RadixAttention, on a Kubernetes cluster using HAMi for GPU memory and compute isolation. Upon completion, you will have an OpenAI-compatible model service running SGLang on a partitioned GPU.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Update the SGLang documentation link.

The URL at Line 15 redirects to a moved page. Link directly to the current SGLang documentation destination. (sgl-project.github.io)

As per coding guidelines, external documentation links must be correct and use HTTPS.

Proposed fix
-This lab demonstrates how to deploy [SGLang](https://sgl-project.github.io/), a high-performance LLM serving framework optimized for RadixAttention, on a Kubernetes cluster using HAMi for GPU memory and compute isolation. Upon completion, you will have an OpenAI-compatible model service running SGLang on a partitioned GPU.
+This lab demonstrates how to deploy [SGLang](https://docs.sglang.io/), a high-performance LLM serving framework optimized for RadixAttention, on a Kubernetes cluster using HAMi for GPU memory and compute isolation. Upon completion, you will have an OpenAI-compatible model service running SGLang on a partitioned GPU.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
This lab demonstrates how to deploy [SGLang](https://sgl-project.github.io/), a high-performance LLM serving framework optimized for RadixAttention, on a Kubernetes cluster using HAMi for GPU memory and compute isolation. Upon completion, you will have an OpenAI-compatible model service running SGLang on a partitioned GPU.
This lab demonstrates how to deploy [SGLang](https://docs.sglang.io/), a high-performance LLM serving framework optimized for RadixAttention, on a Kubernetes cluster using HAMi for GPU memory and compute isolation. Upon completion, you will have an OpenAI-compatible model service running SGLang on a partitioned GPU.
🤖 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 `@tutorials/labs/hami-sglang.md` at line 15, Update the SGLang hyperlink in the
lab introduction to point directly to the current HTTPS documentation
destination at sgl-project.ai, replacing the redirecting sgl-project.github.io
URL while preserving the surrounding description.

Sources: Coding guidelines, MCP tools

Comment thread tutorials/labs/hami-sglang.md Outdated
Comment on lines +40 to +41
SVC --> P1["SGLang Pod 1<br/>Meta-Llama-3-8B-Instruct<br/>1 GPU slot / 24 GiB"]
SVC --> P2["SGLang Pod 2<br/>Meta-Llama-3-8B-Instruct<br/>1 GPU slot / 24 GiB"]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Align the architecture diagram with the Deployment.

Lines 40-41 show two SGLang Pods, but Line 79 sets replicas: 1. This conflicts with the one-virtual-GPU-per-replica description. Change the diagram to one Pod, or set replicas: 2 and update the resource prerequisites.

Also applies to: 79-79

🤖 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 `@tutorials/labs/hami-sglang.md` around lines 40 - 41, Align the SGLang
architecture diagram with the Deployment replica count: update the diagram
around SVC, P1, and P2 to show one Pod when replicas remains 1, preserving the
one-virtual-GPU-per-replica description.

Comment thread tutorials/labs/hami-sglang.md Outdated
Comment on lines +153 to +163
Wait for the SGLang pod to become `Running`. Since it needs to download the Llama 3 weights, this might take several minutes depending on your network speed.

```bash
kubectl get pods -l app=sglang -w
```

Once running, port-forward the service to your local machine:

```bash
kubectl port-forward svc/sglang-service 30000:30000
```

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== locate file =="
git ls-files | grep -F 'tutorials/labs/hami-sglang.md' || true

echo "== relevant file excerpt =="
sed -n '1,230p' tutorials/labs/hami-sglang.md

echo "== search Sglang/sglang definitions =="
rg -n "sglang|SGLang|sglang-image|model|readiness|liveness|deployment|svc/sglang-service|kubectl port-forward" -S .

Repository: Project-HAMi/website

Length of output: 277


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== repository root =="
pwd
echo "== top-level files/dirs =="
git ls-files | sed -n '1,120p'
echo "== files around hami-sglang =="
git ls-files | grep -i 'sglang\|hami' | sed -n '1,200p'
echo "== search target identifiers across repo =="
rg -n -i 'hami-sglang|sglang|SGLang|svc/sglang-service|kubectl port-forward|model initialization|model loading' . || true

Repository: Project-HAMi/website

Length of output: 22881


Wait for the SGLang backend to accept requests before using it.

kubectl get pods -w only watches the Pod phase. A Running SGLang container can still be loading model weights, so the port-forward or API request can fail. Use a bounded retry against the server, or add readiness-probe support that reflects the container/image readiness before the curl call.

🤖 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 `@tutorials/labs/hami-sglang.md` around lines 153 - 163, Update the SGLang
startup instructions after the pod watch to wait for the backend to accept
requests before proceeding. Add a bounded retry against the SGLang API, or
configure a readiness probe that reflects model-loading completion, and ensure
the subsequent port-forward/curl flow runs only after readiness succeeds.

Source: MCP tools

…t generator

Signed-off-by: harshit kudhial <harshitkudhial@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Implement Interactive Kubernetes Manifest Generator for heterogeneous devices

2 participants