evo-trend-anomaly-causal-inference

evo-trend-anomaly-causal-inference is a skill for Claude Code, Codex from OpenLAIR/OpenSkill. It costs 47 tokens per session (731 once invoked), scanned A, original, Apache-2.0.

An analysis pipeline for finding unusual changes in e-commerce spending by product category and examining possible demographic explanations. It uses forecasting and Difference-in-Differences, a statistical method for comparing changes between groups over time.

In plain words
What is it for?
Use it to clean purchase and survey data, measure spending deviations, encode demographic features, and study changes in purchase amounts or purchase likelihood.
Why use it?
It combines data cleaning, unusual-pattern detection, and causal analysis instead of requiring separate manual steps.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to clean purchase and survey data, measure spending deviations, encode demographic features, and study changes in purchase amounts or purchase likelihood.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/openlair/openskill/evo-trend-anomaly-causal-inference
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add OpenLAIR/OpenSkill --skill evo-trend-anomaly-causal-inference
Clone the repo
git clone --depth 1 https://github.com/OpenLAIR/OpenSkill

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for evo-trend-anomaly-causal-inference

README.md
[![agentmods](https://agentmods.dev/badge/skills/openlair/openskill/evo-trend-anomaly-causal-inference/github.svg)](https://agentmods.dev/skills/openlair/openskill/evo-trend-anomaly-causal-inference)
Your own site
<a href="https://agentmods.dev/skills/openlair/openskill/evo-trend-anomaly-causal-inference"><img src="https://agentmods.dev/badge/skills/openlair/openskill/evo-trend-anomaly-causal-inference/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for evo-trend-anomaly-causal-inference

Your own site · 80×15
<a href="https://agentmods.dev/skills/openlair/openskill/evo-trend-anomaly-causal-inference"><img src="https://agentmods.dev/badge/skills/openlair/openskill/evo-trend-anomaly-causal-inference.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 731 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00047 $0.00731
Opus 5.5 $0.00019 $0.00292
Sonnet 5.5 $0.00009 $0.00146
Haiku 4.5 $0.00005 $0.00073

Measured 2mo ago against content hash 3b9d3aac068c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

evo-trend-anomaly-causal-inference scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2mo ago.

The scan reads SKILL.md. This mod also ships 3 executable files (scripts/anomaly_detection.py, scripts/clean_data.py, scripts/feature_engineering.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

subprocess.run(['python3', '/app/environment/skills/evo-trend-anomaly-causal-inference/scripts/clean_data.py'], check=True)
tasks-evolved/trend-anomaly-causal-inference/environment/skills/evo-trend-anomaly-causal-inference/SKILL.md · 49 lines

How it starts

The opening of the file, as written. The whole thing — 49 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Evo Trend Anomaly Causal Inference

Complete pipeline for identifying anomalous product category spending patterns and using DiD causal inference to explain anomalies through demographic factors.

Pipeline Steps

  1. Data Cleaning (scripts/clean_data.py): Clean survey and purchase data, handling duplicates, missing values, inconsistent formatting, date parsing, monetary columns, and category extraction.
  2. Anomaly Detection (scripts/anomaly_detection.py): Prophet-based counterfactual forecasting to compute deviation index (-100 to 100) per category for March 2020.
  3. Feature Engineering (scripts/feature_engineering.py): One-hot/ordinal encode demographics, bin continuous variables, produce feature-engineered survey CSV.
  4. DiD Analysis (scripts/did_analysis.py): Difference-in-Differences causal analysis for intensive margin (univariate DiD on spend among purchasers) and extensive margin (multivariate heterogeneous DiD on purchase propensity).

Usage

import subprocess
subprocess.run(['python3', '/app/environment/skills/evo-trend-anomaly-causal-inference/scripts/clean_data.py'], check=True)
subprocess.run(['python3', '/app/environment/skills/evo-trend-anomaly-causal-inference/scripts/anomaly_detection.py'], check=True)
subprocess.run(['python3', '/app/environment/skills/evo-trend-anomaly-causal-inference/scripts/feature_engineering.py'], check=True)
subprocess.run(['python3', '/app/environment/skills/evo-trend-anomaly-causal-inference/scripts/did_analysis.py'], check=True)

Key Design Decisions

  • Survey IDs are case-sensitive (R_ prefix preserved)
  • hh-size outliers (53, 33, etc.) capped using IQR method
  • Prophet trained on all pre-March 2020 data only; cmdstanpy logging suppressed
  • Anomaly index: 100 * tanh(raw_deviation) for [-100, 100] range
  • Binary variable one-hot: remove negative indicator (e.g., _No, _Female) to avoid dummy variable trap
  • Intensive margin: purchasers only (Total_Spend > 0), sum spending per user-category-period
  • Extensive margin: full cross-join of all survey users × selected categories × periods
  • Univariate DiD for intensive margin (robust to small samples), multivariate heterogeneous DiD for extensive margin
  • Surge drivers sorted descending, slump drivers sorted ascending by DiD estimate
  • JSON serialization uses custom NpEncoder to handle numpy types
  • Robust error handling: skips categories with insufficient data, handles singular matrices, validates variance before regression

Read the full file on GitHub · 49 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2mo ago First seen · 49 lines · 47 tokens per session scan A 3b9d3aac068c

Subscribe to this mod's changes

evo-trend-anomaly-causal-inference is a skill published in the GitHub repository OpenLAIR/OpenSkill (101 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 47 tokens to every session and 731 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-11.

Related

evo-trend-anomaly-causal-inference compared with skills from other repositories

evo-trend-anomaly-causal-inference next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
evo-trend-anomaly-causal-inferenceOpenLAIR/OpenSkillSkill1012mo agoApache-2.0A47Claude Code, Codex
stripe-bfcm-dashboardstripe/aiSkill2.1k5d agoMITA120Claude Code, Codex
stripe-best-practicesstripe/aiSkill2.1k5d agoMITA161Claude Code, Codex
inventory.countXiaoLuoLYG/GODSkill1.3k5d agoApache-2.0A10Claude Code, Codex
shop.runXiaoLuoLYG/GODSkill1.3k5d agoApache-2.0A11Claude Code, Codex
stall.runXiaoLuoLYG/GODSkill1.3k5d agoApache-2.0A13Claude Code, Codex
Cursor rules for MedusaAmariahAK/atlarix-skillsSkill02mo agoApache-2.0A5Claude Code, Codex