← Browse

@linkedin/liger-kernel-dev

A

Develops production-ready Triton kernels for Liger Kernel. Creates new kernels from PyTorch operations (local files, URLs, code snippets, or natural language) with ops, module wrappers, functional APIs, unit tests, benchmarks, and plots. Also modifies existing Liger kernels. Use when adding a new Triton kernel, converting a PyTorch operation to Triton, or updating an existing Liger kernel.

skillclaude

Install

agr install @linkedin/liger-kernel-dev --target claude

Writes 5 files into .claude/skills/, pinned to git-48e7fb2b.

  • .claude/skills/liger-kernel-dev/SKILL.md
  • .claude/skills/liger-kernel-dev/analyzer.md
  • .claude/skills/liger-kernel-dev/generator.md
  • .claude/skills/liger-kernel-dev/kernel-profile-format.md
  • .claude/skills/liger-kernel-dev/validator.md

Document


name: liger-kernel-dev description: "Develops production-ready Triton kernels for Liger Kernel. Creates new kernels from PyTorch operations (local files, URLs, code snippets, or natural language) with ops, module wrappers, functional APIs, unit tests, benchmarks, and plots. Also modifies existing Liger kernels. Use when adding a new Triton kernel, converting a PyTorch operation to Triton, or updating an existing Liger kernel."

Liger Kernel Dev

Develops Triton kernels for Liger Kernel through a 3-stage pipeline with human review between stages. Supports creating new kernels and modifying existing ones. NVIDIA GPUs only.

Mode Detection

  • Create mode: User asks to create/add/generate/write/build a new kernel → full pipeline
  • Modify mode: User asks to update/fix/change/extend an existing kernel → skip Analyze, modify files, then Validate

Pipeline (Create Mode)

Stage 1: Analyze

Follow the Analyzer workflow in analyzer.md. If the host runtime supports parallel subagents, this stage may be delegated to one; otherwise execute the workflow directly.

Accepts any input: local file, URL, code snippet, natural language description, or model component reference. Produces a standalone PyTorch reference implementation and a kernel profile.

Human checkpoint: Present PyTorch reference + kernel profile. Confirm before proceeding.

Stage 2: Generate

Follow the Generator workflow in generator.md.

Generates/modifies up to 8 files:

  1. src/liger_kernel/ops/{kernel}.py — NEW Triton kernels + autograd Function
  2. src/liger_kernel/transformers/{kernel}.py — NEW nn.Module wrapper
  3. src/liger_kernel/transformers/functional.py — MODIFY add functional API
  4. src/liger_kernel/ops/__init__.py — MODIFY export Function class
  5. src/liger_kernel/transformers/__init__.py — MODIFY export Module + __all__
  6. test/transformers/test_{kernel}.py — NEW unit tests
  7. benchmark/scripts/benchmark_{kernel}.py — NEW benchmark script
  8. benchmark/data/all_benchmark_data.csv — MODIFY (after benchmarks run)

Human checkpoint: Present changes for review.

Stage 3: Validate

Follow the Validator workflow in validator.md.

Runs checkstyle, unit tests (hard gate — stops on persistent failure), benchmarks, and generates plots. Optionally runs ncu profiling.

Human checkpoint: Report final results with benchmark numbers and plots.

Pipeline (Modify Mode)

  1. Read existing kernel files to understand current implementation
  2. Understand the requested modification
  3. Make targeted changes (Generator handles this)
  4. Run full Validate stage (same as create mode)

Reference Files

Trustgrade A

  • passBody integrity

    Whether the stored document is plausibly the kind of file the artifact declares, rather than something fetched by mistake.

  • passType matchnot applicable to this artifact type

    Whether the artifact is really the kind of thing its metadata claims it is.

  • passFreshness

    How long since the source repository was last pushed to.

  • passPrompt injection

    Scans the artifact's own text for instructions aimed at your agent rather than at you.

  • passLicense

    Whether the source repository declares an SPDX license permissive enough to redistribute.

How the grade is calculated

Each check contributes 0 points when it passes, 1 when it warns, and 2 when it fails. The total maps to a letter:

  • Aevery check passed
  • Bone warning
  • Ctwo warnings
  • Dprompt injection or body integrity failed, or three warnings
  • Fone of those failed, and something else is wrong

These are automated hygiene checks, not a security audit, and not a dependency or vulnerability scan. A grade of A means nothing was flagged — not that the artifact is safe.

Versions

  • git-48e7fb2bb6072026-07-31