skills/model-optimization/sglang/sglang-ernie45-optimization/SKILL.md
PR-backed optimization manual for Ernie4.5 / Ernie4.5-VL in SGLang. Use when an engineer needs to audit, debug, extend, or document the SGLang Ernie4.5 multimodal runtime, especially the initial VL landing, fused Triton rotary path, and later cos/sin cache rewrite for Ernie4.5-VL.
npx skillsauth add BBuf/AI-Infra-Auto-Driven-SKILLS sglang-ernie45-optimizationInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Ernie4.5 is already supported on the checked SGLang mainline. The high-signal changes for this family are the initial VL bring-up, then two successive rotary embedding optimizations for the vision tower.
Evidence snapshot:
c122d343adb969cd9bbd1af2ca86727a11be3845e88b0fd8ac5b1caa6eb42766035029220053369breferences/pr-history.mdmodel-pr-optimization-history/sglang/ernie45/README.zh.md and README.en.mdUse skills/model-optimization/model-pr-diff-dossier/SKILL.md as the bar.
For Ernie4.5-VL, name the exact rotary path being changed:
original rotary embedding, fused Triton rope, or cached cos/sin route.
sglang/python/sglang/srt/configs/model_config.pysglang/python/sglang/srt/models/ernie45_vl.pysglang/python/sglang/srt/models/ernie45_moe_vl.pysglang/python/sglang/srt/multimodal/processors/ernie45_vl.pysglang/python/sglang/srt/layers/rotary_embedding.py#15679 lands the Ernie4.5-VL and Ernie4.5-MoE-VL runtime plus the multimodal
processor and model-config registration.#18856 adds a fused Triton Q/K rope kernel tailored to Ernie4.5-VL's
(h, w, t) layout.#19743 rewrites the vision tower to use get_rope(...).get_cos_sin(...)
instead of recomputing rotary embeddings for every call.Add Ernie4.5 VL model supportOptimize Ernie4.5-VL rotary embedding with fused triton kernelSupport cos sin cache for Ernie4.5-VLgrid_thw and rotary
indexing.references/pr-history.md: diff-reviewed Ernie4.5 cards.Use skills/model-optimization/model-pr-diff-dossier/SKILL.md as the production bar.
Every PR cited for this family must be based on diff reading, not only PR titles.
development
Perform SGLang code review in the style of human maintainers by consulting the full non-agent PR review episode corpus from project start through the latest refresh (June 2026), including inline review threads, top-level PR comments, review submissions, original multilingual text, and multi-round discussions. Use when reviewing SGLang PRs, diffs, patches, or local changes for correctness, tests, performance, GPU/runtime risks, API compatibility, and maintainability.
documentation
Use when an SGLang, vLLM, or TensorRT-LLM serving/model optimization task needs prior model-family PR evidence. Query and read the PR-driven history docs under model-pr-optimization-history before choosing source paths, fast paths, kernel/fusion ideas, regression risks, or validation lanes.
development
Run an autonomous Humanize-governed vLLM SOTA performance loop for one LLM model: first perform the fixed fair vLLM/SGLang/TensorRT-LLM deployment search and benchmark, then start one RLCR loop that repeatedly decides the gap, profiles the current bottleneck, runs layer/kernel pipeline analysis, patches vLLM code, optionally uses ncu-report-skill for kernel evidence, and revalidates until vLLM matches or beats the best observed framework under the same workload and SLA.
devops
Inspect LLM torch profiler traces at forward-pass, layer, and kernel level. Use when you need layer timings, anchor-kernel boundaries, representative kernel flows, or Perfetto time ranges.