Skip to content

Commit 744eeb6

Browse files
committed
chore: initialize skills repository
Add initial repo files, docs, workflows, scripts, and random-image-placeholder skill. Made-with: Cursor
0 parents  commit 744eeb6

25 files changed

Lines changed: 991 additions & 0 deletions

File tree

.github/workflows/validate.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Validate Skills
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
validate:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout
15+
uses: actions/checkout@v4
16+
17+
- name: Set up Python
18+
uses: actions/setup-python@v5
19+
with:
20+
# scripts use Python 3.10+ syntax (e.g. `int | None`)
21+
python-version: '3.11'
22+
23+
- name: Validate skills
24+
run: python scripts/validate_skill.py skills

.gitignore

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# OS
2+
.DS_Store
3+
Thumbs.db
4+
5+
# Editors
6+
.idea/
7+
.vscode/
8+
9+
# Python
10+
__pycache__/
11+
*.pyc
12+
13+
# Node
14+
node_modules/
15+
16+
# Build output
17+
dist/
18+
coverage/
19+
tmp/

CODE_OF_CONDUCT.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Code of Conduct
2+
3+
This project follows the Contributor Covenant.
4+
5+
## Our Pledge
6+
7+
We pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
8+
9+
## Our Standards
10+
11+
Examples of behavior that contributes to a positive environment include:
12+
13+
- Being respectful and considerate
14+
- Gracefully accepting constructive feedback
15+
- Focusing on what is best for the community
16+
17+
Examples of unacceptable behavior include:
18+
19+
- Harassment, discrimination, or hate speech
20+
- Personal attacks or trolling
21+
- Publishing others' private information without permission
22+
23+
## Enforcement
24+
25+
Project maintainers are responsible for clarifying standards and taking appropriate action in response to any behavior deemed inappropriate.
26+

CONTRIBUTING.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Contributing
2+
3+
Thanks for contributing!
4+
5+
## What belongs in this repo
6+
7+
- New skills under `skills/<skill-name>/` (must include `SKILL.md`)
8+
- Improvements to templates in `skills/_template/`
9+
- Documentation in `docs/`
10+
- Utilities in `scripts/` that improve scaffolding/validation/packaging
11+
12+
## Skill requirements
13+
14+
- `skills/<skill-name>/SKILL.md` must have YAML frontmatter with only:
15+
- `name`
16+
- `description`
17+
- `name` must match the folder name and be lowercase kebab-case
18+
- Keep `SKILL.md` concise and procedural
19+
20+
## Local checks
21+
22+
Validate all skills:
23+
24+
```bash
25+
python scripts/validate_skill.py skills
26+
```
27+
28+
Validate a single skill:
29+
30+
```bash
31+
python scripts/validate_skill.py skills/<skill-name>
32+
```
33+
34+
Package a skill:
35+
36+
```bash
37+
python scripts/package_skill.py skills/<skill-name>
38+
```
39+
40+
## Pull requests
41+
42+
- Keep changes focused (one skill / one improvement per PR when possible)
43+
- Update docs when behavior changes
44+
- If you add scripts, prefer standard library only (or document dependencies clearly)
45+

LICENSE

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
MIT License
2+
3+
Copyright (c) 2026
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.
22+

