Index of every page on this site: llms.txt
All skills
qiao-925 avatar

/file-guardrails

@50a1ee4
Run it yourself

文件级工程护栏能力单元,帮助 Agent 在新建、修改、重构代码文件时,同时控制顶部说明、单文件体量与拆分方式,确保文件易读、可维护、职责清晰,并在超过 300 行时立即停下并给出拆分方案。关键词:文件护栏、文件头注释、300 行限制、拆分方案、代码可读性、职责清晰。

Use this Skill: https://skilld.dev/gh/qiao-925/qiao-skills/file-guardrails

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencescomment-templates.md

≈286 tokens on demand. Your agent reads this file only when SKILL.md points to it.

顶部说明模板

Python

"""一句话说明文件用途。

主要职责:
- 职责 1
- 职责 2

快速开始:
    from module import MainClass
    result = MainClass().run(...)
"""

JavaScript / TypeScript

/**
 * 一句话说明文件用途。
 *
 * 主要职责:
 * - 职责 1
 * - 职责 2
 *
 * @example
 * import { run } from './module';
 * run();
 */

Shell / Bash

#!/usr/bin/env bash
# 一句话说明脚本用途。
#
# 用法:
#   ./script.sh [options]
#
# 示例:
#   ./script.sh --help

Go

// Package name 提供一句话功能说明。
//
// 主要职责:
//   - 职责 1
//   - 职责 2
package name

Java

/**
 * 一句话说明类或文件用途。
 *
 * <p>主要职责:
 * <ul>
 *   <li>职责 1</li>
 *   <li>职责 2</li>
 * </ul>
 */

模板使用规则

  • 保留最少必要字段,不要为了“完整”把每一段都写满。
  • 主要职责 只列高价值点,通常 2-4 条足够。
  • 快速开始 只在首次使用成本较高时保留。
  • 如果文件足够简单,最小版一段注释通常就够了。

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts8mo3 checks · Risk SAFE
  • Gen Agent Trust Hub8mo

    The 'file-guardrails' skill provides engineering guidelines for AI agents to maintain code readability by enforcing file length limits and standardized header comments. It contains no executable scripts, network operations, or sensitive data access patterns and is safe for use.

  • Socket8mo

    No alerts

  • Snyk8mo

    Risk: LOW · No issues

Signed by skilld at 50a1ee4. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 months ago.

Dormantupdated 8 months ago
Other metadata
metadata
{
  "type": "declarative",
  "category": "engineering",
  "scope": "generic",
  "role": "skill-unit"
}

README badge

README badge for qiao-925/qiao-skills/file-guardrails