By OpenRaiser
Automates visual typesetting optimization for LaTeX academic papers: detects layout defects (overfull boxes, widows, float issues), applies minimal fixes, migrates between conference templates, and adjusts page count through iterative visual proofing.
**作用**: 对当前 LaTeX 项目执行完整的视觉排版优化(VTO)闭环
**作用**: 仅执行视觉检测,输出诊断报告,不修改源文件。它是专家快捷入口,对应的普通自然语言请求如“检查这篇论文的视觉排版问题”“先做诊断不要改源码”也应能触发同类任务。
**作用**: 针对指定表格或当前论文中的表格问题执行修复闭环。它是专家快捷入口;普通自然语言如“修 Table 2 太挤的问题”也应能触发同类任务。
**作用**: 尝试通过排版微调或受控语义改写逼近目标页数。它是专家快捷入口;普通自然语言如“把正文压到 8 页,尽量不要改语义”也应能触发同类任务。
**作用**: 将论文从原模板迁移至目标模板,自动处理图表尺寸、页数、宏兼容性等问题。它是专家快捷入口;普通自然语言如“把这篇论文迁移到 CVPR 模板”也应能触发同类任务。
你是 **Orchestrator Agent**(主调度器),是 PaperFit 系统的中央协调者。你的核心职责是:
`layout-detective-agent` 是 PaperFit 的视觉诊断 Agent。它的职责只有一个:基于 PDF 页图、交叉引用与日志线索,判断论文当前到底有哪些可见排版问题,以及这些问题的严重程度。
你是 **Rule Engine Agent**(规则引擎),是 PaperFit 系统中专门负责 **解析编译日志、识别确定性错误与警告** 的智能体。你的核心职责是:
`code-surgeon-agent` 是 PaperFit 的源码执行器。它负责把上游已经决定的修复策略安全地落到 `.tex` 上,再把修改结果交回闭环。
`semantic-polish-agent` 只负责受控语义修改,而且只能在排版手段已经用尽后出场。它不是常规修复主路径,而是最后阶段的受限补充能力。
本技能专门处理 **Category C:排版一致性缺陷**,包括:
本技能专门处理 **Category B:浮动体缺陷**,包括:
本技能专门处理 **Category D:溢出与对齐缺陷**,包括:
本技能专门处理 **Category A:空间利用缺陷**,包括:
本技能为 **Visual Typesetting Optimization (VTO)** 任务提供完整的视觉排版缺陷分类知识库。它是 `layout-detective-agent` 进行逐页视觉诊断的核心参考手册,定义了每一类缺陷的**视觉特征、诊断方法、严重等级判定**以及与编译日志信号的对应关系。
Uses power tools
Uses Bash, Write, or Edit tools
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Vision-in-the-Loop Academic Typesetting Agent System
PaperFit 是面向 Claude Code、Codex、Cursor 的 LaTeX 论文排版 Agent System。你只需要在论文项目根目录描述目标,PaperFit 会自动完成编译、页图渲染、视觉诊断、源码修复与最终验收。
论文的 LaTeX 编译通过,并不代表版面已经合格。真实投稿前常见的问题往往发生在视觉层面:浮动体堆在一起、双栏页面出现大面积空洞、表格风格不一致、公式或表格溢出、模板迁移后对象位置失控。这些问题很难只靠 .log 文件发现,也很难靠一次性文本改写稳定解决。
PaperFit 把论文排版视为一个视觉闭环任务:先把 PDF 渲染成页面图像,再结合 LaTeX 日志、交叉引用和模板规则判断问题,最后回写源码并重新渲染验收。它的目标不是替代作者写论文,而是把“看版面、修源码、再检查”的重复劳动交给 Agent。
| 传统方式 | PaperFit |
|---|---|
| 主要关注编译错误 | 同时关注编译、视觉版面和内容完整性 |
| 人工翻 PDF 找问题 | 页图渲染后按缺陷类型系统诊断 |
| 手动调整浮动体和表格 | 由 Agent 生成修复策略并受控改源码 |
| 模板迁移后逐页救火 | 将模板规则、栏型、浮动体和表格一起处理 |
| 修完后靠肉眼确认 | 用视觉门禁决定继续修复还是交付 |
| 能力 | 说明 |
|---|---|
| 视觉排版诊断 | 识别孤行、末页留白、双栏空洞、浮动体堆积、表格不一致、溢出与对齐问题。 |
| 完整 VTO 修复 | 串联编译、日志解析、页图渲染、视觉诊断、源码修复与复验。 |
| 模板迁移 | 支持 CVPR、ICLR、ACL、ACM 等常见学术模板之间的迁移与版式重整。 |
| 页数控制 | 在目标页数预算下优先做版式级调整,必要时进行最小、可审计的语义微调。 |
| 局部对象修复 | 针对单个表格、图、公式或页面问题执行更小范围的修复。 |
| 跨宿主分发 | 同一套能力可安装到 Claude Code、Codex、Cursor。 |
下面的案例来自 PaperFit 的真实排版修复效果展示。
安装完成后,在论文项目根目录直接对宿主说目标即可:
用 PaperFit 分析这篇论文的排版问题
Use the paperfit agent to inspect this paper's layout and tell me the main visual defects
用 PaperFit 把这篇论文迁移到 CVPR 模板,并尽量保持图表和引用稳定
用 PaperFit 把正文压到 8 页,尽量不要改学术内容
PaperFit 会自动推断主 .tex 文件、当前模板、页面预算和需要进入的修复路径。只有在项目结构不清楚、环境缺失或目标本身有歧义时,它才需要你补充信息。
18+3.8+tectonic、pdflatex 或模板要求的工具链macOS 上可安装 Poppler:
brew install poppler
npm install -g paperfit-cli
paperfit-install --target claude
也可以安装到其他宿主:
paperfit-install --target codex
paperfit-install --target cursor --project /path/to/paper
paperfit-install --target all
安装后建议运行一次体检,并安装 Python 依赖:
paperfit doctor --target claude
pip3 install -r "$(npm root -g)/paperfit-cli/requirements.txt"
git clone https://github.com/OpenRaiser/PaperFit.git
cd PaperFit
npm install
bash install.sh --local --target claude
Claude Code 插件市场安装:
/plugin marketplace add OpenRaiser/PaperFit
/plugin install paperfit@paperfit-vto
Codex provider 相关说明见 docs/CODEX_PROVIDER_SETUP.md。
PaperFit 的推荐入口是自然语言,而不是记忆内部命令。
| 宿主 | 推荐入口 |
|---|---|
Claude Code | /paperfit 后描述排版目标;也可使用 /fix-layout、/check-visual、/repair-table 等快捷命令。 |
Codex | 明确请求 Use the paperfit agent to ...,之后可通过 /agent 切回已创建的 PaperFit agent 线程。 |
Cursor | 在论文项目中描述任务,项目级 rule 会引导 Cursor 调用 PaperFit 能力。 |
常见任务:
| 任务 | 示例 |
|---|---|
| 排版分析 | 用 PaperFit 分析 main.tex 的视觉排版问题 |
| 完整修复 | Use the paperfit agent to run a full layout repair loop |
| 视觉检查 | Use PaperFit for visual inspection only |
| 表格修复 | 用 PaperFit 修复这个跨栏表格,不要用 resizebox 硬压缩 |
| 模板迁移 | 用 PaperFit 把这篇论文迁移到 CVPR 模板 |
| 长度调整 | 用 PaperFit 把正文压到 8 页,语义修改要最小 |
| 状态查看 | Use the paperfit agent to summarize the current layout status |
PaperFit 的闭环可以概括为:
LaTeX project
-> compile and parse logs
-> render PDF pages
-> diagnose visual defects
-> plan source-level repairs
-> patch LaTeX safely
-> recompile and rerender
-> gatekeeper acceptance
npx claudepluginhub openraiser/paperfit --plugin paperfitDocument and LaTeX formatting skills for publication-quality output
16-Skill Claude Code plugin for academic paper writing, polishing, and submission.
学术论文写作 — 12 agent 协作:结构设计、段落写作、引用合规、双语摘要、格式排版
Multi-agent orchestrator for academic writing: 12 specialist agents and 30 writing principles for review, research, drafting, polishing, bibliography auditing, and literature surveys.
Verify academic paper citations: extract references from LaTeX/PDF, check formatting, verify existence via Crossref/Semantic Scholar, and score thematic/semantic relevance.
Research-team agents for Claude Code: supervisor, analysis-implementer, paper-writer, figure-descriptor, reviewer, literature-curator.