init-latex-project

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Initialize LaTeX Academic Project

初始化LaTeX学术项目

Set up a complete LaTeX academic paper project from the standard template.
基于标准模板搭建完整的LaTeX学术论文项目。

Skill Directory Layout

技能目录结构

<installed-skill-dir>/
├── SKILL.md
├── sources.yaml                    # Authoritative download sources per venue (verified)
├── templates/
│   ├── macros.tex                  # Full math macro library
│   ├── main.tex                    # Generic arXiv/whitepaper template
│   ├── CLAUDE.md                   # Writing rules for AI agents
│   └── venues/
│       ├── icml/main.tex           # ICML two-column template
│       ├── acl/main.tex            # ACL/*ACL single-column template
│       ├── emnlp/main.tex          # EMNLP (same acl.sty as ACL)
│       ├── naacl/main.tex          # NAACL (same acl.sty as ACL)
│       ├── iccv/main.tex           # ICCV two-column template
│       ├── eccv/main.tex           # ECCV single-column (Springer LNCS)
│       ├── neurips/main.tex        # NeurIPS single-column template
│       ├── iclr/main.tex           # ICLR single-column template
│       ├── cvpr/main.tex           # CVPR two-column template
│       └── acm/main.tex            # ACM SIGCONF template
└── scripts/
    └── init.sh                     # Builds project + downloads official style files
<installed-skill-dir>/
├── SKILL.md
├── sources.yaml                    # 各会议权威下载源(已验证)
├── templates/
│   ├── macros.tex                  # 完整数学宏包库
│   ├── main.tex                    # 通用arXiv/白皮书模板
│   ├── CLAUDE.md                   # AI Agent写作规则
│   └── venues/
│       ├── icml/main.tex           # ICML双栏模板
│       ├── acl/main.tex            # ACL/*ACL单栏模板
│       ├── emnlp/main.tex          # EMNLP(与ACL使用相同的acl.sty)
│       ├── naacl/main.tex          # NAACL(与ACL使用相同的acl.sty)
│       ├── iccv/main.tex           # ICCV双栏模板
│       ├── eccv/main.tex           # ECCV单栏模板(Springer LNCS格式)
│       ├── neurips/main.tex        # NeurIPS单栏模板
│       ├── iclr/main.tex           # ICLR单栏模板
│       ├── cvpr/main.tex           # CVPR双栏模板
│       └── acm/main.tex            # ACM SIGCONF模板
└── scripts/
    └── init.sh                     # 构建项目并下载官方样式文件

How venue_preamble.tex works

venue_preamble.tex 的工作原理

Every venue template uses
\input{venue_preamble}
instead of a hardcoded
\usepackage{neurips_<year>}
.
init.sh
downloads the official
.sty
/
.bst
files from the venue's authoritative source (see
sources.yaml
), detects the actual filename, and writes
venue_preamble.tex
automatically.
project/
├── main.tex              ← \input{venue_preamble}  (stable, never changes)
├── venue_preamble.tex    ← generated by init.sh  (edit here to change mode)
├── neurips_<year>.sty    ← downloaded from neurips.cc
└── ...
To switch submission mode (e.g., anonymous → camera-ready), only edit
venue_preamble.tex
main.tex
never needs to change.

每个会议模板都使用
\input{venue_preamble}
而非硬编码的
\usepackage{neurips_<year>}
init.sh
会从会议的权威源(详见
sources.yaml
)下载官方
.sty
/
.bst
文件,检测实际文件名,并自动生成
venue_preamble.tex
project/
├── main.tex              ← \input{venue_preamble} (稳定,无需修改)
├── venue_preamble.tex    ← 由init.sh生成(可在此编辑切换提交模式)
├── neurips_<year>.sty    ← 从neurips.cc下载
└── ...
如需切换提交模式(例如:匿名版→终稿版),仅需编辑
venue_preamble.tex
——
main.tex
无需任何改动。

Steps to Follow

操作步骤

1. Parse
$ARGUMENTS

