From 70aef3e24a13ee8a1ddaa601d468d65501667352 Mon Sep 17 00:00:00 2001 From: Woosuk Kwon Date: Wed, 2 Sep 2026 21:53:43 +0000 Subject: [PATCH 1/4] [Agents] Add concise Triton kernel-writing skill Co-authored-by: OpenAI Codex Signed-off-by: Woosuk Kwon --- .agents/skills/triton-kernel-writing/SKILL.md | 60 +++++++++++++++++++ .../triton-kernel-writing/agents/openai.yaml | 4 ++ 2 files changed, 64 insertions(+) create mode 100644 .agents/skills/triton-kernel-writing/SKILL.md create mode 100644 .agents/skills/triton-kernel-writing/agents/openai.yaml diff --git a/.agents/skills/triton-kernel-writing/SKILL.md b/.agents/skills/triton-kernel-writing/SKILL.md new file mode 100644 index 000000000000..48d1c751d0b5 --- /dev/null +++ b/.agents/skills/triton-kernel-writing/SKILL.md @@ -0,0 +1,60 @@ +--- +name: triton-kernel-writing +description: Write or review Triton kernels for vLLM, with practical guidance for generated-code inspection, launch grids, indexing, specialization, tuning, and representative performance validation. +--- + +# Triton Kernel Writing + +## Implementation + +- Follow the official + [Triton semantics](https://triton-lang.org/main/python-api/triton-semantics.html). + Check it when behavior may differ from Python or NumPy, especially type + promotion, integer division and modulo, casts, broadcasting, and variable + scoping. +- Use the Triton kernel generated by `torch.compile` as a possible + implementation to inspect. Print Inductor's generated code with + `TORCH_LOGS="output_code" .venv/bin/python