add-mlinter-rule

Automates adding and wiring a new TRF rule into mlinter.

5|9|Updated Apr 16, 2026
One-click install
npx skills add https://github.com/huggingface/transformers-mlinter --skill add-mlinter-rule
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: add-mlinter-rule
Source: https://github.com/huggingface/transformers-mlinter/tree/main/.ai/skills/add-mlinter-rule
Command: npx skills add https://github.com/huggingface/transformers-mlinter --skill add-mlinter-rule

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Add a new TRF rule to mlinter and ensure it is properly integrated with duplicates checks, TOML entry, module creation, and test coverage.

Core Features & Use Cases

  • Provides a repeatable workflow to add a TRF rule to mlinter, including duplicate detection, rule numbering, TOML entry, rule module scaffolding, and test scaffolding.
  • Ensures cross-model compatibility by aligning with mlinter's discovery and validation workflows, and generating documentation stubs.

Quick Start

Follow the guided workflow to generate a new TRF rule scaffold and wire it into mlinter.

Frequently Asked Questions about add-mlinter-rule

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add a new custom rule to mlinter?▼

To add a custom rule to mlinter, you need to scaffold a new TRF module, register it in the TOML configuration, implement the Python static analysis logic, and generate corresponding tests and documentation stubs.

What is the TRF naming convention used for mlinter rule development?▼

The TRF naming convention is a standardized identification format required by mlinter's discovery and validation workflows to properly detect, register, and apply custom static analysis rules across all models and configurations.

How do I avoid duplicate rule entries when extending mlinter with new rules?▼

Avoiding duplicate mlinter rules requires running duplicate detection checks during the scaffolding workflow before assigning a new rule number and creating the TOML entry for your Python static analysis module.

Does mlinter rule creation require manual test and documentation scaffolding?▼

Manual test and documentation scaffolding is not required for mlinter rule creation; the automated workflow generates test scaffolds and documentation stubs to ensure cross-model compatibility and proper integration.

Can I use mlinter custom rules across all model configurations?▼

Yes, mlinter custom rules apply across all models and configurations when you align the Python static analysis implementation with mlinter's TRF discovery workflow and properly wire the TOML entry.

What are the limitations when adding a TRF rule to mlinter?▼

A key limitation is that rule development strictly requires Python-based static analysis and adherence to the TRF naming convention; deviating from this discovery workflow will prevent mlinter from validating and integrating the custom rule.