1. 解析
$ARGUMENTS
参数

Position/FlagMeaningRequired
First wordProject nameYes
Second wordTarget directory (default: current dir)No
--venue <name>
Conference venueNo
--git
Initialize git repoNo
--offline
Skip style-file download (creates placeholder venue_preamble.tex)No
Supported venues (by deadline month):
VenueMonthStyleSource
icml
Jantwo-columnicml.cc
acl
Febsingle-columngithub.com/acl-org/acl-style-files
iccv
Mar (biennial, odd)two-columnCVF / iccv.thecvf.com
eccv
Mar (biennial, even)single-column (LNCS)github.com/paolo-favaro/paper-template
neurips
Maysingle-columnneurips.cc
emnlp
Maysingle-columngithub.com/acl-org/acl-style-files
iclr
Sepsingle-columngithub.com/ICLR/Master-Template
cvpr
Novtwo-columngithub.com/cvpr-org/author-kit
naacl
Decsingle-columngithub.com/acl-org/acl-style-files
acm
variessingle-columnCTAN (pre-installed)
位置/标志含义是否必填
第一个单词项目名称
第二个单词目标目录(默认:当前目录)
--venue <name>
目标会议
--git
初始化git仓库
--offline
跳过样式文件下载(生成占位符venue_preamble.tex)
支持的会议(按截止月份排序):
会议截止月份版式来源
icml
1月双栏icml.cc
acl
2月单栏github.com/acl-org/acl-style-files
iccv
3月(两年一届,奇数年)双栏CVF / iccv.thecvf.com
eccv
3月(两年一届,偶数年)单栏(LNCS格式)github.com/paolo-favaro/paper-template
neurips
5月单栏neurips.cc
emnlp
5月单栏github.com/acl-org/acl-style-files
iclr
9月单栏github.com/ICLR/Master-Template
cvpr
11月双栏github.com/cvpr-org/author-kit
naacl
12月单栏github.com/acl-org/acl-style-files
acm
不固定单栏CTAN(预安装)

2. Run the init script

2. 运行初始化脚本

bash
bash <init-latex-project-skill-dir>/scripts/init.sh <project-name> [target-dir] [--venue <venue>] [--git]
Important: Resolve
<init-latex-project-skill-dir>
as the installed directory for this skill and use the absolute path to
init.sh
. Do not assume a Claude-specific install path.
bash
bash <init-latex-project-skill-dir>/scripts/init.sh <project-name> [target-dir] [--venue <venue>] [--git]
重要提示:请将
<init-latex-project-skill-dir>
替换为该技能的安装目录,并使用
init.sh
的绝对路径。不要假设特定的Claude安装路径。

3. Offer to immediately customize

3. 提供即时定制选项

After the script runs, ask the user if they want to:
  • Update
    sections/title.tex
    with their actual title
  • Fill in authors and affiliations in
    main.tex
  • Any other immediate adjustments
脚本运行完成后,询问用户是否需要:
  • 更新
    sections/title.tex
    中的实际标题
  • main.tex
    中填写作者及所属机构信息
  • 其他即时调整需求

4. Print the script's output to the user

4. 向用户展示脚本输出内容

The script prints a file tree and venue-specific setup notes. Make sure the user sees these.

脚本会打印文件目录树和会议专属设置说明,请确保用户能看到这些信息。

Venue Details

会议细节说明

All sources are verified in
sources.yaml
.
init.sh
downloads style files automatically. Edit
venue_preamble.tex
to switch submission mode.
所有源文件均已在
sources.yaml
中验证。
init.sh
会自动下载样式文件。编辑
venue_preamble.tex
即可切换提交模式。

ICML — Jan deadline

