Guide · Agent skill
How to use the cohort-analysis agent skill for retention
Updated · written with AI from the project's own documentation and checked against our catalogue data
The cohort-analysis skill teaches an AI agent to study how groups of users, such as everyone who signed up in the same month, keep using a product over time. You give the agent a CSV, Excel or JSON file of engagement data and it checks the data, calculates retention and feature adoption, draws charts and points out patterns such as early churn. This guide explains what a skill is, how to install this one, how to ask for an analysis and where its limits are.
Quick start
- 1Download the skill. Download the ZIP for the cohort-analysis skill from this page and unzip it so the SKILL.md file is available.
- 2Place the skill folder. Move the unzipped folder into ~/.claude/skills/ for personal use or into a project's .claude/skills/ folder. Alternatively, upload it in the Claude apps under Settings → Capabilities → Skills.
- 3Prepare your data. Export user engagement data as CSV, Excel, JSON or SQL query output, with a cohort identifier, a time dimension and engagement metrics. Remove or anonymize personal information first.
- 4Check Python if you need scripts. If you want analysis scripts, make sure Python with pandas and numpy is available where the agent runs.
- 5Make the request. Upload the file and describe the question in plain language, naming the columns and the output you want.
- 6Review the findings. Check the data summary and quality notes first, then read the patterns and verify important ones before acting on them.
What is an agent skill and what does this one do?
An agent skill is a folder containing a SKILL.md file with instructions that an AI agent loads when a request matches the skill's description. This skill's description is: perform cohort analysis on user engagement data, covering retention curves, feature adoption trends and segment-level insights.
Once triggered, the skill tells the agent to work in five steps: read and validate your data, generate quantitative analysis, create visualizations, identify insights and patterns, and suggest follow-up research.
- Checks cohort identifiers, time periods and engagement metrics, and looks for missing values and data quality issues
- Calculates cohort retention rates, feature adoption rates and period-over-period changes
- Generates retention heatmaps (cohorts against time periods) and line charts of cohort progression
- Flags early churn, late-stage engagement changes, feature adoption clusters and seasonal trends
- Suggests user interviews, feature surveys, session replays, win/loss analysis and A/B tests
How do you install the cohort-analysis skill?
Download the ZIP for this skill from this page and unzip it. The skill is a single file, SKILL.md, so the unzipped folder should contain that file. You can install it in one of three places:
- Personal skills folder: unzip into ~/.claude/skills/ so the skill is available across your projects
- Project skills folder: unzip into the .claude/skills/ folder of a specific project so it is shared with that project
- Claude apps: upload the skill under Settings → Capabilities → Skills
What do you need before you start?
The skill expects a user cohort dataset. Your file can be CSV, Excel, JSON, or the output of a SQL query. If you want the agent to produce analysis scripts, you also need Python with pandas and numpy installed on the machine where the agent runs code.
The data should include a cohort identifier, a time dimension and at least one engagement or retention metric. The skill's own tips recommend at least three to four cohorts for meaningful patterns, and recommend stating how cohorts are defined (for example signup month or feature launch date).
- A cohort dataset in CSV, Excel, JSON or SQL query output
- Python with pandas and numpy, only if you request analysis scripts
- Context about product changes, launches or events during the period
How do you trigger the skill with a natural request?
You do not need a special command. Describe your data and what you want to know, and mention retention, cohorts, feature adoption or churn so the agent matches the skill. Name the file you are uploading and the columns it contains.
The skill's examples show three request styles: a CSV with a question about why one quarter's cohorts underperform another, a plain-language description of monthly cohorts with a question about long-term retention, and an Excel file of feature adoption data asking which cohorts adopted fastest.
- Name the file and its columns, for example cohort_month, weeks_active, user_id, feature_x_usage, engagement_score
- Ask a specific question, such as which cohorts retain best long term
- Ask for the output you want: charts, a Python script or research recommendations
Analyze retention patterns in cohort_engagement.csv and identify why Q4 2025 cohorts underperform compared to Q3.What output should you expect?
The skill's output format lists the parts you should receive. Not every request produces every part; the analysis scripts appear only if you ask for them.
- Data Summary: cohort overview and data quality assessment
- Quantitative Findings: key metrics, retention rates and trend analysis
- Visualizations: charts showing retention curves and adoption patterns
- Pattern Identification: 2-3 significant insights
- Research Recommendations: qualitative and quantitative follow-ups
- Analysis Scripts (if requested): Python code for reproducible analysis
- Next Steps: prioritized actions based on findings
What are the safety notes?
This skill runs scripts, so review any code the agent writes before running it on your machine. It does not use the network, according to its listed requirements.
Your data is the bigger concern. Uploading raw user records to an AI tool may breach privacy rules. Anonymize or pseudonymize user identifiers and remove personal details before you upload.
- Review generated scripts before running them
- Anonymize user data before uploading it to an AI tool
- Treat outputs as directional, not as statistically tested conclusions
What tips give the best results?
Clear inputs produce clearer analysis. The skill's own guidance is to make the cohort definition explicit, provide data across several time periods, and include context about product changes during the period. Include more than one metric, such as retention, engagement, feature usage or revenue, because the skill can compare them.
- Include the time dimension: data across multiple periods
- Define cohorts explicitly: signup month, feature launch date and so on
- Explain launches and events that happened during the period
- Include several metrics, not just one
- Use at least 3-4 cohorts
- Ask for the specific outputs you need
What people use it for
- Checking whether users who signed up in newer months retain better or worse than older cohorts
- Comparing adoption curves for a new feature across launch periods to see which cohorts adopted fastest
- Producing a first-pass retention report with heatmaps for a product review
- Generating a reusable pandas script to rerun the same cohort analysis each month
- Planning user interviews with churning users after an early-churn pattern appears
Frequently asked questions
Is the cohort-analysis skill free?
The skill is published under the MIT licence, as listed on this page. Check the licence file in the source repository for full terms. Any AI service you use to run the skill may have its own pricing.
How do I install a Claude skill?
Download the ZIP from this page and unzip it into ~/.claude/skills/ or a project's .claude/skills/ folder. In the Claude apps you can instead upload it under Settings → Capabilities → Skills.
What data does the cohort analysis skill need?
It accepts CSV, Excel, JSON or SQL query output containing user cohort information. The data should include a cohort identifier, time periods and engagement metrics, with at least three to four cohorts for meaningful patterns.
Does the skill need Python?
Only if you request analysis scripts. Those scripts use pandas and numpy, so those libraries must be installed where the agent runs code.
Is it safe to upload user data?
Uploading raw user records to an AI tool may breach privacy rules. Anonymize identifiers and remove personal details before uploading, and review any scripts before running them.
Can the skill prove a retention difference is statistically significant?
Not as a rigorous test. The skill gives directional insight and its description does not mention significance testing, so an analyst should verify conclusions before making important decisions.
New agent skills, repos and AI tools — every week
The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.
Our verdict
Product managers, growth analysts and data analysts who want a fast first-pass retention and feature adoption report, with reusable pandas scripts, will find this skill useful. If you need statistically rigorous conclusions or must handle sensitive personal data without anonymizing it, pick a dedicated analytics tool or involve a specialist instead.
Download the skill