Use this skill when the user needs to organize questionnaire items, scale dimensions, variable names, scoring rules, reverse-scored items, or data-entry specifications for psychology, education, public-health, social-science, or student research projects.
The core output is a clean codebook that can be copied into Word, Excel, SPSS, R, Mplus, or a research protocol.
Activate this skill when the user asks for any of the following:
When the user provides questionnaire items, output the following sections unless they request a different format:
Provide a TSV table with these columns:
variable, item_id, dimension, item_text, response_range, reverse_scored, scoring_note, missing_rule.
Explain how to compute dimension scores and total scores. State whether to use sum scores or mean scores. If missing-value rules are not provided, recommend a transparent rule such as "calculate the mean score only when at least 80% of items in the dimension are non-missing".
List reverse-scored variables and give the formula. For a 1–5 item, use reversed = 6 - original. For a 0–4 item, use reversed = 4 - original.
Provide short, readable variable names. Avoid spaces, Chinese punctuation, hyphens, and overly long names. Use prefixes such as dep_, anx_, smu_, sleep_, neuro_, or eant_ when relevant.
Mention duplicate item IDs, inconsistent response ranges, missing dimensions, and reverse-scoring ambiguity.
dep_01, dep_02, anx_01.For an item with minimum min and maximum max:
reversed_score = min + max - original_score
Common examples:
reverse = 6 - original.reverse = 8 - original.reverse = 4 - original.reverse = 10 - original.Use the user's stated rule when available. If no rule is given:
This skill includes scripts/make_codebook.py, which converts a simple CSV item file into a Markdown codebook and a TSV variable map. It uses only Python standard-library modules.
Input CSV columns:
item_id,item_text,dimension,scale_min,scale_max,reverse
Example command:
python3 scripts/make_codebook.py examples/demo_items.csv --out-dir output
If python3 is not available, try:
python scripts/make_codebook.py examples/demo_items.csv --out-dir output
共 1 个版本