ICML — 1月截止日期

  • Layout: Two-column
  • Doc class:
    article
    +
    \usepackage{icml{YEAR}}
    (year-specific)
  • Bibliography:
    icml{YEAR}.bst
  • MANDATORY:
    sections/impact.tex
    (Broader Impact, no page limit)
  • Note: Uses ICML-specific author macros (
    \icmltitle
    ,
    \icmlauthor
    , etc.)
  • 版式:双栏
  • 文档类
    article
    +
    \usepackage{icml{YEAR}}
    (按年份区分)
  • 参考文献
    icml{YEAR}.bst
  • 必填项
    sections/impact.tex
    (更广泛影响说明,无页数限制)
  • 注意:使用ICML专属作者宏命令(
    \icmltitle
    ,
    \icmlauthor
    等)

ACL / EMNLP / NAACL — *ACL family

ACL / EMNLP / NAACL — *ACL系列会议

  • Layout: Single-column
  • Doc class:
    \documentclass[11pt]{article}
    +
    \usepackage[review]{acl}
    (stable name)
  • Bibliography:
    acl_natbib.bst
  • Citations:
    \citet{}
    in-text;
    \cite{}
    /
    \citep{}
    parenthetical
  • MANDATORY:
    sections/limitations.tex
    (no page limit)
  • Required if applicable:
    sections/ethics.tex
  • 版式:单栏
  • 文档类
    \documentclass[11pt]{article}
    +
    \usepackage[review]{acl}
    (名称稳定)
  • 参考文献
    acl_natbib.bst
  • 引用格式:文中使用
    \citet{}
    ;括号引用使用
    \cite{}
    /
    \citep{}
  • 必填项
    sections/limitations.tex
    (局限性说明,无页数限制)
  • 适用时必填
    sections/ethics.tex
    (伦理说明)

ICCV — Mar deadline (biennial, odd years: 2025, 2027, …)

ICCV — 3月截止日期(两年一届,奇数年:2025、2027…)

  • Layout: Two-column (same CVF format as CVPR)
  • Doc class:
    \documentclass[times,10pt,twocolumn,letterpaper]{article}
    +
    \usepackage[review]{iccv}
  • Bibliography:
    ieeenat_fullname.bst
  • Note: Use
    figure*
    /
    table*
    for full-width floats
  • 版式:双栏(与CVPR相同的CVF格式)
  • 文档类
    \documentclass[times,10pt,twocolumn,letterpaper]{article}
    +
    \usepackage[review]{iccv}
  • 参考文献
    ieeenat_fullname.bst
  • 注意:全宽浮动元素使用
    figure*
    /
    table*

ECCV — Mar deadline (biennial, even years: 2024, 2026, …)

ECCV — 3月截止日期(两年一届,偶数年:2024、2026…)

  • Layout: Single-column (Springer LNCS)
  • Doc class:
    \documentclass[runningheads]{llncs}
    NOT article
  • Style:
    eccv.sty
    +
    eccvabbrv.sty
  • Bibliography:
    splncs04.bst
  • Page limit: 14 pages including figures; references uncapped
  • Author format: LNCS
    \author{}\inst{}\institute{}
    macros
  • 版式:单栏(Springer LNCS格式)
  • 文档类
    \documentclass[runningheads]{llncs}
    —— 请勿使用article类
  • 样式
    eccv.sty
    +
    eccvabbrv.sty
  • 参考文献
    splncs04.bst
  • 页数限制:含图表共14页;参考文献无页数限制
  • 作者格式:LNCS专属
    \author{}\inst{}\institute{}
    宏命令

NeurIPS — May deadline

NeurIPS — 5月截止日期

  • Layout: Single-column
  • Doc class:
    article
    +
    \usepackage{neurips_{YEAR}}
    (year-specific)
  • Bibliography:
    unsrtnat
    (numeric, sorted by appearance)
  • Acknowledgments: Use
    {ack}
    environment (auto-hides in anonymous mode)
  • MANDATORY:
    sections/impact.tex
    (Broader Impact, no page limit)
  • MANDATORY:
    sections/checklist.tex
    (Author Checklist, no page limit)
  • 版式:单栏
  • 文档类
    article
    +
    \usepackage{neurips_{YEAR}}
    (按年份区分)
  • 参考文献
    unsrtnat
    (数字编号,按出现顺序排序)
  • 致谢:使用
    {ack}
    环境(匿名模式下自动隐藏)
  • 必填项
    sections/impact.tex
    (更广泛影响说明,无页数限制)
  • 必填项
    sections/checklist.tex
    (作者 checklist,无页数限制)

