@orbit-build/cli 0.4.4 → 0.4.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/commands/math-draft.md +11 -0
  2. package/dist/index.js +271 -40
  3. package/package.json +4 -2
  4. package/skills/math-model-draft/SKILL.md +216 -0
  5. package/skills/math-model-draft/agents/openai.yaml +6 -0
  6. package/skills/math-model-draft/assets/project-template/code/always/__init__.py +1 -0
  7. package/skills/math-model-draft/assets/project-template/code/always/config.py +17 -0
  8. package/skills/math-model-draft/assets/project-template/code/always/data.py +23 -0
  9. package/skills/math-model-draft/assets/project-template/code/always/plotting.py +24 -0
  10. package/skills/math-model-draft/assets/project-template/code/always/validation.py +20 -0
  11. package/skills/math-model-draft/assets/project-template/code/finalize.py +55 -0
  12. package/skills/math-model-draft/assets/project-template/code/requirements.txt +11 -0
  13. package/skills/math-model-draft/assets/project-template/paper/AI/345/267/245/345/205/267/344/275/277/347/224/250/350/257/246/346/203/205.tex +34 -0
  14. package/skills/math-model-draft/assets/project-template/paper/ai-use-log.md +7 -0
  15. package/skills/math-model-draft/assets/project-template/paper/contest-profile.json +25 -0
  16. package/skills/math-model-draft/assets/project-template/paper/main.tex +53 -0
  17. package/skills/math-model-draft/assets/project-template/paper/sections/abstract.tex +6 -0
  18. package/skills/math-model-draft/assets/project-template/paper/sections/ai-disclosure.tex +3 -0
  19. package/skills/math-model-draft/assets/project-template/paper/sections/appendix.tex +9 -0
  20. package/skills/math-model-draft/assets/project-template/paper/sections/assumptions.tex +5 -0
  21. package/skills/math-model-draft/assets/project-template/paper/sections/data.tex +19 -0
  22. package/skills/math-model-draft/assets/project-template/paper/sections/evaluation.tex +9 -0
  23. package/skills/math-model-draft/assets/project-template/paper/sections/problem-analysis.tex +3 -0
  24. package/skills/math-model-draft/assets/project-template/paper/sections/problem-restatement.tex +3 -0
  25. package/skills/math-model-draft/assets/project-template/paper/sections/references.tex +6 -0
  26. package/skills/math-model-draft/assets/project-template/paper/sections/source-code.tex +1 -0
  27. package/skills/math-model-draft/assets/project-template/paper/sections/support-files.tex +3 -0
  28. package/skills/math-model-draft/references/code-and-output-style.md +91 -0
  29. package/skills/math-model-draft/references/cumcm-compliance.md +56 -0
  30. package/skills/math-model-draft/references/latex-figures-tables.md +60 -0
  31. package/skills/math-model-draft/references/modeling-quality.md +91 -0
  32. package/skills/math-model-draft/references/paper-architecture.md +125 -0
  33. package/skills/math-model-draft/references/paper-revision.md +76 -0
  34. package/skills/math-model-draft/references/project-architecture.md +65 -0
  35. package/skills/math-model-draft/scripts/audit_paper.py +185 -0
  36. package/skills/math-model-draft/scripts/bootstrap_project.py +275 -0
  37. package/skills/math-model-draft/scripts/build_paper.py +226 -0
  38. package/skills/math-model-draft/scripts/capture_environment.py +46 -0
  39. package/skills/math-model-draft/scripts/clean_project.py +46 -0
  40. package/skills/math-model-draft/scripts/finalize_project.py +49 -0
  41. package/skills/math-model-draft/scripts/inspect_inputs.py +193 -0
  42. package/skills/math-model-draft/scripts/package_support.py +52 -0
  43. package/skills/math-model-draft/scripts/project_utils.py +106 -0
  44. package/skills/math-model-draft/scripts/validate_project.py +313 -0
