Kernel Organization
sgl-project/sglang
Apply the SGLang kernels RFC when adding, moving, splitting, or reviewing kernel APIs, registry metadata, kernel tests, benchmarks, and model-specific implementations.
FLA KDA kernel workflow and public technical notes. An agent skill from fla-org/flash-linear-attention.
$ npx skills add fla-org/flash-linear-attention --skill fla-kda -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install fla-org/flash-linear-attention fla-kda --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/fla-org/flash-linear-attention.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/fla-kda .claude/skills/fla-kda && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "fla-kda" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kda into .claude/skills/fla-kda/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-kda", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kdaType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add fla-org/flash-linear-attention --skill fla-kda -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install fla-org/flash-linear-attention fla-kda --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/fla-org/flash-linear-attention.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/fla-kda .agents/skills/fla-kda && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "fla-kda" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kda into .agents/skills/fla-kda/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-kda", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add fla-org/flash-linear-attention --skill fla-kda -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install fla-org/flash-linear-attention fla-kda --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/fla-org/flash-linear-attention.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/fla-kda .cursor/skills/fla-kda && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "fla-kda" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kda into .cursor/skills/fla-kda/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-kda", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/fla-org/flash-linear-attention.git --path .agents/skills/fla-kda--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add fla-org/flash-linear-attention --skill fla-kda -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install fla-org/flash-linear-attention fla-kda --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/fla-org/flash-linear-attention.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/fla-kda .gemini/skills/fla-kda && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "fla-kda" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kda into .gemini/skills/fla-kda/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-kda", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install fla-org/flash-linear-attention fla-kdaInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add fla-org/flash-linear-attention --skill fla-kda -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/fla-org/flash-linear-attention.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/fla-kda .github/skills/fla-kda && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "fla-kda" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kda into .github/skills/fla-kda/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-kda", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add fla-org/flash-linear-attention --skill fla-kda -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install fla-org/flash-linear-attention fla-kda --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/fla-org/flash-linear-attention.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/fla-kda .opencode/skills/fla-kda && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "fla-kda" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-kda into .opencode/skills/fla-kda/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-kda", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
fla-kdaFLA KDA kernel workflow and public technical notes. An agent skill from fla-org/flash-linear-attention.
Fla Kda is an agent skill from fla-org/flash-linear-attention. FLA KDA kernel workflow and public technical notes. Use when modifying or reviewing fla/ops/kda/, KDA gate modes, chunk intra/inter kernels, safegate behavior, KDA backends, or KDA-specific tests and benchmarks.
Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.
The repository describes itself as: 🚀 Efficient implementations for emerging model architectures. The licence is MIT.
2 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit b8ff848. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Fla Kda loads about 1.3k tokens when it runs. Until then it costs about 56 tokens; SKILL.md has 563 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from fla-org/flash-linear-attention at commit b8ff848, republished under its MIT licence (© fla-org). 563 words, ~1,297 tokens.
.claude/skills/fla-kda/SKILL.md (or your agent's skills folder).Use this skill for KDA-specific work under fla/ops/kda/** and tests that
exercise KDA behavior.
fla.ops.kda.chunk_kda, fla.ops.kda.fused_recurrent_kda.naive_kda_gate, naive_kda_lowerbound_gate,
kda_gate_fwd, kda_gate_bwd, fused_kda_gate,
kda_gate_chunk_cumsum in fla/ops/kda/gate.py.chunk_kda_fwd in chunk_fwd.py.chunk_kda_fwd_intra,
chunk_kda_fwd_kernel_intra_sub_chunk,
chunk_kda_fwd_kernel_inter_solve_fused in chunk_intra.py.chunk_kda_fwd_intra_token_parallel in
chunk_intra_token_parallel.py.recompute_w_u_fwd and recompute_w_u_fwd_kda_kernel in
wy_fast.py.chunk_kda_bwd, chunk_kda_bwd_intra,
chunk_kda_bwd_wy_dqkg_fused.FlashKDABackend, KDATileLangBackend.chunk_kda has two gate input contracts:
use_gate_in_kernel=False.g is already the log-space decay tensor.A_log, dt_bias, and lower_bound are not part of the gate activation.use_gate_in_kernel=True.g is raw gate input.A_log is required and dt_bias is optional.safe_gate, activation is -exp(A_log) * softplus(g + dt_bias).safe_gate, activation is
lower_bound * sigmoid(exp(A_log) * (g + dt_bias)).safe_gate=True requires use_gate_in_kernel=True, lower_bound is not None,
and -5 <= lower_bound < 0.
With lower_bound=-5, every per-token gate value is in [-5, 0) before the
RCP_LN2 conversion used by chunk_kda_fwd. A 16-token sub-chunk can therefore
accumulate -80 in natural-log units. Directly feeding the full span to exp2
would be larger in base-2 units, so the safe intra path relies on offsetting.
chunk_kda_fwd_kernel_intra_sub_chunk uses a midpoint offset before
exponentiation:
b_gm = b_g - b_gn;exp2(b_gm) and exp2(-b_gm).With the midpoint offset, each exponent operand covers at most about half of the
16-token sub-chunk. Under lower_bound=-5, this is about 40 / ln(2), which is
below the kernel's exp2 safety comment threshold. The important invariant is
not the raw cumulative value alone; it is that each exponentiation uses a local
offset rather than the full chunk cumsum directly.
For inter-subchunk work, chunk_kda_fwd_kernel_inter_solve_fused computes decay
ratios with paired offsets such as:
exp2(b_g1 - b_gn1) and exp2(b_gn1 - b_g0);exp2(b_g2 - b_gn2) and exp2(b_gn2 - b_g1).Both terms are non-positive under monotonic accumulated decay, so the off-diagonal inter path avoids positive exponent growth. The triangular solve operates on masked lower-triangular blocks, so it does not introduce an unbounded exponent path.
chunk_kda_fwd_intra(..., safe_gate=True) calls
chunk_kda_fwd_kernel_intra_sub_chunk for 16-token diagonal blocks, then
calls chunk_kda_fwd_kernel_inter_solve_fused with USE_SAFE_GATE=True.safe_gate=False calls chunk_kda_fwd_intra_token_parallel
for diagonal blocks, then calls the same inter/solve kernel with
USE_SAFE_GATE=False.Before finishing a KDA behavior change, use fla-correctness-coverage and cover
only axes affected by the change:
use_qk_l2norm_in_kernel=True/False where relevant;HV > H);D != Dv when value dimension is involved;return_intermediate_states, and CP paths when touched;lower_bound=-5, a lower bound close to 0, large positive and negative
g + dt_bias, extreme A_log, long-sequence cumulative decay, chunk
boundaries, and ragged varlen boundaries.fla.utils (device, device_platform, IS_NVIDIA,
IS_NVIDIA_HOPPER, IS_NVIDIA_BLACKWELL, IS_AMD, IS_INTEL) instead of
adding new direct torch.cuda platform checks in tests or public code. If no
helper covers the condition, add one in fla.utils first.© fla-org, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
Just SKILL.md in .agents/skills/fla-kda of fla-org/flash-linear-attention.
Open the folder on GitHubat commit b8ff848
Fla Kda next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Fla Kda this skillfla-org/flash-linear-attention | 5.8k | — | ~1.3k | Automated safety check: Pass | MIT | |
| Kernel Organizationsgl-project/sglang | 37k | — | ~1.3k | Automated safety check: Pass | Apache-2.0 | |
| Metal Kernelpytorch/pytorch | 104k | — | ~4.9k | Automated safety check: Pass | Custom licence | |
| Semantic Kernelgithub/awesome-copilot | 40k | 2 repos | ~756 | Automated safety check: Pass | MIT | |
| Add Sgl Kernelsgl-project/sglang | 37k | 2 repos | ~3.4k | Automated safety check: Pass | Apache-2.0 | |
| Add Jit Kernelsgl-project/sglang | 37k | — | ~13k | Automated safety check: Pass | Apache-2.0 |
sgl-project/sglang
Apply the SGLang kernels RFC when adding, moving, splitting, or reviewing kernel APIs, registry metadata, kernel tests, benchmarks, and model-specific implementations.
pytorch/pytorch
Write Metal/MPS kernels for PyTorch operators. An agent skill from pytorch/pytorch.
github/awesome-copilot
Create, update, refactor, explain, or review Semantic Kernel solutions using shared guidance plus language-specific references for .NET and Python.
sgl-project/sglang
Step-by-step tutorial for adding a heavyweight AOT CUDA/C++ kernel to sgl-kernel (including tests & benchmarks)
sgl-project/sglang
Step-by-step tutorial for adding a new lightweight JIT CUDA kernel to sglang.kernels JIT infrastructure and public operator groups
PaddlePaddle/Paddle
A skill your agent uses when working with Paddle's PHI kernel system: registering new kernels, debugging kernel selection/dispatch, understanding code auto-generation from YAML, or implementing…
fla-org/flash-linear-attention
Guidelines for Ascend NPU kernel / Triton-Ascend backend performance work in the FLA repo.
fla-org/flash-linear-attention
Disciplined, reproducible loop for making an FLA kernel faster (Triton, Gluon, TileLang, CuTe) without ever breaking or gaming correctness.
fla-org/flash-linear-attention
Workflow for porting an existing Triton kernel in fla/ops/ to Gluon (triton.experimental.gluon) to gain explicit control over tensor layouts, shared memory, async data movement (cp.async / TMA), MMA…
fla-org/flash-linear-attention
Guidelines for kernel correctness testing and coverage in fla/ops/ and related modules, including common Triton grid/addressing pitfalls.
fla-org/flash-linear-attention
Contract-first design and coverage discipline for FLA kernel and numerical changes.
fla-org/flash-linear-attention
Workflow for FLA backend dispatch decorators and backend implementations.
FLA KDA kernel workflow and public technical notes. An agent skill from fla-org/flash-linear-attention. Fla Kda is an agent skill from fla-org/flash-linear-attention. FLA KDA kernel workflow and public technical notes.
Fla Kda fits situations like: reviewing fla/ops/kda/; chunk intra/inter kernels; safegate behavior; KDA-specific tests and benchmarks.
Run `npx skills add fla-org/flash-linear-attention --skill fla-kda -a claude-code`. Or copy the skill folder (.agents/skills/fla-kda in fla-org/flash-linear-attention) into .claude/skills/fla-kda in your project. Claude Code loads it when a task matches its description.
Run `npx skills add fla-org/flash-linear-attention --skill fla-kda -a codex`. Or copy the skill folder (.agents/skills/fla-kda in fla-org/flash-linear-attention) into .agents/skills/fla-kda in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add fla-org/flash-linear-attention --skill fla-kda -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/fla-kda, .gemini/skills/fla-kda, .github/skills/fla-kda and .opencode/skills/fla-kda in your project.
SKILL.md names no scripts, command-line tools or credentials: Fla Kda is instructions for the agent only.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Fla Kda is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 1.3k tokens (SKILL.md is roughly 5.2k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Fla Kda: Kernel Organization (sgl-project/sglang, 37k stars), Metal Kernel (pytorch/pytorch, 104k stars), Semantic Kernel (github/awesome-copilot, 40k stars) and Add Sgl Kernel (sgl-project/sglang, 37k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
fla-org (a GitHub organization) maintains it in fla-org/flash-linear-attention, which has 5,828 GitHub stars. The repository holds 9 skills in this directory. The repository was last updated on October 6, 2026.
Source: fla-org/flash-linear-attention on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.