ICLR — Sep deadline

ICLR — 9月截止日期

  • Layout: Single-column
  • Doc class:
    article
    +
    \usepackage[submitted]{iclr{YEAR}_conference}
    (year-specific)
  • Bibliography:
    iclr{YEAR}_conference.bst
  • Extra:
    sections/impact.tex
    (optional Ethics Statement)
  • 版式:单栏
  • 文档类
    article
    +
    \usepackage[submitted]{iclr{YEAR}_conference}
    (按年份区分)
  • 参考文献
    iclr{YEAR}_conference.bst
  • 附加项
    sections/impact.tex
    (可选伦理声明)

CVPR — Nov deadline

CVPR — 11月截止日期

  • Layout: Two-column
  • Doc class:
    \documentclass[times,10pt,twocolumn,letterpaper]{article}
    +
    \usepackage[review]{cvpr}
    (stable name)
  • Bibliography:
    ieeenat_fullname.bst
  • Note: Use
    figure*
    /
    table*
    for full-width floats
  • 版式:双栏
  • 文档类
    \documentclass[times,10pt,twocolumn,letterpaper]{article}
    +
    \usepackage[review]{cvpr}
    (名称稳定)
  • 参考文献
    ieeenat_fullname.bst
  • 注意:全宽浮动元素使用
    figure*
    /
    table*

ACM — varies

ACM — 截止日期不固定

  • Layout: Single-column (sigconf)
  • Doc class:
    \documentclass[sigconf,review,anonymous]{acmart}
    (pre-installed via CTAN)
  • Bibliography:
    ACM-Reference-Format.bst
  • Camera-ready extras:
    \acmConference
    ,
    \acmDOI
    ,
    \setcopyright
    , CCS concepts

  • 版式:单栏(sigconf格式)
  • 文档类
    \documentclass[sigconf,review,anonymous]{acmart}
    (通过CTAN预安装)
  • 参考文献
    ACM-Reference-Format.bst
  • 终稿附加项
    \acmConference
    ,
    \acmDOI
    ,
    \setcopyright
    , CCS概念

What Is Always Included (Every Venue)

所有会议通用内容

macros.tex
— complete math macro library:
  • Calligraphic
    \calA
    \calZ
    , bold
    \bA
    \bZ
    /
    \ba
    \bz
  • Blackboard bold
    \R
    \E
    \P
    \B
  • Greek shortcuts
    \sG
    \lG
    \tG
    \pa
    \half
  • Operators
    \argmin
    \argmax
    \Softmax
    \Sigmoid
    \Var
  • Sum shortcuts
    \sumN
    \sumK
    \sumM
    \sumT
  • Theorem environments (grey tcolorbox):
    theorem
    lemma
    definition
    remark
    assumption
  • Author comment macros
    \jerry{}
    \wwm{}
    \jieke{}
    etc.
Standard section files (all placeholder):
title.tex
,
abstract.tex
,
intro.tex
,
related.tex
,
method.tex
,
exp.tex
,
conclusion.tex
,
appendix.tex
,
acknowledgement.tex
bib/refs.bib
— empty with usage example

macros.tex
—— 完整数学宏包库:
  • 花体字母
    \calA
    \calZ
    、粗体字母
    \bA
    \bZ
    /
    \ba
    \bz
  • 黑板粗体
    \R
    \E
    \P
    \B
  • 希腊字母快捷命令
    \sG
    \lG
    \tG
    \pa
    \half
  • 算子命令
    \argmin
    \argmax
    \Softmax
    \Sigmoid
    \Var
  • 求和快捷命令
    \sumN
    \sumK
    \sumM
    \sumT
  • 定理环境(灰色tcolorbox):
    theorem
    lemma
    definition
    remark
    assumption
  • 作者注释宏命令
    \jerry{}
    \wwm{}
    \jieke{}
