This scaffolds exercise directory structures for what looks like an AI Hero course repository, creating the section and exercise folders with the right numeric prefixes, generating stub readme files, and running a linter to make sure everything's valid before you commit. It handles the three exercise variants (problem, solution, explainer) and knows all the lint rules like non-empty readmes, no broken links, and when you need a main.ts file. The workflow is parse your plan, mkdir everything, stub out readmes with titles, lint, fix, repeat. Saves you from manually creating dozens of folders and forgetting which exercises need which variants, then discovering lint failures after the fact.

skills.sh installs
5.7K
GitHub stars
5.7K
last updated
Aug 21, 2026

Install

$ npx -y skills add vinvcn/mattpocock-skills-zh-cn --skill scaffold-exercises --agent claude-code

Installs into .claude/skills of the current project.

Files

搭建练习

创建能通过 pnpm ai-hero-cli internal lint 的 exercise directory structures,然后用 git commit 提交。

目录命名

  • Sections:exercises/ 下的 XX-section-name/(例如 01-retrieval-skill-building)
  • Exercises:section 下的 XX.YY-exercise-name/(例如 01.03-retrieval-with-bm25)
  • Section number = XX,exercise number = XX.YY
  • Names 使用 dash-case(小写、连字符)

Exercise 变体

每个 exercise 至少需要这些 subfolders 中的一个:

  • problem/ - student workspace,包含 TODOs
  • solution/ - reference implementation
  • explainer/ - conceptual material,不含 TODOs

创建 stub 时,除非 plan 指定其他 variant,否则默认使用 explainer/。

必需文件

每个 subfolder(problem/、solution/、explainer/)都需要一个 readme.md,要求:

  • 非空(必须有真实内容,即使只有一行 title 也可以)
  • 没有 broken links

创建 stub 时,生成带 title 和 description 的最小 readme:

# Exercise Title

Description here

如果 subfolder 有 code,还需要 main.ts(>1 行)。但对 stubs 来说,readme-only exercise 可以接受。

工作流

  1. Parse the plan - 提取 section names、exercise names 和 variant types
  2. Create directories - 对每个 path 执行 mkdir -p
  3. Create stub readmes - 每个 variant folder 一个带 title 的 readme.md
  4. Run lint - 执行 pnpm ai-hero-cli internal lint 验证
  5. Fix any errors - 迭代直到 lint 通过

Sponsors

Details

Repository
github.com/vinvcn/mattpocock-skills-zh-cn
Category
Automation & Workflows
First seen
Jun 3, 2026

More from vinvcn/mattpocock-skills-zh-cn

All 39
1trailofbits avatartesting-handbook-generatortrailofbits/skillsMeta-skill that analyzes the Trail of Bits Testing Handbook (appsec.guide) and generates Claude Code skills for security testing tools and techniques. Use when 5.6Kskills.sh installs
2web-infra-dev avatarandroid-device-automationweb-infra-dev/midscene-skillsVision-driven Android device automation using Midscene. Operates entirely from screenshots — no DOM or accessibility labels required. Can interact with all visi5.5Kskills.sh installs
3affaan-m avatarcost-aware-llm-pipelineaffaan-m/everything-claude-codecost aware llm pipeline5.4Kskills.sh installs
4claude-office-skills avatarsheets-automationclaude-office-skills/skillsGoogle Sheets automation workflows - data sync, task management, reporting dashboards, and multi-platform integrations5.4Kskills.sh installs
5czlonkowski avatarn8n-code-pythonczlonkowski/n8n-skillsWrite Python code in n8n Code nodes. Use when writing Python in n8n, using _input/_json/_node syntax, working with standard library, or need to understand Pytho5.1Kskills.sh installs
6aaron-he-zhu avatarschema-markup-generatoraaron-he-zhu/seo-geo-claude-skillsschema markup generator5Kskills.sh installs