diff --git a/docs/reference-matrix.md b/docs/reference-matrix.md index c44816e3e..98e9b5435 100644 --- a/docs/reference-matrix.md +++ b/docs/reference-matrix.md @@ -575,3 +575,14 @@ create a repo runtime descriptor, backend port or measured resource effect. | Source | Inspected scope | Canonical extraction and boundary | | --- | --- | --- | | [ronak-create/deepseek-v4-in-c](https://github.com/ronak-create/deepseek-v4-in-c/tree/d0402056d0da4bf7edfd2d4977de479a0db9d201) @ `d0402056d0da4bf7edfd2d4977de479a0db9d201` (Apache-2.0 root and selected-file declarations; third-party/model rights excluded) | Bounded source inspection, 2026-11-03: byte/fixture geometry, begin/end slot lifetime, actual model/oracle callback wiring and tiny-reference limits; [selected hashes, regions and rights](../src/inferrsi/knowledge/data/skill_library/playbooks/optimization/weight-loading-optimization/references/deepseek-expert-cache-source.json) | [weight-loading-optimization](../src/inferrsi/knowledge/data/skill_library/playbooks/optimization/weight-loading-optimization/SKILL.md) ([expert-cache oracle reference](../src/inferrsi/knowledge/data/skill_library/playbooks/optimization/weight-loading-optimization/references/deepseek-expert-cache-oracles.md)): independent buffered bytes, usable residents during misses, ordered accumulation and oracle reachability. Source-derived candidate/not_run; historical corruption reports are not reproduced tests, and tiny fixtures do not establish released-model quality or performance. | + +## Ascend service, operator, scheduler and quantization sources + +These four source reviews extend existing procedures. Each records `empirical_validation: not_run` for device and service behavior. + +| Pinned source and license | Inspected implementation and reuse | Existing procedure and readset | +| --- | --- | --- | +| [MindStudio Service Profiler @ `04bd9bf0cb804e7bca92103d47b3ad029b999f51`](https://github.com/Ascend/msserviceprofiler/tree/04bd9bf0cb804e7bca92103d47b3ad029b999f51) (MulanPSL-2.0 (software), CC BY 4.0 (documentation)) | Request and batch correlation, KV counter semantics, async completion and instrumentation overhead. Use aligned device activity to distinguish compute from communication. | [ascend-performance-analysis](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md) · [source notes](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/references/mindstudio-service-attribution.md) | +| [TileLang Ascend 0.1.4 @ `3a93b960d22359de40db86250d335693b4b1a5f4`](https://github.com/tile-ai/tilelang-ascend/tree/3a93b960d22359de40db86250d335693b4b1a5f4) (MIT for the inspected example, separate third-party notices) | Follow one score tile through Cube, Vector and the three-slot pipeline. Verify the generated entry point and match correctness, operator selection and timing boundaries. | [ascend-operator-tuning](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md) · [source notes](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/references/tilelang-ascend-flash-attention.md) | +| [xLLM 0.12.0 @ `90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4`](https://github.com/xLLM-AI/xllm/tree/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4) (Apache-2.0 with component-specific notices) | Identify the selected scheduler, already-computed tokens, decode reservation and native PULL failure before enqueue. Deployment examples do not qualify a topology. | [performance-ceiling-analysis](../src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md) · [source notes](../src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/references/xllm-pd-handoff.md) | +| [msModelSlim @ `d4ee30cb6ed97448f79c80652db6ec0f911a47f9`](https://github.com/Ascend/msmodelslim/tree/d4ee30cb6ed97448f79c80652db6ec0f911a47f9) (MulanPSL-2.0 (product code), CC BY 4.0 under docs/, component-specific notices) | Trace the DeepSeek-V3.1 W4A8 recipe through input conversion, two calibration inputs, per-module precision and consumer-specific export. Loading, held-out quality and serving performance require separate checks. | [ascend-model-adaptation](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md) · [source notes](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/references/msmodelslim-deepseek-w4a8.md) | diff --git a/docs/searchspace-index.json b/docs/searchspace-index.json index 4ee47deb1..d5eefeacc 100644 --- a/docs/searchspace-index.json +++ b/docs/searchspace-index.json @@ -6,7 +6,7 @@ "skill_root": "src/inferrsi/knowledge/data/skill_library", "matrix_sha256": "8e47da7aa4824d160710dee6ec63e91011f399def948b25a6bf74abe1bc45db9", "catalog_sha256": "d243e2ae44c7badc8e68788153de35fe6ac31de618b7499fef6339eadf396871", - "metadata_sha256": "7e3efbdd366d493e8db5fa06c87a45ecbdb4b51bdb55b3dc30679afe697733e5" + "metadata_sha256": "f4399276c8389f33ad81a2a25ccd0ff4392a37635ae9c53943ece4995c84d246" }, "skills": { "ascend-aclgraph-capture-replay": {"path": "systems/platforms/ascend/ascend-aclgraph-capture-replay/SKILL.md", "state": "covered", "coordinates": [["Accelerator", "Configure"], ["Accelerator", "Diagnose"], ["Accelerator", "Optimize"], ["Accelerator", "Verify"]]}, diff --git a/docs/skill-coverage.md b/docs/skill-coverage.md index 45a60da9b..4d92f1500 100644 --- a/docs/skill-coverage.md +++ b/docs/skill-coverage.md @@ -4,7 +4,7 @@ Generated from the registry, SKILL.md frontmatter and the two maintained matrices. **Do not edit by hand**; regenerate after any registry, skill, matrix or frozen-plan change. -- Input digest: `sha256:5a8f15648776120480e4baf2dba29e2e909775795543f51a1035fde748b89630` +- Input digest: `sha256:b1f3b477729a45ae923a5365d905c2715c5aac9d08a09d2dde92017c7aea2a09` - Regenerate: `python tools/build_skill_coverage.py` - Verify without writing: `python tools/build_skill_coverage.py --check` @@ -73,7 +73,7 @@ optimization is fully covered or that any procedure has measured benefit. | [kernel-writing-guide](../src/inferrsi/knowledge/data/skill_library/playbooks/optimization/kernel-writing-guide/SKILL.md) | common | Decision guide for writing custom inference kernels: when to write one, which framework to choose (Triton, CuTe DSL ... | Deciding whether to write a custom inference kernel, routing a kernel pattern to Triton ... | failure_modes, input_contract, produced_artifact, refusal_point
6 advice | 1 Accelerator · Optimize / Diagnose / Configure / Verify | 1 · Systems sources (Dao-AILab/causal-conv1d @ `cd81f0413cad2fc1e6f17e785ac39f59aae690cd` ...)
1 · Systems sources (NVIDIA/TensorRT-LLM @ f33e0e5fd)
1 · Systems sources (huggingface/transformers @ `0dad7b822255a0ae261ec45ae937371e859ffd1a` ...)
1 · Systems sources (mindspore-ai/akg @ `5aa15f3fe4d856eb60cd3b27447e04f5f1fb4dff` ...)
1 · Systems sources (sgl-project/sglang @ `16176278d0180f1a1a578e53e6eef432577876c2` ...)
1 · Systems sources (vllm-project/vllm @ `537a79f0fc5ba564d2bef43d54915b2f80f9f77d` (root ...) | candidate · not_run · 7 readset(s) | no-eval | | [model-sol-analysis](../src/inferrsi/knowledge/data/skill_library/playbooks/measurement/model-sol-analysis/SKILL.md) | common | Walk a whole model to per-phase (prefill, decode) speed-of-light figures under a declared parallel layout - anchored ... | Model-level prefill and decode speed-of-light analysis for decoder-only (optionally ... | failure_modes, input_contract, produced_artifact, refusal_point
5 advice | 1 Accelerator · Diagnose / Verify
4 Network · Diagnose / Verify | 2 · Methodology and corpus references (shenh10/HuggingArch @ `e69d20a028e5b17524aa48b53bddf8b9aad5d15b` ...) | candidate · not_run · 6 readset(s) | no-eval | | [optimization-search-policy](../src/inferrsi/knowledge/data/skill_library/playbooks/planning/optimization-search-policy/SKILL.md) | common | Policy for how an optimization agent should select, order, and stop optimization experiments. Covers candidate ... | Selecting, ordering and stopping optimization experiments: candidate generation ... | failure_modes, input_contract, produced_artifact, refusal_point
5 advice | 1 Accelerator · Optimize | 2 · Methodology and corpus references (JiusiServe/vllm-evolve @ 43cc82c)
2 · Methodology and corpus references (RRSI — arXiv 2609.24972v3)
2 · Methodology and corpus references (arXiv 2608.01867 (CRISP))
2 · Methodology and corpus references (microsoft/SkillOpt @ 343db22) | candidate · not_run · 9 readset(s) | no-eval | -| [performance-ceiling-analysis](../src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md) | common | Estimate optimization headroom before modifying an inference system. Produces a three-level ceiling model (analytical ... | inference serving systems (LLM, diffusion, audio) | 2 advice | 1 Accelerator · Diagnose / Verify
5 OS · Configure | 1 · Systems sources (FlexGen — [ICML 2023 / PMLR 202:31094–31116](https://proceedings.mlr.p ...)
1 · Systems sources (Mooncake — FAST '25 proceedings, pp. 155-170)
1 · Systems sources (NVIDIA/TensorRT-LLM @ f33e0e5fd)
1 · Systems sources (ebugger/Empirical-Roofline-Toolkit @ 0771fa9)
1 · Systems sources (hahnyuan/LLM-Viewer @ 1893e4b)
2 · Methodology and corpus references ([shenh10/HuggingArch](https://github.com/shenh10/HuggingArch/tree/facb ...)
2 · Methodology and corpus references (shenh10/HuggingArch @ `e69d20a028e5b17524aa48b53bddf8b9aad5d15b` ...) | candidate · not_run · 20 readset(s) | no-eval | +| [performance-ceiling-analysis](../src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md) | common | Estimate optimization headroom before modifying an inference system. Produces a three-level ceiling model (analytical ... | inference serving systems (LLM, diffusion, audio) | 2 advice | 1 Accelerator · Diagnose / Verify
5 OS · Configure | 1 · Systems sources (FlexGen — [ICML 2023 / PMLR 202:31094–31116](https://proceedings.mlr.p ...)
1 · Systems sources (Mooncake — FAST '25 proceedings, pp. 155-170)
1 · Systems sources (NVIDIA/TensorRT-LLM @ f33e0e5fd)
1 · Systems sources (ebugger/Empirical-Roofline-Toolkit @ 0771fa9)
1 · Systems sources (hahnyuan/LLM-Viewer @ 1893e4b)
2 · Methodology and corpus references ([shenh10/HuggingArch](https://github.com/shenh10/HuggingArch/tree/facb ...)
2 · Methodology and corpus references (shenh10/HuggingArch @ `e69d20a028e5b17524aa48b53bddf8b9aad5d15b` ...)
Ascend service, operator, scheduler and quantization sources ([xLLM 0.12.0 @ `90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4`](https://git ...) | candidate · not_run · 21 readset(s) | no-eval | | [plan-activation-residency](../src/inferrsi/knowledge/data/skill_library/playbooks/planning/plan-activation-residency/SKILL.md) | common | Propose training activation and gradient memory reductions by distinguishing lifetime reordering, address packing and ... | Proposing training activation and gradient memory reductions when pressure appears to ... | failure_modes, input_contract, produced_artifact, refusal_point
3 advice | 1 Accelerator · Diagnose / Optimize / Verify | 1 · Systems sources (Checkmate — [1910.02653v3](https://arxiv.org/abs/1910.02653v3)) | candidate · not_run · 1 readset(s) | no-eval | | [training-input-pipeline](../src/inferrsi/knowledge/data/skill_library/playbooks/optimization/training-input-pipeline/SKILL.md) | common | Diagnose training input stalls and choose bounded queue, shard-cache and cache-ownership changes from DALI, Mosaic ... | Diagnosing training input stalls and choosing bounded queue, shard-cache and ... | failure_modes, input_contract, produced_artifact, refusal_point
4 advice | 1 Accelerator · Observe / Configure / Optimize
2 RAM/Host · Observe / Diagnose / Configure / Optimize
3 SSD · Diagnose / Configure / Optimize
4 Network · Configure / Optimize
5 OS · Configure / Optimize | 1 · Systems sources (B1 / NVIDIA DALI @ `6fe47c48d3b0ca335f5e1afd3c77c750b2c7e041` ...)
1 · Systems sources (B2 / Mosaic Streaming @ `d99bf9c7cdf2dd4ed62a4960ed35270b93337a5f` ...)
1 · Systems sources (B3 / FFCV @ `3a12966b3afe3a81733a732e633317d747bfaac7` ...) | candidate · not_run · 1 readset(s) | no-eval | | [training-resource-budget](../src/inferrsi/knowledge/data/skill_library/playbooks/planning/training-resource-budget/SKILL.md) | common | Choose training offload and resource-budget changes using pinned DeepSpeed configuration, attributed expert diagnosis ... | Choosing training offload and resource-budget changes from pinned DeepSpeed ... | failure_modes, input_contract, produced_artifact, refusal_point
4 advice | 1 Accelerator · Diagnose / Configure / Optimize
2 RAM/Host · Observe / Diagnose / Configure / Optimize / Verify
3 SSD · Configure / Optimize
4 Network · Observe / Diagnose / Verify
5 OS · Diagnose / Configure | 1 · Systems sources (CR1 / DeepSpeed ZeRO-Infinity @ `5f266e26d216a705d9c64cac88fb813ce ...)
1 · Systems sources (CR5 / Ascend MindSpeed adaptive memory — historical `core_r0.8.0` ...)
1 · Systems sources (ZeRO-Offload — [2101.06840v1](https://arxiv.org/abs/2101.06840v1))
2 · Methodology and corpus references (CR6 / Stas Bekman ML Engineering Open Book @ ...) | candidate · not_run · 9 readset(s) | no-eval | @@ -88,10 +88,10 @@ optimization is fully covered or that any procedure has measured benefit. | [ascend-device-health](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-device-health/SKILL.md) | ascend | Pre-run health checks and recovery procedures for Ascend NPU devices on shared machines: card-group topology ... | Pre-run Ascend device-health, topology, occupancy and timing checks before a trusted ... | failure_modes, input_contract, produced_artifact
3 advice | 4 Network · Diagnose
5 OS · Observe / Profile / Diagnose / Configure / Verify | 1 · Systems sources (Ascend/MindIE-SD @ 8481d39) | candidate · not_run · 0 readset(s) | no-eval | | [ascend-distributed-parallel](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-distributed-parallel/SKILL.md) | ascend | Select and validate distributed parallelism strategy on Ascend NPU: topology-aware card-group selection, USP/CP/TP/PP ... | Select and diagnose Ascend parallel strategies and their activation/overlap, with a ... | failure_modes, input_contract, produced_artifact
4 advice | 1 Accelerator · Configure
4 Network · Diagnose / Configure / Optimize / Verify / Observe | 1 · Systems sources (Ascend/MindIE-SD @ 8481d39)
1 · Systems sources (ascend-ai-coding/awesome-ascend-skills @ 75ec89c)
1 · Systems sources (cann/hccl @ `96fab0a2acb761e7f8ab0f94aeb5138f200a345b` (CANN Open ...) | candidate · not_run · 3 readset(s) | no-eval | | [ascend-graph-mode](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-graph-mode/SKILL.md) | ascend | Diagnose an Ascend TorchAir ACL graph path from versioned configuration through FX compilation, capture-key selection ... | Diagnose the TorchAir Python ACL graph path from configuration and FX compilation through ... | failure_modes, input_contract, produced_artifact
3 advice | 1 Accelerator · Diagnose / Configure / Verify
3 SSD · Diagnose | 1 · Systems sources (Ascend/torchair @ `e1118e8b0fc1b95190ab53b732c0872989550e20` ...)
1 · Systems sources (ascend-ai-coding/awesome-ascend-skills @ 75ec89c) | candidate · not_run · 3 readset(s) | no-eval | -| [ascend-model-adaptation](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md) | ascend | Patterns for porting LLM/VLM model adapters to Ascend NPU: FP8 checkpoint handling, KV replication with TP, multimodal ... | Checkpoint onboarding for LLM/VLM adapters on Ascend: weight/scale loading, KV-head ... | failure_modes, input_contract, produced_artifact, refusal_point
3 advice | 1 Accelerator · Configure
3 SSD · Diagnose / Configure | 1 · Systems sources (vllm-project/vllm-ascend @ bc8115ed) | candidate · not_run · 1 readset(s) | no-eval | +| [ascend-model-adaptation](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md) | ascend | Patterns for porting LLM/VLM model adapters to Ascend NPU: FP8 checkpoint handling, KV replication with TP, multimodal ... | Checkpoint onboarding for LLM/VLM adapters on Ascend: weight/scale loading, KV-head ... | failure_modes, input_contract, produced_artifact, refusal_point
3 advice | 1 Accelerator · Configure
3 SSD · Diagnose / Configure | 1 · Systems sources (vllm-project/vllm-ascend @ bc8115ed)
Ascend service, operator, scheduler and quantization sources ([msModelSlim @ `d4ee30cb6ed97448f79c80652db6ec0f911a47f9`](https://git ...) | candidate · not_run · 2 readset(s) | no-eval | | [ascend-operator-profiling](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-profiling/SKILL.md) | ascend | Benchmark a single Ascend NPU operator using msprof op: build, collect with warmup, read the 8 CSV metrics files ... | Build, measure and diagnose one Ascend operator in isolation using msprof op, before ... | failure_modes, input_contract, produced_artifact
3 advice | 1 Accelerator · Observe / Profile
5 OS · Observe / Profile | 1 · Systems sources (ascend-ai-coding/awesome-ascend-skills @ 75ec89c) | candidate · not_run · 0 readset(s) | no-eval | -| [ascend-operator-tuning](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md) | ascend | Run a staged, accuracy-gated tuning campaign on a single Ascend NPU operator: set a numeric target up front, block ... | Run a bounded, accuracy-gated tuning campaign for a single Ascend operator already ... | failure_modes, input_contract, produced_artifact, refusal_point
3 advice | 1 Accelerator · Optimize | 1 · Systems sources (ascend-ai-coding/awesome-ascend-skills @ 75ec89c) | candidate · not_run · 0 readset(s) | no-eval | -| [ascend-performance-analysis](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md) | ascend | Diagnose performance bottlenecks on Ascend NPU systems using CANN profiling data. Maps GPU profiling concepts (nsys ... | Interpret Ascend CANN profiling evidence from step breakdown through ... | failure_modes, input_contract, produced_artifact
3 advice | 1 Accelerator · Observe / Profile / Diagnose / Verify
4 Network · Observe / Profile / Diagnose / Verify
5 OS · Diagnose | 1 · Systems sources (Ascend/MindIE-SD @ 8481d39)
1 · Systems sources (cann/cannbot @ `c0e2ad23ee1a73e3c0f84c8df1cc459e2aae3110` (selected ...) | candidate · not_run · 1 readset(s) | no-eval | +| [ascend-operator-tuning](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md) | ascend | Run a staged, accuracy-gated tuning campaign on a single Ascend NPU operator: set a numeric target up front, block ... | Run a bounded, accuracy-gated tuning campaign for a single Ascend operator already ... | failure_modes, input_contract, produced_artifact, refusal_point
3 advice | 1 Accelerator · Optimize | 1 · Systems sources (ascend-ai-coding/awesome-ascend-skills @ 75ec89c)
Ascend service, operator, scheduler and quantization sources ([TileLang Ascend 0.1.4 @ `3a93b960d22359de40db86250d335693b4b1a5f4`](h ...) | candidate · not_run · 1 readset(s) | no-eval | +| [ascend-performance-analysis](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md) | ascend | Diagnose performance bottlenecks on Ascend NPU systems using CANN profiling data. Maps GPU profiling concepts (nsys ... | Interpret Ascend CANN profiling evidence from step breakdown through ... | failure_modes, input_contract, produced_artifact
3 advice | 1 Accelerator · Observe / Profile / Diagnose / Verify
4 Network · Observe / Profile / Diagnose / Verify
5 OS · Diagnose | 1 · Systems sources (Ascend/MindIE-SD @ 8481d39)
1 · Systems sources (cann/cannbot @ `c0e2ad23ee1a73e3c0f84c8df1cc459e2aae3110` (selected ...)
Ascend service, operator, scheduler and quantization sources ([MindStudio Service Profiler @ `04bd9bf0cb804e7bca92103d47b3ad029b999f ...) | candidate · not_run · 2 readset(s) | no-eval | | [ascend-video-diffusion-optimization](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-video-diffusion-optimization/SKILL.md) | ascend | Run and verify goal-driven Ascend video diffusion optimization. Specializes the backend-agnostic ... | Ascend NPU video diffusion inference and serving optimization | failure_modes, input_contract, produced_artifact
3 advice | 1 Accelerator † guidance: Video diffusion campaign guidance (unvalidated) | — | candidate · not_run · 1 readset(s) | no-Reference-Matrix-row, no-eval | | [ascendc-tiling-design](../src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascendc-tiling-design/SKILL.md) | ascend | Design tiling for a custom AscendC operator: normalize the shape first (axis-collapse or flatten), answer the ... | Design or restructure AscendC tiling for the covered reduction, broadcast and elementwise ... | failure_modes, input_contract, produced_artifact
3 advice | 1 Accelerator · Optimize | 1 · Systems sources (ascend-ai-coding/awesome-ascend-skills @ 75ec89c) | candidate · not_run · 0 readset(s) | no-eval | | [audit-afd-p2p-exchanges](../src/inferrsi/knowledge/data/skill_library/systems/engines/afd-plugin/audit-afd-p2p-exchanges/SKILL.md) | cuda | Audit CUDA P2pNccl Attention/FFN rank namespaces and per-stage, per-peer hidden-state ownership when uneven worker ... | Source-based CUDA P2pNccl rank/payload audit; selected eager dense-FFN path with ... | failure_modes, input_contract, produced_artifact, refusal_point
3 advice | 1 Accelerator · Diagnose / Configure / Verify | 1 · Systems sources (vllm-project/afd-plugin @ `df8d6a0c403c3ca1b4ed9cf1687e7204908bebec` ...) | candidate · not_run · 1 readset(s) | no-eval | diff --git a/src/inferrsi/knowledge/data/skill_library/_compiled/_provenance.json b/src/inferrsi/knowledge/data/skill_library/_compiled/_provenance.json index 381c5f1d7..3abf1a04e 100644 --- a/src/inferrsi/knowledge/data/skill_library/_compiled/_provenance.json +++ b/src/inferrsi/knowledge/data/skill_library/_compiled/_provenance.json @@ -1,7 +1,7 @@ { "schema_version": 1, "repository": "https://github.com/InferMatrixLab/InferRSI", - "source_revision": "2b72038b6d9468c085ee977786a769a849e79cf7", + "source_revision": "bf14fec0bd909efcfeb2bc02d69fe227d0c51ce6", "registry": { "path": "src/inferrsi/knowledge/data/skill_library/skill-index.json", "sha256": "d243e2ae44c7badc8e68788153de35fe6ac31de618b7499fef6339eadf396871" diff --git a/src/inferrsi/knowledge/data/skill_library/_compiled/inputs.json b/src/inferrsi/knowledge/data/skill_library/_compiled/inputs.json index 5a1e54426..93037ddac 100644 --- a/src/inferrsi/knowledge/data/skill_library/_compiled/inputs.json +++ b/src/inferrsi/knowledge/data/skill_library/_compiled/inputs.json @@ -50,7 +50,8 @@ "description": "Patterns for porting LLM/VLM model adapters to Ascend NPU: FP8 checkpoint handling, KV replication with TP, multimodal feature validation order, graph mode startup, and feature-status reporting. Source-grounded from vllm-ascend production experience. Use when adapting a new model checkpoint to run on Ascend via vllm-ascend or a similar framework.\n" }, "files": { - "SKILL.md": "bf1630e5f7f716dac4c8d59235dd2b088e126c80a544f01ff6daabb6ac0abdf0", + "SKILL.md": "64d9c5ae031ae55674862765a17195b19e749d721fc5d3e7c7abefd3b35e1152", + "references/msmodelslim-deepseek-w4a8.md": "8cfae39536e0a012b2a53caa75c66fcc8caf0da835bfd274813de6981ab8425f", "references/source-notes.md": "500966fe5ddd3b52bb8405b406ba9c707b5e68c0ec8317f8b1ac8c109d38936b" } }, @@ -69,7 +70,8 @@ "description": "Run a staged, accuracy-gated tuning campaign on a single Ascend NPU operator: set a numeric target up front, block tuning until an on-device accuracy pass is logged, escalate code-level then scheduling then instruction-level tuning with per-stage stall counters and kill-switches, and route each change by the metric contract (core utilization, bubble rate, load balance). Use after ascend-operator-profiling has measured a baseline and the operator is confirmed as the bottleneck.\n" }, "files": { - "SKILL.md": "b226f5597b964bf2616d7faa68f7fa047789695904ba6e44e9c8ca2b7741d2ef" + "SKILL.md": "179620517814dc4b62702cd82694949ae44a2fc3226f3aec88d671ee0c6f830a", + "references/tilelang-ascend-flash-attention.md": "86b617f9950c9b101487ace5f29a516f7eca8c1d61eccbc1e4331e70977f0b2f" } }, "ascend-optimization-casebook": { @@ -87,9 +89,10 @@ "description": "Diagnose performance bottlenecks on Ascend NPU systems using CANN profiling data. Maps GPU profiling concepts (nsys, ncu, SOL%, roofline) to their NPU equivalents (msprof, torch_npu.profiler, CSV/JSON outputs, AI Core utilization, HCCL communication analysis). Covers measurement discipline on shared NPU machines and evidence acceptance for automated NPU optimization stages. Use when profiling data is available or a stage report needs its execution and validation evidence checked.\n" }, "files": { - "SKILL.md": "8fdbb60d366a2e03f08d17a4604210833a54104fc0a22cd2be68c2cc2052deba", + "SKILL.md": "7b28775f2615800d10cd91269d7994f3c97c38fd9dc39d970308f06b4c36beff", "references/cannbot-CANN-2.0-LICENSE.md": "89b1c114df62cfd183004f38d18d07f186436c3b37203dd69c3e84becf9d2282", - "references/cannbot-stage-evidence.md": "f56e4125325c9c1b9235a1d64fd732861c7686444492422daff44ba8dd648be4" + "references/cannbot-stage-evidence.md": "f56e4125325c9c1b9235a1d64fd732861c7686444492422daff44ba8dd648be4", + "references/mindstudio-service-attribution.md": "54a5bd01b6db3787dd78a251b7204283c84ddd46b0419bc95c3c0d2504059d3d" } }, "ascend-video-diffusion-optimization": { @@ -932,7 +935,7 @@ "description": "Estimate optimization headroom before modifying an inference system. Produces a three-level ceiling model (analytical, empirical component, end-to-end) and a prioritized measurement plan. Use to formulate acceptance targets when the user has not supplied them, assess a requested speedup, or identify the binding bottleneck.\n" }, "files": { - "SKILL.md": "9827a346ee26c500e886f9c051e914b97b8ffd25ac5533ef26b377b1817f5aa5", + "SKILL.md": "baeab73fb1fbf09da6ae0930b380720c66d9dc8085f8ccd1fb61381bb894799f", "references/acceptance-criteria.md": "e96efc42005af591a87b57dd6f1e9bffa8e351bcd023bd093ac37239a0486638", "references/flexgen-offload-feasibility.md": "5c72ae959c6cc72aa9e96a17a2934d6bfcfb055b25fda3221c99382dc09910d9", "references/huggingarch-checkpoint-anchor.md": "ca03747be29a93b579849ee361b67632e541218a68310e0f3369868c6a45da7e", @@ -956,6 +959,7 @@ "references/papers-20261015/references/vidur.md": "d38602af5219f5feeb49e6cd6bf53d66098c77fad141dae676f1d8a6743cf25d", "references/roofline-contract.md": "419ec4bcaec45ac579a133bce083d4f48779f26e664d7a86f720fa65f343b1d1", "references/roofline-example.json": "597cd3205df043cff3ae9d15924c77934e8d8eb300c00c4840f6bb2921f90faf", + "references/xllm-pd-handoff.md": "66226190ab90cab2057cdd867714725a084396fa9ccaa87efab8b14ca021bd2a", "scripts/roofline.py": "524de48a6764401695fe1444f1fa3d38f363069b0cd2fba4715a86ca4b28a5d4" } }, diff --git a/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md b/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md index 580e51adf..48542c287 100644 --- a/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md +++ b/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/SKILL.md @@ -107,6 +107,26 @@ metadata: "readset": "references/huggingarch-checkpoint-anchor.md", "scope": "Live, unversioned companion post; sections 2.5, 2.6, 3.6 and 3.7 read from one retrieval, whose HTML bytes the sha256 identifies. Published before the pinned commit, so not attributable to it; figures absent from the repository are recorded as unverified.", "license": "UNKNOWN" + }, + { + "type": "git", + "url": "https://github.com/xLLM-AI/xllm", + "commit": "90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4", + "paths": [ + "LICENSE", + "THIRDPARTYNOTICES.md", + "docs/src/content/docs/en/features/disagg_pd.md", + "docs/src/content/docs/en/hardware/ascend_npu.md", + "tests/core/scheduler/pd_scheduler_test.cpp", + "version.txt", + "xllm/core/disaggregation/pd_scheduler.cpp", + "xllm/core/disaggregation/pd_service_impl.cpp", + "xllm/core/scheduler/scheduler_factory.cpp", + "xllm/core/scheduler/scheduler_factory.h", + "xllm/core/scheduler/scheduler_policy.cpp" + ], + "readset": "references/xllm-pd-handoff.md", + "license": "Apache-2.0 with component-specific notices" } ], "verification": { @@ -159,7 +179,8 @@ metadata: "references/papers-20261015/references/inferencebench.md", "references/papers-20261015/references/prior-coverage.md", "references/papers-20261015/references/vidur.md", - "references/papers-20261015/STATIC_CHECKS.md" + "references/papers-20261015/STATIC_CHECKS.md", + "references/xllm-pd-handoff.md" ], "consumption_mode": "packaged", "recommendations": [ @@ -250,6 +271,8 @@ relates KV loading time to saved prefill work. Its paper-specific inequality screens a candidate; current cache validity, effective rates, exposed costs and service outcomes still require evidence. +For disaggregated prefill and decode, the [xLLM handoff procedure](references/xllm-pd-handoff.md) separates prefill work saved through prefix reuse from decode-side reservation and KV transfer. Account for failed restoration before estimating headroom. + For throughput-oriented offline inference with CPU/disk offload, use the [FlexGen feasibility comparison](references/flexgen-offload-feasibility.md) to check joint weights/KV/activation placement, resident plus working-memory peaks, diff --git a/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/references/xllm-pd-handoff.md b/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/references/xllm-pd-handoff.md new file mode 100644 index 000000000..61da96121 --- /dev/null +++ b/src/inferrsi/knowledge/data/skill_library/playbooks/measurement/performance-ceiling-analysis/references/xllm-pd-handoff.md @@ -0,0 +1,69 @@ +# xLLM on Ascend: accounting for prefill reuse and decode transfer + +At [xLLM revision `90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4`][version] (`0.12.0` in +`version.txt`), a prefill-side prefix hit can reduce the tokens computed in a +chunk. A separate operation prepares the decode instance to serve the next +token. Account for both before estimating how much of a request can get faster. +This source inspection extends the [prefix-reuse cost comparison](mooncake-prefix-reuse-feasibility.md) +with one engine's actual scheduling and transfer boundaries. + +## Trace one request + +| Decision | What the pinned source shows | How to use it | +| --- | --- | --- | +| Which scheduler runs? | [Selection][factory] tests `enable_disagg_pd`. [Construction][create] picks `PDScheduler` or the continuous scheduler. The [batch policy][mode] disables mixed batches on a disaggregated `PREFILL` instance. | Check the effective flag and role on each instance. Chunking by itself also exists on the continuous path. | +| Which prompt tokens need compute? | [Prefill allocation][chunk] normally looks up shared blocks before computing the number of new tokens in the chunk. It bounds the end by both the prompt length and the cached-token count plus the budget. Linear-attention models can introduce an alignment step. Redistribution can skip a shared lookup to avoid matching the sequence's own published blocks. | Record matched tokens, newly scheduled tokens and the chunk budget separately. Block capacity can include reserved but uncomputed tokens. A cold prompt has no reusable prefix. | +| Is decode ready? | The [decode admission RPC][admit] first tries to allocate the destination blocks and prepares the transfer metadata, then publishes a reservation. It distinguishes an overlong prompt from transient cache pressure. The [first-generation handler][id] also checks the request and reservation identity. | Trace one request across both roles. Refuse the handoff on a stale reservation, even if the request identifier matches. | +| Did the KV arrive? | On native `PULL`, the [restore path][pull] checks group identities and local/remote block counts, then checks transfer success before normal enqueue. The same code describes a different ordering for heterogeneous `PUSH`, in which writes precede the first-generation message. | Record the transport mode, both endpoints, rank mapping and restore outcome. A prefix hit on prefill or an accepted reservation on decode establishes neither transfer completion nor interoperability. | + +The [P/D example][pd] uses etcd for instance metadata and an external xLLM +Service for routing. Its example launches separate prefill and decode roles +with both chunking and prefix caching disabled. Its later note describes +enabling both on the prefill path. The [Ascend guide][ascend] separately +documents compatible drivers, a model-supported NPU image and an example +using HCCL. Its single-service health check cannot test a cross-instance handoff. + +## Recheck and reject + +1. On the pinned source, follow the factory into the batch policy. With + disaggregation off, the factory must select the continuous path. With it on + and role `PREFILL`, confirm the policy disables mixed batches. +2. Compare a prompt with no match against one with a matched prefix. Read + `allocate_for_prefill` and check that new compute is the difference between + the target position and the sequence's current KV token count (including any shared prefix and earlier computed chunks). Follow the allocation + target separately if full-prompt reservation is enabled. +3. Inspect the upstream [failed-pull test definition][test]. A fake worker + returns failure after decode has reserved blocks. Its assertions require the + free-block count to recover and the decode queue to stay empty. The test + body is an oracle for this failure path. It supplies no hardware result. +4. For a future service comparison, hold weights, tokenizer, KV representation, + device budget, arrival trace and prompt/output lengths fixed. Include cold + and repeated-prefix requests. Capture queue time per role, actual prefix + tokens, bytes transferred, restore time, TTFT, token-gap distribution and + failed requests. With unknown topology or cache representation, or with only + a health response or a prefix-hit counter, leave service impact unresolved. + +**Evidence.** `empirical_validation: not_run`. The deployment commands are +upstream examples. No scheduler tests, service, external router, transport +or NPU result was executed or qualified for this source note. + +**License.** The pinned [root license][license] is Apache-2.0. The inspected +implementation and test carry xLLM Authors' Apache-2.0 notices. The +[third-party notice][notices] assigns component-specific terms, including +BSD-3-Clause for etcd-cpp-apiv3 and Apache-2.0 for bRPC. This note includes +original analysis and links only. External xLLM Service, dependencies, images +and model weights are outside the inspected source scope. + +[version]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/version.txt +[factory]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/scheduler/scheduler_factory.cpp#L26-L32 +[create]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/scheduler/scheduler_factory.h#L42-L70 +[mode]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/scheduler/scheduler_policy.cpp#L1150-L1193 +[chunk]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/scheduler/scheduler_policy.cpp#L584-L653 +[admit]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/disaggregation/pd_service_impl.cpp#L229-L299 +[id]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/disaggregation/pd_scheduler.cpp#L999-L1079 +[pull]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/xllm/core/disaggregation/pd_scheduler.cpp#L1140-L1228 +[pd]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/docs/src/content/docs/en/features/disagg_pd.md +[ascend]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/docs/src/content/docs/en/hardware/ascend_npu.md +[test]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/tests/core/scheduler/pd_scheduler_test.cpp#L1141-L1186 +[license]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/LICENSE +[notices]: https://github.com/xLLM-AI/xllm/blob/90f6f13ea3d94334d4b5bd73d9fb23fc66bef1e4/THIRDPARTYNOTICES.md diff --git a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md index cba519770..cc03f8954 100644 --- a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md +++ b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/SKILL.md @@ -27,7 +27,8 @@ metadata: "Original typed source inventory is not normalized; retain source identities and limits in the procedure/readsets." ], "provenance_readsets": [ - "references/source-notes.md" + "references/source-notes.md", + "references/msmodelslim-deepseek-w4a8.md" ], "consumption_mode": "packaged", "applicability": { @@ -42,6 +43,24 @@ metadata: "Gate onboarding in order: dummy architecture check, real-weight loading, model endpoint, text request and then multimodal request when the model supports VL; retain the evidence each stage actually supplies.", "Check weight/scale pairing and each attention tensor loading path, especially when TP exceeds the KV-head count; verify historical FP8 guidance against the actual stack.", "Expand capacity/concurrency only after basic modality and expected replay checks; mark MoE-only features inapplicable for non-MoE models and require full-layer validation before sign-off." + ], + "sources": [ + { + "type": "git", + "url": "https://github.com/Ascend/msmodelslim", + "commit": "d4ee30cb6ed97448f79c80652db6ec0f911a47f9", + "paths": [ + "LICENSE", + "docs/en/legal/license_notice.md", + "example/DeepSeek/README.md", + "example/DeepSeek/convert_fp8_to_bf16.py", + "example/DeepSeek/quant_deepseek_w4a8.py", + "example/common/copy_config_files.py", + "msmodelslim/Third_Party_Open_Source_Software_Notice" + ], + "readset": "references/msmodelslim-deepseek-w4a8.md", + "license": "MulanPSL-2.0 (product code), CC BY 4.0 under docs/, component-specific notices" + } ] } --- @@ -61,6 +80,8 @@ To prevent duplicate definitions and maintain strict attribution boundaries acro For the runtime capture/replay execution contract, follow [ascend-aclgraph-capture-replay](../ascend-aclgraph-capture-replay/SKILL.md). Its wrapper evidence does not revalidate this entry or establish a compatible installed stack. For compiler pass options, follow [ascend-graph-mode](../ascend-graph-mode/SKILL.md). For host offload descriptor pooling, follow [host-memory-management](../../host/host-memory-management/SKILL.md). See the [version and responsibility table](../../../../README.md#vllm-ascend-version-and-responsibility-routing) for their separate evidence boundaries. +For a DeepSeek-V3.1 mixed-precision export, use the [msModelSlim W4A8 checkpoint checks](references/msmodelslim-deepseek-w4a8.md) to match the weights, two calibration inputs, actual per-module types and intended loader before evaluating quality or service latency. + ## Debug order for a new checkpoint Always follow this sequence. Each step gates the next. diff --git a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/references/msmodelslim-deepseek-w4a8.md b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/references/msmodelslim-deepseek-w4a8.md new file mode 100644 index 000000000..50677c373 --- /dev/null +++ b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-model-adaptation/references/msmodelslim-deepseek-w4a8.md @@ -0,0 +1,38 @@ +# Selecting a DeepSeek mixed-W4A8 checkpoint for an Ascend loader + +Source review of Ascend/msmodelslim at `d4ee30cb6ed97448f79c80652db6ec0f911a47f9`. Scope is the DeepSeek-V3.1 example export path. `empirical_validation: not_run`. The observations below come from inspecting the upstream files. Loader compatibility, model quality and service performance remain unmeasured in InferRSI. + +## Select the model, recipe and consumer together + +The support table gives different recipes for DeepSeek-V3.1, V3.1-Terminus and V3.2-Exp. For **V3.1 W4A8**, the linked command uses `quant_deepseek_w4a8.py`, the V3.1 anti-outlier and calibration prompt files, and mixed multi-token prediction (MTP). V3.1-Terminus lists W8A8C8 and W4A4C8. V3.2-Exp has its own W4A8 command. Match all three identifiers (model revision, mode and exporter) before applying the mechanism below. The V3 preflight in this revision specifies Transformers 4.48.2 and model-specific preparation. [Support table][matrix] · [V3 preflight][preflight] · [V3.1 recipe][recipe] + +| Inspection point | What the pinned path does | What to record or reject | +| --- | --- | --- | +| Input dtype | The loader requests `torch_dtype="auto"` and calls the FP8-to-BF16 helper before calibration. Forced FP8 requires matched scale entries. Forced BF16 skips conversion. Auto mode can skip on an empty scale list or warn on a shard/index mismatch. [Loader][load] · [Conversion helper][convert] | Record checkpoint and shard-index identity, original dtype and conversion mode. Stop on missing or mismatched weight/scale pairs for a declared FP8 input. A completed auto path alone cannot establish the input dtype. | +| Calibration | The two JSON prompt lists have different consumers. The anti-outlier pass uses `m4` on the first list. The calibrator receives the second list with the mixed configuration. Both lists are split into chunks of up to 512 **characters** before tokenization, then batched and padded. [Batch builder][batch] · [Consumers][mix] | Record both dataset digests, tokenizer revision, batch size and actual token lengths. Keep quality evaluation prompts independent of these two inputs. A 512-token truncation changes the input. | +| Layer precision | The module map selects dynamic W4A8 for routed main-model experts, dynamic W8A8 for shared experts and the first three dense MLPs, and W8A8 for attention. Per-layer `self_attn.kv_b_proj` is excluded. Mixed MTP has separate expert and exclusion rules. [Module map][mix] | Inspect one tensor description from each applicable class and the declared MTP mode. A single top-level dtype or a reduced-layer export cannot establish the full model layout. | +| Backend packaging | The default branch saves `ascendV1` with `quant_model_description.json` and the vLLM config hook. With `--mindie_format`, it selects `safe_tensor`, a differently named description and the MindIE config hook. The README describes this compatibility flag for MindIE 2.1.RC1 and earlier. Both branches set the summary `model_quant_type` to `W8A8_DYNAMIC` even with mixed W4A8 experts. [Flag scope][flags] · [Exporter][save] · [Config writers][hooks] | Record the serving engine and plugin versions, hardware, format switch, description filename and per-layer entries. Reject a loader/format mismatch or an inference about all weights from the summary field. | + +## Checks and fallback + +1. **Reproduce the source review without a device.** At the pinned revision, follow the V3.1 W4A8 row through the linked command to `main()`. Trace the two JSON inputs to their distinct consumers, then trace the module map, both save branches and both config hooks. Cross-check the V3.1-Terminus row as a negative example. This verifies what the exporter requests. +2. **Quality gate for a future authorized run.** Preserve the original checkpoint and loader configuration. Stage the export separately. With real weights and all layers, require a successful load by the intended consumer and compare held-out task outputs against the original under the same tokenizer, prompts, decoding parameters and MTP mode. Use the acceptance issue's predeclared quality bar. +3. **Performance gate for a future authorized run.** Only after the quality gate, compare both variants on the same device topology, serving stack, request mix, sequence lengths, concurrency and warm-up policy. Judge the requested service metrics against the issue's frozen gates. On a failed load or quality regression, restore the original checkpoint/configuration. Record a failed performance gate separately. Missing baseline or incompatible conditions leave the comparison inconclusive. + +## Attribution + +The exporter and conversion helper carry Huawei Technologies' 2026 MulanPSL-2.0 notices. The repository distinguishes product code from CC BY 4.0 documentation under `docs/`. The package also lists component-specific terms, including Apache-2.0, BSD-3-Clause, MIT and NOASSERTION entries. Check the separate terms for any model weights, tokenizer, data or third-party code before reuse. This reference contains original source analysis. [Product license][license] · [Documentation notice][docs-license] · [Third-party notice][third-party] + +[matrix]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/README.md#L35-L50 +[preflight]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/README.md#L190-L200 +[recipe]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/README.md#L259-L265 +[flags]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/README.md#L108-L121 +[load]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/quant_deepseek_w4a8.py#L185-L238 +[convert]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/convert_fp8_to_bf16.py#L117-L154 +[batch]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/quant_deepseek_w4a8.py#L103-L128 +[mix]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/quant_deepseek_w4a8.py#L242-L293 +[save]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/DeepSeek/quant_deepseek_w4a8.py#L296-L338 +[hooks]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/example/common/copy_config_files.py#L43-L95 +[license]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/LICENSE +[docs-license]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/docs/en/legal/license_notice.md +[third-party]: https://github.com/Ascend/msmodelslim/blob/d4ee30cb6ed97448f79c80652db6ec0f911a47f9/msmodelslim/Third_Party_Open_Source_Software_Notice diff --git a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md index 964804994..d4e5c7d96 100644 --- a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md +++ b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/SKILL.md @@ -27,7 +27,9 @@ metadata: "Source-derived candidate; no local efficacy validation.", "Original typed source inventory is not normalized; retain source identities and limits in the procedure/readsets." ], - "provenance_readsets": [], + "provenance_readsets": [ + "references/tilelang-ascend-flash-attention.md" + ], "consumption_mode": "packaged", "applicability": { "scope": "Run a bounded, accuracy-gated tuning campaign for a single Ascend operator already identified as the bottleneck, escalating from code-level to scheduling and instruction-level changes.", @@ -41,6 +43,26 @@ metadata: "Change one parameter and recheck accuracy each round; keep the failure record when reverting and compare the final configuration against the same baseline workload and warmup policy.", "Route scheduler bubbles separately from predecessor dependencies and enter instruction-level tuning only after isolating a specific long task.", "Verify the analyzer parsed real cores before trusting its diagnosis, and rederive PyPTO tile/buffer/scheduling settings for the target SoC rather than copying numeric examples." + ], + "sources": [ + { + "type": "git", + "url": "https://github.com/tile-ai/tilelang-ascend", + "commit": "3a93b960d22359de40db86250d335693b4b1a5f4", + "paths": [ + "LICENSE", + "THIRDPARTYNOTICES.txt", + "VERSION", + "examples/flash_attention/fa_opt/expert_v3/README.md", + "examples/flash_attention/fa_opt/expert_v3/kernel.py", + "examples/flash_attention/fa_opt/expert_v3/kernel.tl", + "examples/flash_attention/fa_opt/expert_v3/tools/preprocess.py", + "examples/flash_attention/fa_opt/reference/ascendc.py", + "examples/flash_attention/fa_opt/run.py" + ], + "readset": "references/tilelang-ascend-flash-attention.md", + "license": "MIT for the inspected example, separate third-party notices" + } ] } --- @@ -55,6 +77,8 @@ are marked **[PyPTO]**. PyPTO itself is never defined in the source [observed ga from usage it is a Python tile-programming frontend for Ascend (AIC/AIV cores, L0/L1/UB buffers, NZ data format). +When tuning a manually synchronized attention kernel, trace the last reader of each reused slot through the [TileLang Ascend FlashAttention example](references/tilelang-ascend-flash-attention.md). Check both a short drain and ring wraparound before comparing timings. + ## SearchSpace mapping Accelerator row → Optimize cell. diff --git a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/references/tilelang-ascend-flash-attention.md b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/references/tilelang-ascend-flash-attention.md new file mode 100644 index 000000000..c3e463094 --- /dev/null +++ b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-operator-tuning/references/tilelang-ascend-flash-attention.md @@ -0,0 +1,59 @@ +# TileLang Ascend FlashAttention stage reuse + +Use this case when reviewing a change to a manually synchronized Ascend attention kernel. It traces one score tile from its first write to the last read that makes its global memory (GM) slot reusable. + +**Source and evidence.** The source inspected is TileLang Ascend revision `3a93b960d22359de40db86250d335693b4b1a5f4`, which declares version `0.1.4`. The example is under the repository's MIT license (Tile-AI). The third-party notice lists separate Apache-2.0 terms for TVM, Marlin and FlashInfer. This note describes the example in original prose. Source inspection and the Python generation check below were completed. **empirical_validation: not_run** for compilation, Ascend accuracy and performance. [Version][version] · [License][license] · [Third-party notices][notices] + +## Trace one packet through the ring + +The kernel handles dense non-causal attention with FP16 Q, K, V and output. It supports grouped query heads when the query head count is a multiple of the KV head count. The builder takes query lengths divisible by 256, key lengths divisible by 512 and head dimension 128. A packet represents a 256-row query tile paired with a 512-row key/value block. Each of 24 logical core groups has three GM slots. Automatic synchronization passes are disabled in this example. [Builder and buffers][builder] · [Compile settings][settings] + +| Step | Where data lives | When the next writer may proceed | +| --- | --- | --- | +| Cube forms QKᵀ | The query is held in L1 across its key blocks. Cube exports scores to FP16 `SP[core,stage]`. | Cube acquires `SP_REUSE(stage)` before the write. After export, `S_READY` allows Vector to read the scores. | +| Vector prepares weights | Vector reads score strips into UB, updates the row maximum and sum in FP32, and writes exponentiated weights back to the **same** FP16 `SP` slot. | `P_READY` is posted from MTE3 after the strip stores. The preceding contribution for the reused slot has already been merged in the Vector loop. | +| Cube forms PV | Cube can prefetch the first V panel before waiting for `P_READY`. After the wait it reads the weights and writes the partial output to a distinct FP16 slot in `OP`. | The last GM weight read returns `SP_REUSE(stage)` from MTE2. The score slot can then receive the next generation. `O_READY` signals that the partial output can be read. | +| Vector merges the contribution | Two FP32 output tiles remain in UB. The saved rescaling coefficient and tile sum belong to the same stage as the returning contribution. | Vector merges both tiles before reusing the stage statistics. On the final KV block it divides by the running sum, converts to FP16 and writes the output. | + +For packet index `p`, Cube writes scores at step `p` and consumes weights at step `p + 3`. Both loops run for `packets + 3` steps. New scores are produced only while `step < packets`. The trailing iterations therefore consume outstanding contributions, even for a core with a single packet. Cube waits for the final `VECTOR_DONE`. A change that stops at `packets` can leave the final output unwritten. Moving the reuse signal ahead of the final weight read can overwrite weights while PV is still consuming them. [Cube ownership][cube] · [Vector math][vector] · [Production and drain loops][loops] + +## Check a proposed change + +1. From the pinned upstream checkout, use the [upstream preprocessor][preprocess] to regenerate the Python entry point and compare its syntax tree with the published file. This checks lock expansion without importing the kernel or requiring a device. + + ```sh + cd examples/flash_attention/fa_opt/expert_v3 + python - <<'PY' + import ast + from pathlib import Path + import subprocess + import sys + + expanded = subprocess.check_output( + [sys.executable, "tools/preprocess.py", "kernel.tl"], encoding="utf-8" + ) + published = Path("kernel.py").read_text(encoding="utf-8") + assert ast.dump(ast.parse(expanded)) == ast.dump(ast.parse(published)) + PY + ``` + +2. At each modified signal, identify the writer, final reader and slot generation for both `SP` and `OP`. Trace one packet to exercise drain, then four packets on one core to exercise wraparound. For a separate device validation, direct-entry examples with `B=1, Q_heads=1, KV_heads=1, D=128` and `S=512` or `S=2048` give active cores one or four KV packets per query tile. Retain the input seed and the output for each. The direct script checks FP32 non-causal PyTorch SDPA cast to FP16, with KV head repetition for GQA. Masked, causal, ragged-tail and other head-dimension workloads require their own implementation and oracle. [Generated entry point][entry] · [Oracle and CLI][oracle] + +3. For a future timing comparison from `fa_opt/`, select `run.py --tl expert_v3/kernel.py` explicitly. The default selects v2. The runner launches two applications under `msprof`, skips the AscendC reference check, and picks the matching op type's **Total Time(us)** from the newest statistics CSV. Run the AscendC script separately with checking enabled on matched inputs. Record actual device, CANN, TileLang/compiler revision, flags, dtype and layout, shape/head mapping, op names, invocation counts, warmup, repeats and timing boundaries. Decline a comparison when either oracle fails, the op row is absent, invocation counts differ or the samples mix simulation and device runs. The v3 README's timings refer to a separate historical A3/CANN 9.1 run at another revision. This intake establishes no operator or service speedup. [Harness parser][parser] · [Applications and defaults][harness] · [AscendC check][ascendc] · [Upstream report][report] + +[version]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/VERSION +[license]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/LICENSE +[notices]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/THIRDPARTYNOTICES.txt +[builder]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.tl#L330-L364 +[settings]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.tl#L13-L46 +[cube]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.tl#L50-L167 +[vector]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.tl#L202-L326 +[loops]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.tl#L410-L494 +[entry]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.py +[oracle]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/kernel.tl#L498-L565 +[parser]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/run.py#L16-L45 +[harness]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/run.py#L178-L308 +[ascendc]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/reference/ascendc.py +[report]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/README.md + +[preprocess]: https://github.com/tile-ai/tilelang-ascend/blob/3a93b960d22359de40db86250d335693b4b1a5f4/examples/flash_attention/fa_opt/expert_v3/tools/preprocess.py diff --git a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md index d55c02fff..ed60fa0ef 100644 --- a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md +++ b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/SKILL.md @@ -47,17 +47,37 @@ metadata: "plugins-official/model-infer-optimize/workflows/scripts/archive_progress.py" ], "readset": "references/cannbot-stage-evidence.md" + }, + { + "type": "git", + "url": "https://github.com/Ascend/msserviceprofiler", + "commit": "04bd9bf0cb804e7bca92103d47b3ad029b999f51", + "paths": [ + "LICENSE", + "docs/LICENSE", + "docs/en/best_practices/vllm_ascend_observability_analysis_guide.md", + "docs/en/user_guide/vLLM_hook_tracing_instruct.md", + "docs/zh/legal/license_notice.md", + "ms_service_profiler/patcher/vllm/config/service_profiling_symbols.yaml", + "ms_service_profiler/patcher/vllm/handlers/v1/batch_handlers.py", + "ms_service_profiler/patcher/vllm/handlers/v1/kvcache_handlers.py", + "ms_service_profiler/patcher/vllm/handlers/v1/model_handlers.py", + "ms_service_profiler/patcher/vllm/handlers/v1/request_handlers.py" + ], + "readset": "references/mindstudio-service-attribution.md", + "license": "MulanPSL-2.0 (software), CC BY 4.0 (documentation)" } ], "empirical_validation": "not_run", "limitations": [ "Source-derived candidate; no local efficacy validation.", "Original typed source inventory is not normalized; retain source identities and limits in the procedure/readsets.", - "Only the incremental canonical CannBot fixed-stage evidence boundary is normalized; inherited MindIE-SD guidance remains unchanged.", + "The CannBot stage and MindStudio service readsets identify their respective sources. Inherited MindIE-SD guidance retains its historical attribution.", "CannBot callback predicates do not establish numerical accuracy or performance; dependent skills, agent-host integration and NPU execution are unverified." ], "provenance_readsets": [ - "references/cannbot-stage-evidence.md" + "references/cannbot-stage-evidence.md", + "references/mindstudio-service-attribution.md" ], "consumption_mode": "packaged", "applicability": { @@ -77,10 +97,12 @@ metadata: # Ascend NPU Performance Analysis -Status: candidate. Source-grounded from MindIE-SD @ 8481d39b. Device-specific +Status: candidate. The five-layer device analysis follows MindIE-SD @ 8481d39b. Device-specific claims are unverified locally (no NPU on this machine). Verify against CANN docs and actual profiler outputs before using. +For a vLLM-Ascend request with elevated first-token or inter-token latency, follow the [MindStudio service attribution procedure](references/mindstudio-service-attribution.md). Match the request, scheduler batch and worker time window before interpreting kernel or HCCL activity. + ## Accepting an automated optimization stage For a CannBot fixed-stage model-inference report, first use the diff --git a/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/references/mindstudio-service-attribution.md b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/references/mindstudio-service-attribution.md new file mode 100644 index 000000000..6a196f7fc --- /dev/null +++ b/src/inferrsi/knowledge/data/skill_library/systems/platforms/ascend/ascend-performance-analysis/references/mindstudio-service-attribution.md @@ -0,0 +1,76 @@ +# Attributing a vLLM-Ascend service delay with MindStudio + +Use this reference when a client observes slow first or subsequent tokens and +you need to choose between investigating queueing, host dispatch, model compute +and communication. Start with the affected request phase and traffic cohort. +Use the owner's CANN procedure when the investigation reaches device work. + +## Scope and attribution + +The source is MindStudio Service Profiler at `04bd9bf0cb804e7bca92103d47b3ad029b999f51`. +The [service diagnostics guide](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/docs/en/best_practices/vllm_ascend_observability_analysis_guide.md) +and [hook tracing guide](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/docs/en/user_guide/vLLM_hook_tracing_instruct.md) describe independent metrics and +tracing paths. The latter requires vLLM V1 with native OpenTelemetry and a +compatible vLLM-Ascend pair. Its documented support floor is vLLM-Ascend +`0.20.0`, with vLLM-Ascend `0.20.2rc1` and vLLM `0.20.2` the first public +pair cited at the pin. Individual YAML hook version guards apply to particular +symbols. They do not establish end-to-end tracing support for older releases. + +MindStudio's software is [MulanPSL-2.0](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/LICENSE), also identified in +the inspected Huawei Technologies handler headers. Its [license notice](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/docs/zh/legal/license_notice.md) +assigns the material in `docs/` to [CC BY 4.0](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/docs/LICENSE). This +reference summarizes the two MindStudio guides and independently describes +selected Python handlers. It includes no upstream implementation or figures. + +## What the hooks measure + +Use the [symbol map](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/config/service_profiling_symbols.yaml) to identify the concrete +entry point for each observation. A named OpenTelemetry span and a profiling +event are different outputs. Check which collector produced the data before +joining observations. + +| Question | Observation at this revision | Boundary | +| --- | --- | --- | +| Did the request wait for scheduling? | `Scheduler.add_request` emits a `WAITING` enqueue after insertion. `schedule` compares the waiting and running queues before and after the call. Match request and queue to the corresponding dequeue on the same time base. [Batch handlers](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/handlers/v1/batch_handlers.py#L29-L118) | A schedule call can serve many requests. Its duration measures scheduler work, not one request's queue residence. The handler returns early when classification yields no request IDs. | +| Was KV block pressure present? | For scheduled tokens, `schedule` records free and used blocks after scheduling. `AllocatedBlocks` is the change in used blocks across the call. `free` records remaining free capacity after freeing, and `get_computed_blocks` records a request token-hit fraction when the return shape and request length allow it. [Batch handler](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/handlers/v1/batch_handlers.py#L65-L109) and [KV handlers](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/handlers/v1/kvcache_handlers.py#L20-L40) | A net delta can hide allocations offset by frees. A low free-block reading or one cache miss is insufficient to attribute a queue stall. Look for coincident allocation failures, wait growth or recomputation under matched load. | +| Did time accumulate around model execution? | `modelExec` spans the executor call. For a future it ends on completion callback, for an awaitable on completion of the await. `modelRunnerExec` wraps the worker's runner invocation. The executor's `batch_size` attribute is populated from the **number of scheduled tokens**. [Model handlers](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/handlers/v1/model_handlers.py#L91-L181) | Compare associated intervals and account for overlaps before attributing a gap to dispatch or IPC. A runner span includes host work. Separate a compute kernel from HCCL only with aligned device activities on the affected ranks. | +| Where are request boundaries? | The request handler emits `httpReq` and `tokenize` together **before** awaiting the original function. A finished output with accessible request state emits `httpRes` before the original output processor runs. [Request handlers](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/handlers/v1/request_handlers.py#L28-L56) | These event names do not measure tokenizer duration or client receipt. Use a client observation for end-to-end latency and first-token timing. | + +## Recheck a proposed attribution + +1. Record the model and software revisions, device and parallel topology, + warm-up, arrival pattern, input/output lengths, concurrency, sampled window + and enabled collection domains. Compare a reference and an affected window + with the same settings. Measure instrumentation overhead separately with + collection off and on at fixed load. Some [model hooks](https://github.com/Ascend/msserviceprofiler/blob/04bd9bf0cb804e7bca92103d47b3ad029b999f51/ms_service_profiler/patcher/vllm/handlers/v1/model_handlers.py#L24-L89) + synchronize the NPU stream around the sampled function. +2. With metrics alone, compare first-token and per-output-token distributions + against queue depth, scheduler duration and KV counters for the same + instance and phase. With tracing, follow a parent, span link or recorded + request ID across boundaries. For cross-process gaps, require aligned + clocks and a shared trace or unified timeline. The documented per-span cap + is 128 request IDs and links. Missing identities beyond that cap leave + batch-level evidence only. +3. Pick the narrowest hypothesis supported by the data. For a scheduler + hypothesis compare queue residence with scheduler duration. For a host + dispatch hypothesis match the executor/runner gap to a host timeline. For + compute versus communication use device kernel and HCCL activities and + check overlap on the critical path. If linkage, device activities or a + comparable baseline are missing, record the observed phase and the missing + discriminator. Overlapping or nested spans cannot be added as wall time. +4. To test causality in a separately authorized experiment, change one + suspected factor, then compare the same cohort, instrumentation and client + measurements. A service-level improvement requires its own end-to-end + evidence. The upstream examples illustrate diagnostic patterns only. + +**Static verification.** At the pinned revision, follow the YAML targets for +`Scheduler.schedule`, `KVCacheManager.free`, `Executor.execute_model`, +`NPUModelRunner.execute_model` and `AsyncLLM.add_request` into the linked +handlers. Inspect their event ordering, early returns, return-type branches +and the value assigned to each counter. Compare the tracing guide's +compatibility section with the YAML version guards. This checks source +semantics without collecting a trace. + +**Evidence status.** `empirical_validation: not_run`. InferRSI has not run +this integration or measured tracing overhead, any suspected bottleneck or a +service gain for this intake. diff --git a/tests/repository/check_installed.py b/tests/repository/check_installed.py index a1da05177..efa83968a 100644 --- a/tests/repository/check_installed.py +++ b/tests/repository/check_installed.py @@ -609,7 +609,7 @@ def _inventory(root, prefix): **_inventory(files("inferrsi").joinpath("knowledge", "data"), "knowledge/data"), **_inventory(files("inferrsi").joinpath("harness", "data"), "harness/data"), } -assert len(inventory) == 771, f"installed resource count is {len(inventory)}, expected 771" +assert len(inventory) == 775, f"installed resource count is {len(inventory)}, expected 775" for name in inventory: if "/skill_library/" in name and name.endswith("/SKILL.md"): assert name.removesuffix("SKILL.md") + "metadata.json" not in inventory, name