标准章节文件(均为占位符):
title.tex
,
abstract.tex
,
intro.tex
,
related.tex
,
method.tex
,
exp.tex
,
conclusion.tex
,
appendix.tex
,
acknowledgement.tex
bib/refs.bib
—— 空文件,包含使用示例

Example Invocations

调用示例

/init-latex-project my-new-paper                                  # generic arXiv
/init-latex-project my-icml-paper   ~/Papers --venue icml   --git
/init-latex-project my-acl-paper    ~/Papers --venue acl    --git
/init-latex-project my-iccv-paper   .        --venue iccv
/init-latex-project my-eccv-paper   .        --venue eccv
/init-latex-project my-neurips-paper .       --venue neurips --git
/init-latex-project my-emnlp-paper  .        --venue emnlp
/init-latex-project my-iclr-paper   ~/Papers --venue iclr   --git
/init-latex-project my-cvpr-paper   .        --venue cvpr
/init-latex-project my-naacl-paper  .        --venue naacl
/init-latex-project my-acm-paper    .        --venue acm
/init-latex-project my-paper-offline . --venue neurips --offline  # skip download
/init-latex-project my-new-paper                                  # 通用arXiv模板
/init-latex-project my-icml-paper   ~/Papers --venue icml   --git
/init-latex-project my-acl-paper    ~/Papers --venue acl    --git
/init-latex-project my-iccv-paper   .        --venue iccv
/init-latex-project my-eccv-paper   .        --venue eccv
/init-latex-project my-neurips-paper .       --venue neurips --git
/init-latex-project my-emnlp-paper  .        --venue emnlp
/init-latex-project my-iclr-paper   ~/Papers --venue iclr   --git
/init-latex-project my-cvpr-paper   .        --venue cvpr
/init-latex-project my-naacl-paper  .        --venue naacl
/init-latex-project my-acm-paper    .        --venue acm
/init-latex-project my-paper-offline . --venue neurips --offline  # 跳过下载

If the Auto-Download Fails

自动下载失败时的处理

If
init.sh
cannot reach the venue server,
venue_preamble.tex
is created as a placeholder. Fix it:
  1. Visit the venue's author instructions page (URL is in
    sources.yaml
    ).
  2. Download the style zip manually and unpack
    .sty
    /
    .bst
    files into the project root.
  3. Edit
    venue_preamble.tex
    to add the correct
    \usepackage{...}
    line.
As a last resort, use WebSearch to find the current year's download URL and fetch it:
bash
undefined
如果
init.sh
无法连接会议服务器,
venue_preamble.tex
会作为占位符生成。修复步骤:
  1. 访问会议的作者指南页面(URL在
    sources.yaml
    中)。
  2. 手动下载样式压缩包,并将
    .sty
    /
    .bst
    文件解压到项目根目录。
  3. 编辑
    venue_preamble.tex
    添加正确的
    \usepackage{...}
    命令。
如果以上方法无效,可使用WebSearch查找当年的下载链接并获取:
bash
undefined

Example for NeurIPS <year>:

NeurIPS <year>示例:

curl -fsSL https://media.nips.cc/Conferences/<year>/Styles/neurips_<year>.zip -o /tmp/n.zip unzip -j /tmp/n.zip "*.sty" -d /path/to/project/

---
curl -fsSL https://media.nips.cc/Conferences/<year>/Styles/neurips_<year>.zip -o /tmp/n.zip unzip -j /tmp/n.zip "*.sty" -d /path/to/project/

---

Package Conflict Notes

包冲突说明

