$npx -y skills add Aperivue/medsci-skills --skill polish-languageAcademic English consistency linting and non-native (ESL) language polish for medical manuscripts. Deterministically flags abbreviation define-once violations, US/UK spelling drift, hyphen-vs-en-dash numeric ranges, P/p case, hyphenation variants, small-number style, and value/un
| 1 | # Polish-Language Skill |
| 2 | |
| 3 | You help a medical researcher tighten a manuscript's **mechanical language |
| 4 | consistency and clarity** before circulation or submission — the copy-editor |
| 5 | pass that content-focused skills skip. The author is frequently a non-native |
| 6 | (ESL) English writer, so clarity edits must preserve the formal academic |
| 7 | register while never touching facts. |
| 8 | |
| 9 | ## Communication Rules |
| 10 | |
| 11 | - Manuscript content and edits in English. |
| 12 | - Converse with the user in their preferred language. |
| 13 | - Report issues first; only edit after the user approves (see gates below). |
| 14 | |
| 15 | ## Scope boundary (what this skill is, and is not) |
| 16 | |
| 17 | | Concern | Skill | |
| 18 | |---|---| |
| 19 | | Mechanical consistency + ESL clarity (this skill) | **polish-language** | |
| 20 | | Removing AI writing tells / de-AI | `humanize` (it explicitly does **not** do general copy-editing) | |
| 21 | | Drafting or restructuring content | `write-paper` | |
| 22 | | Reporting-guideline item compliance (STROBE, CLAIM, …) | `check-reporting` | |
| 23 | | AI-search-engine optimization (GEO) | `academic-aio` | |
| 24 | | Reference formatting / citation integrity | `manage-refs`, `verify-refs` | |
| 25 | |
| 26 | This skill **never** rewrites scientific claims, changes numeric values, edits |
| 27 | citations, or judges study quality. It only standardizes house style and |
| 28 | improves sentence-level clarity with explicit user approval. |
| 29 | |
| 30 | ## Inputs / Outputs |
| 31 | |
| 32 | - **Input**: a manuscript or section (Markdown / plain text). |
| 33 | - **Output**: (1) a deterministic consistency report, and (2) — only after a |
| 34 | user gate — a clarity-polished revision with a change log limited to style. |
| 35 | |
| 36 | ## Workflow |
| 37 | |
| 38 | ### Phase 1: Deterministic consistency lint (no LLM judgement) |
| 39 | |
| 40 | Run the bundled deterministic linter — it reports, never edits: |
| 41 | |
| 42 | ```bash |
| 43 | python3 scripts/lint_consistency.py path/to/manuscript.md |
| 44 | # add --strict to exit non-zero when any issue is found (CI / pre-submission gate) |
| 45 | ``` |
| 46 | |
| 47 | It flags seven families, each with line numbers and a per-category + total |
| 48 | count: |
| 49 | |
| 50 | 1. **Abbreviations** — used-before-defined, defined-but-unused, defined-twice, |
| 51 | used-but-never-defined (define-once discipline). |
| 52 | 2. **Spelling** — mixed US/UK variants (analyze/analyse, tumor/tumour, …); |
| 53 | reports the minority side against the document's dominant variant. |
| 54 | 3. **Numeric ranges** — hyphen between numbers where an en-dash belongs |
| 55 | (`5-10` → `5–10`). |
| 56 | 4. **p-values** — mixed `P`/`p` case; impossible `P = 0.000`. |
| 57 | 5. **Hyphenation / terminology** — variant forms of one term |
| 58 | (follow-up / followup / "follow up"). |
| 59 | 6. **Small numbers** — single digits 1–9 written as digits in prose. |
| 60 | 7. **Units** — missing space between value and unit (`5mg` → `5 mg`). |
| 61 | |
| 62 | Present the report to the user. The linter output is the source of truth for |
| 63 | what is mechanically wrong; do not invent additional "issues" from memory. |
| 64 | |
| 65 | ### Phase 2: Triage with the user (gate) |
| 66 | |
| 67 | Walk the user through the report. Some flags are author choices (a journal may |
| 68 | mandate UK spelling, or digits for all numbers). **User approval is required** |
| 69 | before any edit — confirm per category which to apply and which to keep. Record |
| 70 | the decisions; do not auto-apply. |
| 71 | |
| 72 | ### Phase 3: Apply mechanical fixes (style-only) |
| 73 | |
| 74 | For each **approved** category, apply the deterministic fix with `Edit`: |
| 75 | - standardize spelling to the chosen variant, |
| 76 | - replace numeric-range hyphens with en-dashes, |
| 77 | - normalize `P`/`p` and fix `P = 0.000` to the reported inequality, |
| 78 | - unify hyphenation, spell out small numbers, add value/unit spaces, |
| 79 | - define each abbreviation once at first use; remove redundant redefinitions. |
| 80 | |
| 81 | Re-run `lint_consistency.py` after editing — the count should drop to the |
| 82 | issues the user chose to keep. This re-run is the verification gate. |
| 83 | |
| 84 | ### Phase 4: ESL clarity polish (optional, gated, style-only) |
| 85 | |
| 86 | If the user requests a clarity pass, improve readability sentence by sentence |
| 87 | while preserving meaning, register, numbers, and citations: |
| 88 | - split run-on sentences; fix article (a/an/the) and preposition usage; |
| 89 | - correct subject–verb agreement and awkward non-native phrasings; |
| 90 | - prefer active voice only where it does not change emphasis or claims. |
| 91 | |
| 92 | Show each proposed change as a before/after diff and get **user review** before |
| 93 | writing. If a sentence's meaning is even slightly uncertain, leave it and ask — |
| 94 | do not guess. Never merge, add, |