Writing Skills
writing-skills
效率与协作技能,来自 obra/superpowers,查看原文获取完整用途和操作说明。
tvm【部署与运维】Guides Apache TVM install/build, Relax compilation, TIRx kernel authoring, S-TIR tuning, and RPC deployment workflows.
独立 GitHub 快照 · 自动分类 · 以原作者文档为准
Use this skill when a task involves Apache TVM as a machine-learning compiler stack: installing or building TVM, compiling Relax/TIR modules, authoring TIRx kernels, scheduling/tuning tensor programs, or deploying through TVM RPC.
This is a router. Read the focused sub-skill before making detailed API, configuration, backend, or verification decisions.
| User task signal | Read |
|---|---|
Build from source, validate import, choose CMake/LLVM/RPC/CUDA flags, fix libtvm or tvm-ffi import failures | sub-skills/install-build/SKILL.md |
Create or import Relax IR, apply optimization pipelines, call tvm.compile, export/load executables, decide target/pipeline boundaries | sub-skills/relax-compile/SKILL.md |
| Write TIRx TVMScript kernels, reason about execution scope, layouts, tile primitives, lowering, CUDA/Blackwell prerequisites, or TIRx GPU tests | sub-skills/tirx-kernels/SKILL.md |
Use tvm.s_tir.Schedule, transformations, dlight, meta-schedule, tune_tir, builders/runners/databases, or tune CPU/GPU TIR | sub-skills/s-tir-tuning/SKILL.md |
| Start/query TVM RPC tracker/server/proxy, cross-compile, upload/load remote modules, debug keys/timeouts/target-host issues | sub-skills/rpc-deployment/SKILL.md |
apache-tvm; import name: tvm.python -m pip install apache-tvm; add optional
dependencies only for the selected workflow, such as meta-schedule, RPC,
Torch frontend, or CUDA helper packages.apache-tvm-ffi,
numpy, ml_dtypes, and typing_extensions.meta-schedule adds xgboost, rpc
adds tornado, psutil, and cloudpickle, popen-pool adds psutil and
cloudpickle, torch adds torch, and cuda adds cuda-bindings.build/ directory plus PYTHONPATH
pointing at the checkout's python/ tree. Avoid editable installs when
working with multiple TVM checkouts because they can silently import a
different checkout's Python package.Minimal verification from this skill directory:
python scripts/check_tvm_runtime.py --expect-backend llvm
Use scripts/check_tvm_runtime.py for a safe
import/backend probe against an installed package or a caller-provided checkout.
Read references/troubleshooting.md when an
import, runtime library, backend, or optional dependency mismatch appears.
tirx-kernels workflows require compute capability
10.0-class NVIDIA hardware and additional packages. Do not present them as
verified from an A100/CPU-only environment.Read references/repo-provenance.md before
assuming this skill matches a different checkout or release. Refresh the skill
when the commit, major package metadata, public API shape, or TIRx/S-TIR/RPC
workflow evidence changes.
Structured router metadata lives in
references/repo-routing-metadata.json.