The
macros.tex
library is loaded last in all venue templates (after venue packages), so our definitions take precedence. Known conflicts:
VenuePotential ConflictResolution
ACM
acmart
redefines
\P
Our
\P = \mathbb{P}
overrides it — intentional
ACM
acmart
has its own
\cite
\let\cite\citep
in macros.tex may interfere — comment it out if needed
CVPRTwo-column layout
tcolorbox
theorem envs may span columns — switch to plain
amsthm
if needed
ICMLUses its own
hyperref
setup
Load macros.tex after
icml<year>
to avoid double-load errors
NeurIPS
algorithmic
vs
algpseudocode
Always use
algpseudocode
(lowercase
\State
,
\Require
, etc.). The older
algorithmic
package uses ALL-CAPS commands and is incompatible with modern algorithm code.
NeurIPS
cleveref
Option Clash
cleveref
must be loaded ONCE, in
main.tex
, AFTER
hyperref
. The macros.tex template also contains
\usepackage[capitalize,noabbrev]{cleveref}
— this causes an Option Clash (
capitalise
vs
capitalize
) when both files are compiled together. Fix: remove or comment out the
cleveref
line from
macros.tex
in NeurIPS projects. The NeurIPS venue template already does this correctly.
ALL
\def\(
,
\def\)
,
\def\[
,
\def\]
in macros.tex
PERMANENTLY DISABLED. These four lines redefined LaTeX's built-in math-mode delimiters (
\( \)
= inline math;
\[ \]
= display math), which broke ALL math environments (
$...$
,
\begin{equation}
,
algorithmic
states, etc.) with cascading "Missing $" and "Extra )" errors. Never re-enable. Use
\left( ... \right)
explicitly instead.
ALL
\usepackage{algorithm}
+
\usepackage{algorithmic}
in macros.tex
PERMANENTLY DISABLED. Loading both
algorithm
/
algorithmic
alongside
algpseudocode
(required by NeurIPS, ICML, ICLR) causes "Command \algorithmicindent already defined" and similar errors. The
algorithm
float wrapper should be loaded once in
main.tex
together with exactly one of
algpseudocode
(modern, recommended) or
algorithmic
(legacy).
macros.tex
库在所有会议模板中最后加载(在会议包之后),因此我们的定义拥有优先级。已知冲突:
会议潜在冲突解决方案
ACM
acmart
重定义
\P
我们的
\P = \mathbb{P
会覆盖它 —— 此为有意设计
ACM
acmart
自带
\cite
命令
macros.tex
中的
\let\cite\citep
可能产生干扰 —— 如有需要可注释该行
CVPR双栏版式
tcolorbox
定理环境可能跨栏 —— 如有需要可切换为普通
amsthm
ICML使用自身的
hyperref
配置
icml<year>
之后加载
macros.tex
以避免重复加载错误
NeurIPS
algorithmic
algpseudocode
冲突
始终使用
algpseudocode
(小写
\State
,
\Require
等)。旧版
algorithmic
包使用全大写命令,与现代算法代码不兼容。
NeurIPS
cleveref
选项冲突
cleveref
必须仅加载一次,在
main.tex
hyperref
之后加载。
macros.tex
模板中也包含
\usepackage[capitalize,noabbrev]{cleveref}
—— 当两个文件一起编译时会导致选项冲突(
capitalise
vs
capitalize
)。修复方法:在NeurIPS项目中删除或注释
macros.tex
中的
cleveref
行。NeurIPS会议模板已正确处理此问题。
所有会议
macros.tex
中的
\def\(
,
\def\)
,
\def\[
,
\def\]
永久禁用。这四行重定义了LaTeX内置的数学模式分隔符(
\( \)
= 行内数学;
\[ \]
= 显示数学),会破坏所有数学环境(
$...$
,
\begin{equation}
,
algorithmic
状态等),引发连锁的"Missing $"和"Extra )"错误。请勿重新启用。如需使用请显式使用
\left( ... \right)
所有会议
macros.tex
中的
\usepackage{algorithm}
+
\usepackage{algorithmic}
永久禁用。同时加载
algorithm
/
algorithmic
algpseudocode
(NeurIPS、ICML、ICLR要求)会导致"Command \algorithmicindent already defined"等类似错误。
algorithm
浮动环境应在
main.tex
中仅加载一次,并搭配
algpseudocode
(现代推荐)或
algorithmic
(旧版)中的其中一个。