@@ -0,0 +1,216 @@
1
+ ---
2
+ name: math-model-draft
3
+ description: Build, revise, or audit a mathematical-modeling competition project from problem statements, attachments, current code, machine-readable results, figures, TeX, PDFs, and reference papers. Produces evidence-linked Chinese LaTeX, runnable q1/q2 code, validated outputs, current figures, AI-use disclosure, and submission packages. Use explicitly for 数学建模、国赛/CUMCM、研究生数模、校赛、美赛中文稿、论文初稿或定稿审查、TeX/PDF 修订、模型—代码—结果—论文一致性核验。
4
+ ---
5
+
6
+ # Build or revise a mathematical-modeling paper
7
+
8
+ Deliver a compilable, evidence-backed project, not an outline or generic prose.
9
+ Never invent a model, algorithm, datum, parameter, numerical result, validation,
10
+ or figure that the current code and artifacts do not support. Mark unresolved
11
+ facts visibly with `TODO[reason]`.
12
+
13
+ ## Mandatory execution order for generation
14
+
15
+ After one project inventory, begin implementation immediately:
16
+
17
+ 1. Trust bundled helpers as public interfaces. Do **not** read their source,
18
+ test verifiers, every template section, or all optional references first.
19
+ 2. Do **not** probe or install the scientific Python stack up front. Use the
20
+ available dependencies; for a small deterministic task, prefer the standard
21
+ library. Add a dependency only when the selected model truly requires it.
22
+ 3. Start the first substantive write within five tool calls after inventory.
23
+ Work in bounded batches: at most four write/edit calls per model response,
24
+ no giant all-project tool call, and leave enough output budget for valid
25
+ tool-call closure. Implement code/results first, then paper sections in
26
+ coherent groups; do not spend turns on cosmetic inspection between them.
27
+ 4. Run `code/run_all.py`, repair its evidence, then call the finalizer without
28
+ reading the finalizer's implementation.
29
+ 5. Spend remaining turns only on failed checks and rendered-page defects.
30
+
31
+ When the project-local finalizer exits with code 0, the strict build, audit,
32
+ page rendering, packaging, and validation are already complete. Stop tool use
33
+ immediately and return the required final report. Do not write scratch verifier
34
+ scripts, inspect build caches, re-parse the PDFs, or rerun checks after a
35
+ successful finalizer. A successful finalizer is the terminal condition.
36
+
37
+ Do not repeat environment, path, template, or helper probes that already
38
+ succeeded. A progress plan must not delay the first substantive write.
39
+ If `paper/input-inventory.json`, `paper/contest-profile.json`, `code/qN`, and
40
+ `paper/main.tex` already exist, the scaffold is ready: do not read the Skill
41
+ directory, helper sources, or every placeholder section. Read only the problem
42
+ inventory/data and the target files needed for the next bounded write batch.
43
+ Never create an environment-probe script; run the required project entry point
44
+ and react only to a concrete missing dependency.
45
+
46
+ ## Guidance routing and round-trip budget
47
+
48
+ This `SKILL.md` contains the complete mandatory contract. Do not spend the
49
+ opening tool turns reading every reference file. Prepare and inspect the actual
50
+ project first, then read only the reference needed at the decision point:
51
+
52
+ - structure: `references/project-architecture.md` and `paper-architecture.md`;
53
+ - model/code quality: `modeling-quality.md` and `code-and-output-style.md`;
54
+ - existing paper: `paper-revision.md`;
55
+ - CUMCM compliance: `cumcm-compliance.md`;
56
+ - final typesetting: `latex-figures-tables.md`.
57
+
58
+ Batch independent reads, writes, and safe commands. Do not repeatedly probe the
59
+ same binary input: use `inspect_inputs.py` once, then consume its extracted text
60
+ and structured inventory. Resolve references relative to this `SKILL.md` if
61
+ `skill://math-model-draft/` is unavailable. Supplied current contest rules and
62
+ templates always outrank this Skill's defaults.
63
+
64
+ ## Select the operating mode
65
+
66
+ The default `/math-draft <project>` path is a one-request, end-to-end generation:
67
+ read the problem, model every question, implement and run the code, generate
68
+ results and figures, write the complete paper, compile, inspect, and package it.
69
+ Do not stop after scaffolding, an outline, sample paragraphs, or formatting.
70
+
71
+ Inspect the project before editing and choose one mode automatically:
72
+
73
+ - **Generate** (default for a problem directory): create the skeleton and fill
74
+ every substantive section from the problem and computed evidence, then finish
75
+ the PDF and support package in the same run.
76
+ - **Revise**: TeX/PDF and code/results already exist. Preserve sound content and
77
+ make local additions or corrections; do not rewrite merely for style.
78
+ - **Audit**: the user asks only for findings. Run read-only checks and report;
79
+ do not change project files.
80
+
81
+ For revision, read every relevant problem/attachment, latest code directory,
82
+ `results/`, `figures/`, current TeX/PDF, and any excellent-paper directory.
83
+ Reference papers guide structure and comparison only; they are never a source
84
+ of this project's results.
85
+
86
+ ## Establish sources of truth
87
+
88
+ Use this precedence for factual conflicts:
89
+
90
+ 1. official problem, supplied data, and current contest rules;
91
+ 2. current runnable code and configuration;
92
+ 3. program-generated JSON/CSV/XLSX and validation artifacts;
93
+ 4. figures generated from those artifacts;
94
+ 5. TeX and compiled PDF;
95
+ 6. excellent papers and secondary commentary.
96
+
97
+ Treat `question/` as immutable. Use JSON/CSV as the numerical fact source and
98
+ check every summary/body/table/figure/conclusion value for units, signs,
99
+ precision, constraints, and consistency. Prefer a reference paper's final
100
+ results table over its abstract when auditing that paper's own numbers.
101
+ In TeX, never write raw underscores or other special characters in paths and
102
+ identifiers; use a safe path command such as `\path{code/q1/model.py}` or escape
103
+ the character explicitly. Treat the finalizer's first file/line diagnostic as
104
+ the repair target instead of launching ad-hoc TeX probes.
105
+
106
+ ## Run the workflow
107
+
108
+ Resolve `<skill-root>` to this Skill's directory and `<project-root>` to the
109
+ project being handled.
110
+
111
+ ### 1. Inventory and configure
112
+
113
+ ```powershell
114
+ python "<skill-root>/scripts/inspect_inputs.py" <project-root>
115
+ python "<skill-root>/scripts/bootstrap_project.py" <project-root> --questions <N>
116
+ ```
117
+
118
+ The bootstrap is additive and idempotent. It may add missing q-folders and
119
+ orchestrator entries, but must not overwrite authored content. Review
120
+ `paper/contest-profile.json`; select `cumcm-2026` only when applicable. Do not
121
+ silently apply CUMCM limits to another contest.
122
+
123
+ ### 2. Plan evidence before prose
124
+
125
+ Maintain `paper/evidence-map.yaml`. Every material claim needs an identifier,
126
+ an in-project `results/` source, a target `paper/sections/` file, and status
127
+ `TODO` or `verified`. Define each subproblem's variables, units, constraints,
128
+ parameter sources, candidate methods, selection reason, data dependencies,
129
+ outputs, and validation.
130
+
131
+ ### 3. Implement and run
132
+
133
+ - Put shared configuration/loading/plotting/validation in `code/always` and
134
+ question-specific work in `code/qN`; keep each `main.py` orchestral.
135
+ - Validate raw data, fix seeds, record the environment, compare a transparent
136
+ baseline where complexity matters, and use appropriate sensitivity,
137
+ residual, uncertainty, cross-validation, or robustness checks.
138
+ - Run from a clean entry point and repair failures before asserting results.
139
+ - Save factual outputs in `results/qN`, paper-ready visuals in `figures/qN`,
140
+ and completed workbook deliverables in `results/qN`.
141
+
142
+ ```powershell
143
+ python <project-root>/code/run_all.py
144
+ python "<skill-root>/scripts/capture_environment.py" <project-root>
145
+ ```
146
+
147
+ ### 4. Write or revise from evidence
148
+
149
+ For every question, make the progression explicit: task interpretation,
150
+ variables and constraints, model choice and reason, equations, parameter
151
+ sources, algorithm, numerical results, interpretation, validation, conclusion,
152
+ and handoff to the next question. Keep the abstract informative: each question
153
+ must retain its model, algorithm, key values, and conclusion.
154
+
155
+ In revision mode, prefer surgical additions and corrections. Do not compress
156
+ the abstract, change global spacing, or replace large passages without factual
157
+ need. Ensure every figure is current, legible in Chinese, cited and interpreted
158
+ near first discussion, and free of clipping, overlap, drift, cross-question
159
+ misplacement, and abnormal whitespace. Check reference aliases, table labels,
160
+ paper-number shorthand, and bibliography numbering for mismatches.
161
+
162
+ If the appendix includes source code, regenerate it from the current code tree.
163
+ Whether support-file lists or source appendices are included is controlled by
164
+ the contest profile; official CUMCM requirements must not be disabled merely as
165
+ a stylistic preference.
166
+
167
+ ### 5. Audit, build, package, and inspect every page
168
+
169
+ Use the one-command finalizer after the substantive code and paper are complete:
170
+
171
+ ```powershell
172
+ python <project-root>/code/finalize.py --run-code --strict-layout --render-pages
173
+ ```
174
+
175
+ The project-local launcher executes the active Skill's trusted finalizer without
176
+ requiring a shell command outside the workspace. It records the environment,
177
+ rebuilds with local TeX Live, audits and optionally
178
+ renders every page, packages support materials, and runs strict validation. Its
179
+ individual scripts may be run separately while repairing a failure.
180
+
181
+ Use the machine-readable audit report to resolve missing inputs, stale figures,
182
+ missing TeX assets, unresolved references, weak question sections, and stale
183
+ PDFs. Render the final PDF and inspect every page. There must be no blank page,
184
+ orphan heading, overflow, missing glyph, undefined reference, overfull/underfull
185
+ box, clipped figure/table, or inexplicable whitespace.
186
+
187
+ Clean only known caches and temporary render products after verification:
188
+
189
+ ```powershell
190
+ python "<skill-root>/scripts/clean_project.py" <project-root> --apply
191
+ ```
192
+
193
+ Never remove original questions, current code, effective results, paper figures,
194
+ TeX sources, final PDFs, or unknown files.
195
+
196
+ ## AI-use compliance
197
+
198
+ Using this Skill is itself AI assistance. For CUMCM 2026, default to the
199
+ official “used AI” declaration unless the project demonstrably predates use.
200
+ Keep the declaration immediately before references and generate the required
201
+ `AI工具使用详情.pdf`. Record tool/model, stage and purpose, prompting process,
202
+ adoption/manual changes, and verification. Never present an unofficial AIGC or
203
+ AIDC percentage from a secondary article as an official disqualification rule.
204
+
205
+ ## Completion gate
206
+
207
+ Finish only when inputs are inventoried; `question/` fingerprint is unchanged;
208
+ all q1/q2/... paths align; code runs; every reported number is evidence-linked;
209
+ assumptions, units, limitations, and validation are explicit; figures and code
210
+ appendix are current; TeX compiles under local TeX Live; the final PDF passes
211
+ page-by-page inspection; package contents satisfy the active profile; and every
212
+ remaining TODO or manual decision is reported.
213
+
214
+ The final response should contain only: material changes, defects fixed,
215
+ numerical consistency result, compile/layout verification, remaining TODOs, and
216
+ absolute paths to final files.
@@ -0,0 +1,6 @@
1
+ interface:
2
+ display_name: "Mathematical Modeling Draft"
3
+ short_description: "One-click complete modeling paper, code, PDF, and compliance package"
4
+ default_prompt: "Use $math-model-draft to read every problem and attachment in this project, complete all modeling and runnable q1/q2 code, generate verified results and figures, write the full evidence-linked LaTeX paper, add the current AI-use declaration, compile with local TeX Live, inspect every PDF page, and package the final delivery. Do not stop at scaffolding or an outline."
5
+ policy:
6
+ allow_implicit_invocation: false
@@ -0,0 +1,17 @@
1
+ from __future__ import annotations
2
+
3
+ from pathlib import Path
4
+
5
+
6
+ CODE_ROOT = Path(__file__).resolve().parents[1]
7
+ PROJECT_ROOT = CODE_ROOT.parent
8
+ QUESTION_DIR = PROJECT_ROOT / "question"
9
+ RESULTS_DIR = PROJECT_ROOT / "results"
10
+ FIGURES_DIR = PROJECT_ROOT / "figures"
11
+ RANDOM_STATE = 2026
12
+
13
+
14
+ def question_output_dirs(question: str) -> tuple[Path, Path]:
15
+ if not question.startswith("q") or not question[1:].isdigit():
16
+ raise ValueError(f"Invalid question name: {question}")
17
+ return RESULTS_DIR / question, FIGURES_DIR / question
@@ -0,0 +1,23 @@
1
+ from __future__ import annotations
2
+
3
+ from pathlib import Path
4
+ from typing import Iterable
5
+
6
+ import pandas as pd
7
+
8
+ from always.config import QUESTION_DIR
9
+
10
+
11
+ def input_files(suffixes: Iterable[str]) -> list[Path]:
12
+ normalized = {suffix.lower() for suffix in suffixes}
13
+ return sorted(
14
+ path
15
+ for path in QUESTION_DIR.rglob("*")
16
+ if path.is_file() and path.suffix.lower() in normalized
17
+ )
18
+
19
+
20
+ def require_columns(frame: pd.DataFrame, columns: Iterable[str]) -> None:
21
+ missing = sorted(set(columns) - set(frame.columns))
22
+ if missing:
23
+ raise ValueError(f"Missing required columns: {missing}")
@@ -0,0 +1,24 @@
1
+ from __future__ import annotations
2
+
3
+ from pathlib import Path
4
+
5
+ import matplotlib.pyplot as plt
6
+
7
+
8
+ def setup_plotting() -> None:
9
+ plt.rcParams["font.sans-serif"] = [
10
+ "Microsoft YaHei",
11
+ "SimHei",
12
+ "Noto Sans CJK SC",
13
+ "Arial Unicode MS",
14
+ ]
15
+ plt.rcParams["axes.unicode_minus"] = False
16
+ plt.rcParams["figure.dpi"] = 140
17
+ plt.rcParams["savefig.dpi"] = 300
18
+
19
+
20
+ def save_figure(path: Path) -> None:
21
+ path.parent.mkdir(parents=True, exist_ok=True)
22
+ plt.tight_layout()
23
+ plt.savefig(path, bbox_inches="tight")
24
+ plt.close()
@@ -0,0 +1,20 @@
1
+ from __future__ import annotations
2
+
3
+ import json
4
+ from pathlib import Path
5
+ from typing import Any
6
+
7
+ import numpy as np
8
+
9
+
10
+ def require_finite(values: np.ndarray, label: str) -> None:
11
+ if not np.isfinite(values).all():
12
+ raise ValueError(f"{label} contains non-finite values.")
13
+
14
+
15
+ def write_summary(path: Path, payload: dict[str, Any]) -> None:
16
+ path.parent.mkdir(parents=True, exist_ok=True)
17
+ path.write_text(
18
+ json.dumps(payload, ensure_ascii=False, indent=2) + "\n",
19
+ encoding="utf-8",
20
+ )
@@ -0,0 +1,55 @@
1
+ from __future__ import annotations
2
+
3
+ import json
4
+ import runpy
5
+ import shutil
6
+ import subprocess
7
+ import sys
8
+ from pathlib import Path
9
+
10
+
11
+ PROJECT_ROOT = Path(__file__).resolve().parent.parent
12
+
13
+
14
+ def resolve_finalizer() -> Path:
15
+ personal = Path.home() / ".orbit" / "skills" / "math-model-draft" / "scripts" / "finalize_project.py"
16
+ if personal.is_file():
17
+ return personal
18
+ orbit = shutil.which("orbit")
19
+ if orbit:
20
+ completed = subprocess.run(
21
+ [orbit, "skills", "list", "--json"],
22
+ cwd=PROJECT_ROOT,
23
+ text=True,
24
+ encoding="utf-8",
25
+ errors="replace",
26
+ stdout=subprocess.PIPE,
27
+ stderr=subprocess.PIPE,
28
+ check=False,
29
+ )
30
+ if completed.returncode == 0:
31
+ try:
32
+ payload = json.loads(completed.stdout)
33
+ except json.JSONDecodeError:
34
+ payload = {}
35
+ for skill in payload.get("skills", []):
36
+ if skill.get("name") != "math-model-draft":
37
+ continue
38
+ candidate = Path(str(skill.get("path", ""))).resolve().parent / "scripts" / "finalize_project.py"
39
+ if candidate.is_file():
40
+ return candidate
41
+ raise SystemExit(
42
+ "Active math-model-draft finalizer is missing. Run `orbit skills list` "
43
+ "and ensure the bundled or personal Skill is enabled."
44
+ )
45
+
46
+
47
+ def main() -> None:
48
+ finalizer = resolve_finalizer()
49
+ sys.path.insert(0, str(finalizer.parent))
50
+ sys.argv = [str(finalizer), str(PROJECT_ROOT), *sys.argv[1:]]
51
+ runpy.run_path(str(finalizer), run_name="__main__")
52
+
53
+
54
+ if __name__ == "__main__":
55
+ main()
@@ -0,0 +1,11 @@
1
+ matplotlib
2
+ numpy
3
+ openpyxl
4
+ pandas
5
+ pypdf
6
+ python-docx
7
+ PyYAML
8
+ scikit-learn
9
+ scipy
10
+ seaborn
11
+ xlrd
@@ -0,0 +1,34 @@
1
+ \documentclass[UTF8,12pt,a4paper]{ctexart}
2
+
3
+ \usepackage[a4paper,margin=2.5cm]{geometry}
4
+ \usepackage{longtable,array,xcolor,hyperref}
5
+ \hypersetup{hidelinks}
6
+ \setlength{\parindent}{2em}
7
+ \pagestyle{plain}
8
+ \newcommand{\TODO}[1]{\textcolor{red}{\textbf{TODO[#1]}}}
9
+ \newcolumntype{L}[1]{>{\raggedright\arraybackslash}p{#1}}
10
+
11
+ \begin{document}
12
+ \begin{center}
13
+ {\zihao{2}\bfseries AI工具使用详情}
14
+ \end{center}
15
+
16
+ \section{工具与使用范围}
17
+ \TODO{逐项填写实际工具名称、版本、模型、提供方,以及使用阶段和用途。}
18
+
19
+ \section{主要提示方式与过程}
20
+ \TODO{概述如何提供题目、代码和证据约束,可列典型提示词;不得虚构未发生的交互。}
21
+
22
+ \section{采纳、人工修改与核验}
23
+ \renewcommand{\arraystretch}{1.3}
24
+ \begin{longtable}{@{}L{0.06\textwidth}L{0.13\textwidth}L{0.15\textwidth}L{0.23\textwidth}L{0.25\textwidth}@{}}
25
+ \hline
26
+ 序号\newline 时间 & 工具、版本\newline 与模型 & 目的\newline 与阶段 & 采纳内容及人工修改 & 核验方式与结果 \\
27
+ \hline
28
+ 1 & \TODO{填写} & \TODO{填写} & \TODO{填写} & \TODO{填写} \\
29
+ \hline
30
+ \end{longtable}
31
+
32
+ \section{责任确认}
33
+ \TODO{确认核心建模与分析由团队主导,AI输出均经人工复核,论文、代码、数据与本记录一致。}
34
+ \end{document}
@@ -0,0 +1,7 @@
1
+ # AI 工具使用记录
2
+
3
+ 比赛期间每次使用后立即追加,不要在交稿前凭记忆补写。
4
+
5
+ | 日期时间 | 工具、版本与提供方 | 使用目的 | 关键提示词/输入 | 输出摘要 | 采纳内容与人工修改 | 核验方式 |
6
+ | --- | --- | --- | --- | --- | --- | --- |
7
+ | TODO | TODO | TODO | TODO | TODO | TODO | TODO |
@@ -0,0 +1,25 @@
1
+ {
2
+ "schema_version": 1,
3
+ "profile": "cumcm-2026",
4
+ "rules_checked_at": "2026-08-05",
5
+ "paper": {
6
+ "max_pdf_mb": 20,
7
+ "max_body_pages": 30,
8
+ "include_support_file_list": true,
9
+ "include_source_appendix": true
10
+ },
11
+ "support": {
12
+ "max_archive_mb": 20,
13
+ "include_ai_log": false
14
+ },
15
+ "ai": {
16
+ "policy": "cumcm-2026",
17
+ "used": true,
18
+ "declaration_before_references": true,
19
+ "details_pdf_required": true
20
+ },
21
+ "sources": [
22
+ "https://www.mcm.edu.cn/html_cn/node/4cd596519c9eb9fbd866398f6df0caa3.html",
23
+ "https://www.mcm.edu.cn/html_cn/node/fef94648f2836ab6cc81586f4c38512b.html"
24
+ ]
25
+ }
@@ -0,0 +1,53 @@
1
+ \documentclass[UTF8,12pt,a4paper]{ctexart}
2
+
3
+ \usepackage[a4paper,margin=2.5cm]{geometry}
4
+ \usepackage{amsmath,amssymb,bm}
5
+ \usepackage{booktabs,longtable,tabularx,array,multirow}
6
+ \usepackage{graphicx,float,caption,subcaption}
7
+ \usepackage{siunitx}
8
+ \usepackage{enumitem}
9
+ \usepackage{xcolor}
10
+ \usepackage{fancyhdr}
11
+ \usepackage{fvextra}
12
+ \usepackage{hyperref}
13
+
14
+ \hypersetup{hidelinks}
15
+ \urlstyle{same}
16
+ \IfFontExistsTF{Microsoft YaHei}
17
+ {\setCJKmonofont{Microsoft YaHei}}
18
+ {\setCJKmonofont{FandolFang-Regular}}
19
+ \graphicspath{{../figures/}}
20
+ \captionsetup{font=small,labelsep=quad}
21
+ \setlength{\parindent}{2em}
22
+ \setlength{\parskip}{0pt}
23
+ \setlist{nosep}
24
+ \pagestyle{plain}
25
+ \newcommand{\TODO}[1]{\textcolor{red}{\textbf{TODO[#1]}}}
26
+ \newcommand{\papertitle}{TODO[填写能够概括方法与对象的论文标题]}
27
+
28
+ \begin{document}
29
+
30
+ \begin{center}
31
+ {\zihao{2}\bfseries \papertitle}
32
+ \end{center}
33
+
34
+ \vspace{1.2em}
35
+ \input{sections/abstract}
36
+
37
+ \clearpage
38
+ \setcounter{page}{2}
39
+ \input{sections/problem-restatement}
40
+ \input{sections/problem-analysis}
41
+ \input{sections/assumptions}
42
+ \input{sections/data}
43
+ \input{sections/questions}
44
+ \input{sections/evaluation}
45
+ \input{sections/ai-disclosure}
46
+ \input{sections/references}
47
+ \label{body-end}
48
+
49
+ \clearpage
50
+ \appendix
51
+ \input{sections/appendix}
52
+
53
+ \end{document}
@@ -0,0 +1,6 @@
1
+ \noindent\textbf{摘要:}
2
+ \TODO{写清研究对象、每问采用的方法、关键数值结果及主要检验;不写背景套话。}
3
+
4
+ \vspace{0.8em}
5
+ \noindent\textbf{关键词:}
6
+ \TODO{填写3--5个能够检索模型与研究对象的关键词}
@@ -0,0 +1,3 @@
1
+ \section*{AI工具使用声明}
2
+
3
+ 本参赛队在竞赛过程中使用了AI工具,主要用于\TODO{如实简述用途,例如代码调试、论文一致性检查等},详细使用情况见支撑材料。
@@ -0,0 +1,9 @@
1
+ \IfFileExists{sections/support-files.tex}{%
2
+ \section{支撑材料文件列表}
3
+ \input{sections/support-files}
4
+ }{}
5
+
6
+ \IfFileExists{sections/source-code.tex}{%
7
+ \section{程序代码}
8
+ \input{sections/source-code}
9
+ }{}
@@ -0,0 +1,5 @@
1
+ \section{模型假设}
2
+
3
+ \begin{enumerate}
4
+ \item \TODO{给出必要假设,并说明它会排除什么情形或带来何种偏差。}
5
+ \end{enumerate}
@@ -0,0 +1,19 @@
1
+ \section{符号说明与数据预处理}
2
+
3
+ \subsection{主要符号}
4
+
5
+ \begin{table}[H]
6
+ \centering
7
+ \caption{主要符号及含义}
8
+ \begin{tabular}{cll}
9
+ \toprule
10
+ 符号 & 含义 & 单位 \\
11
+ \midrule
12
+ \TODO{符号} & \TODO{含义} & \TODO{单位} \\
13
+ \bottomrule
14
+ \end{tabular}
15
+ \end{table}
16
+
17
+ \subsection{数据审计与预处理}
18
+
19
+ \TODO{报告数据规模、缺失/异常/重复情况、单位转换和预处理原则。保留关键诊断证据。}
@@ -0,0 +1,9 @@
1
+ \section{模型评价与推广}
2
+
3
+ \subsection{模型优点}
4
+
5
+ \TODO{结合本题证据说明可解释性、精度、稳健性或计算效率,避免空泛形容。}
6
+
7
+ \subsection{模型局限与改进}
8
+
9
+ \TODO{指出假设、数据、算法或外推范围造成的具体限制,并给出可执行改进方向。}
@@ -0,0 +1,3 @@
1
+ \section{问题分析}
2
+
3
+ \TODO{说明各小题之间的数据流、约束关系与总体求解路线。若依赖关系复杂,插入一张信息密度足够的流程图。}
@@ -0,0 +1,3 @@
1
+ \section{问题重述}
2
+
3
+ \TODO{用自己的语言凝练任务、对象、输入与交付物,不逐句抄写题面。}
@@ -0,0 +1,6 @@
1
+ \begin{thebibliography}{99}
2
+
3
+ \bibitem{todo-reference}
4
+ \TODO{按正文首次引用顺序补充真实、可核验的参考文献。}
5
+
6
+ \end{thebibliography}
@@ -0,0 +1 @@
1
+ \TODO{运行构建脚本后自动生成代码附录}
@@ -0,0 +1,3 @@
1
+ \begin{itemize}
2
+ \item \TODO{运行构建脚本后自动生成支撑材料列表}
3
+ \end{itemize}