便携式代理技能/手册,供 OpenClaw、Her...、Claude、Codex 等代理修订科学稿件并导出为 DOCX/PDF,尤其是...
Use this skill/playbook to turn manuscript source files into Word/PDF-safe submission artifacts. It is written to be usable by OpenClaw, Hermes, Claude, Codex, and other coding or research agents. The goal is not only correct content, but correct rendering in the actual files that authors, reviewers, or journal portals will inspect.
This file is the authoritative workflow. Agents that do not support formal skill metadata can ignore the YAML header and follow the Markdown instructions directly.
AGENTS.md first, then this file for the full workflow.name and description metadata above.Do not assume a specific agent runtime, memory format, tool wrapper, or repository layout. Use the available shell, document, image, and file-inspection tools in the current environment.
Treat this skill as a living checklist. When using it on a real manuscript and discovering a reusable failure mode, formula pattern, DOCX/PDF conversion issue, figure-layout fix, table-rendering fix, or submission-package synchronization problem, update this SKILL.md before finishing if the lesson is likely to recur.
Only add generalizable lessons. Do not add project-specific paths, manuscript titles, private author details, transient filenames, or one-off numerical results unless they describe a reusable workflow pattern.
Good additions:
Bad additions:
manuscript.md, .tex, .docx) and figure/table generation scripts.Screenshots can reflect stale DOCX output. Inspect the current manuscript source and then rebuild.
Search for formula-risk patterns: bash
rg -n "\\$\\$|\\\\\\(|\\\\\\)|\\\\frac|\\\\sum|metric|SE_|Y_\\{|w_\\{|scores\\[|weights\\[" manuscript code
Use inline math for scientific variables with subscripts: $Y_{ij}$, $w_{ij}$, $x_i$.
Do not use code spans for mathematical variables in prose when subscripts matter: avoid `Y_ij` unless referring to a literal column name.
For multi-letter quantities inside display math, use \operatorname{} or \text{} so Word does not space letters apart.
Good: tex
$$\theta = \max\left(0, \min\left(1,
\frac{|\operatorname{metric}_{\text{raw}} - \operatorname{metric}_{\text{processed}}|}
{|\operatorname{metric}_{\text{raw}}|}\right)\right)$$
Risky for Word/PDF export: tex
$$\mathrm{metricValue}_{\mathrm{raw}}$$
This can render as spaced letters in some LibreOffice/PDF conversion paths.
For standard errors and named subscripts, use: tex
$\text{SE}_{\text{raw}}$
$|\operatorname{metric}_{\text{raw}}/t_{\text{raw}}|$
Avoid long code-style formulas in prose. If a formula is conceptually simple but visually fragile, replace code notation with a short sentence and a display equation.
metric_raw, metric_processed, qc_score.Rebuild DOCX from source, then validate ZIP integrity: bash
pandoc manuscript/manuscript.md -o build/manuscript.docx
unzip -t build/manuscript.docx | tail -5
Convert to PDF with LibreOffice: bash
soffice --headless --convert-to pdf --outdir build/pdf_check build/manuscript.docx
pdfinfo build/pdf_check/manuscript.pdf | rg 'Pages|Page size|File size'
Render pages for visual review: bash
rm -rf build/pdf_check/pages
mkdir -p build/pdf_check/pages
pdftoppm -png -r 130 build/pdf_check/manuscript.pdf build/pdf_check/pages/page
subplots_adjust, reduce label density, wrap panel titles, move annotations into empty space, or remove nonessential callout boxes.unzip -t.Copy rebuilt manuscript, figures, scripts, and embedded image folders into the submission/upload directory.
Verify the upload directory is not stale by comparing file sizes/timestamps.
Rebuild and test the final zip: bash
zip -r upload_package_qc.zip upload_package_dir
unzip -t upload_package_qc.zip
\operatorname{} or \text{}.\mathrm{metricValue} renders as spaced letters in PDF: replace with \operatorname{metricValue}.Y_ij instead of showing a subscript: replace code span with $Y_{ij}$.figures/ but wrong in DOCX: the embedded image was stale or missing.When reporting back, give:
unzip -t, PDF conversion, page count, contact sheet or page inspection, zip unzip -t.