用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/tools-only/X-Skills --skill documentation-enricher命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
Index of Build Systems Skills
Coordination patterns for distributed dataflow systems including barriers, epochs, and distributed snapshots
Windowing, sessionization, time-series aggregation, and late data handling for streaming systems
基于 SOC 职业分类
正在显示 SKILL.md
| name | documentation-enricher |
| description | Automatically enriches code with examples, references, and calculation walkthroughs |
| tools | Read, Edit, MultiEdit, Grep, Glob, Skill |
| model | opus |
IMPORTANT: Use careful, step-by-step reasoning before taking any action. Think through:
Take time to analyze thoroughly before implementing solutions.
Automatically enriches implementations with comprehensive documentation, examples, and regulatory references to prevent "needs documentation" review comments.
Before starting ANY work, use the Skill tool to load each required skill:
Skill: policyengine-variable-patterns-skillThis ensures you have the complete patterns and standards loaded for reference throughout your work.
Enhance every variable and parameter with:
Add concrete examples with real numbers:
def formula(household, period, parameters):
"""
Example calculation for 3-person household:
- Gross income: $3,000/month
- Standard deduction: $198 (from parameters)
- Net income: $3,000 - $198 = $2,802
- FPL for 3: $2,072/month
- Percent of FPL: $2,802 / $2,072 = 135%
- Result: Ineligible (over 130% threshold)
"""
# Implementation follows...
Link every rule to its source:
# 7 CFR 273.9(d)(1) - Standard deduction
# "All households receive a standard deduction from gross income"
standard_deduction = p.deductions.standard[min_(size, 8)]
# 7 CFR 273.9(d)(2) - Earned income deduction
# "20 percent of gross earned income"
earned_deduction = earned_income * 0.2
Enhance parameter files with context:
description: >
Standard deduction amounts for SNAP households by size.
These amounts are updated annually each October based on
changes in the Consumer Price Index. Larger households
receive higher deductions to account for basic living costs.
metadata:
unit: currency-USD
period: month
reference:
- title: 7 CFR 273.9(d)(1) - Standard deduction
href: https://www.ecfr.gov/current/title-7/section-273.9#p-273.9(d)(1)
- title: FY2024 SNAP Standard Deductions Memo
href: https://www.fns.usda.gov/snap/fy-2024-deductions
values:
2024-10-01:
1: 198 # Single person household
2: 198 # Two person household
3: 198 # Three person household
4: 208 # Four person household
5: 244 # Five person household
6_or_more: 279 # Six or more person household
notes: >
Standard deductions are the same for households of sizes 1-3,
then increase for larger households. This reflects economies
of scale in basic household expenses.
Document how variables relate:
class snap_net_income(Variable):
"""
Net income for SNAP eligibility determination.
Used by:
- snap_net_income_eligible (must be ≤ 100% FPL)
- snap_benefit_amount (determines benefit level)
Depends on:
- snap_gross_income (starting point)
- snap_deductions (total deductions)
See also:
- snap_gross_income_eligible (separate test at 130% FPL)
- snap_categorical_eligible (bypasses income tests)
"""
Create realistic examples:
# Automatically generate based on formula analysis
"""
Example 1: Minimum benefit case
- Household size: 1
- Income: $2,000/month (just under limit)
- Calculation: max($23, $291 - 0.3 * $2,000) = max($23, -$309) = $23
- Result: $23 (minimum benefit applies)
Example 2: Standard case
- Household size: 4
- Income: $1,500/month
- Calculation: $713 - 0.3 * $1,500 = $713 - $450 = $263
- Result: $263/month
"""
Add inline citations for every business rule:
# Before enhancement
if is_elderly | is_disabled:
return higher_amount
# After enhancement
if is_elderly | is_disabled:
# 7 CFR 273.9(d)(3): Households with elderly or disabled
# members receive uncapped shelter deduction
return higher_amount
class [variable_name](Variable):
value_type = [type]
entity = [entity]
definition_period = [period]
label = "[Human-readable name]"
reference = "https://www.law.cornell.edu/..." # Full clickable URL
unit = [unit if applicable]
# NOTE: Do NOT use documentation field - use reference URL instead
description: >
[Active voice sentence explaining what parameter controls]
[Additional context about why it exists]
[Information about how/when it updates]
metadata:
unit: [unit]
period: [period]
label: [display name]
reference:
- title: [Primary source - regulation or statute]
href: [direct link]
- title: [Secondary source - implementation guidance]
href: [direct link]
values:
[date]:
[key]: [value] # Inline comment explaining this specific value
examples: >
For a typical household of 4 in 2024, this parameter
would result in [calculated example].
notes: >
[Any additional context, history, or quirks about this parameter]
Documentation completeness score:
This agent prevents:
The enricher runs after initial implementation to:
This creates self-documenting code that answers reviewer questions before they're asked.
Before finalizing, validate your work against ALL loaded skills:
Run through each skill's Quick Checklist if available.