Orchestrates parallel paper processing by splitting into H1 sections and dispatching subagents to run skills like polish, translation, de-ai on .tex or .md files.
How this skill is triggered — by the user, by Claude, or both
Slash command
/paper-polish-workflow:ppw-teamThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
This Skill orchestrates parallel paper processing by splitting a paper into H1 sections and dispatching eligible Skills to subagents. In Phase 19 (current), it validates the proof-of-concept gate by running a single subagent on one section. Full parallel dispatch across all sections is Phase 20.
This Skill orchestrates parallel paper processing by splitting a paper into H1 sections and dispatching eligible Skills to subagents. In Phase 19 (current), it validates the proof-of-concept gate by running a single subagent on one section. Full parallel dispatch across all sections is Phase 20.
Activates on: ppw:team [skill] [file] invocations.
Examples:
| Mode | Default | Behavior |
|---|---|---|
guided | Yes | split -> user confirms sections -> user selects PoC section -> run PoC -> user confirms quality |
direct | skip confirmations, auto-select all body sections and first section for PoC |
Mode inference: "直接" or "direct" in trigger switches to direct mode.
required: [] -- This Skill does not produce academic text itself. It orchestrates other Skills that load their own references at runtime. No reference files are needed by the orchestrator.
Guided mode -- three interaction points via AskUserQuestion:
Direct mode -- skip all three: auto-select all body sections (exclude preamble and bibliography), auto-select first body section for PoC, auto-approve PoC output.
$ARGUMENTS to extract: Skill name (first word) and file path (remaining words).["translation", "polish", "de-ai"].tex or .md format. If file not found or wrong format, report error and stop.{"skill": "ppw:team", "ts": "<ISO timestamp>"} to .planning/workflow-memory.json. Create file as [] if missing. Drop oldest entry if log length >= 50..paper-team/ directory structure: sections/, output/..paper-team/ already exists: in guided mode, ask to overwrite or cancel; in direct mode, overwrite silently..paper-team/{filename}-backup-{YYYYMMDD-HHmm}.{ext} (timestamped to prevent overwrite on re-runs)..paper-team/manifest.json:{
"version": "1.0",
"created": "<ISO timestamp>",
"source_file": "<original file path>",
"source_format": "tex|md",
"target_skill": "<skill name>",
"sections": [],
"poc": { "section_id": null, "status": "pending", "timestamp": null },
"backup": "<backup filename>"
}
For .tex files:
\begin{document} (inclusive). Label "00 - Preamble".\bibliography{} or \printbibliography through \end{document}. Label "99 - Bibliography".\section command. Match \section followed by optional * and optional [...] then {...}. Ignore lines starting with % (LaTeX comments).\begin{document} and the first \section{} is "00 - Pre-section content" (if non-empty after trimming).\section{Title} line through the line before the next \section{ or the bibliography boundary.For .md files:
# heading. Label "00 - Frontmatter" (if non-empty).# (H1 headings).# is one section.Section file naming: {NN}-{sanitized-title}.{ext} where NN = zero-padded sequence number, sanitized-title = title lowercased, spaces to hyphens, special chars removed, max 50 chars. Preamble: 00-preamble.{ext}. Pre-section: 00-presection.{ext}. Bibliography: 99-bibliography.{ext}. Frontmatter: 00-frontmatter.md.
Edge cases:
\section{} commands: treat entire body as "01 - Full Body".Write each section to .paper-team/sections/{filename}. Update manifest.json sections array with { "id": "NN", "title": "...", "file": "sections/filename", "selected": false, "status": "pending" } for each section.
Guided mode: Present all detected sections via AskUserQuestion multiSelect:
AskUserQuestion({
question: "Select sections to process with ppw:{skill}:\n选择要用 ppw:{skill} 处理的章节:",
multiSelect: true,
options: [
{ label: "NN - Title", description: "brief description or first line" }
]
})
Update manifest.json to set selected: true for chosen sections.
Direct mode: Auto-select all sections EXCEPT those with id "00" (preamble/presection/frontmatter) and "99" (bibliography). Update manifest accordingly. Display selected sections to user.
Guided mode: Present selected sections via AskUserQuestion (single select):
AskUserQuestion({
question: "Select one section for proof-of-concept test:\n选择一个章节进行概念验证测试:",
options: [
{ label: "NN - Title", description: "will be processed by a subagent" }
]
})
Direct mode: Auto-select the first selected section (lowest NN number among selected).
.claude/skills/ppw-{skill}/SKILL.md. If not found, report error: "Skill ppw:{skill} not found at .claude/skills/ppw-{skill}/SKILL.md" and stop..paper-team/sections/{file}.You are executing a paper section processing task in direct mode.
## Skill Instructions
{FULL CONTENT OF TARGET SKILL.MD INSERTED HERE}
## Task
Process the following paper section file using the Skill instructions above.
- Input file: .paper-team/sections/{section-filename}
- Mode: direct (skip all AskUserQuestion calls, skip Workflow Memory Step 0)
- Write output to: .paper-team/output/{section-filename}
- Do NOT ask the user any questions. Proceed with defaults.
- Load all required references as specified in the Skill instructions.
- Produce output as if you were running the Skill directly on this section.
- If the Skill normally edits in-place, instead write the processed output to the output path above.
manifest.json: set poc.section_id, poc.status to "completed", poc.timestamp to current ISO timestamp. Set the section's status to "completed".Guided mode: Read the subagent output from .paper-team/output/{file}. Display a brief excerpt (first 20-30 lines) to the user. Then ask:
AskUserQuestion({
question: "PoC gate: Is the subagent output quality acceptable?\n概念验证:子代理输出质量是否可接受?",
options: [
{ label: "Approved - PoC gate passed", description: "Quality is comparable to main-session execution" },
{ label: "Retry", description: "Re-run PoC on the same section" },
{ label: "Exit", description: "Stop orchestration, quality is not acceptable" }
]
})
manifest.json poc.status to "passed". Display: "PoC gate passed. The ppw:team orchestrator is validated. To process all sections in parallel, use Phase 20's parallel dispatch (coming soon)."manifest.json poc.status to "failed". Display message and suggest running the Skill directly: "/ppw:{skill} {file}"Direct mode: Auto-approve (set poc.status to "passed"), display the first 10 lines of output and the success message.
| Output | Format | Condition |
|---|---|---|
section_files | Individual files in .paper-team/sections/ | Always produced after Step 3 |
manifest | .paper-team/manifest.json | Always produced, updated throughout workflow |
poc_output | Single file in .paper-team/output/ | Produced after Step 6 |
| Situation | Handling |
|---|---|
Paper has no \section{} commands | Treat entire body as one section "01 - Full Body" |
| Paper has only one section | Warn parallel processing has no benefit; proceed with PoC |
| File path has spaces | Quote file paths in all Read/Write operations |
.paper-team/ already exists | Ask to overwrite or cancel (guided) / overwrite silently (direct) |
| Subagent fails or times out | Report error, suggest retry or exit |
\section*{} (unnumbered) | Match as section boundary (pattern includes optional *) |
\section[short]{long} (optional arg) | Match as section boundary (pattern includes optional [...]) |
| Empty section (no content between boundaries) | Skip empty sections, do not create files |
| Scenario | Fallback |
|---|---|
| Structured Interaction unavailable | Ask plain-text questions for section selection |
| Agent tool fails | Report error; suggest running Skill directly on the section |
| Target Skill SKILL.md not found | Report: "Skill ppw:{skill} not found at .claude/skills/ppw-{skill}/SKILL.md" |
.planning/workflow-memory.json missing | Create as [] before appending |
Skill: ppw-team Conventions: references/skill-conventions.md
npx claudepluginhub lylll9436/paper-polish-workflow-skill --plugin paper-polish-workflowAcademic writing multi-agent orchestrator. TRIGGER when: user is editing .tex files, reviewing thesis/paper chapters, drafting academic content, checking writing quality, or analyzing research positioning. Coordinates specialist agents in parallel for review, research, drafting, polishing, figure work, bibliography auditing, and literature surveys.
Provides systematic top-down workflow to polish academic papers: structure to logic to expression with user confirmations at each step. Activates on requests to revise or improve papers section-by-section.
Multi-agent pipeline for academic paper writing with 10 modes, 6 paper types, 5 citation formats, and bilingual abstracts. Outputs LaTeX, DOCX via Pandoc, PDF.