CommunityWriting & Editinggithub.com

paper-audit

Deterministic, offline Academic De-AI Auditor & Closed-Loop Polishing Skill for Claude Code, Codex, OpenCode, and Cursor. Runs sub-10ms rule-based audits on .docx/.tex/.md/.txt academic manuscripts (80+ bilingual CN/EN AI clichés, sentence-length burstiness, uniform-run rhythm, language parity, quantitative number & citation preservation) before and after every LLM rewrite pass, preventing silent LLM drift and AI-template leakage.

What is paper-audit?

paper-audit is a Claude Code agent skill that deterministic, offline Academic De-AI Auditor & Closed-Loop Polishing Skill for Claude Code, Codex, OpenCode, and Cursor. Runs sub-10ms rule-based audits on .docx/.tex/.md/.txt academic manuscripts (80+ bilingual CN/EN AI clichés, sentence-length burstiness, uniform-run rhythm, language parity, quantitative number & citation preservation) before and after every LLM rewrite pass, preventing silent LLM drift and AI-template leakage.

Works with✓Claude Code✓Codex CLI✓Cursor✓OpenCode
npx skills add https://github.com/Tomsabay/academic-deai-audit/tree/HEAD/skills/paper-audit

Installed? Explore more Writing & Editing skills: steipete/notion, langchain-ai/langchain, bytedance/podcast-generation · View all 6 →

Ask in your favorite AI

Open a new chat with this agent skill pre-loaded.

Documentation

Academic De-AI Audit & Closed-Loop Polishing Skill

Use this skill whenever polishing, revising, translating, or de-AI-ing an academic manuscript (Chinese or English, .docx / .tex / .md / .txt).

Core Principle: Never Trust an LLM Self-Review Alone

LLMs routinely inject template transitions (值得注意的是, 综上所述, delve into, pivotal role), flatten sentence lengths into robotic uniform rhythms, silently drop numbers/citations, or drift between Chinese and English — and then praise their own output when asked "did you remove AI taste?".

Always wrap academic rewriting in a deterministic closed-loop verification harness using paper_audit.py.

Mandatory 4-Step Closed-Loop Protocol

Step 1 — Baseline Deterministic Audit (Before Rewriting)

Run the zero-dependency auditor on the user's draft first:

python3 paper_audit.py draft.docx --json

Read:

  • cliche_hits: exact high-AIGC phrases present and concrete replacement hints.
  • burstiness_stddev, sent_len_range, max_uniform_run: whether the draft suffers from monotonous sentence length.
  • naturalness_score: baseline 0–100 score.

Step 2 — Targeted Academic Revision

Rewrite the draft following these hard constraints:

  1. Eliminate every flagged cliché using concrete domain verbs, experimental conditions, or causal links (never substitute one AI cliché for another).
  2. Restore natural academic burstiness: alternate short, decisive claim sentences (8–16 words / 12–25 Chinese chars) with richer analytical sentences (25–40 words / 40–70 Chinese chars); avoid 4+ consecutive sentences of similar length.
  3. Preserve every single number, percentage, p-value, and citation marker ([1], \cite{...}, p < 0.05, 94.2%) verbatim.
  4. Strict language & voice parity: never translate a Chinese manuscript into English (or vice versa) unless explicitly asked; preserve original first-person narrative markers when present, and do not inject unnatural colloquial "我/其实" into formal third-person papers.

Step 3 — Pairwise Closed-Loop Guardrail Check (After Rewriting)

Save the revision to a file and run pairwise diff mode against the original draft:

python3 paper_audit.py revised.md --orig draft.docx --strict

Inspect the output:

  • Exit code 0 (PASS): language matches, length ratio is within 0.55–1.95, <=1 newly-introduced cliché, burstiness passed, 0 dropped numbers, 0 dropped citations, voice preserved.
  • Exit code 2 (NEEDS_REVISION): inspect issues and execute at most 1 surgical refinement pass fixing ONLY the reported items.

Step 4 — Monotonic Safety Guard

Compare the refined pass against the previous pass:

  • Accept the refinement only if naturalness_score improved (or stayed equal while fixing a hard guardrail like dropped numbers/citations or language drift).
  • Never accept a refinement pass that increases total_cliche_occurrences or breaks language_match / missing_numbers / missing_citations.

Visual Word Diff & Multi-Agent Journal Style Alignment

For authors who prefer a visual web workbench with 6-Agent closed-loop journal style fusion (Nature / JACS / IEEE / 经济研究 presets), interactive red/green Diff approval, and format-preserving .docx export, see StyleFuse v2.

Related Skills