README.md

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
# Agent Skills 🧰
2+
3+
English | [中文](README.zh-CN.md)
4+
5+
A collection of skills for AI coding agents. Skills are packaged instructions and scripts that extend agent capabilities.
6+
7+
## Available Skills ✨
8+
9+
### random-image-placeholder
10+
11+
Generate stable or random image placeholder URLs (and optionally download them) using [Lorem Picsum](https://picsum.photos/).
12+
13+
**Use when:**
14+
15+
- Building UI mockups / docs / demos that need images without hosting assets
16+
- You need reproducible images for tests/snapshots (use `seed`)
17+
- The user mentions picsum, placeholder images, grayscale, blur, seed, id
18+
19+
**Examples:**
20+
21+
```bash
22+
python skills/random-image-placeholder/scripts/picsum.py url --seed avatar-42 --width 400 --height 400 --grayscale --blur 2
23+
```
24+
25+
```bash
26+
python skills/random-image-placeholder/scripts/picsum.py download --seed avatar-42 --width 120 --height 80 --out ./tmp/picsum_test.jpg
27+
```
28+
29+
Docs:
30+
31+
- `skills/random-image-placeholder/README.md`
32+
- `skills/random-image-placeholder/SKILL.md`
33+
34+
## Installation
35+
36+
This repo supports two common installation paths:
37+
38+
1. **Use directly from source**: clone the repo and use the skill files/scripts under `skills/`
39+
2. **Use packaged `.skill` artifacts**: import a `.skill` file produced under `dist/` (or from your GitHub Releases, if you publish them)
40+
41+
Package a skill locally:
42+
43+
```bash
44+
python scripts/package_skill.py skills/random-image-placeholder
45+
```
46+
47+
## Usage
48+
49+
Skills are automatically available once installed/imported (depending on your editor/agent). If a skill includes helper scripts, run them directly when a deterministic result is needed.
50+
51+
## Skill Structure
52+
53+
Each skill contains:
54+
55+
- `SKILL.md` - Instructions for the agent
56+
- `scripts/` - Helper scripts for automation (optional)
57+
- `references/` - Supporting documentation (optional)
58+
- `assets/` - Bundled assets (optional)
59+
60+
## License
61+
62+
MIT. See [LICENSE](LICENSE).

README.zh-CN.md

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Agent Skills 🧰
2+
3+
[English](README.md) | 中文
4+
5+
一个面向 AI 编程代理的 skill 合集。Skill 本质是可打包的说明与脚本,用来扩展代理能力。
6+
7+
## 当前可用的 Skills ✨
8+
9+
### random-image-placeholder
10+
11+
基于 [Lorem Picsum](https://picsum.photos/) 生成随机/可复现的占位图 URL(可选下载到本地)。
12+
13+
**适用场景:**
14+
15+
- 做 UI mock / 文档 / demo,需要图片但不想托管静态资源
16+
- 测试/快照需要可复现图片(使用 `seed`
17+
- 用户提到 picsum / 占位图 / grayscale / blur / seed / id
18+
19+
**示例:**
20+
21+
```bash
22+
python skills/random-image-placeholder/scripts/picsum.py url --seed avatar-42 --width 400 --height 400 --grayscale --blur 2
23+
```
24+
25+
```bash
26+
python skills/random-image-placeholder/scripts/picsum.py download --seed avatar-42 --width 120 --height 80 --out ./tmp/picsum_test.jpg
27+
```
28+
29+
相关文档:
30+
31+
- `skills/random-image-placeholder/README.md`
32+
- `skills/random-image-placeholder/SKILL.md`
33+
34+
## 安装
35+
36+
本仓库支持两种常见使用方式:
37+
38+
1. **直接用源码**:clone 仓库后直接使用 `skills/` 下的 skill 文件与脚本
39+
2. **使用打包产物 `.skill`**:导入 `dist/` 下生成的 `.skill` 文件(如果你发布了 GitHub Releases,也可以从 Release 下载)
40+
41+
本地打包:
42+
43+
```bash
44+
python scripts/package_skill.py skills/random-image-placeholder
45+
```
46+
47+
## 使用
48+
49+
安装/导入后,skill 会根据你的编辑器/代理规则自动可用。若 skill 自带脚本,建议在需要“确定性输出”时直接运行脚本获得稳定结果。
50+
51+
## Skill 结构
52+
53+
每个 skill 通常包含:
54+
55+
- `SKILL.md`:给代理的使用说明
56+
- `scripts/`:可选的辅助脚本(更稳定、可复用)
57+
- `references/`:可选的参考资料
58+
- `assets/`:可选的资源文件
59+
60+
## 许可
61+
62+
MIT,见 [LICENSE](LICENSE)
63+

SECURITY.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Security Policy
2+
3+
## Supported Versions
4+
5+
This repository provides scripts and documentation. Security updates are provided on a best-effort basis for the latest version of the default branch.
6+
7+
## Reporting a Vulnerability
8+
9+
Please do **not** open a public issue for security-sensitive reports.
10+
11+
Instead, contact the maintainer with:
12+
13+
- A clear description of the issue and impact
14+
- Reproduction steps (or a minimal PoC)
15+
- Any relevant logs or screenshots
16+
17+
If you're unsure who to contact, open a draft issue with minimal detail and request a private channel.
18+

docs/skill-authoring-guide.md

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
# Skill Authoring Guide
2+
3+
## Minimum files
4+
5+
Each skill should include:
6+
7+
- `SKILL.md`: the required Claude Code skill file
8+
9+
## Required `SKILL.md` format
10+
11+
Use YAML frontmatter at the top of the file:
12+
13+
```md
14+
---
15+
name: my-skill
16+
description: Explain what the skill does and when to use it.
17+
---
18+
```
19+
20+
Only use `name` and `description` in frontmatter.
21+
22+
## Recommended body sections
23+
24+
1. `## Triggers`
25+
2. `## Workflow`
26+
3. `## Rules`
27+
4. `## References`
28+
5. `## Examples`
29+
6. `## Output`
30+
31+
## Naming guidance
32+
33+
- Use lowercase kebab-case for folder names
34+
- Keep names specific to the job the skill performs
35+
- Prefer verbs or clear job titles, such as `release-helper` or `security-auditor`
36+
37+
## Versioning
38+
39+
Skills do not need a separate metadata version file in this repository format.
40+
41+
Track revisions with git history, release tags, or packaged `.skill` artifacts.
42+
43+
## Validation and packaging
44+
45+
- Validate all skills: `python scripts/validate_skill.py skills`
46+
- Validate one skill: `python scripts/validate_skill.py skills/<skill-name>`
47+
- Package one skill: `python scripts/package_skill.py skills/<skill-name>`
48+
49+
The packager validates before creating a distributable `.skill` file.

scripts/new-skill.ps1

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
param(
2+
[Parameter(Mandatory = $true)]
3+
[string]$Name
4+
)
5+
6+
$repoRoot = Split-Path -Parent $PSScriptRoot
7+
$templateDir = Join-Path $repoRoot "skills\_template"
8+
$targetDir = Join-Path $repoRoot "skills\$Name"
9+
10+
if (Test-Path $targetDir) {
11+
Write-Error "Skill '$Name' already exists."
12+
exit 1
13+
}
14+
15+
Copy-Item $templateDir $targetDir -Recurse
16+
17+
$skillPath = Join-Path $targetDir "SKILL.md"
18+
$content = Get-Content $skillPath -Raw
19+
$description = "Describe what this skill does and when to use it. Mention concrete triggers, repositories, file types, or workflows so Claude can activate it correctly."
20+
$content = $content.Replace("{{SKILL_NAME}}", $Name)
21+
$content = $content.Replace("{{SKILL_DESCRIPTION}}", $description)
22+
Set-Content -Path $skillPath -Value $content
23+
24+
Write-Host "Created skill scaffold at $targetDir"

0 commit comments

Comments
 (0)