
Skill Awesome
- 8 installs
- 2 repo stars
- Updated July 29, 2026
- full-statck-skills/utility-skills
Reference knowledge base for the Agent Skills spec: frontmatter rules, naming conventions, directory structure and progressive disclosure.
About
Serves as a canonical reference for designing Agent Skills, covering the spec, best practices, description optimization and the TRACE evaluation framework. A developer uses it when designing or reviewing a skill for compliance.
- Distills frontmatter, naming and directory-structure rules
- Covers progressive disclosure and script safety guidelines
Skill Awesome by the numbers
- 8 all-time installs (skills.sh)
- Ranked #545 of 782 Skill Development skills by installs in the Skillselion catalog
- Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/full-statck-skills/utility-skills --skill skill-awesomeAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 8 |
|---|---|
| repo stars | ★ 2 |
| Last updated | July 29, 2026 |
| Repository | full-statck-skills/utility-skills ↗ |
What it does
Reference knowledge base for the Agent Skills spec: frontmatter rules, naming conventions, directory structure and progressive disclosure.
Files
When to use this skill
ALWAYS use this skill when you need to know:
- What the Agent Skills specification requires (directory structure, SKILL.md format, frontmatter fields)
- What naming conventions to follow for a skill (
namemust match directory, lowercase + hyphens only, etc.) - What frontmatter fields are required vs optional, and their constraints
- What progressive disclosure means and how to structure a skill to use it
- What the official best practices say about scope, context budgeting, gotchas, and checklists
- How to write a good
descriptionthat triggers reliably - What script safety rules apply (non-interactive,
--help, no secrets, structured output) - How the TRACE evaluation framework judges skill quality
- What a well-structured skill looks like (reference examples)
- "设计技能" (design a skill), "创建技能" (create a skill), "技能规范" (skill specification)
- "技能命名规则" (skill naming rules), "技能命名规范" (skill naming conventions)
- "SKILL.md 怎么写" (how to write SKILL.md), "frontmatter 规范" (frontmatter specification)
- "技能最佳实践" (skill best practices), "技能目录结构" (skill directory structure)
- "渐进式披露" (progressive disclosure), "Agent Skills 规范" (Agent Skills spec)
- "怎么写 description" (how to write description), "skill description 怎么写"
- "技能脚本安全" (skill script safety), "技能触发条件" (skill trigger conditions)
Trigger phrases include:
- "我要设计一个新的 Skill,告诉我规范" (I want to design a new skill, tell me the spec)
- "SKILL.md 的 frontmatter 有哪些字段" (what fields are in SKILL.md frontmatter)
- "技能的 name 有什么命名规则" (what are the naming rules for skill name)
- "怎么让技能的 description 触发更准确" (how to make skill description trigger more accurately)
- "技能的最佳实践有哪些" (what are the best practices for skills)
- "渐进式披露怎么用" (how to use progressive disclosure)
- "设计一个 Skill 需要注意什么" (what to pay attention to when designing a skill)
- "tell me the Agent Skills specification", "what makes a good skill"
- "how should I structure a skill directory", "skill frontmatter rules"
---
1. Agent Skills Specification
1.1 Directory Structure
Every skill is a folder containing at minimum a SKILL.md file:
skill-name/
├── SKILL.md # Required: metadata + instructions
├── scripts/ # Optional: executable code
├── references/ # Optional: documentation loaded on demand
├── assets/ # Optional: templates, images, data files
└── LICENSE.txt # Optional: license file1.2 SKILL.md Format
The SKILL.md file must contain YAML frontmatter followed by Markdown body.
Required frontmatter fields
| Field | Required | Constraints |
|---|---|---|
name | Yes | Max 64 characters. Lowercase letters (a-z), digits (0-9), and hyphens (-) only. Must NOT start or end with a hyphen. Must NOT contain consecutive hyphens (--). Must match the parent directory name. |
description | Yes | Max 1024 characters. Non-empty. Must describe BOTH what the skill does AND when to use it. This is the primary mechanism the agent uses to decide whether to activate the skill. |
Optional frontmatter fields
| Field | Constraints |
|---|---|
license | License name or reference to a bundled license file (e.g., LICENSE.txt). Keep it short. |
compatibility | Max 500 characters. Indicates environment requirements (intended product, system packages, network access). Only include if your skill has specific requirements. |
metadata | Arbitrary key-value mapping for additional metadata. Use reasonably unique key names to avoid conflicts. |
allowed-tools | Space-separated string of pre-approved tools the skill may use. Experimental — support varies between agent implementations. |
Name field rules (detailed)
VALID names:
mermaid ✅ lowercase only
roll-dice ✅ lowercase + hyphen
skill-awesome ✅ lowercase + hyphen
INVALID names:
My-Skill ❌ uppercase
-skill ❌ starts with hyphen
skill- ❌ ends with hyphen
skill--awesome ❌ consecutive hyphens
skill_name ❌ underscore
123skill ❌ starts with digit (no, actually digits ARE allowed)Body content rules
- No format restrictions — write whatever helps the agent perform the task.
- Keep SKILL.md under 500 lines / 5000 tokens. Move detailed reference material to
references/. - Recommended sections: step-by-step instructions, examples of inputs and outputs, common edge cases.
1.3 Progressive Disclosure
Agents load skills progressively in three stages:
| Stage | What loads | Token cost | When |
|---|---|---|---|
| Discovery | Only name + description | ~100 tokens | Agent startup |
| Activation | Full SKILL.md body | <5000 tokens (recommended) | Task matches description |
| Execution | references/, scripts/, assets/ | On demand | As needed during execution |
Key implications for skill design:
- The
descriptioncarries the entire burden of triggering — if it doesn't convey when the skill is useful, the agent won't know to reach for it. - Keep
SKILL.mdfocused on core instructions. Tell the agent when to load reference files, not just that they exist: "Readreferences/api-errors.mdif the API returns a non-200 status code." - Avoid deeply nested reference chains — keep references one level deep from SKILL.md.
---
2. Best Practices for Skill Design
2.1 Start from Real Expertise
Do NOT ask an LLM to generate a skill from its general training knowledge — this produces vague, generic procedures. Ground skills in real, domain-specific context:
- Extract from a hands-on task: Complete a real task, then extract the reusable pattern. Capture steps that worked, corrections you made, input/output formats, and project-specific context.
- Synthesize from existing project artifacts: Internal documentation, runbooks, API specifications, code review comments, version control history, real-world failure cases.
2.2 Spend Context Wisely
Every token in your skill competes for the agent's attention.
| Do | Don't |
|---|---|
| Add what the agent lacks (project conventions, domain procedures, edge cases) | Explain what the agent already knows (what a PDF is, how HTTP works) |
| Design coherent units (one skill = one cohesive workflow) | Scope too narrowly (many skills for one task) or too broadly (hard to trigger precisely) |
| Aim for moderate detail (concise stepwise guidance + working examples) | Be overly comprehensive (agent struggles to extract what's relevant) |
| Structure large skills with progressive disclosure | Put everything in SKILL.md |
Ask yourself about each piece of content: "Would the agent get this wrong without this instruction?" If no, cut it.
2.3 Calibrate Control
Match the specificity of instructions to the fragility of the task:
| Situation | Strategy |
|---|---|
| Multiple valid approaches, task tolerates variation | Give the agent freedom. Explain why rather than rigid directives. |
| Operations are fragile, consistency critical, specific sequence required | Be prescriptive. Use exact commands, explicit sequences. |
| Multiple tools/approaches could work | Pick a default and mention alternatives briefly. Provide defaults, not menus. |
| Teaching a class of problems | Favor procedures ("how to approach") over declarations ("what to produce for one instance"). |
2.4 Effective Instruction Patterns
Gotchas sections — the highest-value content in many skills. Environment-specific facts that defy reasonable assumptions:
## Gotchas
- The `users` table uses soft deletes. Queries must include `WHERE deleted_at IS NULL`.
- The user ID is `user_id` in the database, `uid` in the auth service, and `accountId` in the billing API. All three refer to the same value.Output format templates — more reliable than prose descriptions. Agents pattern-match well against concrete structures:
## Report structure
Use this template, adapting sections as needed:
# [Analysis Title]
## Executive summary
[One-paragraph overview]
## Key findings
- Finding 1 with supporting data
## Recommendations
1. Specific actionable recommendationChecklists for multi-step workflows — helps the agent track progress and avoid skipping steps:
## Workflow
- [ ] Step 1: Analyze input
- [ ] Step 2: Create plan
- [ ] Step 3: Validate plan
- [ ] Step 4: Execute
- [ ] Step 5: Verify outputValidation loops — instruct the agent to validate before proceeding:
1. Make your edits
2. Run validation: `python scripts/validate.py output/`
3. If validation fails: review error, fix issues, re-run validation
4. Only proceed when validation passes2.5 "When to use" / "When NOT to use" sections
Include a clear "When NOT to use" section with near-miss boundaries — scenarios that share keywords or concepts with your skill but need a different skill. This prevents false triggering.
---
3. Description Optimization
3.1 Principles for Effective Descriptions
| Principle | Explanation |
|---|---|
| Use imperative phrasing | "Use this skill when..." not "This skill does..." The agent is deciding whether to act. |
| Focus on user intent, not implementation | Describe what the user is trying to achieve, not the skill's internal mechanics. |
| Err on the side of being pushy | Explicitly list contexts where the skill applies, including cases where the user doesn't name the domain directly. |
| Keep it concise | A few sentences to a short paragraph. Hard limit: 1024 characters. |
3.2 Testing Description Triggering
Create eval queries (~20) — realistic user prompts labeled with whether they should or shouldn't trigger your skill. Design:
- Should-trigger queries: Vary phrasing (formal/casual/typos), explicitness (naming the domain vs describing the need), detail level, and complexity.
- Should-not-trigger queries: Focus on near-misses — queries that share keywords with your skill but actually need something different. These are the most valuable negative test cases.
Run each query 3+ times (model behavior is nondeterministic) and compute a trigger rate. Use a train/validation split (60%/40%) to avoid overfitting.
---
4. Script Safety Guidelines
When a skill bundles executable scripts in scripts/ or instructs the agent to run shell commands:
Required
| Rule | Description |
|---|---|
| Non-interactive | No prompts waiting for stdin/TTY. All inputs via flags, environment variables, or stdin explicitly. |
| `--help` available | Prints usage instructions and examples. This is the primary way an agent learns the script's interface. |
| Clear error messages | Say what failed, what was expected, and what to try next. "Error: --format must be one of: json, csv, table. Received: 'xml'" |
| No secrets | No hardcoded tokens, keys, or passwords. No logging of secrets. |
| Safe defaults | Destructive operations require explicit --force or --confirm flags. |
Recommended
| Rule | Description |
|---|---|
| Structured output | --format json option. Data to stdout, diagnostics to stderr. |
| Idempotency | Repeated runs do not corrupt state. "Create if not exists" over "create and fail on duplicate". |
| `--dry-run` support | For destructive or stateful operations, let the agent preview what will happen. |
| Predictable output size | Default to summary; support pagination flags if output can be large. |
| Meaningful exit codes | Distinct exit codes for different failure types. Document them in --help. |
Self-contained scripts (recommended pattern)
Use inline dependency declarations so scripts can run with a single command:
- Python (PEP 723):
# /// script/# dependencies = [...]/# ///→ run withuv run - Deno:
import from "npm:package@version"→ run withdeno run - Bun:
import from "package@version"→ run withbun run
---
5. Evaluation Frameworks
5.1 Official Rubric (agentskills.io)
Five inspection dimensions from the official specification:
| Dimension | What it checks | Severity |
|---|---|---|
| Spec compliance | Frontmatter fields, name/directory match, field format validity | Must |
| Progressive disclosure | SKILL.md conciseness, references with trigger conditions, no deep chains | Should |
| Description quality | User-intent language, trigger/not-trigger boundaries | Should |
| Script readiness | Non-interactive CLI, --help, structured output, safe defaults | Conditional |
| Security hygiene | No hardcoded secrets, no suspicious download/exfiltration instructions | Must |
5.2 TRACE Model (SkillHub)
Five-dimension quality model for evaluating skills:
| Dimension | Core question |
|---|---|
| T · Trust | "Can I safely use it?" — permissions, secrets, dependency risks, third-party scan evidence, China network compatibility |
| R · Reliability | "Can I use it consistently?" — input constraints, failure feedback, validation loops, repeatability |
| A · Adaptability | "Should I use it in this scenario?" — boundary clarity, trigger precision, near-miss handling |
| C · Convention | "Can it be understood, maintained, and reused?" — structure, progressive disclosure, templates, naming consistency |
| E · Effectiveness | "Did it actually solve the problem?" — output correctness, coverage, reusability, improvement over no-skill baseline |
---
6. Complete Skill Creation Checklist
When designing a new skill, verify all of the following:
Structure
- [ ] Directory name uses lowercase letters, digits, and hyphens only
- [ ]
namein frontmatter matches directory name exactly - [ ]
SKILL.mdexists at the skill root - [ ] Optional directories follow conventions (
scripts/,references/,assets/)
Frontmatter
- [ ]
nameis 1-64 characters, lowercase + hyphens only, no leading/trailing hyphens, no consecutive hyphens - [ ]
descriptionis 1-1024 characters, describes both what AND when to use - [ ]
descriptionuses imperative phrasing ("Use when...") - [ ]
licensefield present (short name or reference to bundled license file)
Body content
- [ ] Under 500 lines / 5000 tokens
- [ ] Step-by-step instructions are clear and actionable
- [ ] Examples of inputs and outputs provided
- [ ] Common edge cases documented
- [ ] Gotchas section for non-obvious facts
- [ ] "When NOT to use" section with near-miss boundaries
Progressive disclosure
- [ ] Long reference material moved to
references/ - [ ] References linked with clear "when to read" triggers
- [ ] No deeply nested reference chains
Scripts (if applicable)
- [ ] Non-interactive — no TTY prompts
- [ ]
--helpprints usage and examples - [ ] Error messages say what failed and what to try
- [ ] No hardcoded secrets
- [ ] Destructive operations require
--force/--confirm - [ ] Structured output option (
--format json)
Trigger quality
- [ ] Description uses user-intent language
- [ ] Both "should trigger" and "should not trigger" scenarios considered
- [ ] Near-miss boundaries defined for adjacent skills
References
This knowledge is distilled from official sources. For the full original content, see:
- agentskills.io Specification
- Best practices for skill creators
- Optimizing skill descriptions
- Evaluating skill output quality
- Using scripts in skills
- How to create custom Skills (Claude)
- SkillHub TRACE Evaluation
For auto-generating an awesome list index from a skills repository, use the companion script:
python3 scripts/build_awesome.py --skills-root <path> --output AWESOME_AGENT_SKILLS.mdFor a complete example of what an awesome list looks like, see examples/sample-awesome.md.
Keywords
English keywords: agent-skills, skill-specification, skill-design, skill-creation, skill-development, skill-best-practices, skill-naming, skill-frontmatter, skill-directory-structure, progressive-disclosure, skill-description, skill-trigger, skill-evaluation, script-safety, trace-evaluation, official-rubric, skill-compliance, skill-checklist, skill-template, how-to-design-a-skill
Chinese keywords (中文关键词): 设计技能, 创建技能, 技能规范, 技能命名规则, 技能命名规范, SKILL.md 怎么写, frontmatter 规范, skill frontmatter, 技能最佳实践, 技能目录结构, 渐进式披露, 怎么写 description, skill description 怎么写, 技能触发条件, 技能脚本安全, 技能评估, TRACE 评测, 技能合规, 技能检查清单, Agent Skills 规范
FAQ
Q1: 如何快速上手此技能? A: 参考上方的快速开始章节,按步骤操作即可。
Q2: 遇到版本不兼容问题怎么办? A: 检查依赖版本,使用 lock 文件锁定,参考常见陷阱章节。
Q3: 如何在生产环境使用? A: 参考最佳实践章节,确保配置正确,做好监控和日志。
Q4: 性能如何优化? A: 参考性能优化相关文档,使用缓存、索引等手段。
Q5: 如何贡献或反馈问题? A: 在 GitHub 仓库提交 Issue 或 Pull Request。
Q6: 是否支持中文? A: 支持中文文档和中文注释,详见国内适配章节。
Awesome Agent Skills
Curated list of resources for designing, building, and evaluating Agent Skills.
_Generated from official specs, best practices, and example skills._
_Review entries periodically for freshness._
Contents
Specs
- Agent Skills Specification — Complete format specification for SKILL.md frontmatter, directory structure, and progressive disclosure. (spec)
- Agent Skills Overview — What Agent Skills are, why they exist, and how progressive disclosure works. (spec)
- How to create custom Skills — Claude-specific guide for creating, structuring, testing, and packaging skills. (spec)
Skill design & best practices
- Best practices for skill creators — How to write well-scoped skills: real expertise extraction, context budgeting, calibration, gotchas, checklists, and validation loops. (best-practice)
- Quickstart: Create your first skill — Step-by-step tutorial creating a
roll-diceskill in VS Code with Copilot. (best-practice examples) - Optimizing skill descriptions — How to test and improve description triggering accuracy with eval queries and a train/validation split. (best-practice evaluation)
- Using scripts in skills — One-off commands, self-contained scripts, and designing script interfaces for agentic use. (best-practice scripts)
Evaluation & QA
- Evaluating skill output quality — Structured eval workflow: test cases, assertions, grading, benchmarking with baseline comparisons. (evaluation)
- SkillHub TRACE Evaluation Framework — Five-dimension quality model (Trust, Reliability, Adaptability, Convention, Effectiveness) for evaluating skills. (evaluation)
- SkillHub TRACE announcement — Tencent × SkillHub × Xuanwu Lab joint release of the TRACE framework. (evaluation)
Security & scripts
- Script safety checklist — Non-interactive CLI,
--help, clear errors, no secrets, safe defaults, structured output. (security scripts) - Using scripts in skills — Covers
uvx,npx,pipx,bunx,deno run,go runfor one-off commands; PEP 723 inline dependencies for self-contained scripts. (security scripts)
Example skills
- Mermaid diagram skill — Well-structured skill with 23+ diagram types, version compatibility handling, and detailed workflow instructions. (examples docs)
- skill-official-evaluation — Official spec compliance evaluator using agentskills.io rubric with script safety checklist. (examples evaluation)
- skill-trace-evaluation — TRACE five-dimension quality evaluator with HTML/Markdown/JSON output and SkillHub-style radar reports. (examples evaluation)
Templates
- Official evaluation report template — Example Pass/Needs-improvement report with spec compliance checklist, Top-3 issues, and prioritized suggestions. (templates evaluation)
- TRACE evaluation report template — Example TRACE report with overall rating, per-dimension scores, evidence, risks, and actionable suggestions. (templates evaluation)
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Tag taxonomy (default)
Use these tags consistently across awesome entries.
Core
- spec
- best-practice
- evaluation
- security
- scripts
- templates
- examples
- integration
Domains
- docs
- devops
- frontend
- backend
- data
- testing
- design
#!/usr/bin/env python3
"""
Build an Awesome Agent Skills markdown index from a skills root directory.
This script is stdlib-only and designed for agentic use (non-interactive).
"""
from __future__ import annotations
import argparse
import os
from dataclasses import dataclass
from datetime import datetime, timezone
from pathlib import Path
from typing import Dict, List, Tuple
@dataclass
class Entry:
path: str
name: str
description: str
def parse_args() -> argparse.Namespace:
"""Parse CLI args."""
p = argparse.ArgumentParser(
prog="build_awesome.py",
description="Generate an AWESOME_AGENT_SKILLS.md index for a skills repository.",
)
p.add_argument("--skills-root", required=True, help="Path to the skills root (contains skill groups).")
p.add_argument("--output", required=True, help="Output markdown file path.")
p.add_argument("--max", type=int, default=5000, help="Max skills to include (safety).")
return p.parse_args()
def read_text(path: Path) -> str:
"""Read UTF-8 text from file."""
return path.read_text(encoding="utf-8")
def parse_frontmatter(skill_md: str) -> Dict[str, str]:
"""Parse minimal frontmatter (name/description/license) without YAML deps."""
lines = skill_md.splitlines()
if not lines or lines[0].strip() != "---":
return {}
fm: Dict[str, str] = {}
for line in lines[1:]:
if line.strip() == "---":
break
if ":" not in line:
continue
k, v = line.split(":", 1)
fm[k.strip()] = v.strip()
return fm
def find_skill_dirs(skills_root: Path, limit: int) -> List[Path]:
"""Discover skill directories by locating SKILL.md under the skills root."""
skill_dirs: List[Path] = []
for p in skills_root.rglob("SKILL.md"):
d = p.parent
if d in skill_dirs:
continue
skill_dirs.append(d)
if len(skill_dirs) >= limit:
break
return sorted(skill_dirs)
def load_entries(skills_root: Path, limit: int) -> List[Entry]:
"""Load skill entries from SKILL.md files."""
entries: List[Entry] = []
for d in find_skill_dirs(skills_root, limit):
fm = parse_frontmatter(read_text(d / "SKILL.md"))
name = fm.get("name", d.name)
desc = fm.get("description", "")
if desc.strip().upper().startswith("DEPRECATED"):
continue
rel = str(d.relative_to(skills_root.parent))
entries.append(Entry(path=rel, name=name, description=desc))
return entries
def group_key(entry: Entry) -> str:
"""Group key for awesome output."""
p = Path(entry.path)
parts = p.parts
if len(parts) >= 2:
return parts[-2]
return "skills"
def render(entries: List[Entry]) -> str:
"""Render markdown content."""
lines: List[str] = []
lines.append("# Awesome Agent Skills")
lines.append("")
lines.append(f"_Generated at {datetime.now(timezone.utc).isoformat().replace('+00:00','Z')}_")
lines.append("")
groups: Dict[str, List[Entry]] = {}
for e in entries:
groups.setdefault(group_key(e), []).append(e)
for g in sorted(groups.keys()):
lines.append(f"## {g}")
for e in sorted(groups[g], key=lambda x: x.name):
one = e.description.strip().replace("\n", " ")
if len(one) > 140:
one = one[:137] + "..."
lines.append(f"- [{e.name}]({e.path}) — {one}")
lines.append("")
return "\n".join(lines)
def main() -> int:
"""CLI entrypoint."""
args = parse_args()
skills_root = Path(args.skills_root).expanduser().resolve()
out_path = Path(args.output).expanduser().resolve()
entries = load_entries(skills_root, args.max)
content = render(entries)
out_path.parent.mkdir(parents=True, exist_ok=True)
out_path.write_text(content, encoding="utf-8")
return 0
if __name__ == "__main__":
raise SystemExit(main())