analyze
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinese/analyze - Answer Data Questions
/analyze - 解答数据问题
If you see unfamiliar placeholders or need to check which tools are connected, see CONNECTORS.md.
Answer a data question, from a quick lookup to a full analysis to a formal report.
若遇到不熟悉的占位符或需要查看已连接的工具,请参阅 CONNECTORS.md。
解答各类数据问题,涵盖快速查询、完整分析到正式报告等场景。
Usage
使用方法
/analyze <natural language question>/analyze <自然语言问题>Workflow
工作流程
1. Understand the Question
1. 理解问题
Parse the user's question and determine:
- Complexity level:
- Quick answer: Single metric, simple filter, factual lookup (e.g., "How many users signed up last week?")
- Full analysis: Multi-dimensional exploration, trend analysis, comparison (e.g., "What's driving the drop in conversion rate?")
- Formal report: Comprehensive investigation with methodology, caveats, and recommendations (e.g., "Prepare a quarterly business review of our subscription metrics")
- Data requirements: Which tables, metrics, dimensions, and time ranges are needed
- Output format: Number, table, chart, narrative, or combination
解析用户的问题,确定:
- 复杂程度:
- 快速解答:单一指标、简单筛选、事实类查询(例如:“上周有多少用户注册?”)
- 完整分析:多维度探索、趋势分析、对比研究(例如:“转化率下滑的原因是什么?”)
- 正式报告:包含方法论、注意事项和建议的全面调研(例如:“准备一份订阅指标的季度业务回顾报告”)
- 数据需求:所需的表、指标、维度和时间范围
- 输出格式:数字、表格、图表、叙述性内容或组合形式
2. Gather Data
2. 收集数据
If a data warehouse MCP server is connected:
- Explore the schema to find relevant tables and columns
- Write SQL query(ies) to extract the needed data
- Execute the query and retrieve results
- If the query fails, debug and retry (check column names, table references, syntax for the specific dialect)
- If results look unexpected, run sanity checks before proceeding
If no data warehouse is connected:
- Ask the user to provide data in one of these ways:
- Paste query results directly
- Upload a CSV or Excel file
- Describe the schema so you can write queries for them to run
- If writing queries for manual execution, use the skill for dialect-specific best practices
sql-queries - Once data is provided, proceed with analysis
若已连接数据仓库MCP服务器:
- 探索数据架构,找到相关的表和列
- 编写SQL查询语句以提取所需数据
- 执行查询并获取结果
- 若查询失败,调试并重试(检查列名、表引用、特定SQL方言的语法)
- 若结果不符合预期,在继续前进行合理性检查
若未连接数据仓库:
- 请用户通过以下方式提供数据:
- 直接粘贴查询结果
- 上传CSV或Excel文件
- 描述数据架构,以便为用户编写可执行的查询语句
- 若为手动执行编写查询语句,请使用技能以遵循特定方言的最佳实践
sql-queries - 数据提供后,继续进行分析
3. Analyze
3. 分析数据
- Calculate relevant metrics, aggregations, and comparisons
- Identify patterns, trends, outliers, and anomalies
- Compare across dimensions (time periods, segments, categories)
- For complex analyses, break the problem into sub-questions and address each
- 计算相关指标、聚合值和对比结果
- 识别模式、趋势、异常值和反常现象
- 跨维度(时间段、细分群体、类别)进行对比
- 对于复杂分析,将问题拆解为子问题并逐一解决
4. Validate Before Presenting
4. 呈现前验证
Before sharing results, run through validation checks:
- Row count sanity: Does the number of records make sense?
- Null check: Are there unexpected nulls that could skew results?
- Magnitude check: Are the numbers in a reasonable range?
- Trend continuity: Do time series have unexpected gaps?
- Aggregation logic: Do subtotals sum to totals correctly?
If any check raises concerns, investigate and note caveats.
在分享结果前,执行以下验证检查:
- 行数合理性:记录数量是否合理?
- 空值检查:是否存在可能影响结果的意外空值?
- 数值范围检查:数值是否在合理范围内?
- 趋势连续性:时间序列是否存在意外缺口?
- 聚合逻辑检查:分项总计是否与总和一致?
若任何检查发现问题,需展开调查并标注注意事项。
5. Present Findings
5. 呈现分析结果
For quick answers:
- State the answer directly with relevant context
- Include the query used (collapsed or in a code block) for reproducibility
For full analyses:
- Lead with the key finding or insight
- Support with data tables and/or visualizations
- Note methodology and any caveats
- Suggest follow-up questions
For formal reports:
- Executive summary with key takeaways
- Methodology section explaining approach and data sources
- Detailed findings with supporting evidence
- Caveats, limitations, and data quality notes
- Recommendations and suggested next steps
快速解答场景:
- 直接给出答案并附上相关背景
- 附上所用查询语句(折叠或放在代码块中)以确保可复现
完整分析场景:
- 先列出关键发现或洞察
- 用数据表和/或可视化图表提供支持
- 标注方法论和注意事项
- 提出后续建议问题
正式报告场景:
- 包含关键要点的执行摘要
- 解释方法和数据源的方法论部分
- 带有支持证据的详细发现
- 注意事项、局限性和数据质量说明
- 建议和后续步骤
6. Visualize Where Helpful
6. 按需可视化
When a chart would communicate results more effectively than a table:
- Use the skill to select the right chart type
data-visualization - Generate a Python visualization or build it into an HTML dashboard
- Follow visualization best practices for clarity and accuracy
当图表比表格更能有效传达结果时:
- 使用技能选择合适的图表类型
data-visualization - 生成Python可视化内容或构建HTML仪表盘
- 遵循可视化最佳实践以确保清晰准确
Examples
示例
Quick answer:
/analyze How many new users signed up in December?Full analysis:
/analyze What's causing the increase in support ticket volume over the past 3 months? Break down by category and priority.Formal report:
/analyze Prepare a data quality assessment of our customer table -- completeness, consistency, and any issues we should address.快速解答:
/analyze 12月有多少新用户注册?完整分析:
/analyze 过去3个月支持工单量增长的原因是什么?按类别和优先级拆分分析。正式报告:
/analyze 准备一份客户表的数据质量评估报告——涵盖完整性、一致性及需要解决的问题。Tips
提示
- Be specific about time ranges, segments, or metrics when possible
- If you know the table names, mention them to speed up the process
- For complex questions, Claude may break them into multiple queries
- Results are always validated before presentation -- if something looks off, Claude will flag it
- 尽可能明确时间范围、细分群体或指标
- 若知晓表名,请告知以加快处理速度
- 对于复杂问题,Claude可能会将其拆分为多个查询
- 结果在呈现前都会经过验证——若发现异常,Claude会进行标记