CtrlK
BlogDocsLog inGet started
Tessl Logo

android-dimen-dp-sp

将布局与代码中的硬编码 dp、sp 改为引用 @dimen/dp_*、@dimen/sp_* 与 R.dimen.*; 资源名规则为整数部分与一位小数部分用下划线连接(如 12.5 → dp_12_5)。 在用户要求去掉魔法数、统一 dimen、替换 dp/sp 字面量或规范化尺寸引用时使用。

76

Quality

93%

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

87%Weight 40%Scale 1-3

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

A compact, actionable skill body with a clear naming algorithm, mapping table, and concrete XML/Kotlin rewrite rules. Its only gap is the absence of a validation/verification checkpoint for the XML/layout edits it performs.

Suggestions

Add a brief verification step (e.g., confirm the referenced @dimen entry resolves or run a build) or state explicitly when verification is intentionally skipped, to satisfy the feedback-loop expectation for XML manipulation.

Consolidate the repeated 12.5555→dp_12_5 truncation example so it appears once authoritatively (e.g., only in the algorithm section) to further tighten token use.

Clarify handling for the noted edge cases (negative values, expressions like 10dp+2dp) with a concrete default or a one-line decision rule instead of only deferring to the user.

DimensionReasoningScore

Conciseness

Lean and purposeful with no padding about what dp/sp/dimen are; the repeated 12.5555→dp_12_5 example reinforces the one genuinely surprising rule (truncate, don't round) rather than explaining concepts Claude knows, so it stays at 'lean and efficient' rather than 'could be tightened'.

3 / 3

Actionability

Provides a deterministic two-step algorithm, a full mapping table (value→resource name→XML ref→code ref), and concrete rewrite examples like 'android:padding="12.5dp"' → '@dimen/dp_12_5', which is copy-paste-ready actionable guidance.

3 / 3

Workflow Clarity

The literal-to-resource-name algorithm is clearly sequenced with worked examples, but the skill involves XML/layout modification with no validation or feedback checkpoint (it explicitly skips verifying the dimen resource exists), so per the feedback-loop guidance for XML manipulation it caps at 2 rather than reaching the explicit-validation level.

2 / 3

Progressive Disclosure

A single well-sectioned SKILL.md under 50 lines with no external file references needed (none referenced, none bundled), so the simple-skill allowance lets well-organized sections score 3.

3 / 3

Total

11

/

12

Passed

Description

100%Weight 40%Scale 1-3

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 tight, specific description that states concrete conversion actions, the naming rule, and an explicit use-when trigger clause in directive third-person voice. It is distinctive and low conflict-risk within a clear Android niche.

DimensionReasoningScore

Specificity

Lists multiple concrete actions — '将硬编码 dp、sp 改为引用 @dimen/dp_*、@dimen/sp_* 与 R.dimen.*' — plus an explicit naming rule, matching the 'lists multiple specific concrete actions' anchor rather than the partial 'names domain and some actions' level.

3 / 3

Completeness

Clearly states what (convert dp/sp literals to dimen references with the naming rule) and an explicit when clause ('在用户要求…时使用'), satisfying the 'both what AND when with explicit triggers' anchor; not capped at 2 because the 'Use when' guidance is explicit.

3 / 3

Trigger Term Quality

Natural trigger phrases a user would say are present: '去掉魔法数', '统一 dimen', '替换 dp/sp 字面量', '规范化尺寸引用', giving good coverage rather than just 'some relevant keywords'.

3 / 3

Distinctiveness Conflict Risk

A narrow Android dp/sp→dimen niche with distinct triggers, unlikely to fire for unrelated skills; matches 'clear niche with distinct triggers' rather than the 'could overlap' level.

3 / 3

Total

12

/

12

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.

Validation16 / 16 Passed

Validation for skill structure

No warnings or errors.

Repository
afkT/DevUtils
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.