name: data-to-word-report description: Automatically generate a professional Word analysis report from user-provided data files, including data overview, key metric statistics and trend analysis, key findings and conclusions.
Automatically generate a professionally formatted analysis report (.docx) from data files, ready for presentation.
7w4.net小葱技能站收录全网优质技能,值得收藏。
Use when users need to "generate analysis report", "convert data to Word", or "produce a report".
Read the user-uploaded data file, automatically detect the format (CSV/JSON/Excel/TXT), extract the data, and confirm the structure.
Perform the following analysis on the data: - Data Overview: Row count, column count, field types, missing value statistics, time range - Key Metrics: Mean/median/max/min/standard deviation for key numeric columns - Trend Analysis: If a time column exists, calculate trends by time dimension - Key Findings: Outliers, significant changes, critical conclusions
Call the script to generate the Word report:
python3 scripts/gen_report.py '<output_path>' '<report_json>'
output_path: Output path, e.g., /root/.openclaw/workspace/analysis_report.docxreport_json: JSON string, see structure below{
"title": "Data Analysis Report",
"sections": [
{
"heading": "I. Data Overview",
"paragraphs": ["This analysis covers 1,234 records...", "Time range: 2024-01 to 2024-12"],
"table": {
"headers": ["Metric", "Value"],
"rows": [["Total Records", "1,234"], ["Fields", "8"], ["Missing Rate", "2.1%"]]
}
},
{
"heading": "II. Key Metrics",
"paragraphs": ["Average sales: 456K, median: 382K..."],
"table": {
"headers": ["Metric", "Mean", "Median", "Max", "Min"],
"rows": [["Sales (10K)", "45.6", "38.2", "120.5", "5.3"]]
}
},
{
"heading": "III. Trend Analysis",
"paragraphs": ["Overall upward trend, Q4 grew 23% QoQ..."],
"table": null
},
{
"heading": "IV. Key Findings & Recommendations",
"paragraphs": ["1. East China region accounts for the highest share (38%)...", "2. December return rate abnormally rose to 5.7%..."],
"table": null
}
]
}
The table field in each section is optional; pass null to output only paragraphs.
Inform the user of the file save location and display an overview of the report structure.
这个 Skill 质量较好,能够可靠地将数据转换为格式专业的 Word 分析报告。它在文档完整性、功能实现和输出美观度方面都表现不错,生成的中文报告排版整齐、样式专业。主要优点是使用简单、结果美观、文档清晰;不足之处是需要额外安装依赖库,对非技术用户可能稍有门槛。整体而言是一个实用且易用的数据分析报告生成工具。