FlashInfer is a library and kernel generator that supplies GPU operations used to run large language model inference, including attention, matrix multiplication, and mixture-of-experts computations. It helps engineers build and optimize LLM serving systems across supported GPU hardware and backend implementations. Its catalogue add-ons provide skills and instructions for working with FlashInfer.
Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/flashinfer-ai/flashinfernpx agentmods add skills/flashinfer-ai/flashinfer/next_cutedsl_megamoeWrote 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.
[](https://agentmods.dev/skills/flashinfer-ai/flashinfer/next_cutedsl_megamoe)<a href="https://agentmods.dev/skills/flashinfer-ai/flashinfer/next_cutedsl_megamoe"><img src="https://agentmods.dev/badge/skills/flashinfer-ai/flashinfer/next_cutedsl_megamoe/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.
<a href="https://agentmods.dev/skills/flashinfer-ai/flashinfer/next_cutedsl_megamoe"><img src="https://agentmods.dev/badge/skills/flashinfer-ai/flashinfer/next_cutedsl_megamoe.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.03557 |
| Opus 5.5 | $0.00000 | $0.01423 |
| Sonnet 5.5 | $0.00000 | $0.00711 |
| Haiku 4.5 | $0.00000 | $0.00356 |
Grade A, and why
next_cutedsl_megamoe 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.
How it starts
The opening of the file, as written. The whole thing — 292 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Updating the Rubin CuTeDSL MegaMoE kernel src
Use this guide when importing a new kernel-team drop or adapting FlashInfer to changes in that drop. VENDOR.md records the pinned source and export exceptions; TUNING.md covers tuning and measurements.
Layout
kernel_src/sm107/next_cutedsl_megamoe/
├── src/sources/ ← immutable output of upstream next/export_src.py
│ ├── api.py, quant_def.py
│ ├── helpers/, communication/
│ └── kernel_src/ ← Rubin inference/mega plus shared dependencies
├── __init__.py ← public package API used by FlashInfer backends
├── shim/ ← FlashInfer-owned adaptation
│ ├── _paths.py ← exposes src/ as the top-level sources package
│ ├── dependencies.py ← native SM107 compiler/target checks
│ ├── block_scaled.py ← config, descriptors, workspace, compile/launch
│ ├── comm.py ← symmetric allocation, peer mapping, lifetime
│ ├── kernel_helpers.py ← weight conversion, quantization, Torch reference
│ ├── knob_cache.py ← heuristic profiles, cache keys and policy
│ ├── autotune.py ← collective candidate validation and timing
│ └── correctness.py ← sampled numerical oracle
├── VENDOR.md ← provenance, supported subset, recorded exceptions
├── SKILL.md ← this update procedure
└── TUNING.md ← tuning and benchmark conventions
Keep src/ byte-for-byte equal to the pinned upstream export, except for the
explicit local patches inventoried in VENDOR.md.
Reapply and requalify those patches after an export until upstream absorbs them.
Record the exporter revision, selected kernels and generated transformations in
VENDOR.md. Fix device/exporter code upstream and re-export; put FlashInfer
adaptation in shim/ and the backend wrappers.
Preserve the vendored-path exclusions in formatting/lint tools.
Import layering
Backends → package __init__.py → shim/ → raw sources modules.
What ships with it
53 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.
- __init__.py 2.9 KB runs code
- shim/__init__.py 1.8 KB runs code
- shim/_paths.py 1.5 KB runs code
- shim/autotune.py 14 KB runs code
- shim/block_scaled.py 43 KB runs code
- shim/comm.py 4.9 KB runs code
- shim/correctness.py 3.7 KB runs code
- shim/dependencies.py 1.6 KB runs code
- shim/kernel_helpers.py 27 KB runs code
- shim/knob_cache.py 14 KB runs code
- src/sources/__init__.py 453 B runs code
- src/sources/api.py 5.2 KB runs code
- src/sources/communication/__init__.py 0 B runs code
- src/sources/communication/nvlink_domain/__init__.py 0 B runs code
- src/sources/communication/nvlink_domain/symmetric_buffer.py 7.3 KB runs code
- src/sources/communication/nvlink_domain/token_comm.py 109 KB runs code
- src/sources/communication/token_protocol.py 1.7 KB runs code
- src/sources/helpers/__init__.py 0 B runs code
- src/sources/helpers/constants.py 491 B runs code
- src/sources/helpers/cute_py_helpers.py 20 KB runs code
- src/sources/helpers/device_workspace.py 11 KB runs code
- src/sources/helpers/dsl_helpers.py 10.0 KB runs code
- src/sources/helpers/flag_batch.py 5.5 KB runs code
- src/sources/helpers/iket_compat.py 982 B runs code
- src/sources/helpers/ptx_helpers.py 24 KB runs code
- src/sources/helpers/smem_workspace.py 14 KB runs code
- src/sources/helpers/software_sync.py 8.7 KB runs code
- src/sources/helpers/utils.py 3.8 KB runs code
- src/sources/kernel_src/__init__.py 0 B runs code
- src/sources/kernel_src/function_mapping.py 6.1 KB runs code
- src/sources/kernel_src/rubin/__init__.py 0 B runs code
- src/sources/kernel_src/rubin/custom_mix_cga_helpers.py 14 KB runs code
- src/sources/kernel_src/rubin/inference/__init__.py 0 B runs code
- src/sources/kernel_src/rubin/inference/mega/__init__.py 0 B runs code
- src/sources/kernel_src/rubin/inference/mega/block_scaled_swap_ab_fc12_epilogue.py 137 KB runs code
- src/sources/kernel_src/rubin/inference/mega/block_scaled_swap_ab_fc12_extension.py 8.6 KB runs code
- src/sources/kernel_src/rubin/inference/mega/block_scaled_swap_ab_fc12_mainloop_gen_specialized.py 87 KB runs code
- src/sources/kernel_src/rubin/inference/mega/block_scaled_swap_ab_fc12_mainloop.py 61 KB runs code
- src/sources/kernel_src/rubin/inference/mega/block_scaled_swap_ab_mega_moe_kernel_gen_specialized.py 63 KB runs code
- src/sources/kernel_src/rubin/inference/mega/block_scaled_swap_ab_mega_moe_kernel.py 57 KB runs code
- src/sources/kernel_src/rubin/inference/mega/dynamic_mainloop.py 8.2 KB runs code
- src/sources/kernel_src/rubin/inference/mega/tma_gather.py 2.9 KB runs code
- src/sources/kernel_src/rubin/inference/mega/token_comm_gen_specialized.py 115 KB runs code
- src/sources/kernel_src/rubin/inference/mega/topk_reduce.py 25 KB runs code
- src/sources/kernel_src/schedulers/__init__.py 0 B runs code
- src/sources/kernel_src/schedulers/base.py 8.4 KB runs code
- src/sources/kernel_src/schedulers/fc12_mapping.py 52 KB runs code
- src/sources/kernel_src/schedulers/fc12_scheduler.py 43 KB runs code
- src/sources/kernel_src/schedulers/non_clc_mixed_cga.py 20 KB runs code
- src/sources/kernel_src/schedulers/work_id_claim.py 32 KB runs code
- src/sources/quant_def.py 11 KB runs code
- TUNING.md 17 KB
- VENDOR.md 12 KB
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.
- yesterday Changed · +83 lines 27a7c055a756
- 11d ago Changed · +2 lines e5ee42cc6298
- 13d ago Changed · +1 lines 0bd99db84407
- 22d ago First seen · 206 lines · 0 tokens per session scan A ce495f03afea
next_cutedsl_megamoe is a skill published in the GitHub repository flashinfer-ai/flashinfer (6,626 stars, last pushed today), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 3,557 tokens. 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-09-24.
Other skills, from other repositories
gpu-server-setup
Prepare a Linux server with NVIDIA GPUs for neural-network and LLM workloads, or diagnose one that misbehaves. Use when the user asks to set up or prepare a GPU server, install NVIDIA drivers or CUDA on Debian/Ubuntu, wire Docker to GPUs (NVIDIA Container Toolkit), deploy vLLM / Infinity / OpenWebUI / Ollama /…
sglang-diffusion-performance
Use when choosing the fastest SGLang Diffusion flags for a model, GPU, and VRAM budget.
sglang-diffusion-cache-dit
Workflow for upgrading/integrating cache-dit in SGLang diffusion (multimodalgen): DBCache, DMD calibrator, TaylorSeer, SVDQuant DQ; porting upstream PRs and resolving conflicts against the per-request knob system; adding new cache knobs; building the sglang generate CLI test matrix; precision validation (PSNR / log…
tensorboard
Visualize training metrics, debug models with histograms, compare experiments, visualize model graphs, and profile performance with TensorBoard - Google's ML visualization toolkit.
ray-train
Distributed training orchestration across clusters. Scales PyTorch/TensorFlow/HuggingFace from laptop to 1000s of nodes. Built-in hyperparameter tuning with Ray Tune, fault tolerance, elastic scaling. Use when training massive models across multiple machines or running distributed hyperparameter sweeps.
skypilot-multi-cloud-orchestration
Multi-cloud orchestration for ML workloads with automatic cost optimization. Use when you need to run training or batch jobs across multiple clouds, leverage spot instances with auto-recovery, or optimize GPU costs across providers.