paperfit-cli 1.0.0
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.
- package/.claude/commands/adjust-length.md +21 -0
- package/.claude/commands/check-visual.md +27 -0
- package/.claude/commands/fix-layout.md +31 -0
- package/.claude/commands/migrate-template.md +23 -0
- package/.claude/commands/repair-table.md +21 -0
- package/.claude/commands/show-status.md +32 -0
- package/.claude-plugin/README.md +77 -0
- package/.claude-plugin/marketplace.json +41 -0
- package/.claude-plugin/plugin.json +39 -0
- package/CLAUDE.md +266 -0
- package/CONTRIBUTING.md +131 -0
- package/LICENSE +21 -0
- package/README.md +164 -0
- package/agents/code-surgeon-agent.md +214 -0
- package/agents/layout-detective-agent.md +229 -0
- package/agents/orchestrator-agent.md +254 -0
- package/agents/quality-gatekeeper-agent.md +270 -0
- package/agents/rule-engine-agent.md +224 -0
- package/agents/semantic-polish-agent.md +250 -0
- package/bin/paperfit.js +176 -0
- package/config/agent_roles.yaml +56 -0
- package/config/layout_rules.yaml +54 -0
- package/config/templates.yaml +241 -0
- package/config/vto_taxonomy.yaml +489 -0
- package/config/writing_rules.yaml +64 -0
- package/install.sh +30 -0
- package/package.json +52 -0
- package/requirements.txt +5 -0
- package/scripts/benchmark_runner.py +629 -0
- package/scripts/compile.sh +244 -0
- package/scripts/config_validator.py +339 -0
- package/scripts/cv_detector.py +600 -0
- package/scripts/evidence_collector.py +167 -0
- package/scripts/float_fixers.py +861 -0
- package/scripts/inject_defects.py +549 -0
- package/scripts/install-claude-global.js +148 -0
- package/scripts/install.js +66 -0
- package/scripts/install.sh +106 -0
- package/scripts/overflow_fixers.py +656 -0
- package/scripts/package-for-opensource.sh +138 -0
- package/scripts/parse_log.py +260 -0
- package/scripts/postinstall.js +38 -0
- package/scripts/pre_tool_use.py +265 -0
- package/scripts/render_pages.py +244 -0
- package/scripts/session_logger.py +329 -0
- package/scripts/space_util_fixers.py +773 -0
- package/scripts/state_manager.py +352 -0
- package/scripts/test_commands.py +187 -0
- package/scripts/test_cv_detector.py +214 -0
- package/scripts/test_integration.py +290 -0
- package/skills/consistency-polisher/SKILL.md +337 -0
- package/skills/float-optimizer/SKILL.md +284 -0
- package/skills/latex_fixers/__init__.py +82 -0
- package/skills/latex_fixers/float_fixers.py +392 -0
- package/skills/latex_fixers/fullwidth_fixers.py +375 -0
- package/skills/latex_fixers/overflow_fixers.py +250 -0
- package/skills/latex_fixers/semantic_micro_tuning.py +362 -0
- package/skills/latex_fixers/space_util_fixers.py +389 -0
- package/skills/latex_fixers/utils.py +55 -0
- package/skills/overflow-repair/SKILL.md +304 -0
- package/skills/space-util-fixer/SKILL.md +307 -0
- package/skills/taxonomy-vto/SKILL.md +486 -0
- package/skills/template-migrator/SKILL.md +251 -0
- package/skills/visual-inspector/SKILL.md +217 -0
- package/skills/writing-polish/SKILL.md +289 -0
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
version: "1.0"
|
|
2
|
+
description: "常见 LaTeX 模板的排版参数,供 template-migrator 技能调用"
|
|
3
|
+
|
|
4
|
+
templates:
|
|
5
|
+
# ------------------------------------------------------------
|
|
6
|
+
# ICLR 2025 — 单栏,约 9 页
|
|
7
|
+
# ------------------------------------------------------------
|
|
8
|
+
ICLR2025:
|
|
9
|
+
name: "ICLR 2025"
|
|
10
|
+
documentclass: "\documentclass{iclr2025}"
|
|
11
|
+
column_type: single
|
|
12
|
+
default_font_size: 10pt
|
|
13
|
+
text_width: "6.5in"
|
|
14
|
+
column_width: null
|
|
15
|
+
default_figure_width: "\linewidth"
|
|
16
|
+
default_table_width: "\linewidth"
|
|
17
|
+
expected_pages: 9
|
|
18
|
+
float_behavior: "figures and tables float within single column"
|
|
19
|
+
forbidden_packages:
|
|
20
|
+
- "fullpage"
|
|
21
|
+
- "geometry"
|
|
22
|
+
required_packages:
|
|
23
|
+
- "times"
|
|
24
|
+
- "mathptmx"
|
|
25
|
+
macro_substitutions:
|
|
26
|
+
"\theoremstyle": "Use \newtheorem directly"
|
|
27
|
+
page_margins: "1in all sides"
|
|
28
|
+
notes: "ICLR 使用单栏格式,正文约 9 页。不接受跨栏图表。"
|
|
29
|
+
|
|
30
|
+
# ------------------------------------------------------------
|
|
31
|
+
# ECCV 2024 — 双栏,约 14 页
|
|
32
|
+
# ------------------------------------------------------------
|
|
33
|
+
ECCV2024:
|
|
34
|
+
name: "ECCV 2024"
|
|
35
|
+
documentclass: "\documentclass[10pt,twocolumn]{article}"
|
|
36
|
+
column_type: double
|
|
37
|
+
default_font_size: 10pt
|
|
38
|
+
text_width: "7.0in"
|
|
39
|
+
column_width: "3.3in"
|
|
40
|
+
default_figure_width: "\columnwidth"
|
|
41
|
+
default_table_width: "\columnwidth"
|
|
42
|
+
expected_pages: 14
|
|
43
|
+
float_behavior: "single column floats use [htbp]; wide floats use figure* [t]"
|
|
44
|
+
forbidden_packages:
|
|
45
|
+
- "amsthm"
|
|
46
|
+
- "algorithm2e"
|
|
47
|
+
required_packages:
|
|
48
|
+
- "graphicx"
|
|
49
|
+
- "amsmath"
|
|
50
|
+
- "amssymb"
|
|
51
|
+
- "subfigure"
|
|
52
|
+
macro_substitutions:
|
|
53
|
+
"\theoremstyle": "Remove and use \newtheorem without amsthm"
|
|
54
|
+
page_margins: "1in top/bottom, 0.75in left/right"
|
|
55
|
+
notes: "双栏模板。跨栏图表(figure*)仅能放置在页顶。"
|
|
56
|
+
|
|
57
|
+
# ------------------------------------------------------------
|
|
58
|
+
# NeurIPS 2025 — 单栏,约 9 页
|
|
59
|
+
# ------------------------------------------------------------
|
|
60
|
+
NeurIPS2025:
|
|
61
|
+
name: "NeurIPS 2025"
|
|
62
|
+
documentclass: "\documentclass{neurips_2025}"
|
|
63
|
+
column_type: single
|
|
64
|
+
default_font_size: 11pt
|
|
65
|
+
text_width: "5.5in"
|
|
66
|
+
column_width: null
|
|
67
|
+
default_figure_width: "\linewidth"
|
|
68
|
+
default_table_width: "\linewidth"
|
|
69
|
+
expected_pages: 9
|
|
70
|
+
float_behavior: "standard single column floats"
|
|
71
|
+
forbidden_packages:
|
|
72
|
+
- "fullpage"
|
|
73
|
+
- "setspace"
|
|
74
|
+
- "titlesec"
|
|
75
|
+
required_packages:
|
|
76
|
+
- "times"
|
|
77
|
+
- "mathptmx"
|
|
78
|
+
macro_substitutions: {}
|
|
79
|
+
page_margins: "1in all sides"
|
|
80
|
+
notes: "NeurIPS 使用单栏,正文严格 9 页,含附录可超。"
|
|
81
|
+
|
|
82
|
+
# ------------------------------------------------------------
|
|
83
|
+
# CVPR 2024 — 双栏,约 8 页
|
|
84
|
+
# ------------------------------------------------------------
|
|
85
|
+
CVPR2024:
|
|
86
|
+
name: "CVPR 2024"
|
|
87
|
+
documentclass: "\documentclass[10pt,twocolumn,letterpaper]{article}"
|
|
88
|
+
column_type: double
|
|
89
|
+
default_font_size: 10pt
|
|
90
|
+
text_width: "7.0in"
|
|
91
|
+
column_width: "3.3in"
|
|
92
|
+
default_figure_width: "\columnwidth"
|
|
93
|
+
default_table_width: "\columnwidth"
|
|
94
|
+
expected_pages: 8
|
|
95
|
+
float_behavior: "similar to ECCV; wide floats at top of pages"
|
|
96
|
+
forbidden_packages:
|
|
97
|
+
- "amsthm"
|
|
98
|
+
required_packages:
|
|
99
|
+
- "cvpr"
|
|
100
|
+
- "graphicx"
|
|
101
|
+
- "amsmath"
|
|
102
|
+
macro_substitutions:
|
|
103
|
+
"\theoremstyle": "Use \newtheorem directly"
|
|
104
|
+
page_margins: "0.75in left/right, 1in top/bottom"
|
|
105
|
+
notes: "CVPR 双栏,正文 8 页,参考文献不计入页数限制。"
|
|
106
|
+
|
|
107
|
+
# ------------------------------------------------------------
|
|
108
|
+
# IEEE (Transactions) — 双栏,典型 8-12 页
|
|
109
|
+
# ------------------------------------------------------------
|
|
110
|
+
IEEE:
|
|
111
|
+
name: "IEEE Transactions"
|
|
112
|
+
documentclass: "\documentclass[10pt,twocolumn,twoside]{IEEEtran}"
|
|
113
|
+
column_type: double
|
|
114
|
+
default_font_size: 10pt
|
|
115
|
+
text_width: "7.0in"
|
|
116
|
+
column_width: "3.3in"
|
|
117
|
+
default_figure_width: "\columnwidth"
|
|
118
|
+
default_table_width: "\columnwidth"
|
|
119
|
+
expected_pages: null # 期刊无严格页数,取决于具体期刊
|
|
120
|
+
float_behavior: "IEEEtran 使用特有的浮动体放置规则,支持 dblfloatfix 宏包"
|
|
121
|
+
forbidden_packages:
|
|
122
|
+
- "algorithm2e"
|
|
123
|
+
- "subfigure"
|
|
124
|
+
required_packages:
|
|
125
|
+
- "graphicx"
|
|
126
|
+
- "amsmath"
|
|
127
|
+
- "cite"
|
|
128
|
+
macro_substitutions:
|
|
129
|
+
"algorithm2e": "Use algorithmic or algorithm2e with compatibility option"
|
|
130
|
+
page_margins: "0.75in left/right, 1in top/bottom"
|
|
131
|
+
notes: "IEEEtran 对浮动体有特殊处理,跨栏图表可使用 figure* 和 table*。"
|
|
132
|
+
|
|
133
|
+
# ------------------------------------------------------------
|
|
134
|
+
# ACL 2024 — 单栏,约 8 页
|
|
135
|
+
# ------------------------------------------------------------
|
|
136
|
+
ACL2024:
|
|
137
|
+
name: "ACL 2024"
|
|
138
|
+
documentclass: "\documentclass[11pt]{article}"
|
|
139
|
+
column_type: single
|
|
140
|
+
default_font_size: 11pt
|
|
141
|
+
text_width: "6.0in"
|
|
142
|
+
column_width: null
|
|
143
|
+
default_figure_width: "\linewidth"
|
|
144
|
+
default_table_width: "\linewidth"
|
|
145
|
+
expected_pages: 8
|
|
146
|
+
float_behavior: "standard single column floats"
|
|
147
|
+
forbidden_packages:
|
|
148
|
+
- "geometry"
|
|
149
|
+
required_packages:
|
|
150
|
+
- "acl"
|
|
151
|
+
- "times"
|
|
152
|
+
macro_substitutions: {}
|
|
153
|
+
page_margins: "1in all sides"
|
|
154
|
+
notes: "ACL 使用 ACL 官方样式文件 acl.sty。"
|
|
155
|
+
|
|
156
|
+
# ------------------------------------------------------------
|
|
157
|
+
# ICML 2024 — 单栏,约 8 页
|
|
158
|
+
# ------------------------------------------------------------
|
|
159
|
+
ICML2024:
|
|
160
|
+
name: "ICML 2024"
|
|
161
|
+
documentclass: "\documentclass{icml2024}"
|
|
162
|
+
column_type: single
|
|
163
|
+
default_font_size: 10pt
|
|
164
|
+
text_width: "6.0in"
|
|
165
|
+
column_width: null
|
|
166
|
+
default_figure_width: "\linewidth"
|
|
167
|
+
default_table_width: "\linewidth"
|
|
168
|
+
expected_pages: 8
|
|
169
|
+
float_behavior: "single column, supports wide tables"
|
|
170
|
+
forbidden_packages:
|
|
171
|
+
- "geometry"
|
|
172
|
+
required_packages:
|
|
173
|
+
- "times"
|
|
174
|
+
macro_substitutions: {}
|
|
175
|
+
page_margins: "1in all sides"
|
|
176
|
+
notes: "ICML 单栏,8 页正文,附录无限。"
|
|
177
|
+
|
|
178
|
+
# ------------------------------------------------------------
|
|
179
|
+
# AAAI 2025 — 双栏,约 7 页
|
|
180
|
+
# ------------------------------------------------------------
|
|
181
|
+
AAAI2025:
|
|
182
|
+
name: "AAAI 2025"
|
|
183
|
+
documentclass: "\documentclass[letterpaper,twocolumn,10pt]{article}"
|
|
184
|
+
column_type: double
|
|
185
|
+
default_font_size: 10pt
|
|
186
|
+
text_width: "7.0in"
|
|
187
|
+
column_width: "3.3in"
|
|
188
|
+
default_figure_width: "\columnwidth"
|
|
189
|
+
default_table_width: "\columnwidth"
|
|
190
|
+
expected_pages: 7
|
|
191
|
+
float_behavior: "双栏,跨栏图表仅支持页顶"
|
|
192
|
+
forbidden_packages: []
|
|
193
|
+
required_packages:
|
|
194
|
+
- "aaai25"
|
|
195
|
+
- "times"
|
|
196
|
+
macro_substitutions: {}
|
|
197
|
+
page_margins: "0.75in left/right, 1in top/bottom"
|
|
198
|
+
notes: "AAAI 使用双栏,7 页正文,技术报告可扩展至 8 页。"
|
|
199
|
+
|
|
200
|
+
# 全局默认值(当具体模板未定义时使用)
|
|
201
|
+
defaults:
|
|
202
|
+
single_column:
|
|
203
|
+
default_figure_width: "\linewidth"
|
|
204
|
+
default_table_width: "\linewidth"
|
|
205
|
+
float_behavior: "standard"
|
|
206
|
+
double_column:
|
|
207
|
+
default_figure_width: "\columnwidth"
|
|
208
|
+
default_table_width: "\columnwidth"
|
|
209
|
+
float_behavior: "figures use figure* for wide content"
|
|
210
|
+
expected_pages_fallback: 8
|
|
211
|
+
page_margins_fallback: "1in all sides"
|
|
212
|
+
|
|
213
|
+
# 模板检测规则(用于自动识别当前模板)
|
|
214
|
+
detection_rules:
|
|
215
|
+
- pattern: "iclr2025"
|
|
216
|
+
template: ICLR2025
|
|
217
|
+
- pattern: "neurips"
|
|
218
|
+
template: NeurIPS2025
|
|
219
|
+
- pattern: "cvpr"
|
|
220
|
+
template: CVPR2024
|
|
221
|
+
- pattern: "eccv"
|
|
222
|
+
template: ECCV2024
|
|
223
|
+
- pattern: "IEEEtran"
|
|
224
|
+
template: IEEE
|
|
225
|
+
- pattern: "acl"
|
|
226
|
+
template: ACL2024
|
|
227
|
+
- pattern: "icml"
|
|
228
|
+
template: ICML2024
|
|
229
|
+
- pattern: "aaai"
|
|
230
|
+
template: AAAI2025
|
|
231
|
+
- pattern: "twocolumn"
|
|
232
|
+
template: null # 无法确定具体会议,使用双栏默认值
|
|
233
|
+
column_type: double
|
|
234
|
+
|
|
235
|
+
---
|
|
236
|
+
|
|
237
|
+
`config/templates.yaml` 已编写完成。需要继续编写下一个模块吗?可选:
|
|
238
|
+
1. `scripts/compile.sh` — 编译脚本说明
|
|
239
|
+
2. `scripts/parse_log.py` — 日志解析器
|
|
240
|
+
3. `scripts/render_pages.py` — 页图渲染器
|
|
241
|
+
4. `scripts/state_manager.py` — 状态管理器
|