cuda-code-generator

A CUDA kernel generator that creates compilable .cu source files from performance-analysis reports or algorithm descriptions. A CUDA kernel is a GPU function, and an NCU report contains measurements from NVIDIA's profiling tool.

In plain words
What is it for?
Use it when you have an NCU analysis report, existing kernel code, or a request for CUDA code and need an optimized .cu implementation.
Why use it?
It turns profiling findings or a requested algorithm into candidate kernel code. This reduces the manual work of applying performance changes to existing CUDA code.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/forceinjection/cuda-code-skill/cuda-code-generator
Any agent
npx skills add ForceInjection/cuda-code-skill --skill cuda-code-generator
Clone the repo
git clone --depth 1 https://github.com/ForceInjection/cuda-code-skill

Made for: Claude Code, Codex.

Per session 102 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,961 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin fork From a forked repository.
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 $0.00102 $0.01961
Opus 5 $0.00051 $0.00981
Sonnet 5 $0.00020 $0.00392
Haiku 4.5 $0.00010 $0.00196

Measured yesterday against content hash 2d47f7c6c484, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

cuda-code-generator 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 yesterday.

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.

skills/cuda-code-generator/SKILL.md · 165 lines

The source is not reproduced here

No licence file

A repository with no LICENSE is all rights reserved by default, so the body is not copied here. The metadata, the measurements and the link are.

Read it on GitHub

Files

What ships with it

1 file 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. yesterday First seen · 165 lines · 102 tokens per session scan A 2d47f7c6c484

Subscribe to this mod's changes

cuda-code-generator is a skill published in the GitHub repository ForceInjection/cuda-code-skill (24 stars, last pushed 1mo ago), with no licence file. It adds 102 tokens to every session and 1,961 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. It comes from a forked repository.

Related

Other skills, from other repositories

kernel-KBS

Corpus-backed GPU kernel knowledge base for CUDA, Triton, CuTe, CUTLASS, and Ampere/Hopper/Blackwell kernel research. Use when the user needs to search merged kernel PR pages, inspect PR diff/provenance artifacts, find KernelWiki synthesis pages, query blog/doc/contest notes, or retrieve evidence-backed implementation…

fmh66/kernel-opt-agent · 109 tokens

kernel-benchmark

Standalone kernel benchmarking skill for cuda-cpp, cutlass, cute-dsl, and triton implementations. Use when the user wants to compare a custom CUDA/CUTLASS .cu kernel or CuTe DSL/Triton .py kernel against selectable PyTorch eager, torch.compile, or FlashInfer baselines, validate correctness, measure execution time with…

fmh66/kernel-opt-agent · 90 tokens

kernel-loop

Iterative GPU kernel optimization orchestrator for CUDA/CUTLASS/CuTe DSL/Triton kernels. Use for measured, one-change-at-a-time optimization loops with correctness, NCU profiling, KBS evidence, hypothesis discipline, hard iteration gates, final benchmarking, and a traceable report.

fmh66/kernel-opt-agent · 63 tokens

kernel-profile

Standalone kernel profiling skill for cuda-cpp, cute-dsl, cutlass, and triton implementations. Checks CUDA/PyTorch/Triton/CuTe DSL/CUTLASS/NCU/nsight-python readiness, optionally locks GPU clocks, validates correctness, collects Nsight Compute metrics with nsight-python, produces envcheck.md, correctness.md…

fmh66/kernel-opt-agent · 168 tokens

mlir-opt-skill

Use when optimizing MLIR GPU performance, compiling PyTorch or linalg/tensor MLIR to PTX, writing Transform dialect schedules, tuning auxiliary pass pipelines, benchmarking MLIR kernels against PyTorch, or diagnosing linalg/torch-mlir GPU codegen.

fmh66/MLIR-OPT-SKILL · 59 tokens

claude-md-improver

Audit and improve CLAUDE.md files in repositories. Use when user asks to check, audit, update, improve, or fix CLAUDE.md files. Scans for all CLAUDE.md files, evaluates quality against templates, outputs quality report, then makes targeted updates. Also use when the user mentions "CLAUDE.md maintenance" or "project…

anthropics/claude-plugins-official · 82 tokens