Agent skill

Bi Retention Analysis

by agentscope-ai in agentscope-ai/QwenPaw-Data

对留存执行完整的分析流程,算清楚用户留不留、留多少、有没有变化,含口径定义、取数、留存率计算,及可选的维度拆分与对比/归因。触发条件:对话涉及留存率分析、留存表现评估、留存变化归因等任务时触发,如出现「留存表现情况如何」「访问留存和使用留存对比怎么样」「不同国家的访问留存是否存在差异」「分维度后留存情况」「次日/第七日留存率变化」等相似问题时触发。

Apache-2.0Auto-check passedData & Analytics

Install Bi Retention Analysis

skills CLI
$ npx skills add agentscope-ai/QwenPaw-Data --skill bi-retention-analysis -a claude-code

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

GitHub CLI
$ gh skill install agentscope-ai/QwenPaw-Data bi-retention-analysis --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/agentscope-ai/QwenPaw-Data.git skills-src && mkdir -p .claude/skills && cp -r skills-src/packages/qwenpaw-data-skills/skills/workflows/bi-retention-analysis .claude/skills/bi-retention-analysis && 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
bi-retention-analysis
GitHub stars
127
Token cost
~978 tokens
SKILL.md length
286 words
Files
1
Skills in repo
29
Repo updated
First seen
Licence
Apache-2.0

At a glance

对留存执行完整的分析流程,算清楚用户留不留、留多少、有没有变化,含口径定义、取数、留存率计算,及可选的维度拆分与对比/归因。触发条件:对话涉及留存率分析、留存表现评估、留存变化归因等任务时触发,如出现「留存表现情况如何」「访问留存和使用留存对比怎么样」「不同国家的访问留存是否存在差异」「分维度后留存情况」「次日/第七日留存率变化」等相似问题时触发。

  • Works in 6 steps: 定义口径 → 取数 → 计算留存率 → …
  • Tasks that involve Product analytics
  • SKILL.md covers 前置条件, 分析原则, 1. 定义口径 and 2. 取数, plus 4 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

Bi Retention Analysis is an agent skill from agentscope-ai/QwenPaw-Data. 对留存执行完整的分析流程,算清楚用户留不留、留多少、有没有变化,含口径定义、取数、留存率计算,及可选的维度拆分与对比/归因。触发条件:对话涉及留存率分析、留存表现评估、留存变化归因等任务时触发,如出现「留存表现情况如何」「访问留存和使用留存对比怎么样」「不同国家的访问留存是否存在差异」「分维度后留存情况」「次日/第七日留存率变化」等相似问题时触发。

Its SKILL.md is about 980 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Data & Analytics, covering Product analytics. The repository describes itself as: Agentic enterprise data analytics: governed facts (DataBridge), reusable methodology (Skill-Hub), and controllable execution (Host). The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Product analytics

Example prompts

  • “/bi-retention-analysis”

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. 定义口径
  2. 取数
  3. 计算留存率
  4. (可选)拆分维度
  5. (可选)对比 / 归因
  6. 解读 & 输出

What it can do on your machine

Read from SKILL.md and the folder at commit e0bae36. 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 (its code samples are csv).

    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

Bi Retention Analysis loads about 978 tokens when it runs. Until then it costs about 49 tokens; SKILL.md has 286 words of instructions outside code blocks.

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

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 agentscope-ai/QwenPaw-Data at commit e0bae36, republished under its Apache-2.0 licence (© agentscope-ai). 286 words, ~978 tokens.

