Not in the top 1,000 by GitHub stars
Krusty84/triton-ascend-agent-dev-kit
A toolkit for AI agents used for development on Triton-Ascend for Ascend NPU
History
Review weekly changes to SKILL.md before updating. Dates mark the weeks in which we observed each version; checks apply to the recorded commits.
View weekly changes
skills/assign-triton-ascend-token-pools/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/batch-triton-ascend-token-reorder/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/batch-triton-ascend-token-unreorder/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-binned-moe-routing/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-fused-attention/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-fused-softmax/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-layer-norm/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-moe-gather-scatter/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-padded-moe-routing/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-small-matmul/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/build-triton-ascend-vector-add/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/fuse-triton-ascend-cat-conv1d/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/max-autotune-triton-ascend/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/optimize-triton-ascend-discrete-loads/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/optimize-triton-ascend-grouped-attention-access/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/optimize-triton-ascend-int-vectors/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/prevent-triton-ascend-ub-overflow/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/rank-triton-ascend-costmodel/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/schedule-triton-ascend-loads/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/skip-triton-ascend-padding-fill/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/tile-triton-ascend-gather/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/tune-triton-ascend-kernels/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/validate-triton-ascend-accuracy/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
skills/vectorize-triton-ascend-comparisons/SKILL.md
Week of Oct 26, 2026 · +0 / −0 lines
Before Instructions only → After Instructions only
4ab5ee7adf47 → 4ab5ee7adf47
Verified commit 4ab5ee7adf47755ecd42723f55f4c58e38be95a7
git clone --filter=blob:none --no-checkout https://github.com/Krusty84/triton-ascend-agent-dev-kit.git .hotskills/krusty84-triton-ascend-agent-dev-kit && git -C .hotskills/krusty84-triton-ascend-agent-dev-kit checkout --detach 4ab5ee7adf47755ecd42723f55f4c58e38be95a7
# Copy each selected skill directory from .hotskills/krusty84-triton-ascend-agent-dev-kit into .agents/skills/<skill-name>/Heat
0.1- Star growth, last 7 daysNot available
- Star growth, last 24 hoursNot available
- Rank movement, last 7 daysNot available
- Commits, last 30 daysNot available
- Accounts asking about it through MCP, last 7 daysNot available
- Hot votes this weekNot available
Heat never changes the order by stars, and sponsorship never touches it. How heat works
Stars over time
30-day change not yet available: not enough history.
Individual skills in this repository
- assign-triton-ascend-token-pools
skills/assign-triton-ascend-token-pools - batch-triton-ascend-token-reorder
skills/batch-triton-ascend-token-reorder - batch-triton-ascend-token-unreorder
skills/batch-triton-ascend-token-unreorder - build-triton-ascend-binned-moe-routing
skills/build-triton-ascend-binned-moe-routing - build-triton-ascend-fused-attention
skills/build-triton-ascend-fused-attention - build-triton-ascend-fused-softmax
skills/build-triton-ascend-fused-softmax - build-triton-ascend-layer-norm
skills/build-triton-ascend-layer-norm - build-triton-ascend-moe-gather-scatter
skills/build-triton-ascend-moe-gather-scatter - build-triton-ascend-padded-moe-routing
skills/build-triton-ascend-padded-moe-routing - build-triton-ascend-small-matmul
skills/build-triton-ascend-small-matmul - build-triton-ascend-vector-add
skills/build-triton-ascend-vector-add - fuse-triton-ascend-cat-conv1d
skills/fuse-triton-ascend-cat-conv1d - max-autotune-triton-ascend
skills/max-autotune-triton-ascend - optimize-triton-ascend-discrete-loads
skills/optimize-triton-ascend-discrete-loads - optimize-triton-ascend-grouped-attention-access
skills/optimize-triton-ascend-grouped-attention-access - optimize-triton-ascend-int-vectors
skills/optimize-triton-ascend-int-vectors - prevent-triton-ascend-ub-overflow
skills/prevent-triton-ascend-ub-overflow - rank-triton-ascend-costmodel
skills/rank-triton-ascend-costmodel - schedule-triton-ascend-loads
skills/schedule-triton-ascend-loads - skip-triton-ascend-padding-fill
skills/skip-triton-ascend-padding-fill - tile-triton-ascend-gather
skills/tile-triton-ascend-gather - tune-triton-ascend-kernels
skills/tune-triton-ascend-kernels - validate-triton-ascend-accuracy
skills/validate-triton-ascend-accuracy - vectorize-triton-ascend-comparisons
skills/vectorize-triton-ascend-comparisons
How it works
assign-triton-ascend-token-pools
When your agent uses it
Implement and optimize Triton-Ascend request-to-token-pool assignment using int32 metadata, masked prefix-length reduction, and fixed-offset block loops. Use when an agent ports SGLang-style KV cache assignment to Ascend NPU, copies variable request spans from a concatenated cache, or needs to replace loop-carried vector offsets that compile poorly.
What it loads into context
Frontmatter
85 tokensAlways available to the agent
SKILL.md
524 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,254 bytesSKILL.mdcore2,254 bytesSKILL.mdcore2,254 bytes
Read SKILL.md
# Assign Triton-Ascend Token Pools
## Goal
Copy each request's contiguous cache segment into the correct row and token range of a request-to-token table.
## Workflow
1. Launch one program per request.
2. Load kv_start, kv_end, and the destination request-pool row.
3. Sum end-start for all earlier requests to find this request's source offset in the concatenated cache.
4. Use int32 metadata when all lengths, offsets, and pool indices fit.
5. Copy kv_end-kv_start elements in fixed BLOCK_SIZE chunks with derived per-iteration offsets.
View the complete source on GitHubbatch-triton-ascend-token-reorder
When your agent uses it
Batch MoE token reordering in Triton-Ascend with contiguous index loads, random source-row reads, extension.insert_slice assembly in UB, and coalesced output stores. Use when an agent must implement output[j] = input[indices[j]] on Ascend NPU and one-program-per-token GPU tiling creates too many logical cores or scattered writes.
What it loads into context
Frontmatter
87 tokensAlways available to the agent
SKILL.md
560 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,387 bytesSKILL.mdcore2,387 bytesSKILL.mdcore2,387 bytesSKILL.mdcore2,387 bytes
Read SKILL.md
# Batch Triton-Ascend Token Reorder
## Goal
Gather several indexed token rows per program, assemble them in an on-chip buffer, and write one contiguous output tile.
## Workflow
1. Treat input and output as S by D and indices as a length-S integer vector.
2. Assign BLOCK_SIZE consecutive output rows to each program.
3. Load their indices as one vector.
4. Loop over valid rows, load each indexed D-element source row, and insert it into a BLOCK_SIZE by D UB tensor.
5. Store the assembled tile with row and column masks.
View the complete source on GitHubbatch-triton-ascend-token-unreorder
When your agent uses it
Batch inverse MoE token reordering in Triton-Ascend with contiguous tile loads, extension.extract_slice row extraction, and indexed output stores. Use when an agent must scatter sequential routed tokens back to output[indices[j]], reduce excessive one-token logical cores, or exploit contiguous reads while accepting dispersed writes on Ascend NPU.
What it loads into context
Frontmatter
81 tokensAlways available to the agent
SKILL.md
500 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,185 bytesSKILL.mdcore2,185 bytes
Read SKILL.md
# Batch Triton-Ascend Token Unreorder
## Goal
Read a contiguous block of routed token rows once, extract rows in UB, and scatter each row to its indexed destination.
## Workflow
1. Treat input as S by D contiguous routed rows and indices as destination rows.
2. Assign BLOCK_SIZE consecutive input rows to each program.
3. Load a BLOCK_SIZE by D input tile and BLOCK_SIZE indices with masks.
4. Extract each valid row with extension.extract_slice.
5. Store the row at indices[row] * D with a column mask.
View the complete source on GitHubbuild-triton-ascend-binned-moe-routing
When your agent uses it
Build capacity-limited binned MoE gather, scatter, and router-weight-gradient kernels for Triton-Ascend using sorted expert bins, UB sub-block buffering, and vector-core-aware tiling. Use when an agent ports MegaBlocks binned routing, packs tokens into fixed expert-capacity tensors, restores top-k token outputs, or must handle sub-blocks that cross expert boundaries.
What it loads into context
Frontmatter
93 tokensAlways available to the agent
SKILL.md
556 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,645 bytes
Read SKILL.md
# Build Triton-Ascend Binned MoE Routing
## Goal
Map sorted token assignments into a tensor shaped experts by expert_capacity by hidden_size, truncate overflow per expert, and implement the inverse scatter and router-weight gradient.
## Workflow
1. Require bin_ids to be nondecreasing expert IDs aligned with indices.
2. Interpret bins[e] as the inclusive cumulative assignment count through expert e.
3. For gather, compute each assignment's offset within its expert and keep only offsets below expert_capacity.
4. Buffer rows for the current expert in UB; flush them when the expert ID changes inside a sub-block.
5. For scatter, load valid expert-capacity rows, store to unique assignment slots, optionally scale, and reduce TOP_K slots per token.
6. For wgrad, dot each kept expert row with the gradient of indices[i] // TOP_K.View the complete source on GitHubbuild-triton-ascend-fused-attention
When your agent uses it
Build and adapt a FlashAttention-v2-style fused forward attention kernel for Triton-Ascend using tiled Q/K/V block pointers, online softmax, causal staging, and float32 accumulation. Use when an agent needs forward scaled dot-product attention in BNSD layout on Ascend NPU, must support causal or non-causal masking, or must handle large head dimensions without overflowing on-chip memory.
What it loads into context
Frontmatter
96 tokensAlways available to the agent
SKILL.md
715 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore3,012 bytes
Read SKILL.md
# Build Triton-Ascend Fused Attention
## Goal
Compute softmax(QKᵀ * scale)V without materializing the full attention matrix. Support BNSD tensors shaped Z by H by N_CTX by HEAD_DIM.
## Workflow
1. Validate matching Q, K, and V shapes, compatible strides, supported dtype, and HEAD_DIM in {16, 32, 64, 128, 256}.
2. Choose BLOCK_M for query rows and BLOCK_N for key/value rows. Require N_CTX to be divisible by both in the compact implementation.
3. Map each task to a batch, head, and query-block tuple and create block pointers for Q, K, V, and output.
4. Load one Q block and stream K/V blocks through an online-softmax inner loop.
5. For causal attention, process preceding blocks and the diagonal block as separate stages; apply the triangular mask only to the diagonal stage.
6. Normalize the accumulated output by the running denominator and store it in the output dtype.View the complete source on GitHubbuild-triton-ascend-fused-softmax
When your agent uses it
Build a fused row-wise softmax kernel for Triton-Ascend with stable reductions, power-of-two padding, strided rows, and masked memory operations. Use when an agent needs to fuse max, exponentiation, sum, and normalization for a two-dimensional NPU tensor or adapt this reduction pattern to a similar row-wise operator.
What it loads into context
Frontmatter
82 tokensAlways available to the agent
SKILL.md
625 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,541 bytesSKILL.mdcore2,541 bytes
Read SKILL.md
# Build Triton-Ascend Fused Softmax
## Goal
Compute softmax across the last dimension while reading each input row once and writing each output row once.
## Workflow
1. Interpret the input as n_rows by n_cols and preserve its row stride.
2. Choose BLOCK_SIZE as the next power of two greater than or equal to n_cols.
3. Let each program process rows separated by tl.num_programs(0).
4. Load a padded row with -inf outside n_cols.
5. Subtract the row maximum, exponentiate, reduce the sum, normalize, and store with the original mask.
View the complete source on GitHubbuild-triton-ascend-layer-norm
When your agent uses it
Build a fused forward LayerNorm kernel for Triton-Ascend with row-wise mean and variance reductions, float32 accumulation, affine weight and bias, and masked feature tiles. Use when an agent needs LayerNorm over the last dimension on Ascend NPU or needs a reusable two-pass reduction pattern for normalization kernels.
What it loads into context
Frontmatter
77 tokensAlways available to the agent
SKILL.md
655 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,634 bytesSKILL.mdcore2,634 bytes
Read SKILL.md
# Build Triton-Ascend LayerNorm
## Goal
Implement the forward equation y = ((x - mean) / sqrt(var + eps)) * weight + bias over the final tensor dimension.
## Workflow
1. Reshape the input logically to M by N, where N is the normalized dimension.
2. Allocate output with the original shape and allocate optional mean and reciprocal-standard-deviation buffers as float32 vectors of length M.
3. Launch one program per row.
4. Accumulate the mean in float32 across masked BLOCK_SIZE tiles.
5. Make a second pass for variance, compute rstd, then make a third pass to normalize and apply weight and bias.
View the complete source on GitHubbuild-triton-ascend-moe-gather-scatter
When your agent uses it
Build Ascend-friendly MoE gather, scatter, and router-weight-gradient kernels with vector-core-sized grids, UB-aware row/column tiling, and CANN slice extensions. Use when an agent ports MegaBlocks-style unbinned token routing to Triton-Ascend, reorders top-k token assignments, combines weighted expert outputs, or computes per-route weight gradients.
What it loads into context
Frontmatter
91 tokensAlways available to the agent
SKILL.md
629 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,783 bytesSKILL.mdcore2,783 bytes
Read SKILL.md
# Build Triton-Ascend MoE Gather and Scatter
## Goal
Implement the unbinned routing triplet over assignment IDs: gather token rows into routing order, scatter weighted rows back to tokens, and compute one router-weight gradient per assignment.
## Workflow
1. Define L = tokens * TOP_K and require indices to be a permutation of assignment IDs in [0, L).
2. Gather routed row i from token row indices[i] // TOP_K.
3. Scatter routed row i into assignment slot indices[i], optionally scale by weights[indices[i]], then reduce the TOP_K slots per token.
4. Compute wgrad[indices[i]] as the float32 dot product of routed row i and grads[indices[i] // TOP_K].
5. Split L approximately evenly across the target vector cores.
6. Process SUB_BLOCK_SIZE assignments and BLOCK_X feature columns at a time.View the complete source on GitHubbuild-triton-ascend-padded-moe-routing
When your agent uses it
Build padded MoE gather, scatter, and router-weight-gradient kernels for Triton-Ascend using real cumulative bins, padded cumulative bins, UB slice assembly, and vector-core-aware tiling. Use when an agent ports MegaBlocks padded routing, aligns each expert's token segment to a fixed multiple, restores weighted top-k outputs, or maps gradients through padded expert storage.
What it loads into context
Frontmatter
90 tokensAlways available to the agent
SKILL.md
560 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,606 bytes
Read SKILL.md
# Build Triton-Ascend Padded MoE Routing
## Goal
Store every expert's real assignments in a separately padded segment, preserve zero-filled gaps, and implement inverse scatter and per-assignment weight gradients.
## Workflow
1. Sort assignments by expert to obtain aligned indices and nondecreasing bin_ids.
2. Build bins from real cumulative counts.
3. Round each expert count to the required padding multiple and build padded_bins from cumulative padded counts.
4. Map sorted position i to offset_in_expert = i - bins[e-1] and padded row = padded_bins[e-1] + offset_in_expert.
5. Gather token indices[i] // TOP_K into that padded row.
6. Scatter real rows back through unique assignment IDs and compute wgrad with the same mapping.View the complete source on GitHubbuild-triton-ascend-small-matmul
When your agent uses it
Build a single-program Triton-Ascend matrix multiplication with fused bias using two-dimensional pointer grids and tl.dot. Use when an agent needs a compact matmul-plus-bias kernel for small fixed shapes, a minimal Ascend cube-operation example, or a correctness scaffold before introducing multi-block tiling.
What it loads into context
Frontmatter
75 tokensAlways available to the agent
SKILL.md
570 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,304 bytesSKILL.mdcore2,304 bytes
Read SKILL.md
# Build Triton-Ascend Small Matmul
## Goal
Compute output[A, C] = x[A, B] @ y[B, C] + bias[A, C] in one Triton program for small compile-time shapes.
## Workflow
1. Validate x as A by B, y as B by C, and bias as A by C.
2. Create row, reduction, and column offsets with tl.arange.
3. Form the flattened pointer grids through broadcasting.
4. Load both matrices and bias, call tl.dot, and store the result.
5. Launch exactly one program only while all tiles fit the target's on-chip resources.
View the complete source on GitHubbuild-triton-ascend-vector-add
When your agent uses it
Build and debug masked one-dimensional elementwise kernels for Triton-Ascend, including launch wrappers and PyTorch/NPU correctness checks. Use when an agent needs a minimal Triton-Ascend kernel scaffold or must apply program IDs, pointer offsets, tail masks, constexpr block sizes, and launch grids to vector operations.
What it loads into context
Frontmatter
77 tokensAlways available to the agent
SKILL.md
550 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,336 bytesSKILL.mdcore2,336 bytes
Read SKILL.md
# Build Triton-Ascend Vector Add
## Goal
Implement a standalone NPU kernel that computes elementwise addition for arbitrary tensor lengths. Reuse the same pattern for other one-dimensional elementwise operations.
## Workflow
1. Require both inputs to have the same shape, dtype, device, and supported layout.
2. Allocate the output with torch.empty_like and use output.numel() as the logical length.
3. Assign one contiguous block to each Triton program.
4. Mask every load and store so non-divisible tail elements never access invalid memory.
5. Derive the launch grid from the selected BLOCK_SIZE.
View the complete source on GitHubfuse-triton-ascend-cat-conv1d
When your agent uses it
Refactor fused causal Conv1d state updates for Triton-Ascend by replacing negative-offset cat emulation and tl.where selection with transposed UB assembly through extension.insert_slice. Use when an agent ports causal_conv1d_update-style kernels, sees discrete scalar loads from negative offsets, suffers 32-byte tail-axis padding, or launches far more logical tasks than Ascend vector cores.
What it loads into context
Frontmatter
93 tokensAlways available to the agent
SKILL.md
552 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,586 bytesSKILL.mdcore2,586 bytes
Read SKILL.md
# Fuse Triton-Ascend Cat and Causal Conv1d
## Goal
Join convolution state and new tokens in UB, update the cached tail, and compute grouped causal Conv1d without materializing a global concatenation.
## Workflow
1. Preserve the reference contract for x, conv_state, depthwise weights, bias, activation, and state-row indices.
2. Load state and input from nonnegative contiguous addresses.
3. Transpose or reshape them so concatenation occurs along a contiguous flattened UB axis.
4. Insert state followed by new tokens with extension.insert_slice.
5. Derive the new state tail and convolution windows from the assembled tensor.
6. Map work to approximately the available vector-core count and loop over remaining feature tiles inside each program.View the complete source on GitHubmax-autotune-triton-ascend
When your agent uses it
Apply Triton-Ascend max_autotune to search base kernel configurations together with Ascend compiler options for vector, cube, or mixed operators. Use when an agent needs multi-parameter performance tuning without manually enumerating every triton.Config combination, must choose kernel_type, or must constrain compiler-option search lists such as num_stages and enable_ubuf_saving.
What it loads into context
Frontmatter
89 tokensAlways available to the agent
SKILL.md
536 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,379 bytesSKILL.mdcore2,379 bytes
Read SKILL.md
# Max-Autotune Triton-Ascend
## Goal
Expand a small set of kernel meta-parameter configurations into a controlled search over Ascend compiler options.
## Workflow
1. Verify the kernel and PyTorch reference before tuning.
2. Import max_autotune from triton.backends.ascend.runtime.
3. Provide a small base configs list containing only meaningful kernel meta-parameters.
4. Set key to runtime values whose changes may require a new winner.
5. Classify the kernel as vector, cube, or mix.
6. Add short explicit option lists only when the built-in search space is unsuitable.View the complete source on GitHuboptimize-triton-ascend-discrete-loads
When your agent uses it
Optimize bounded discrete reads in Triton-Ascend by staging a contiguous source vector in UB and selecting elements with tl.gather. Use when an agent implements out = x[idx], ports arbitrary global-memory gathers from GPU, or sees scalarized indirect loads and the complete source domain is small enough to fit on chip.
What it loads into context
Frontmatter
78 tokensAlways available to the agent
SKILL.md
452 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytesSKILL.mdcore2,066 bytes
Read SKILL.md
# Optimize Triton-Ascend Discrete Loads
## Goal
Replace repeated indirect global reads with one contiguous global-to-UB transfer followed by on-chip gather.
## Workflow
1. Confirm the source domain length M is bounded and fits the UB budget.
2. Load x[0:M] contiguously into an on-chip vector.
3. Load the N indices and validate both lower and upper bounds.
4. Replace invalid indices with a safe value before tl.gather.
5. Gather along the source axis and store only valid outputs.
View the complete source on GitHuboptimize-triton-ascend-grouped-attention-access
When your agent uses it
Optimize irregular KV-cache access in Triton-Ascend grouped decode attention by vector-loading contiguous inner dimensions, assembling discrete outer rows with CANN slice extensions, and transposing UB tiles for tl.dot. Use when an agent ports grouped-query decode attention whose K or V cache addresses are indirect and naive low-axis-discrete loads degrade to scalar memory access.
What it loads into context
Frontmatter
86 tokensAlways available to the agent
SKILL.md
574 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,629 bytesSKILL.mdcore2,629 bytes
Read SKILL.md
# Optimize Triton-Ascend Grouped Attention Access
## Goal
Preserve vectorized contiguous loads while gathering KV-cache rows selected by an indirect token-location vector.
## Workflow
1. Classify each target tile by which axis is discrete and which axis is contiguous.
2. Load a discrete outer row and its contiguous head dimension as one vector.
3. Assemble BLOCK_N rows into an on-chip tensor with extension.insert_slice.
4. Transpose the assembled K tile when tl.dot requires HEAD_DIM by BLOCK_N.
5. Load V directly as BLOCK_N by VALUE_DIM when its inner value dimension is contiguous.
6. Feed the tiles into numerically stable online softmax across KV splits.View the complete source on GitHuboptimize-triton-ascend-int-vectors
When your agent uses it
Optimize integer vector kernels for Triton-Ascend by preferring int32 arithmetic when the value and index ranges permit it. Use when an agent ports an int64 GPU elementwise kernel to Ascend NPU, observes scalarized integer arithmetic, or designs vector addition, subtraction, or reduction over integer tensors.
What it loads into context
Frontmatter
76 tokensAlways available to the agent
SKILL.md
508 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,179 bytesSKILL.mdcore2,179 bytes
Read SKILL.md
# Optimize Triton-Ascend Integer Vectors
## Goal
Keep integer elementwise work on efficient Ascend vector paths without changing numerical semantics.
## Workflow
1. Determine the minimum signed range required by inputs, offsets, intermediates, and outputs.
2. Use torch.int32 tensors and int32-compatible scalar arguments when every possible value fits.
3. Keep pointer arithmetic and tail masking separate from the arithmetic dtype decision.
4. Launch a masked one-dimensional kernel and compare it with an int32 PyTorch reference.
5. Benchmark int32 and int64 only after synchronizing the NPU around timed regions.
View the complete source on GitHubprevent-triton-ascend-ub-overflow
When your agent uses it
Prevent Triton-Ascend Unified Buffer overflow by streaming large logical vectors through bounded compile-time tiles with masked loop iterations. Use when an agent ports a GPU kernel that loads a long sequence or metadata array at once, compilation reports UB pressure, or runtime shapes such as KV-page allocation exceed safe on-chip capacity.
What it loads into context
Frontmatter
77 tokensAlways available to the agent
SKILL.md
471 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,231 bytesSKILL.mdcore2,231 bytes
Read SKILL.md
# Prevent Triton-Ascend UB Overflow
## Goal
Keep each live tile within Ascend UB while preserving the semantics of a larger logical operation.
## Workflow
1. List all simultaneously live tensors and estimate their bytes, including padding and multibuffer copies.
2. Select a BLOCK_SIZE that fits the UB budget with safety margin.
3. Replace one load over the maximum logical length with a compile-time loop over BLOCK_SIZE tiles.
4. Recompute global offsets from the loop index and apply a runtime validity mask.
5. Store each completed tile before advancing so earlier tiles do not remain live.
View the complete source on GitHubrank-triton-ascend-costmodel
When your agent uses it
Generate TTIR for Triton-Ascend kernel configurations and rank them with the Ascend costmodel backend before empirical autotuning. Use when an agent needs to prefilter a large configuration space, construct costmodel_bench items, bind runtime TTIR arguments or program IDs, or interpret predicted latency values.
What it loads into context
Frontmatter
74 tokensAlways available to the agent
SKILL.md
626 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,883 bytesSKILL.mdcore2,883 bytesSKILL.mdcore2,883 bytes
Read SKILL.md
# Rank Triton-Ascend Configs with Costmodel
## Goal
Predict latency for several compile-time kernel configurations and retain the most promising candidates for real correctness checks and benchmarking.
## Workflow
1. Define the Triton kernel, pointer/runtime signature, and candidate constexpr values.
2. Build a separate ASTSource and TTIR string for every candidate.
3. Enable the costmodel backend in Ascend compiler options.
4. Create one item per candidate with a unique config name, TTIR, and optional arg_bindings.
5. Call costmodel_bench, sort the returned microsecond predictions, and shortlist candidates.
6. Verify and benchmark the shortlist on real NPU inputs.View the complete source on GitHubschedule-triton-ascend-loads
When your agent uses it
Reorder independent Triton-Ascend loads to expose overlap with loop-carried stores and reduce dependency stalls. Use when an agent profiles a loop where an early load waits on a previous iteration's store, a later load is independent, or assumes the compiler will automatically reorder source-level memory operations.
What it loads into context
Frontmatter
72 tokensAlways available to the agent
SKILL.md
473 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,232 bytesSKILL.mdcore2,232 bytesSKILL.mdcore2,232 bytesSKILL.mdcore2,232 bytes
Read SKILL.md
# Schedule Triton-Ascend Loads
## Goal
Issue independent memory work before a dependency-blocked load so the Ascend pipeline can overlap operations across loop iterations.
## Workflow
1. Draw read/write dependencies for every load and store in one loop iteration and across adjacent iterations.
2. Identify a load blocked by a prior store to the same or possibly aliased address.
3. Find later loads that have no dependency on that store.
4. Move only those independent loads before the blocked load.
5. Preserve calculation and store semantics, then inspect the generated schedule or profiler trace.
View the complete source on GitHubskip-triton-ascend-padding-fill
When your agent uses it
Use Triton-Ascend tl.load care_padding=False safely to skip initialization of masked tail lanes and remove unnecessary padding work. Use when an agent profiles a runtime-masked tail load whose invalid lanes are never consumed, or needs to decide whether undefined padded values can be permitted for a bandwidth-sensitive Ascend kernel.
What it loads into context
Frontmatter
75 tokensAlways available to the agent
SKILL.md
389 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore1,919 bytesSKILL.mdcore1,919 bytes
Read SKILL.md
# Skip Triton-Ascend Padding Fill
## Goal
Avoid filling invalid load lanes when those values have no influence on any observable result.
## Workflow
1. Trace every consumer of the loaded tensor.
2. Prove that lanes where mask is false cannot reach arithmetic, reductions, indexing, control flow, or stores.
3. Omit other and set care_padding=False on the masked load.
4. Preserve downstream masks until the loaded value is no longer live.
5. Benchmark against the default padded load on the same runtime-tail shapes.
View the complete source on GitHubtile-triton-ascend-gather
When your agent uses it
Tile two-dimensional torch.gather(dim=1) kernels for Triton-Ascend so the logical grid stays near the physical vector-core count while each program handles multiple batch rows and loops over K. Use when an agent ports a GPU grid of B by ceil(K/BLOCK_K), observes NPU launch or scheduling overhead, or needs stride-aware indexed row gathers.
What it loads into context
Frontmatter
86 tokensAlways available to the agent
SKILL.md
604 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,330 bytesSKILL.mdcore2,330 bytes
Read SKILL.md
# Tile Triton-Ascend Gather
## Goal
Compute out[b, k] = x[b, index[b, k]] without launching one logical program for every batch-row and K tile.
## Workflow
1. Query the target num_vectorcore value.
2. Choose BLOCK_B so ceil(B / BLOCK_B) is close to, and not far above, the core count.
3. Launch a one-dimensional grid over batch blocks.
4. Loop over K inside each program in BLOCK_K tiles.
5. Load index tiles, validate them against C, gather x values with explicit strides, and store with combined masks.
View the complete source on GitHubtune-triton-ascend-kernels
When your agent uses it
Add standard or advanced autotuning to Triton-Ascend kernels, define shape keys and candidate meta-parameters, and structure kernels so automatic split and tiling analysis can recognize their axes. Use when an agent needs to benchmark block-size or multibuffer choices, use configs=[] for generated vector-kernel candidates, or diagnose why Triton-Ascend autotune cannot infer a tunable axis.
What it loads into context
Frontmatter
93 tokensAlways available to the agent
SKILL.md
744 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore3,251 bytesSKILL.mdcore3,251 bytesSKILL.mdcore3,251 bytes
Read SKILL.md
# Tune Triton-Ascend Kernels
## Goal
Select a correct kernel configuration for each relevant input shape without hardcoding one block size for all workloads.
## Workflow
1. Establish a correct untuned kernel and reference test.
2. Choose standard autotune when candidate configurations are known.
3. Choose advanced autotune when Triton-Ascend should infer vector split or tiling candidates.
4. Put only values that can change the winner in key.
5. Derive the launch grid from meta-parameters and omit tunable meta-parameters at launch.
6. Validate the tuned result, then benchmark representative shapes.View the complete source on GitHubvalidate-triton-ascend-accuracy
When your agent uses it
Validate Triton-Ascend kernel outputs against PyTorch references with dtype-aware tolerances, exact integer checks, bfloat16 promotion, and boolean handling. Use when an agent writes or reviews NPU kernel tests, needs a reusable accuracy-comparison helper, or must choose an initial comparison policy for float16, bfloat16, float32, integer, or boolean outputs.
What it loads into context
Frontmatter
88 tokensAlways available to the agent
SKILL.md
561 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore2,593 bytesSKILL.mdcore2,593 bytes
Read SKILL.md
# Validate Triton-Ascend Accuracy
## Goal
Make correctness checks explicit and consistent across Triton-Ascend kernel tests.
## Workflow
1. Compute the PyTorch reference from the same inputs before interpreting performance.
2. Assert identical output shape and dtype.
3. Compare floating-point tensors with dtype-aware tolerances.
4. Compare integer and boolean tensors exactly.
5. Add edge shapes, tail masks, zeros, extreme values, and NaNs when the operator semantics allow them.
View the complete source on GitHubvectorize-triton-ascend-comparisons
When your agent uses it
Vectorize explicit integer comparisons in Triton-Ascend by casting bounded index vectors to float32 before tl.where or similar compute expressions. Use when an agent observes scalarized int32 or int64 comparison code on Ascend NPU, especially in LayerNorm tail handling, while load/store masks already compile efficiently.
What it loads into context
Frontmatter
77 tokensAlways available to the agent
SKILL.md
442 tokensWhen the skill is activated
Reference documents
0 tokensLoaded on request
Token counts are estimates. Scripts run separately; they are not counted as reference context.
The playbook
- Goal
- Workflow
- Implementation Pattern
- Ascend Guardrails
- Verification
Files
SKILL.mdcore1,991 bytesSKILL.mdcore1,991 bytes
Read SKILL.md
# Vectorize Triton-Ascend Comparisons
## Goal
Move eligible explicit comparisons onto Ascend vector cast and compare instructions without changing mask semantics.
## Workflow
1. Identify comparisons used in compute expressions such as tl.where, not only load/store masks.
2. Prove that all compared integer values are exactly representable in float32.
3. Cast the index vector to tl.float32 immediately before the comparison.
4. Keep original integer offsets for pointer arithmetic and memory masks.
5. Inspect performance and compare results around the tail boundary.
View the complete source on GitHubSkills included
- assign-triton-ascend-token-pools
- batch-triton-ascend-token-reorder
- batch-triton-ascend-token-unreorder
- build-triton-ascend-binned-moe-routing
- build-triton-ascend-fused-attention
- build-triton-ascend-fused-softmax
- build-triton-ascend-layer-norm
- build-triton-ascend-moe-gather-scatter
- build-triton-ascend-padded-moe-routing
- build-triton-ascend-small-matmul
- build-triton-ascend-vector-add
- fuse-triton-ascend-cat-conv1d
- max-autotune-triton-ascend
- optimize-triton-ascend-discrete-loads
- optimize-triton-ascend-grouped-attention-access
- optimize-triton-ascend-int-vectors
- prevent-triton-ascend-ub-overflow
- rank-triton-ascend-costmodel
- schedule-triton-ascend-loads
- skip-triton-ascend-padding-fill
- tile-triton-ascend-gather
- tune-triton-ascend-kernels
- validate-triton-ascend-accuracy
- vectorize-triton-ascend-comparisons
Repository facts
- License
- Apache-2.0
- Created
- Aug 14, 2026
- Last pushed
- Aug 15, 2026
- Forks
- 3
- Open issues
- 0
- Project activity
- Slowing
Before you install
Instructions onlyAutomated signals, not a guarantee
Checked Nov 4, 2026
Not fully analyzed: some files were too long, unreadable or missing. This never lowers the level.
Show 35 notes
skills/assign-triton-ascend-token-pools/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/assign-triton-ascend-token-pools/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/batch-triton-ascend-token-reorder/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/batch-triton-ascend-token-reorder/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/batch-triton-ascend-token-reorder/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/batch-triton-ascend-token-unreorder/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/build-triton-ascend-fused-softmax/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/build-triton-ascend-layer-norm/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/build-triton-ascend-moe-gather-scatter/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/build-triton-ascend-small-matmul/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/build-triton-ascend-vector-add/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/fuse-triton-ascend-cat-conv1d/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/max-autotune-triton-ascend/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzedskills/optimize-triton-ascend-discrete-loads/SKILL.md:1Analysis incomplete: Referenced executable target unavailable; not analyzed
- No broad tool permissions
- No dangerous shell commands
- No network access
- No hidden or obfuscated text
- No instruction overrides
- No executable scripts
- No access to secrets
- No requests to vote in Hot
How the signals fit together
Facts from a static read of the files at the pinned commit. They describe what the code does, not why.
Some files could not be read; the facts below still hold.
No combined signals at this commit.
Works with
| Agent | Status | Evidence | Install to |
|---|---|---|---|
| Claude Code | Compatible | Standard SKILL.md skills/assign-triton-ascend-token-pools/SKILL.md | .claude/skills/<skill-name>/ |
| Codex | Native | Manifest AGENTS.md | .agents/skills/<skill-name>/ |
| Cursor | Compatible | Standard SKILL.md skills/assign-triton-ascend-token-pools/SKILL.md | .cursor/skills/<skill-name>/ |
| Gemini CLI | Compatible | Standard SKILL.md skills/assign-triton-ascend-token-pools/SKILL.md | .gemini/skills/<skill-name>/ |
| GitHub Copilot | Compatible | Standard SKILL.md skills/assign-triton-ascend-token-pools/SKILL.md | .github/skills/<skill-name>/ |
| OpenCode | Compatible | Standard SKILL.md skills/assign-triton-ascend-token-pools/SKILL.md | .opencode/skills/<skill-name>/ |
- Native The repository ships a manifest, folder or frontmatter field for this agent.
- Compatible A standard SKILL.md that this agent can read.
- Unknown No evidence either way.
Derived automatically from paths, manifests and frontmatter. Not tested on each agent.