business-analytics-reporter by ailabs-393/ai-labs-claude-skills
npx skills add https://github.com/ailabs-393/ai-labs-claude-skills --skill business-analytics-reporter生成全面的商业绩效报告,分析销售和收入数据,识别业务薄弱环节,解读统计数据所指示的含义,并提供可操作的改进策略。该技能使用数据驱动分析来检测薄弱领域,并推荐基于商业框架支持的具体策略。
当用户提出以下请求时调用此技能:
该技能期望接收包含业务数据(销售、收入、交易)的 CSV 文件,其列可能包括日期、金额、类别或产品。
首先理解数据结构以及用户想要分析的内容。
如有需要,请提出澄清问题:
加载并探索数据:
import pandas as pd
# 加载 CSV 文件
df = pd.read_csv('business_data.csv')
# 显示基本信息
print(f"Data shape: {df.shape}")
print(f"Columns: {df.columns.tolist()}")
print(f"Date range: {df['date'].min()} to {df['date'].max()}")
print(df.head())
使用捆绑的分析脚本生成全面的洞察:
python scripts/analyze_business_data.py path/to/business_data.csv output_report.json
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
该脚本将:
输出结构:
{
"metadata": {...},
"findings": {
"basic_statistics": {...},
"trend_analysis": {...},
"category_analysis": {...},
"variability": {...}
},
"weak_areas": [...],
"improvement_strategies": [...]
}
读取生成的 JSON 报告,并用通俗易懂的语言为用户解读发现。
重点关注:
示例解读:
Based on the analysis of your sales data from January to December 2024:
Current State:
- Total revenue: $1.2M with average monthly revenue of $100K
- Average growth rate: -3.5% indicating declining performance
- Revenue stability: High volatility (CV: 58%) suggesting inconsistent performance
Weak Areas Identified:
1. Revenue Growth (High Severity): Negative average growth rate of -3.5%
2. Performance Consistency (Medium Severity): 45% of periods show declining performance
3. Category Performance (Medium Severity): 4 underperforming categories identified
参考商业框架资料以提供战略性建议:
加载商业框架以获取背景信息: 参考 references/business_frameworks.md 获取:
将建议结构化为:
针对每个识别出的薄弱环节,提供:
示例建议:
Strategy: Revenue Acceleration Program
Area: Revenue Growth
Objective: Reverse negative growth trend and achieve 10%+ monthly growth
Key Actions:
1. Implement aggressive customer acquisition campaigns
2. Review and optimize pricing strategy
3. Launch upselling and cross-selling initiatives
4. Expand into new market segments or geographies
5. Accelerate product development and innovation
Expected Impact: High
Timeline: 3-6 months
Success Metrics: Monthly revenue growth rate, new customer acquisition, ARPU increase
如果用户要求,使用 Plotly 创建交互式可视化图表来说明发现:
参考可视化指南: 参考 references/visualization_guide.md 获取:
可创建的常见可视化图表:
收入趋势示例代码:
import plotly.graph_objects as go
from plotly.subplots import make_subplots
fig = make_subplots(specs=[[{"secondary_y": True}]])
# 添加收入线
fig.add_trace(
go.Scatter(x=df['date'], y=df['revenue'], name="Revenue",
line=dict(color='blue', width=3)),
secondary_y=False
)
# 添加增长率线
fig.add_trace(
go.Scatter(x=df['date'], y=df['growth_rate'], name="Growth Rate",
line=dict(color='green', dash='dash')),
secondary_y=True
)
fig.update_layout(title_text="Revenue Performance & Growth Rate")
fig.show()
将发现整理成全面的报告格式。
选项 A:生成 HTML 报告
使用 assets/report_template.html 中的报告模板:
# Read the template
with open('assets/report_template.html', 'r') as f:
template = f.read()
# Load analysis results
with open('output_report.json', 'r') as f:
analysis = json.load(f)
# Populate the template with actual data
# Replace placeholders with real values from analysis
# Add Plotly charts as JavaScript
# Save as final HTML report
with open('business_report.html', 'w') as f:
f.write(populated_template)
HTML 模板包括:
选项 B:生成 Markdown 报告
创建结构化的 Markdown 文档:
# Business Performance Analysis Report
**Generated:** [Date]
**Data Period:** [Period]
## Executive Summary
[Brief overview of findings]
## Key Metrics
- Total Revenue: $X
- Average Growth Rate: X%
- Revenue Stability: [Assessment]
- Weak Areas Identified: X
## Performance Trends
[Insert chart or describe trends]
## Areas of Weakness
### 1. [Weak Area Name] (Severity)
**Finding:** [Description]
**Impact:** [Business impact]
### 2. [Next weak area...]
## Strategic Recommendations
### Strategy 1: [Name]
**Objective:** [Goal]
**Actions:**
- [Action 1]
- [Action 2]
...
**Expected Impact:** High/Medium/Low
**Timeline:** X months
分析脚本自动计算以下指标:
生成建议时,请利用 references/business_frameworks.md 中记录的框架:
将识别出的薄弱环节与适当的战略框架相匹配,以提供与上下文相关的建议。
分析会自动检测这些常见的业务问题:
| 薄弱环节 | 检测标准 | 典型根本原因 |
|---|---|---|
| 收入增长 | 平均增长率为负 | 市场饱和、竞争加剧、定位不佳 |
| 绩效一致性 | >40% 的期间表现下降 | 缺乏经常性收入、季节性依赖 |
| 收入稳定性 | CV > 50% | 客户集中、需求波动大 |
| 类别绩效 | 处于后 25% 的类别 | 产品市场契合度差、定价问题、知名度低 |
用户请求: "分析我第四季度的销售数据,告诉我我们的薄弱环节以及如何改进"
工作流程:
df = pd.read_csv('q4_sales.csv')python scripts/analyze_business_data.py q4_sales.csv q4_report.jsonwith open('q4_report.json') as f: report = json.load(f)references/visualization_guide.md)assets/report_template.html 生成 HTML 报告references/business_frameworks.md 提供战略建议预期输出:
analyze_business_data.py:自动化分析引擎,检测数据结构、计算指标、识别薄弱环节并生成改进策略business_frameworks.md:商业战略框架、常见薄弱环节和解决方案模板的综合指南visualization_guide.md:图表类型推荐、Plotly 代码示例和仪表板设计最佳实践report_template.html:专业的 HTML 模板,包含交互式可视化、用于薄弱环节和策略的样式化卡片,以及可打印格式每周安装次数
112
代码仓库
GitHub 星标数
324
首次出现
Jan 23, 2026
安全审计
安装于
opencode98
codex97
gemini-cli93
cursor88
github-copilot86
kimi-cli73
Generate comprehensive business performance reports that analyze sales and revenue data, identify areas where the business is lacking, interpret what the statistics indicate, and provide actionable improvement strategies. The skill uses data-driven analysis to detect weak areas and recommends specific strategies backed by business frameworks.
Invoke this skill when users request:
The skill expects CSV files containing business data (sales, revenue, transactions) with columns like dates, amounts, categories, or products.
Start by understanding the data structure and what the user wants to analyze.
Ask clarifying questions if needed:
Load and explore the data:
import pandas as pd
# Load the CSV file
df = pd.read_csv('business_data.csv')
# Display basic information
print(f"Data shape: {df.shape}")
print(f"Columns: {df.columns.tolist()}")
print(f"Date range: {df['date'].min()} to {df['date'].max()}")
print(df.head())
Use the bundled analysis script to generate comprehensive insights:
python scripts/analyze_business_data.py path/to/business_data.csv output_report.json
The script will:
Output structure:
{
"metadata": {...},
"findings": {
"basic_statistics": {...},
"trend_analysis": {...},
"category_analysis": {...},
"variability": {...}
},
"weak_areas": [...],
"improvement_strategies": [...]
}
Read the generated JSON report and interpret the findings for the user in plain language.
Focus on:
Example interpretation:
Based on the analysis of your sales data from January to December 2024:
Current State:
- Total revenue: $1.2M with average monthly revenue of $100K
- Average growth rate: -3.5% indicating declining performance
- Revenue stability: High volatility (CV: 58%) suggesting inconsistent performance
Weak Areas Identified:
1. Revenue Growth (High Severity): Negative average growth rate of -3.5%
2. Performance Consistency (Medium Severity): 45% of periods show declining performance
3. Category Performance (Medium Severity): 4 underperforming categories identified
Consult the business frameworks reference to provide strategic recommendations:
Load business frameworks for context: Refer to references/business_frameworks.md for:
Structure recommendations as:
For each identified weak area, provide:
Example recommendation:
Strategy: Revenue Acceleration Program
Area: Revenue Growth
Objective: Reverse negative growth trend and achieve 10%+ monthly growth
Key Actions:
1. Implement aggressive customer acquisition campaigns
2. Review and optimize pricing strategy
3. Launch upselling and cross-selling initiatives
4. Expand into new market segments or geographies
5. Accelerate product development and innovation
Expected Impact: High
Timeline: 3-6 months
Success Metrics: Monthly revenue growth rate, new customer acquisition, ARPU increase
If requested, create interactive visualizations using Plotly to illustrate findings:
Consult visualization guide: Refer to references/visualization_guide.md for:
Common visualizations to create:
Example code for revenue trend:
import plotly.graph_objects as go
from plotly.subplots import make_subplots
fig = make_subplots(specs=[[{"secondary_y": True}]])
# Add revenue line
fig.add_trace(
go.Scatter(x=df['date'], y=df['revenue'], name="Revenue",
line=dict(color='blue', width=3)),
secondary_y=False
)
# Add growth rate line
fig.add_trace(
go.Scatter(x=df['date'], y=df['growth_rate'], name="Growth Rate",
line=dict(color='green', dash='dash')),
secondary_y=True
)
fig.update_layout(title_text="Revenue Performance & Growth Rate")
fig.show()
Compile findings into a comprehensive report format.
Option A: Generate HTML Report
Use the report template from assets/report_template.html:
# Read the template
with open('assets/report_template.html', 'r') as f:
template = f.read()
# Load analysis results
with open('output_report.json', 'r') as f:
analysis = json.load(f)
# Populate the template with actual data
# Replace placeholders with real values from analysis
# Add Plotly charts as JavaScript
# Save as final HTML report
with open('business_report.html', 'w') as f:
f.write(populated_template)
The HTML template includes:
Option B: Generate Markdown Report
Create a structured markdown document:
# Business Performance Analysis Report
**Generated:** [Date]
**Data Period:** [Period]
## Executive Summary
[Brief overview of findings]
## Key Metrics
- Total Revenue: $X
- Average Growth Rate: X%
- Revenue Stability: [Assessment]
- Weak Areas Identified: X
## Performance Trends
[Insert chart or describe trends]
## Areas of Weakness
### 1. [Weak Area Name] (Severity)
**Finding:** [Description]
**Impact:** [Business impact]
### 2. [Next weak area...]
## Strategic Recommendations
### Strategy 1: [Name]
**Objective:** [Goal]
**Actions:**
- [Action 1]
- [Action 2]
...
**Expected Impact:** High/Medium/Low
**Timeline:** X months
The analysis script calculates the following metrics automatically:
When generating recommendations, leverage the frameworks documented in references/business_frameworks.md:
Match identified weak areas with appropriate strategic frameworks to provide contextually relevant recommendations.
The analysis automatically detects these common business problems:
| Weak Area | Detection Criteria | Typical Root Causes |
|---|---|---|
| Revenue Growth | Negative average growth rate | Market saturation, increased competition, poor positioning |
| Performance Consistency | >40% declining periods | Lack of recurring revenue, seasonal dependency |
| Revenue Stability | CV > 50% | Customer concentration, volatile demand |
| Category Performance | Categories in bottom 25% | Poor product-market fit, pricing issues, low awareness |
User request: "Analyze my Q4 sales data and tell me where we're weak and how to improve"
Workflow:
df = pd.read_csv('q4_sales.csv')python scripts/analyze_business_data.py q4_sales.csv q4_report.jsonwith open('q4_report.json') as f: report = json.load(f)references/visualization_guide.md)assets/report_template.htmlreferences/business_frameworks.mdExpected output:
analyze_business_data.py: Automated analysis engine that detects data structure, calculates metrics, identifies weak areas, and generates improvement strategiesbusiness_frameworks.md: Comprehensive guide to business strategy frameworks, common weak areas, and solution templatesvisualization_guide.md: Chart type recommendations, Plotly code examples, and dashboard design best practicesreport_template.html: Professional HTML template with interactive visualizations, styled cards for weak areas and strategies, and print-ready formattingWeekly Installs
112
Repository
GitHub Stars
324
First Seen
Jan 23, 2026
Security Audits
Gen Agent Trust HubPassSocketPassSnykWarn
Installed on
opencode98
codex97
gemini-cli93
cursor88
github-copilot86
kimi-cli73
Azure Data Explorer (Kusto) 查询技能:KQL数据分析、日志遥测与时间序列处理
100,500 周安装