math-modeling
当用户要求数学建模、建模竞赛、建模分析、代码求解、结果可视化或生成数学建模论文时使用。支持完整三阶段流程、单独执行任一角色,以及在关键节点使用独立 Subagent 进行阶段内质检;默认只启用质检 Subagent,用户可明确选择额外协作。
读取、创建、修改和验证 XLSX,支持模板保留、公式重算和错误检查。
Claude Code
$ npx -y skills add XiaoMaColtAI/math-modeling-skill --skill xlsx --agent claude-code
Codex
$ npx skills add XiaoMaColtAI/math-modeling-skill --skill xlsx -a codex -y
Cursor
$ npx skills add XiaoMaColtAI/math-modeling-skill --skill xlsx -a cursor -y
Gemini CLI
$ npx skills add XiaoMaColtAI/math-modeling-skill --skill xlsx -a gemini-cli -y
GitHub Copilot
$ npx skills add XiaoMaColtAI/math-modeling-skill --skill xlsx -a github-copilot -y
OpenCode
$ npx skills add XiaoMaColtAI/math-modeling-skill --skill xlsx -a opencode -y
Windsurf
$ npx skills add XiaoMaColtAI/math-modeling-skill --skill xlsx -a windsurf -y
name: Excel工具 description: 读取、创建、修改和验证 XLSX,支持模板保留、公式重算和错误检查。
import pandas as pd
# 第一行就是数据时必须显式使用 header=None。
data = pd.read_excel("data/input.xlsx", sheet_name=0, header=None)
assert len(data) == 7470, f"行数异常: {len(data)}"
result = pd.DataFrame({"方案": names, "目标值": values})
result.to_excel("results/结果.xlsx", index=False)禁止依赖 `pandas.read_excel()` 默认的 `header=0` 猜测表头,否则第一行数据会被当成列名。未知表头结构或必须精确保留行时使用无隐式推断的读取工具:
from scripts.read_rows import read_excel_rows
rows = read_excel_rows(
"data/input.xlsx",
header=False,
expected_rows=7470,
)
assert rows[0][0] == 399.6747读取后必须核对首行、末行、原始工作表有效行数和题目声明的记录数;行数不符时立即报错,不得静默继续建模。
使用模板时用 `openpyxl.load_workbook()` 打开,写入指定单元格后另存新文件。不要删除未知工作表、命名区域、公式或验证规则。
`openpyxl` 不计算公式。修改含公式的工作簿后使用 LibreOffice 隔离重算:
python scripts/recalc.py "<PROJECT_ROOT>/results/结果.xlsx" 60
工具会:
1. 使用唯一临时 LibreOffice 配置; 2. 把重算结果写入临时目录; 3. 检查常见 Excel 错误; 4. 仅在成功后原子替换目标文件; 5. 超时、失败或未生成输出时保留原文件。
DOCX 与 XLSX 共用的 OOXML/LibreOffice 基础代码位于 `../docx/scripts/office/`,本工具不再维护重复副本。
当用户要求数学建模、建模竞赛、建模分析、代码求解、结果可视化或生成数学建模论文时使用。支持完整三阶段流程、单独执行任一角色,以及在关键节点使用独立 Subagent 进行阶段内质检;默认只启用质检 Subagent,用户可明确选择额外协作。
创建、编辑、校验和转换 Word DOCX,支持把完整 LaTeX 论文转换为 DOCX,以及数学建模论文模板、原生公式、三线表、修订和批注。
从数据剖析到出版级成图的完整可视化工具。先做数据剖析(列类型/样本量/分布/异常值/分组结构/相关性), 再结合论证目标推荐图型,主动拦截科研画图经典错误,产出 Nature / Science / IEEE / Elsevier / PNAS /…
Use this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs,…
Use this skill when the user requests to review, analyze, critique, or summarize academic papers, research articles, preprints,…
Research what people actually say about any topic in the last 30 days. Pulls posts and engagement from Reddit, X, YouTube,…
Estimates intracellular metabolic fluxes from steady-state carbon-13 isotope-tracing measurements using validated atom maps,…
Search literature across sources, verify or manage citations, and build MeSH strategies or citation-impact audits. Use for…