Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
brycewang-stanford avatar

Codebook

  • 1 installs
  • 3.2k repo stars
  • Updated August 4, 2026
  • brycewang-stanford/awesome-agent-skills-for-empirical-research

codebook is a skill that auto-generates a Markdown codebook of variable types and summary statistics from a dataset.

About

codebook is a skill that auto-generates a Markdown codebook documenting the variables in a dataset. A researcher uses it to produce a variable reference with types and summary statistics from a CSV, Stata, Excel, or Parquet file. It reads the data read-only and outputs a summary table plus per-variable detail sections with description placeholders.

  • Auto-generates a Markdown codebook from a dataset
  • Supports CSV, Stata, Excel, and Parquet inputs
  • Documents variable types and summary statistics, read-only on source data

Codebook by the numbers

  • 1 all-time installs (skills.sh)
  • Ranked #1,361 of 1,879 Documentation skills by installs in the Skillselion catalog
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
At a glance

codebook capabilities & compatibility

Capabilities
data documentation · codebook generation
Use cases
documentation · data analysis
Pricing
Free
From the docs

What codebook says it does

Auto-generates a Markdown codebook from a dataset (CSV, DTA, Excel, Parquet) with types and summary statistics. Use when documenting variables.
SKILL.md
Never modify the source data file. This command is read-only with respect to data.
SKILL.md
npx skills add https://github.com/brycewang-stanford/awesome-agent-skills-for-empirical-research --skill codebook

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs1
repo stars3.2k
Last updatedAugust 4, 2026
Repositorybrycewang-stanford/awesome-agent-skills-for-empirical-research

What it does

Auto-generate a Markdown codebook of variable types and summary statistics from a CSV, Stata, Excel, or Parquet dataset.

Who is it for?

Documenting dataset variables with types and summary statistics

When should I use this skill?

Generating a Markdown codebook for a dataset file

What you get

A Markdown codebook with a summary table and per-variable statistics and description placeholders.

  • Markdown codebook file
  • variable summary table

By the numbers

  • 4 supported dataset formats (CSV, DTA, Excel, Parquet)
  • top 5 frequent values per categorical variable

Files

SKILL.mdMarkdownGitHub ↗

Generate Variable Codebook

Auto-generate a Markdown codebook documenting all variables in a dataset.

Arguments

  • $ARGUMENTS — path to a dataset file (e.g., data/rawData/sample_data.csv, data/panel.dta)

Steps

1. Determine the file format from the extension:

  • .csv — read with pandas read_csv
  • .dta — read with pandas read_stata
  • .xlsx / .xls — read with pandas read_excel
  • .parquet — read with pandas read_parquet
  • Other formats: ask the user how to load it

2. Load the dataset using uv run python and extract metadata for each variable:

  • Variable name
  • Data type (numeric, string, categorical, datetime)
  • Non-missing count and missing count
  • Number of unique values
  • For numeric variables: min, max, mean, median, standard deviation
  • For categorical/string variables: top 5 most frequent values with counts
  • For datetime variables: min and max date

3. Generate a Markdown codebook with:

  • Header: Dataset name, file path, number of observations, number of variables, date generated
  • Summary table: Variable name | Type | Non-missing | Unique | Description (placeholder)
  • Detailed sections per variable: Full statistics and a [FILL: description] placeholder for the user to add a human-readable description

4. Derive the output filename from the dataset name:

  • data/rawData/sample_data.csvreferences/sample-data-codebook.md

5. Save to references/<dataset-name>-codebook.md

6. Report the file path and the number of variables documented.

Error handling

  • If the file does not exist, report the error and suggest checking the path.
  • If the file cannot be read (corrupt, unsupported format), report the error and ask for guidance.
  • Never modify the source data file. This command is read-only with respect to data.

Related skills

Documentationanalytics

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.