Hands-on implementation template and API reference for writing, tuning, debugging, and benchmarking Triton GPU kernels. Covers the full triton.language API surface, autotuning patterns, profiling workflows, and production integration.
SkillScore100Maintained
Automatic
◆AI Engineer pack
Last verified 8/21/2026
What it changes
Passed 23 of 23 test cases with the skill, and 19 of 23 without it.
Without skill83%
With skill100%
Checks it passed that the model alone missed
Uses `tl.device_assert` for runtime validation on the GPU device
Passes a boolean boundary mask tensor to memory load instructions
Specifies `other=0.0` or a safe fallback value for masked-out tile elements
and 2 more in the full report
4 fixed19 passed either way0 still failing0 broke
Pass-rate lift
+17 pp
Tokens
+115%
Agent turns
0%
Response time
-40%
Model gemini-3.6-flashMeasured 8/21/2026v123 of 23 cases passed with skill
Tokens, turns and time describe resource use, not a dollar price.
See it in action
One of 4 test cases the skill fixed. Same model, same prompt, with and without the skill.
1 of 4
Prompt
When running a custom GPU matrix kernel, we suspect vector loads are reading out-of-bounds across partial tile boundaries. Which NVIDIA CLI memory inspection tool should we execute, and what code construct prevents partial tile memory faults?
What was checked, without and with the skill
Checked
Without skill
With skill
Recommends running `compute-sanitizer` to detect out-of-bounds GPU memory accesses
Passed
Passed
Identifies missing or incomplete boundary masks as the root cause of out-of-bounds memory faults
Missed
Passed
case-06 · gemini-3.6-flash · 8/21/2026 · answers are capped and redacted
What's inside
The instructions your model reads when the skill loads.
SKILL.md341 linessingle file
Triton Kernel Programming
Overview
This skill provides a hands-on reference for building production Triton kernels. It covers the triton.language API, autotune decorators, the @triton.jit compilation model, debugging/interpreter workflows, and triton.testing benchmarks.
When to Use
Use this skill when:
Implementing any custom GPU compute kernel in Triton
Optimizing inference latency for small-batch transformer operations
Fusing operations (e.g., matmul + activation, attention with softmax)
Porting CUDA kernels to Triton for easier maintenance
Do not use for:
Standard PyTorch operations that already run fast (use torch.compile)
Distributed or multi-GPU parallelism patterns
CPU-bound workloads
Installation
# Triton ships with PyTorch ≥2.0. Install latest:
pip install -U triton
# Or build from source for latest features:
git clone https://github.com/triton-lang/triton.git
cd triton
pip install -r python/requirements.txt
pip install .
# For profiling:
pip install nvitools # NVIDIA profiling helpers
pip install torch_tb_profiler # PyTorch profiling