Adk Verify Snippets
google/adk-python
Checks that every Python code block in a Markdown file actually compiles and runs, by extracting each block to a temporary file, executing it in an isolated subprocess, and writing a pass/fail…
Disciplined, reproducible loop for making an FLA kernel faster (Triton, Gluon, TileLang, CuTe) without ever breaking or gaming correctness.
$ npx skills add fla-org/flash-linear-attention --skill fla-optimization-loop -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install fla-org/flash-linear-attention fla-optimization-loop --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-optimization-loop .claude/skills/fla-optimization-loop && 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-optimization-loop" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-optimization-loop into .claude/skills/fla-optimization-loop/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-optimization-loop", 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-optimization-loopType 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-optimization-loop -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install fla-org/flash-linear-attention fla-optimization-loop --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-optimization-loop .agents/skills/fla-optimization-loop && 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-optimization-loop" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-optimization-loop into .agents/skills/fla-optimization-loop/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-optimization-loop", 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-optimization-loop -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install fla-org/flash-linear-attention fla-optimization-loop --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-optimization-loop .cursor/skills/fla-optimization-loop && 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-optimization-loop" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-optimization-loop into .cursor/skills/fla-optimization-loop/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-optimization-loop", 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-optimization-loop--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-optimization-loop -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install fla-org/flash-linear-attention fla-optimization-loop --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-optimization-loop .gemini/skills/fla-optimization-loop && 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-optimization-loop" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-optimization-loop into .gemini/skills/fla-optimization-loop/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-optimization-loop", 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-optimization-loopInstalls 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-optimization-loop -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-optimization-loop .github/skills/fla-optimization-loop && 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-optimization-loop" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-optimization-loop into .github/skills/fla-optimization-loop/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-optimization-loop", 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-optimization-loop -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-optimization-loop --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-optimization-loop .opencode/skills/fla-optimization-loop && 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-optimization-loop" agent skill from https://github.com/fla-org/flash-linear-attention/tree/main/.agents/skills/fla-optimization-loop into .opencode/skills/fla-optimization-loop/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "fla-optimization-loop", 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-optimization-loopDisciplined, reproducible loop for making an FLA kernel faster (Triton, Gluon, TileLang, CuTe) without ever breaking or gaming correctness.
Fla Optimization Loop is an agent skill from fla-org/flash-linear-attention. Disciplined, reproducible loop for making an FLA kernel faster (Triton, Gluon, TileLang, CuTe) without ever breaking or gaming correctness. Synthesizes the task-contract / three-phase / iteration-protocol / silent-bug-catalog discipline of agent kernel-optimization frameworks (KDA, the MLSys FlashInfer contest workflow, AKO4ALL/AKO4X), and anchors all of it on FLA's frozen pytest (forward AND backward, under NaN poisoning) as the immutable correctness gate. Use when iterating on fla/ops/ performance over multiple…
Its SKILL.md is about 2.6k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including reference files (for example `references/TRAPS.md` and `references/opt-log-template.md`).
It sits in Testing & QA, covering Unit testing. It works with pytest. The repository describes itself as: 🚀 Efficient implementations for emerging model architectures. The licence is MIT.
8 steps, taken from the step headings 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.
Shell commands in SKILL.md call:
pythongitFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use git, which can reach the network depending on how they are called.
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 Optimization Loop loads about 2.6k tokens when it runs, and up to ~4.8k if it reads all its reference files. Until then it costs about 138 tokens; SKILL.md has 1,276 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). 1,276 words, ~2,568 tokens.
.claude/skills/fla-optimization-loop/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.Use this when you are making an existing fla/ops/** kernel faster — or bringing a new kernel from correct to fast —
across more than one iteration, in any FLA backend language (Triton, Gluon, TileLang, CuTe DSL).
This skill is the search discipline that ties the other skills together; it does not replace them:
fla-nvidia-performance — how to profile (NCU), hardware baselines, MR-ready perf evidence.fla-ascend-performance — how to profile (torch_npu), diagnose Cube/Vector/MTE/UB bottlenecks, and optimize Triton-Ascend kernels.fla-correctness-coverage — how to design the test coverage matrix for an op.fla-mr-readiness — how to package the promoted change into a PR.This skill covers the loop around those: what to lock, how to iterate, what to record, and when to stop.
The op's tests/ops/test_<op>.py and its fla/ops/<op>/naive.py reference are frozen for the entire optimization loop.
The whole point of "faster" only means something if correctness — forward and backward,
under the conftest NaN-memory poisoning — is held fixed.
During a perf loop you may not:
naive.py reference;assert_close tolerance, or widen rms_eps / dtype to make a diff pass;skip parametrized shapes;Run the gate with the unmodified test, every iteration:
python -m benchmarks.ops.verify --op <op> [--gate-k <subset>]verify.py runs the pytest file as a black box and refuses to report a speedup on a red gate.
--gate-k only selects a shape subset for a fast signal — it never edits the test;
promote only on a full (no -k) green gate.
Banned vs. allowed implementation (anti-reward-hacking):
| Banned | Allowed |
|---|---|
Making the op a thin wrapper that delegates the whole compute to a vendor lib (a plain torch.matmul / F.scaled_dot_product_attention standing in as the operator) just to win latency | Hand-written Triton / Gluon / TileLang / CuTe kernels; torch ops used as glue around a kernel you wrote |
| Returning uninitialized / partially-written outputs that happen to pass | Fully initialized outputs (NaN poisoning will catch partial writes) |
| Stream tricks / monkey-patching the bench to dodge timing | Genuine latency reduction measured by verify.py / run.py |
One-sided numeric relaxation the baseline doesn't get — flipping allow_tf32 on, dropping the fp32 accumulator to bf16/tf32, a config that quietly changes the numeric path | Same accumulation precision and numeric flags on both sides; speed comes from the kernel, not from computing something less accurate |
If you genuinely believe a test is wrong, that is a separate PR with its own justification — never bundled into a perf change. Stop and ask the user.
Put a short docs/draft.md in your scratch workspace (see §6) stating:
chunk_gla in fla.ops.gla.benchmarks/ops/registry.py SHAPE_CONFIGS), and a target speedup vs. main.python -m benchmarks.ops.verify --op <op> (the frozen gate).python -m benchmarks.ops.verify --op <op> --base main.naive.py, and the public op signature.Do not start editing kernels until the draft exists. (Borrowed from KDA: plan, then execute.)
Run these in order; repeat 2 and 3 with progressively higher targets.
python -m benchmarks.ops.verify --op <op> --base main.
For a brand-new kernel, get the gate green first; performance is secondary here.fla-nvidia-performance for NCU evidence on NVIDIA backends, or fla-ascend-performance for Ascend NPU / Triton-Ascend backends.
Enumerate candidate directions, rank them by expected benefit vs. implementation risk,
and explore each for at most a few iterations. Keep, revise, or reject each with evidence — don't optimize blindly.T, small vs. large D), add dispatch / specialized paths.
Justify the added complexity with the measured win; validate on the full shape set, not the one you tuned on.
Record each bucket (condition / entry point / per-bucket latency + speedup / reason) in dispatch.md
(template in references/opt-log-template.md) — a specialized path without that evidence is unjustified complexity.Every iteration is exactly three steps, in order, with no telescoping into the next iteration between them:
verify.py — gate must stay green; record the bench number.OPT_LOG.md (see references/opt-log-template.md) and git commit.A failed or no-change iteration is still an iteration: log it and commit before debugging the next direction. (Borrowed from AKO4ALL: bench → log → commit, the most-skipped step in practice.)
Stall handling. After 3 consecutive iterations with no improvement (≥ a few % over current best, above noise),
stop and re-assess: re-profile, re-read OPT_LOG.md for which axes you've already tried,
and search for known techniques for this op family before picking a new direction.
When to stop. A user-set iteration cap is reached;
or re-assessment produces hard evidence of a floor (bandwidth-bound at HBM limit, launch-overhead dominated,
timer-resolution limited — cite it in OPT_LOG.md);
or you've documented ≥3 distinct directions tried with evidence.
Don't stop silently because a tool (e.g. NCU) was unavailable — that's a re-assessment input.
No-go bar. If stopping means concluding there's no win to promote — a no-go — that verdict has its own bar: a first candidate losing doesn't clear it. A no-go needs a recorded baseline number, at least one reasoned candidate attempt (not a blind guess), the gate status, the bench evidence, and a named active bound or blocker (name which roofline/launch/timer limit, with the number). Without those five it's an unfinished loop.
torch.manual_seed(42); don't undermine it.verify.py prints GPU / CUDA / PyTorch / Triton / commit SHA;
paste that line into OPT_LOG.md so a number is interpretable later.--gate-k subset is a signal only.--base main comparison only at the verdict.
Clock noise on unlocked GPUs can swing absolute speedup — see references/TRAPS.md.Read references/TRAPS.md before trusting any number.
It catalogs FLA-specific traps (NaN poisoning on partial writes, TF32 inflating fp32 reference diffs,
assert_close relative tolerance, one-sided numeric-flag relaxation, autotune-cache staleness across edits,
int64 address arithmetic, implausible speedups that signal a silently-skipped path).
When you hit a new one, add it there with Fact / Why / How to apply so the next session doesn't re-learn it.
(Borrowed from AKO4X's TRAPS.md.)
Keep your search artifacts in a git-ignored directory — profile/<op>-opt/ is already ignored:
profile/<op>-opt/
docs/draft.md # the task contract (§1)
OPT_LOG.md # one row per iteration (template in references/)
dispatch.md # one row per shape bucket — only if Phase 3 specializes (template in references/)
TRAPS.md # traps you hit this session (seed: references/TRAPS.md)
trace/ # torch.profiler / NCU artifacts (kept out of git)Each kept candidate's kernel gets a short header (Identity / Delta / Lessons / Dead-ends / Open-directions)
per references/opt-log-template.md, so a later session can see what was tried and why.
A candidate is promotable only on a full green gate plus a measured, repeatable win on the target shapes, and a profiler/roofline reading that explains the win (or, for a no-go, the blocker) — a speedup you can't account for is a silent-skip suspect, not a result (see §5). Then:
fla-nvidia-performance (before/after, NCU summary, dense + varlen coverage) or fla-ascend-performance (before/after, pipe/UB metrics, round summary template) —
and a full final-claim stats block (median/mean/std/min/p10/p90 per shape, equal-weight geomean speedup,
exact commands, baseline commit + candidate SHA, GPU id/model with idle-clock evidence —
the last guards the clock-drift trap in §5).fla-mr-readiness.The scratch workspace under profile/<op>-opt/ stays local; it is not part of the PR.
© 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
SKILL.md and 2 other files (references) in .agents/skills/fla-optimization-loop of fla-org/flash-linear-attention.
Open the folder on GitHubat commit b8ff848
Fla Optimization Loop 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 Optimization Loop this skillfla-org/flash-linear-attention | 5.8k | — | ~2.6k | Automated safety check: Pass | MIT | |
| Adk Verify Snippetsgoogle/adk-python | 22k | — | ~1.4k | Automated safety check: Pass | Apache-2.0 | |
| Hermetic Python Unit TestsdimensionalOS/dimos | 4.6k | — | ~1.4k | Automated safety check: Pass | Custom licence | |
| Test GuardamElnagdy/guard-skills | 1.3k | 2 repos | ~2.1k | Automated safety check: Pass | MIT | |
| Pytest Runnersaleor/saleor | 23k | — | ~251 | Automated safety check: Pass | BSD-3-Clause | |
| Port Node Red Nodeoldrev/edgelinkd | 121 | — | ~3k | Automated safety check: Pass | Apache-2.0 |
google/adk-python
Checks that every Python code block in a Markdown file actually compiles and runs, by extracting each block to a temporary file, executing it in an isolated subprocess, and writing a pass/fail…
dimensionalOS/dimos
Rules for writing, fixing and reviewing pytest unit tests that are hermetic: behavior-focused, deterministic, isolated and cheap to run.
amElnagdy/guard-skills
Reviews newly written or edited tests against nine rules that cut test bloat, such as mock-heavy checks and near-duplicate cases, before they are committed.
saleor/saleor
Run pytest tests with automatic virtual environment activation. Use this skill whenever running tests, executing pytest, or when asked to "run tests", "test…
oldrev/edgelinkd
Port a Node-RED node into EdgeLinkd the way this repo does it: implement the node in Rust under crates/core/src/runtime/nodes, mirror Node-RED's mocha spec as pytest tests under tests/, register the…
microsoft/onnxruntime
Runs and debugs ONNX Runtime tests: Google Test executables for C++ and unittest or pytest for Python, with filters and build-directory guidance.
fla-org/flash-linear-attention
Guidelines for Ascend NPU kernel / Triton-Ascend backend performance work in the FLA repo.
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-org/flash-linear-attention
FLA KDA kernel workflow and public technical notes. An agent skill from fla-org/flash-linear-attention.
Works with
Categories
Disciplined, reproducible loop for making an FLA kernel faster (Triton, Gluon, TileLang, CuTe) without ever breaking or gaming correctness. Fla Optimization Loop is an agent skill from 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 Optimization Loop fits situations like: iterating on fla/ops/ performance over multiple rounds; tasks that involve Unit testing.
Run `npx skills add fla-org/flash-linear-attention --skill fla-optimization-loop -a claude-code`. Or copy the skill folder (.agents/skills/fla-optimization-loop in fla-org/flash-linear-attention) into .claude/skills/fla-optimization-loop in your project. Claude Code loads it when a task matches its description.
Run `npx skills add fla-org/flash-linear-attention --skill fla-optimization-loop -a codex`. Or copy the skill folder (.agents/skills/fla-optimization-loop in fla-org/flash-linear-attention) into .agents/skills/fla-optimization-loop 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-optimization-loop -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-optimization-loop, .gemini/skills/fla-optimization-loop, .github/skills/fla-optimization-loop and .opencode/skills/fla-optimization-loop in your project.
Going by SKILL.md and its folder, Fla Optimization Loop needs the command-line tools its instructions call (python and git). Our summary lists: Python 3.
SKILL.md contains no URLs. Its commands use git, which can reach the network depending on how they are called. 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 Optimization Loop is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.6k tokens (SKILL.md is roughly 10k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 2.3k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Fla Optimization Loop: Adk Verify Snippets (google/adk-python, 22k stars), Hermetic Python Unit Tests (dimensionalOS/dimos, 4.6k stars), Test Guard (amElnagdy/guard-skills, 1.3k stars) and Pytest Runner (saleor/saleor, 23k 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.