Triton Operator Dev logo

Triton Operator Dev

Organization
Ascend
triton-operator-dev

昇腾 Triton 算子全流程开发编排。当用户需要从零开发 Triton 算子、进行端到端开发流程、或不确定该用哪个子 skill 时使用。自动编排:环境配置→需求设计→代码生成→静态检视→精度验证→性能评估→性能优化。关键词:全流程、开发编排、端到端、workflow orchestration。

Overview

PublisherAscend
Repositoryagent-skills
Skill nametriton-operator-dev
Stars
54
Forks
4
Bundled files
Instructions only
LicenseMulanPSL-2.0
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by Ascend on GitHub. Read the source before you install it.

Installation

Install the Triton Operator Dev AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/Ascend/agent-skills/tree/master/skills/triton-operator-dev
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Ascend/agent-skills.git /tmp/agent-skills
mkdir -p .claude/skills
cp -r /tmp/agent-skills/skills/triton-operator-dev .claude/skills/triton-operator-dev
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Triton Operator Dev in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Triton Operator Dev on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Triton Operator Dev is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Triton 算子全流程开发

工作流概览

构建 Triton 算子分 7 个阶段(含 1 个条件阶段):

#阶段产出Skill是否可跳过
1环境配置环境验证报告triton-operator-env-config是:torch/torch_npu/triton 已可用
2需求设计设计文档triton-operator-design是:用户已提供完整设计文档
3代码生成kernel + smoke testtriton-operator-code-gen否
4静态检视检视报告triton-operator-code-review否
5精度验证精度报告triton-operator-precision-eval否
6性能评估性能报告 + ratiotriton-operator-performance-eval否
7性能优化优化后代码triton-operator-performance-optim条件:ratio ≥ 目标则跳过

⚠️ 核心约束

  1. 必须走完全流程:阶段 3-6 不可跳过,不可在代码生成后停止
  2. 用 TaskCreate 跟踪进度:每阶段一个 Task,进入时 in_progress,完成后 completed
  3. 精度通过前不做性能优化(precision-eval 的核心原则)
  4. 输出最终报告:精度结果 + 性能 ratio + 优化历史 + 结论

场景路由

用户意图正确做法
"开发一个算子"、"从零开发"本 skill 全流程
"帮我写算子代码"不用本 skill,直接 triton-operator-code-gen
"优化算子性能"不用本 skill,直接 triton-operator-performance-optim
"检查算子精度"不用本 skill,直接 triton-operator-precision-eval

阶段执行要点

阶段 1-2:环境 + 设计(可跳过)

跳过判断:

  • 阶段 1 跳过条件:能 import torch, torch_npu, triton 且 torch.npu.is_available()
  • 阶段 2 跳过条件:用户已提供设计文档(如 docs/context/*.md)或直接给出算子 API 规格

阶段 3:代码生成

调用 Skill(triton-operator-code-gen)。此阶段只生成代码和 smoke test,不运行。

进入下一阶段前:kernel 代码 + 测试文件已写入磁盘

阶段 4:静态检视

调用 Skill(triton-operator-code-review)。此阶段只静态分析,不运行。

进入下一阶段前:P0/P1 问题已修复

阶段 5:精度验证(MANDATORY 运行)

调用 Skill(triton-operator-precision-eval)。

此阶段必须在 NPU 上运行测试。 关键产出:

  • 多 shape × dtype 的误差指标
  • 通过/失败判定

进入下一阶段前:所有精度测试通过

阶段 6:性能评估(MANDATORY 运行)

调用 Skill(triton-operator-performance-eval)。

此阶段必须在 NPU 上运行 benchmark。 关键产出:

  • Triton vs torch_npu 的 ratio
  • 瓶颈类型诊断

阶段 7:性能优化(条件执行)

触发条件:阶段 6 的 ratio < 用户要求的性能目标。

调用 Skill(triton-operator-performance-optim)。优化后必须重新运行精度验证确认无回归。

常见陷阱

陷阱症状正确做法
代码生成后停止用户以为开发完成但无验证强制执行阶段 5-6
精度未通过就优化优化了错误的代码精度通过是优化的前提
跳过 TaskCreate阶段遗漏无法追溯每阶段创建 Task
混淆"生成测试"和"运行测试"只有测试文件但从未执行阶段 5-6 必须实际运行

反模式清单(NEVER)

  • ❌ 代码生成后停止,不执行精度验证和性能评估
  • ❌ 精度未通过就做性能优化
  • ❌ 不创建任务跟踪就开始执行
  • ❌ 跳过阶段但不更新任务状态
  • ❌ 只生成代码就说"开发完成"
  • ❌ 用"只需代码"的借口跳过验证流程

检查清单(最终输出前确认)

  • 代码已生成并通过静态检视(P0/P1 清零)
  • 精度测试已在 NPU 上运行,所有 dtype/shape 通过
  • 性能测试已在 NPU 上运行,有 ratio 数据
  • ratio < 目标时已尝试优化并重新验证精度
  • 性能报告已生成并写入磁盘(包含 ratio 数据、瓶颈诊断、优化历史、结论)
  • 精度报告已生成并写入磁盘(包含多 shape × dtype 误差指标、通过/失败判定)
  • 向用户输出完整最终报告(精度 + 性能 + 结论)

最终交付物

全流程完成后,必须在算子目录下输出以下文件:

文件内容必须
{算子名}.pyKernel 代码 + Host 接口是
test_{算子名}.pySmoke test是
precision_eval.py精度评估脚本是
precision_report.md精度报告是
performance_eval.py性能评估脚本是
performance_report.md性能报告是

Frequently asked questions

What does the Triton Operator Dev AI skill do?

昇腾 Triton 算子全流程开发编排。当用户需要从零开发 Triton 算子、进行端到端开发流程、或不确定该用哪个子 skill 时使用。自动编排:环境配置→需求设计→代码生成→静态检视→精度验证→性能评估→性能优化。关键词:全流程、开发编排、端到端、workflow orchestration。

Why use Triton Operator Dev on TypingMind?

Because you install it once and use it with any model. Triton Operator Dev is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Triton Operator Dev in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/Ascend/agent-skills/tree/master/skills/triton-operator-dev. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Triton Operator Dev?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Triton Operator Dev?

As many as you like. As long as a model supports skills, you can use Triton Operator Dev with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Triton Operator Dev AI skill free?

Yes. It is published on GitHub by Ascend under the MulanPSL-2.0 license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