tilelang-ascend: Skill for Claude Code

.agents/skills/tilelang-op-design/SKILL.md

tilelang-op-design is a skill for Claude Code, Codex from tile-ai/tilelang-ascend. It costs 92 tokens per session (3,188 once invoked), scanned A, original, MIT.

A design-document generator for TileLang Ascend operators, where an operator is a computation such as softmax, layer normalization, or matrix multiplication.

In plain words
What is it for?
Use it when designing a new operator, planning a migration, or generating a design.md file with the programming mode, API mapping, memory layout, tiling strategy, and verification plan.
Why use it?
It turns an operator’s formula and tensor shapes into a documented implementation plan. This makes choices about memory, tiling, loops, synchronization, and testing explicit before coding.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions subagents; names the AskUserQuestion tool; installed under .agents/ (shared by several agents).

This is tile-ai/tilelang-ascend's own configuration. It tells Claude Code and Codex how to work on tilelang-ascend itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything tilelang-ascend configures →

Reuse

Borrowing it

Nothing to install: this file belongs to tile-ai/tilelang-ascend. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/tile-ai/tilelang-ascend/ascendc_pto/.agents/skills/tilelang-op-design/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/tile-ai/tilelang-ascend

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for tilelang-op-design

README.md
[![agentmods](https://agentmods.dev/badge/skills/tile-ai/tilelang-ascend/tilelang-op-design/github.svg)](https://agentmods.dev/skills/tile-ai/tilelang-ascend/tilelang-op-design)
Your own site
<a href="https://agentmods.dev/skills/tile-ai/tilelang-ascend/tilelang-op-design"><img src="https://agentmods.dev/badge/skills/tile-ai/tilelang-ascend/tilelang-op-design/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for tilelang-op-design

Your own site · 80×15
<a href="https://agentmods.dev/skills/tile-ai/tilelang-ascend/tilelang-op-design"><img src="https://agentmods.dev/badge/skills/tile-ai/tilelang-ascend/tilelang-op-design.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 92 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,188 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00092 $0.03188
Opus 5 $0.00046 $0.01594
Sonnet 5 $0.00018 $0.00638
Haiku 4.5 $0.00009 $0.00319

Measured 10d ago against content hash 1df54d4c8494, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

tilelang-op-design scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/skills/tilelang-op-design/SKILL.md · 191 lines

How it starts

The opening of the file, as written. The whole thing — 191 lines — stays where its author put it; the contents beside it link to each section on GitHub.

TileLang-Ascend 算子设计文档生成

1. 目标

根据算子需求信息,生成一份完整的 TileLang-Ascend 算子设计文档(design.md),涵盖以下核心决策:

  • 编程模式选型:Developer / Expert / 混合模式
  • API 映射:将数学公式拆解为 TileLang DSL 原语组合
  • 内存层级规划:GM → L1/UB → L0 的数据搬运路径
  • Tiling 策略:Block 划分与 Tile Shape 设计
  • 循环结构:T.Parallel / T.serial / T.Pipelined / T.Persistent 的选择
  • 同步策略:自动同步 vs 手动同步标志
  • 验证方案:Golden 函数与 L0 门槛测试计划(完整分层套件 L1/L2/Boundary 由 tilelang-op-test-design 生成)

2. 输入要求

必需信息

字段 说明
算子名称 softmaxlayer_normflash_attention
数学公式 算子的数学表达,如 $\text{softmax}(x_i) = e^{x_i} / \sum e^{x_j}$
输入张量规格 shape、dtype
输出张量规格 shape、dtype
编程模式偏好 Developer / Expert / 混合
迁移算子路径 原算子文件路径(迁移时必需),用于获取 golden 实现
输出形状 原算子输出 shape(迁移时必需),如 (N, M)(M, N)

迁移算子时必须提供原算子路径和输出形状,否则无法证明迁移正确性。Golden 实现一致性要求详见 tilelang-op-develop checklist.md #9 Golden 实现一致 / #10 输出形状匹配

提问规则(必须严格遵守)

  1. 优先使用调用方传入的字段:若调用方(如 @tilelang-op-orchestrator 通过 analyst 传入 op_requirements 结构)已经提供了字段值,全部跳过提问,直接进入技术约束检测和 design 生成
  2. 每次只询问一个字段:使用 question 工具时,questions 数组中只包含一个元素
  3. 按表格顺序依次询问:算子名称 → 数学公式 → 输入张量规格 → 输出张量规格 → 编程模式偏好
  4. 已提供的字段跳过:如果用户在初始请求中已提供某个字段的值,跳过该字段继续下一个
  5. 示例
    • 第 1 次询问:只问"数学公式"
    • 用户回答后,第 2 次询问:只问"输入张量规格"
    • 以此类推

⚠️ 当被 orchestrator → analyst Subagent 链路调度时

  • analyst 会把 orchestrator 在 Primary 上下文预检收集到的 op_requirements 完整传入
  • 此时 5 个必需字段应当全部已 provided,跳过整个提问环节
  • 若 skill 仍发现字段歧义或缺漏,不要在当前 Subagent 上下文调用 AskUserQuestion(透传不到真实用户),而是让 analyst 返回 partial_input + 缺失字段名给 orchestrator,由 orchestrator 在 Primary 上下文追问

推荐信息

字段 说明
典型配置 常用的 shape 组合与优先级
参考实现 PyTorch / NumPy 参考代码
性能目标 目标吞吐量或延迟
动态轴说明 哪些维度在运行时变化

若用户未提供必需信息中的任一项,通过提问补全后再继续。


3. 技术约束(必须遵守)

本项目为 TileLang-Ascend(华为昇腾 NPU),与 GPU 版 TileLang 有显著差异。外部参考实现不可直接使用,必须转换为 Ascend 兼容方案。

生成 design.md 前必须执行强制检测:三维 Kernel、threads 参数、动态循环边界、GPU 专用 API、GEMM 非整除、L0C 溢出等。

Read the full file on GitHub · 191 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 191 lines · 92 tokens per session scan A 1df54d4c8494

Subscribe to this mod's changes

tilelang-op-design is a skill published in the GitHub repository tile-ai/tilelang-ascend (364 stars, last pushed today), licensed MIT. It adds 92 tokens to every session and 3,188 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

insight-error-page

Write or audit an insight-kind error page for the Next.js dev overlay. Use when creating a new errors/ .mdx page, auditing an existing one, or checking that a page matches the framework fix cards. Covers page structure, title alignment, FixCard cards with Copy prompt button, code snippets, terminology verification…

vercel/next.js · 83 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens