Agent skill

Choosing Causalpy Methods

by pymc-labs in pymc-labs/CausalPy

Choose the appropriate CausalPy experiment class from a causal or impact question, data structure, treatment assignment, and identification assumptions.

Apache-2.0Auto-check passedWriting & Content

Install Choosing Causalpy Methods

skills CLI
$ npx skills add pymc-labs/CausalPy --skill choosing-causalpy-methods -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install pymc-labs/CausalPy choosing-causalpy-methods --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/pymc-labs/CausalPy.git skills-src && mkdir -p .claude/skills && cp -r skills-src/causalpy/skills/choosing-causalpy-methods .claude/skills/choosing-causalpy-methods && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
choosing-causalpy-methods
GitHub stars
1.2k
Token cost
~1.4k tokens
SKILL.md length
635 words
Files
12
Skills in repo
12
Repo updated
First seen
Licence
Apache-2.0

At a glance

Choose the appropriate CausalPy experiment class from a causal or impact question, data structure, treatment assignment, and identification assumptions.

  • Works in 6 steps: Estimand: ATE, ATT, local threshold… → Assignment mechanism: known intervention… → Data topology: single outcome series,… → …
  • Tasks that involve Plain language and style rules
  • SKILL.md covers Required Intake, Routing Workflow, Output Contracts and References
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Choosing Causalpy Methods is an agent skill from pymc-labs/CausalPy. Choose the appropriate CausalPy experiment class from a causal or impact question, data structure, treatment assignment, and identification assumptions. Use before writing analysis code when the method is not yet settled, including plain-English questions about whether a campaign, policy, or intervention worked.

Its SKILL.md is about 1.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 13 other files (for example `reference/decision_tree.md`, `reference/disambiguation/did_vs_staggered_vs_panel.md` and `reference/disambiguation/ipw_vs_iv_vs_panel.md`).

It sits in Writing & Content, covering Plain language and style rules. The repository describes itself as: A Python package for causal inference in quasi-experimental settings. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Plain language and style rules

Example prompts

  • “/choosing-causalpy-methods”

Workflow steps

6 steps, taken from the first numbered list in SKILL.md.

  1. Estimand: ATE, ATT, local threshold effect, event-study path, cumulative post-period impact, baseline-adjusted group contrast, or…
  2. Assignment mechanism: known intervention time, common pre/post group treatment, staggered adoption, cutoff, kink, instrument, observed…
  3. Data topology: single outcome series, wide unit-by-time panel, long unit-time panel, cross-section, or single pre/post observations by…
  4. Controls: none, donor units, treated/control groups, never-treated cohorts, measured covariates, near-cutoff observations, or instruments.
  5. Identification support: pre-period history, donor support, overlap/positivity, no anticipation, absorbing treatment, no manipulation at…
  6. Backend/reporting constraints: whether the user needs OLS/sklearn, Bayesian uncertainty, effect_summary(), or a unified plot().

What it can do on your machine

Read from SKILL.md and the folder at commit f17b30f. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Choosing Causalpy Methods loads about 1.4k tokens when it runs. Until then it costs about 85 tokens; SKILL.md has 635 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~85
When it runs · the whole SKILL.md, loaded when a task matches
~1.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from pymc-labs/CausalPy at commit f17b30f, republished under its Apache-2.0 licence (© pymc-labs). 635 words, ~1,386 tokens.

Download SKILL.mdSave it as .claude/skills/choosing-causalpy-methods/SKILL.md (or your agent's skills folder). This skill also uses 11 other files; get the full folder from GitHub.
name
choosing-causalpy-methods
description
Choose the appropriate CausalPy experiment class from a causal or impact question, data structure, treatment assignment, and identification assumptions. Use before writing analysis code when the method is not yet settled, including plain-English questions about whether a campaign, policy, or intervention worked.

Choosing CausalPy Methods

Use this skill to translate a user's causal or impact question into a CausalPy experiment choice, including plain-English questions like "did the campaign work?", "what was the effect of the rollout?", or "did the policy change sales?". See Skill triggers for additional discovery keywords. This is the design-intake skill, not the implementation skill. Optimize for agent use: follow the ordered routing steps, prefer explicit uncertainty over force-fitting, and do not write analysis code until the method route is matched or the user has answered the key ambiguity. Once the method is chosen, hand off to running-causalpy-experiments for constructor details, model configuration, priors, summaries, plots, and interpretation.

Required Intake

Before naming a method, identify these facts. If the request is missing several, ask for the single most decision-relevant missing fact.

  1. Estimand: ATE, ATT, local threshold effect, event-study path, cumulative post-period impact, baseline-adjusted group contrast, or coefficient-level association.
  2. Assignment mechanism: known intervention time, common pre/post group treatment, staggered adoption, cutoff, kink, instrument, observed treatment with measured confounders, or no credible assignment story.
  3. Data topology: single outcome series, wide unit-by-time panel, long unit-time panel, cross-section, or single pre/post observations by unit or group.
  4. Controls: none, donor units, treated/control groups, never-treated cohorts, measured covariates, near-cutoff observations, or instruments.
  5. Identification support: pre-period history, donor support, overlap/positivity, no anticipation, absorbing treatment, no manipulation at cutoff, instrument validity, or baseline adjustment.
  6. Backend/reporting constraints: whether the user needs OLS/sklearn, Bayesian uncertainty, effect_summary(), or a unified plot().

Routing Workflow

Use the canonical routing algorithm in Decision tree. It is deliberately written as text/pseudocode, not a visual decision tree, so agents can follow it linearly. Do not skip from a keyword such as "time series" or "panel" directly to a class; route through assignment mechanism, data topology, controls, and disqualifiers.

When a route is close but not settled, use the disambiguation cards:

Output Contracts

Return exactly one of these outcomes.

Show full SKILL.md (286 more words)Show less
Matched
  • Recommended method: name one primary CausalPy experiment class.
  • Why it fits: tie the recommendation to estimand, assignment mechanism, data topology, and controls.
  • Disqualifiers checked: name the main alternatives rejected and why.
  • Required columns/data layout: list the minimal structure needed.
  • Key assumptions: state what must be credible for causal interpretation.
  • Main risks: name likely failure modes and sensitivity checks.
  • Next step: route to running-causalpy-experiments and the relevant method reference. If the user wants to stress-test the claim before trusting it, also suggest causal-detective.
Ambiguous
  • Candidate methods: name the top two plausible CausalPy classes.
  • What separates them: state the concrete distinction, such as forecast counterfactual vs segmented level/slope model.
  • Deciding question: ask one question that will resolve the route.
  • Next step: do not write analysis code until the user answers.
Not Identifiable Yet
  • Status: the method may exist in CausalPy, but the available data or assumptions are insufficient.
  • Missing requirement: name the specific missing design fact, such as no pre-period, no donor support, no overlap check, or no credible instrument.
  • Deciding question: ask for the missing fact or suggest what evidence would be needed.
  • Next step: do not force a method recommendation.
Not Implemented In CausalPy
  • Status: state "CausalPy has not implemented the right method."
  • Ideal method category: name the method family the user likely needs.
  • Why no CausalPy experiment fits: explain the mismatch with assignment, estimand, treatment type, data topology, or reporting needs.
  • Closest partial fit: mention a CausalPy class only if it is genuinely useful, and state its limitations.
  • What would unlock CausalPy: describe the data or assumption change that would make an implemented experiment appropriate.

References

© pymc-labs, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 11 other files in causalpy/skills/choosing-causalpy-methods of pymc-labs/CausalPy.

  • SKILL.md
  • reference/decision_tree.md
  • reference/disambiguation/did_vs_staggered_vs_panel.md
  • reference/disambiguation/ipw_vs_iv_vs_panel.md
  • reference/disambiguation/its_vs_piecewise_its.md
  • reference/disambiguation/its_vs_sc_vs_did.md
  • reference/disambiguation/prepostnegd_vs_did.md
  • reference/disambiguation/sc_vs_sdid.md
  • reference/experiment_decision_guide.md
  • reference/method_capability_matrix.md
  • reference/not_in_causalpy.md
  • reference/triggers.md

Open the folder on GitHubat commit f17b30f

Compare with similar skills

Choosing Causalpy Methods next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Choosing Causalpy Methods compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Choosing Causalpy Methods this skillpymc-labs/CausalPy1.2k—~1.4kAutomated safety check: PassApache-2.0
Asd Ste100danyuchn/asd-ste100-skill4k—~4.1kAutomated safety check: PassMIT
Simple Issue Descriptionevery-app/open-seo23k1 repos~1.2kAutomated safety check: PassMIT
Ponytail AuditDietrichGebert/ponytail158k—~1.3kAutomated safety check: PassMIT
Technical Writing Standardcursor/plugins10k10 repos~2.4kAutomated safety check: PassNone
Natural Japanese Business Writingcoji/natural-japanese1.9k—~2.1kAutomated safety check: PassMIT

Similar skills

  • Asd Ste100

    danyuchn/asd-ste100-skill

    A skill your agent uses when English text must be parsed without a human to resolve ambiguity — tool descriptions, error messages, inter-agent instructions, system prompts, status reports — and…

    4k GitHub stars~4.1k tokensUpdated 4 days ago
    Writing & ContentAuto-check passed
  • Simple Issue Description

    every-app/open-seo

    Turn a rough bug report, feature request, support note, or pull request into a short, plain-language issue focused on the problem and desired behavior.

    23k GitHub starsUsed in 1 repo~1.2k tokens
    Writing & ContentAuto-check passed
  • Ponytail Audit

    DietrichGebert/ponytail

    Quality audit of a whole repo: bugs, security holes, what breaks under real load, risky code without tests, slow paths, and what to delete, merge or split.

    158k GitHub stars~1.3k tokensUpdated yesterday
    Writing & ContentAuto-check passed
  • Official

    Applies four layers of technical-writing rules to docs, RFCs, readmes, PR descriptions and commit messages so a tired engineer follows them on the first read.

    10k GitHub starsUsed in 10 repos~2.4k tokens
    Writing & ContentAuto-check passed
  • Writes and edits Japanese business documents so they read clearly and naturally, removes AI-sounding phrasing and can score how AI-like a text reads.

    1.9k GitHub stars~2.1k tokensUpdated 1 mo ago
    Writing & ContentAuto-check passed
  • Pgjev

    realZachi/pg-jev

    Install, configure, query and explain pgjev (the jev PostgreSQL extension that filters, ranks and classifies rows with plain-language conditions via TypeSafe's Jev model).

    1k GitHub stars~2.9k tokensUpdated 2 days ago
    Writing & ContentAuto-check passed

More from pymc-labs/CausalPy

All 12 skills in this repo
  • Example Datasets

    pymc-labs/CausalPy

    Load built-in CausalPy example datasets for demos, tutorials, tests, and quick causal-analysis prototypes.

    1.2k GitHub stars~587 tokensUpdated yesterday
    Auto-check passed
  • Review PR

    pymc-labs/CausalPy

    Review CausalPy pull requests end-to-end by classifying PR type, checking branch freshness, mergeability, remote CI, correctness, security, tests, docs, and maintainer concerns.

    1.2k GitHub stars~2.2k tokensUpdated yesterday
    Auto-check passed
  • Causal Detective

    pymc-labs/CausalPy

    Challenge causal claims through structured threat assessment, counterfactual reasoning, and CausalPy falsification checks.

    1.2k GitHub stars~809 tokensUpdated yesterday
    Auto-check passed
  • Running Placebo Analysis

    pymc-labs/CausalPy

    Performs placebo-in-time sensitivity analysis with hierarchical null model and optional Bayesian assurance.

    1.2k GitHub starsUsed in 1 repo~442 tokens
    Auto-check passed
  • Python Environment

    pymc-labs/CausalPy

    Detect, configure, and use the project's Python environment (uv by default, conda-compatible tool as a fallback).

    1.2k GitHub stars~1.1k tokensUpdated yesterday
    Auto-check passed
  • Feature Exploration

    pymc-labs/CausalPy

    Explore unfamiliar APIs, libraries, or implementation behavior with minimal reproducible examples and documented findings.

    1.2k GitHub stars~442 tokensUpdated yesterday
    Auto-check passed

Questions about Choosing Causalpy Methods

What does Choosing Causalpy Methods do?

Choose the appropriate CausalPy experiment class from a causal or impact question, data structure, treatment assignment, and identification assumptions. Choosing Causalpy Methods is an agent skill from pymc-labs/CausalPy. Choose the appropriate CausalPy experiment class from a causal or impact question, data structure, treatment assignment, and identification assumptions.

When should I use Choosing Causalpy Methods?

Choosing Causalpy Methods fits situations like: tasks that involve Plain language and style rules.

How do I install Choosing Causalpy Methods in Claude Code?

Run `npx skills add pymc-labs/CausalPy --skill choosing-causalpy-methods -a claude-code`. Or copy the skill folder (causalpy/skills/choosing-causalpy-methods in pymc-labs/CausalPy) into .claude/skills/choosing-causalpy-methods in your project. Claude Code loads it when a task matches its description.

How do I install Choosing Causalpy Methods in Codex?

Run `npx skills add pymc-labs/CausalPy --skill choosing-causalpy-methods -a codex`. Or copy the skill folder (causalpy/skills/choosing-causalpy-methods in pymc-labs/CausalPy) into .agents/skills/choosing-causalpy-methods in your project. Codex loads it when a task matches its description.

Can I use Choosing Causalpy Methods in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add pymc-labs/CausalPy --skill choosing-causalpy-methods -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/choosing-causalpy-methods, .gemini/skills/choosing-causalpy-methods, .github/skills/choosing-causalpy-methods and .opencode/skills/choosing-causalpy-methods in your project.

What does Choosing Causalpy Methods need to run?

SKILL.md names no scripts, command-line tools or credentials: Choosing Causalpy Methods is instructions for the agent only.

Does Choosing Causalpy Methods access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Choosing Causalpy Methods safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Choosing Causalpy Methods use?

Choosing Causalpy Methods is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Choosing Causalpy Methods use?

About 1.4k tokens (SKILL.md is roughly 5.5k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Choosing Causalpy Methods?

Skills that share tags, products or a category with Choosing Causalpy Methods: Asd Ste100 (danyuchn/asd-ste100-skill, 4k stars), Simple Issue Description (every-app/open-seo, 23k stars), Ponytail Audit (DietrichGebert/ponytail, 158k stars) and Technical Writing Standard (cursor/plugins, 10k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Choosing Causalpy Methods?

pymc-labs (a GitHub organization) maintains it in pymc-labs/CausalPy, which has 1,201 GitHub stars. The repository holds 12 skills in this directory. The repository was last updated on October 7, 2026.

Source: pymc-labs/CausalPy on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.