CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

migrate-to-shoehorn

将测试文件从 `as` 类型断言迁移到 @total-typescript/shoehorn。适用于用户提到 shoehorn、想替换测试中的 `as`,或需要局部测试数据时。

Quality

87%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

SKILL.md
Quality
Evals
Security

Quality

Content

86%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

A lean, highly actionable body: every migration pattern is shown as executable Before/After code, and the workflow ends in an explicit type-check validation step. The only gaps are a trimmable rationale section and a missing fix-and-revalidate loop after the type check.

DimensionReasoningScore

Conciseness

The body is efficient — terse Before/After pairs, a compact decision table ("何时使用哪一个"), and a one-line install command. Minor over-explanation could be trimmed (e.g., "经过训练,不去使用它" and the long first Before example with 20 fake properties), fitting anchor 4 rather than 5.

4 / 5

Actionability

Fully executable guidance: "npm i @total-typescript/shoehorn", a ready-to-run grep ("grep -r \" as [A-Z]\" --include=*.test.ts --include=*.spec.ts"), three copy-paste Before/After code patterns (fromPartial, fromAny, large-object case), and a table covering which function to use. This matches anchor 5 — specific examples cover the common cases.

5 / 5

Workflow Clarity

The "工作流" section gives a clear sequenced checklist (install → grep for `as` → replace patterns → add imports → "运行 type check 验证") with an explicit validation step. It falls short of anchor 5 because there is no error-recovery loop (what to do when the type check fails), fitting anchor 4 (minor validation gaps).

4 / 5

Progressive Disclosure

No bundle files exist and none are needed: this single-purpose skill (~120 lines) is appropriately self-contained with well-organized, clearly headed sections (为什么用, 安装, 迁移模式, 何时使用哪一个, 工作流) that are easy to navigate — matching the simple-skill case for anchor 5.

5 / 5

Total

18

/

20

Passed

Description

82%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

A strong description: it names the exact transformation, the target library, and an explicit use-when clause with three natural triggers. The only weakness is single-action coverage — it states one action (migrate) rather than enumerating several capabilities.

DimensionReasoningScore

Specificity

The description states a single, precise action — "将测试文件从 `as` 类型断言迁移到 @total-typescript/shoehorn" — naming the source pattern, target library, and test-file scope. It matches anchor 3 (domain plus 1-2 concrete actions, not comprehensive) rather than 4, because it lists only one action rather than several; it is not 2 because the action is fully concrete, not generic.

3 / 5

Completeness

It explicitly answers both: what ("将测试文件从 `as` 类型断言迁移到 @total-typescript/shoehorn") and when ("适用于用户提到 shoehorn、想替换测试中的 `as`,或需要局部测试数据时"), with three concrete trigger phrases — a clear match for anchor 5. It is not 4 because the 'when' clause is fully explicit, not merely present-but-vague.

5 / 5

Trigger Term Quality

Natural trigger phrases are present: "用户提到 shoehorn、想替换测试中的 `as`,或需要局部测试数据". This fits anchor 4 (good keyword coverage, a few natural terms missing) — synonyms like "type casting" / "type assertions" are absent, keeping it below anchor 5.

4 / 5

Distinctiveness Conflict Risk

It occupies a clear niche: migrating `as` assertions in test code to a specifically named library (@total-typescript/shoehorn), with no overlap with generic testing or refactoring skills — anchor 5.

5 / 5

Total

17

/

20

Passed

Validation

100%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation — 16 / 16 Passed

Validation for skill structure

No warnings or errors.

Repository

vinvcn/mattpocock-skills-zh-CN

Path

skills/misc/migrate-to-shoehorn/SKILL.md

Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.