Download SKILL.mdSave it as .claude/skills/bi-retention-analysis/SKILL.md (or your agent's skills folder).
name
bi-retention-analysis
description
对留存执行完整的分析流程,算清楚用户留不留、留多少、有没有变化,含口径定义、取数、留存率计算,及可选的维度拆分与对比/归因。触发条件:对话涉及留存率分析、留存表现评估、留存变化归因等任务时触发,如出现「留存表现情况如何」「访问留存和使用留存对比怎么样」「不同国家的访问留存是否存在差异」「分维度后留存情况」「次日/第七日留存率变化」等相似问题时触发。

bi-retention-analysis

对留存执行完整的分析流程,核心目标是算清楚用户留不留、留多少、有没有变化:定义口径 → 取数 → 计算留存率 →(可选)拆分维度 →(可选)对比/归因 → 解读与输出。

前置条件

开始执行前,确认以下信息已就绪:

  • 留存锚点明确,即作为 day0 的起算时间点(如注册日、首次访问、首次付费等)已定义
  • 留存事件已确定,即衡量「留下来」的行为(如再次访问、再次使用、再次付费等)口径清晰
  • 留存窗口已确定(如次日、7 日、30 日等),对应 day0 / dayn 口径清晰
  • 数据获取能力可用,能取到计算留存率所需的 CSV 或等价数据
  • 分析范围明确,包括时间窗口、对象范围,以及是否需要拆分维度或做对比

若留存锚点、留存事件或留存窗口不明确,需先回到规划阶段补充,或向用户确认后再开始执行。

分析原则

主要步骤
步骤用途是否必选
定义口径确定锚点、留存事件、留存窗口必选,见步骤 1
取数按口径取 day0 / dayn 数据必选,见步骤 2
计算留存率计算 day0 用户在 dayn 的留存率必选,见步骤 3
拆分维度按渠道、端、国家、版本等分别计算可选,见步骤 4
对比/归因跨时间、群体等维度对比留存差异可选,见步骤 5
解读 & 输出留存曲线、关键节点、变化趋势、差异结论必选,见步骤 6

典型产出:留存率表、留存曲线、分维度留存对比。

最短路径:定义口径 → 取数 → 算留存率 → 看曲线 / 报数字(即步骤 1 → 2 → 3 → 6,跳过步骤 4、5)。

本 workflow 主要提供留存分析场景下的编排与数据衔接逻辑,各步骤的具体执行按相应分析方法的标准流程进行。


1. 定义口径

明确留存分析的三要素,这是后续取数与计算的基础:

要素含义常见取值
锚点(day0)用户被纳入留存统计的起算时间点注册日、首次访问、首次付费等
留存事件衡量「留下来」的目标行为再次访问、再次使用、再次付费等
留存窗口在锚点后第几天考察留存次日(D1)、7 日(D7)、30 日(D30)等

要点:

  • 同一分析可包含多个留存窗口(如同时看 D1/D7/D30 以绘制留存曲线)
  • 同一分析可包含多种留存事件(如访问留存 vs 使用留存),需分别定义口径
  • 口径一旦确定,后续取数、计算、对比须保持一致,避免分子分母错配

2. 取数

按步骤 1 确定的口径取数,准备留存率计算所需的数据。

数据准备

整理 CSV,包含:

  • 第 0 天用户数(分母,即锚点当日纳入统计的用户数,如当日新增用户数、当日首次访问用户数)
  • 第 n 天留存用户数(分子,即上述用户在 dayn 仍触发留存事件的用户数)
  • 如需多个留存窗口或多种留存事件,分别取对应的分子列

示例:

csv
date,当日新增用户数,次日访问用户数,7日访问用户数
2025-01-01,10000,3000,1500
2025-01-02,10500,3200,1600

若计划在步骤 4 拆分维度,取数时一并带出维度列(如渠道、端、国家、版本),或按维度分别取数。


3. 计算留存率

计算 day0 用户在后续第 n 天的留存率。

计算执行
  • 对每个需要报告的留存率指标(如次日留存、第 7 日留存、访问留存 vs 使用留存)按留存率公式(dayn 留存用户数 / day0 用户数)或可用脚本进行计算
  • 不遗漏任何必要的留存窗口与留存事件
  • 多窗口时,输出可绘制留存曲线的结果(如 D1/D3/D7/D14/D30 各点留存率)
  • 保存计算结果

若已规划拆分维度,可在此步先算整体留存率,维度拆分在步骤 4 展开。


4. (可选)拆分维度

根据分析要求,判断是否需要按维度分别计算留存率:

需要拆分 → 按维度分别计算,完成后进入步骤 5 无需拆分 → 跳过本步骤,直接进入步骤 5(最短路径在此跳过)

判断依据
信号示例
按已有维度拆分「按渠道/端/国家/版本看留存」(维度已在数据中,直接分组计算)
需发现未知用户子结构「哪些用户群体留存更高」「用户自然分群后的留存差异」(走聚类分群)
多维特征综合分群需结合多个用户属性(消费、活跃、渠道等)划分群体再算留存(走聚类分群)
信号示例
仅看整体「整体次日留存如何」
仅关注时间趋势「最近一周留存率变化」(走步骤 5 时间对比,无需拆分维度)
拆分执行(若启用)
  • 按已有维度拆分:以维度列(渠道 / 端 / 国家 / 版本等)为分组键,对每个维度值分别按步骤 3 计算留存率
  • 按用户特征分群:整理用户级 CSV(对象标识列 + 分群特征列),对用户进行分群并将结果保存为 JSON,再按用户 ID 关联留存数据,按群分别准备 day0 / dayn 用户数后计算留存率
  • 保留各维度 / cohort 及总体(若需要)的结果,供步骤 5 对比与步骤 6 输出

5. (可选)对比 / 归因

根据分析要求,判断是否需对不同时间、群体、地区等进行留存率对比:

需要对比 → 进行对比分析,完成后进入步骤 6 不需要对比 → 跳过本步骤,直接进入步骤 6

判断依据
信号示例
时间维度对比「环比/同比变化」「最近 vs 历史」「留存率是否下降」
群体/空间维度对比「不同国家/渠道/端/版本/实验组留存差异」「访问留存 vs 使用留存」「A 群 vs B 群」
显式对比/差异/优劣「对比」「差异」「哪个更高/更低」「是否显著」
信号示例
仅报告当前水平「当前次日留存是多少」「整体留存表现如何」(步骤 3 结果已足够)
单一对象无参照只有一个时间点、一个群体,无对比参照物
对比执行(若启用)
  1. 基于步骤 3 / 4 的留存率结果,整理 对比分析用 CSV:
    • 时间对比:每列对应一个时期,或一列时间序列供环比/同比计算
    • 空间对比:每列对应一个国家/渠道/端/版本/cohort/留存类型(访问 vs 使用)等
  2. 选择合适比较维度(时间 / 空间 / 标准)与计算方式(绝对差值 / 相对差值)执行对比分析
  3. 多样本时按显著性检验规则执行
  4. 保存对比分析结果

示例(不同国家次日留存对比):

csv
业务日期,中国次日留存率,美国次日留存率
20251101,0.3856,0.4343
20251102,0.4288,0.4122

6. 解读 & 输出

完成以上步骤后,围绕留不留、留多少、有没有变化汇总并输出。

字段说明
执行内容本步骤做了什么(含跳过的可选步骤及原因)
取数文件原始数据路径
中间产物分群 JSON(若执行)、对比用 CSV(若执行)
计算结果留存率及对比分析结果路径
结论留存率水平、关键节点、变化趋势、群体差异及显著性

汇总结构建议:

  1. 分析范围:时间窗口、口径定义(锚点 / 留存事件 / 留存窗口)、是否拆分维度、是否做对比
  2. 留存率结果:整体及各维度/cohort 的留存率水平,含关键节点(如次日、第 7 日)与留存曲线
  3. 对比发现(若执行步骤 5):时间变化幅度、群体间差异、显著性结论
  4. 业务解读:留存表现评价、关键驱动因素与可执行建议
  5. 局限与不确定性:样本量、口径差异、分群稳定性、未覆盖维度等

© agentscope-ai, 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

Just SKILL.md in packages/qwenpaw-data-skills/skills/workflows/bi-retention-analysis of agentscope-ai/QwenPaw-Data.

Open the folder on GitHubat commit e0bae36

Compare with similar skills

Bi Retention Analysis 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.

Bi Retention Analysis compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Bi Retention Analysis this skillagentscope-ai/QwenPaw-Data127—~978Automated safety check: PassApache-2.0
PostHog CLI Queriesdebugtheworldbot/keyStats1.5k—~1.2kAutomated safety check: PassMIT
Retentioneering Contributingretentioneering/retentioneering-tools927—~1.8kAutomated safety check: PassApache-2.0
Retentioneering Product Analyticsretentioneering/retentioneering-tools927—~1.6kAutomated safety check: PassApache-2.0
Feature Analytics Instrumentation Plannermistralai/mistral-vibe5.1k—~2.2kAutomated safety check: PassApache-2.0
Funnel Analysisliangdabiao/claude-data-analysis-ultra-main2901 repos~781Automated safety check: NotesNone

Similar skills

  • PostHog CLI Queries

    debugtheworldbot/keyStats

    Runs HogQL queries against this project's PostHog data from the terminal using posthog-cli, with bundled scripts for dashboard metadata the CLI itself has no command for.

    1.5k GitHub stars~1.2k tokensUpdated 8 days ago
    Data & AnalyticsAuto-check passed
  • Retentioneering Contributing

    retentioneering/retentioneering-tools

    Help the user turn their Retentioneering ideas, friction reports, bug findings, or feature needs into high-quality upstream contributions: from capturing and validating the idea, through minimal…

    927 GitHub stars~1.8k tokensUpdated 3 days ago
    Data & AnalyticsAuto-check passed
  • Retentioneering Product Analytics

    retentioneering/retentioneering-tools

    Analyze event logs, clickstreams, user paths, product funnels, retention, behavioral segments, transition graphs, step matrices, sequence patterns, and customer journeys using Retentioneering.

    927 GitHub stars~1.6k tokensUpdated 3 days ago
    Data & AnalyticsAuto-check passed
  • Official

    Plans which analytics events and properties a new feature needs, checks them against the existing event registry, and verifies them per environment.

    5.1k GitHub stars~2.2k tokensUpdated yesterday
    Data & AnalyticsAuto-check passed
  • Funnel Analysis

    liangdabiao/claude-data-analysis-ultra-main

    Analyze user conversion funnels, calculate step-by-step conversion rates, create interactive visualizations, and identify optimization opportunities.

    290 GitHub starsUsed in 1 repo~781 tokens
    Data & AnalyticsAuto-check: notes
  • Event Tracking

    linuxfoundation/insights

    Add event tracking calls to Vue/Nuxt components in the Insights app using the useTrackEvent composable.

    282 GitHub stars~1.9k tokensUpdated 9 days ago
    Data & AnalyticsAuto-check passed

More from agentscope-ai/QwenPaw-Data

All 29 skills in this repo
  • Bi Report Generation

    agentscope-ai/QwenPaw-Data

    将 BI 数据分析结果组织成可视化 HTML 报告。当分析完成、需要生成报告时调用. An agent skill from agentscope-ai/QwenPaw-Data.

    127 GitHub stars~1.2k tokensUpdated 5 days ago
    Auto-check passed
  • Fetch Data

    agentscope-ai/QwenPaw-Data

    取数 / 查数据 / 拉数据 / 跑 SQL。把自然语言取数需求转为 SQL,经数据湖仓执行后返回查询结果供下游分析。任何需要业务数据的任务在工作区缺少对应文件时都必须先调用此技能——覆盖 BI 业务分析、留存 / 转化 / 同期群分析、数据探索 EDA、统计建模、定量计算、元数据查询、数据查询。命中任一即触发:(1) 直接索要指标或记录,如「DAU 多少」「上月销售额」「3…

    127 GitHub stars~2.5k tokensUpdated 5 days ago
    Auto-check passed
  • Bi Adaptive Threshold

    agentscope-ai/QwenPaw-Data

    通过量化历史数据的自然波动幅度,自适应计算判定阈值。当需要从数据本身确定阈值(如波动阈值、影响度阈值等)、而非使用固定值时调用。仅适用于日/周粒度阈值确定。

    127 GitHub stars~726 tokensUpdated 5 days ago
    Auto-check passed
  • Bi Anomaly Detection

    agentscope-ai/QwenPaw-Data

    基于阈值检测时间序列中的显著异常波动点。当需要找出指标异常波动日期、识别数据异动时调用. An agent skill from agentscope-ai/QwenPaw-Data.

    127 GitHub stars~637 tokensUpdated 5 days ago
    Auto-check passed
  • Bi Attribution Analysis

    agentscope-ai/QwenPaw-Data

    计算各维度(组)值对指标变动的贡献度,支持可加型量值指标和加权平均型/率值指标。当需要计算贡献度、解释指标"为什么涨/跌"时调用。

    127 GitHub stars~1.2k tokensUpdated 5 days ago
    Auto-check passed
  • Bi Causal Attribution

    agentscope-ai/QwenPaw-Data

    从运营周报、活动文档、对话输入或文档工具 API 中提取业务事件,与指标异常时间窗口对齐,生成有证据支撑的因果归因假设并排序。当已知指标存在异常波动、需要从外部文档证据中解释"为什么"时调用。

    127 GitHub stars~1.3k tokensUpdated 5 days ago
    Auto-check passed

Questions about Bi Retention Analysis

What does Bi Retention Analysis do?

对留存执行完整的分析流程,算清楚用户留不留、留多少、有没有变化,含口径定义、取数、留存率计算,及可选的维度拆分与对比/归因。触发条件:对话涉及留存率分析、留存表现评估、留存变化归因等任务时触发,如出现「留存表现情况如何」「访问留存和使用留存对比怎么样」「不同国家的访问留存是否存在差异」「分维度后留存情况」「次日/第七日留存率变化」等相似问题时触发。. Bi Retention Analysis is an agent skill from agentscope-ai/QwenPaw-Data.

When should I use Bi Retention Analysis?

Bi Retention Analysis fits situations like: tasks that involve Product analytics.

How do I install Bi Retention Analysis in Claude Code?

Run `npx skills add agentscope-ai/QwenPaw-Data --skill bi-retention-analysis -a claude-code`. Or copy the skill folder (packages/qwenpaw-data-skills/skills/workflows/bi-retention-analysis in agentscope-ai/QwenPaw-Data) into .claude/skills/bi-retention-analysis in your project. Claude Code loads it when a task matches its description.

How do I install Bi Retention Analysis in Codex?

Run `npx skills add agentscope-ai/QwenPaw-Data --skill bi-retention-analysis -a codex`. Or copy the skill folder (packages/qwenpaw-data-skills/skills/workflows/bi-retention-analysis in agentscope-ai/QwenPaw-Data) into .agents/skills/bi-retention-analysis in your project. Codex loads it when a task matches its description.

Can I use Bi Retention Analysis 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 agentscope-ai/QwenPaw-Data --skill bi-retention-analysis -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/bi-retention-analysis, .gemini/skills/bi-retention-analysis, .github/skills/bi-retention-analysis and .opencode/skills/bi-retention-analysis in your project.

What does Bi Retention Analysis need to run?

SKILL.md names no scripts, command-line tools or credentials: Bi Retention Analysis is instructions for the agent only.

Does Bi Retention Analysis 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 Bi Retention Analysis 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 Bi Retention Analysis use?

Bi Retention Analysis 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 Bi Retention Analysis use?

About 978 tokens (SKILL.md is roughly 3.9k 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 Bi Retention Analysis?

Skills that share tags, products or a category with Bi Retention Analysis: PostHog CLI Queries (debugtheworldbot/keyStats, 1.5k stars), Retentioneering Contributing (retentioneering/retentioneering-tools, 927 stars), Retentioneering Product Analytics (retentioneering/retentioneering-tools, 927 stars) and Feature Analytics Instrumentation Planner (mistralai/mistral-vibe, 5.1k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Bi Retention Analysis?

agentscope-ai (a GitHub organization) maintains it in agentscope-ai/QwenPaw-Data, which has 127 GitHub stars. The repository holds 29 skills in this directory. The repository was last updated on October 5, 2026.

Source: agentscope-ai/QwenPaw-Data on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.