Core stance
De-AI-ification is not banning words or injecting a "public account persona" into the text. Handle it according to the following priority:
- Author facts and sources of judgment: do not fabricate experiences, feelings, materials, or changes in stance;
- Paragraph function and information structure: protect categories, steps, responsibility assignment, and necessary repetition;
- Natural expression: remove posturing, templates, semantic dilution, and machine rhythm;
- Voice calibration: only match voice when the user provides or explicitly selects a sample.
When judging a sentence, first ask what function it serves, then ask whether it sounds like AI. Word lists are only for recall and cannot replace reading through.
Scope of responsibility: only revise the body, do not take over the heading structure
de-ai-polish is responsible for the language expression within sentences and paragraphs of the body, not for the article's information architecture. Level-2, level-3 headings and other Markdown ATX headings fall within the responsibility of WeChat Article Writer or the original writing process.
Therefore, by default, implement the following boundaries:
- Preserve the text, level, numbering, and order of all heading lines in the source draft; do not add, delete, rename, promote, demote, or reorder headings;
- Internal paragraph function annotations, temporary groupings, and issue summaries are only for analysis and must not become new headings or numbering in the final draft;
- When hidden lists exist in the body, handle them within the original heading framework by merging, transitioning, causal, temporal, or scenario reorganization, and do not create separate subheadings for each analytical grouping;
- If the heading itself has an obvious template tone, mark it in the report and suggest handing it to WeChat Article Writer for handling; this Skill does not modify it directly;
- If the user separately requests adjustment of the heading system, first complete the de-AI body revision, then hand the heading task to the corresponding writing Skill, and do not mix the two responsibilities into one rewrite.
Usage mode
/de-ai-polish detect @article.md # 只检测并给出 finding
/de-ai-polish fix @article.md # 在原文件上修订并执行交付门禁
detect read-only, do not generate snapshots or modify files.fix must execute the complete workflow.
Read reference materials as needed
- Scan for contamination patterns: read
references/pollution-patterns.md。 - Decide to delete, merge, restore enumeration, or rebuild sentences: read
references/expression-transformations.md。 - Handle consecutive short paragraphs, hidden lists, and functional parallelism: read
references/sentence-rhythm-guide.md。 - Use author samples or local private anchors: read
references/personal-style-guide.md。 - Select local private anchor: first read
assets/local-voice-anchors/config.json; if the user explicitly gives an ID, use that ID; otherwise only readlocal_anchorwhen the user has already selecteddefault_voice_anchor_id. Then read the same directory's<voice_anchor_id>.md. The entire directory stores only local materials and is excluded by the project.gitignore. - Delivery scoring: read
references/quality-scoring.md。
Do not load unrelated reference files all at once.SKILL.md is responsible for the process; details are subject to the corresponding reference.
Startup gate
1. Determine the scenario
| scene | Default intensity | Focus | Protection scope |
|---|---|---|---|
legal_document |
Restrained | Posturing, process, format | Widest |
wechat_public_comment |
Stronger | Template, rhythm, semantic dilution | Standard |
chat_reply |
Minimal | Sycophancy, traces of collaboration | Standard |
general |
Medium | All categories | Standard |
Formal register, procedural terminology, and fixed structures in legal documents are retained by default.
2. Determine voice mode
| voice_mode | Conditions of use | Permitted actions |
|---|---|---|
cleanup_only |
No author samples, or the user has not asked to match a voice | Only clean up and clarify; do not inject a persona |
provided_sample |
The user provides and authorizes samples for this use | Extract a ten-dimensional profile, then match |
local_anchor |
The user explicitly requests use of the local personal voice, and the configuration and corresponding files exist | Calibrate to the deep profile of an explicit ID or the local default anchor |
Local private anchors are not part of the public Skill content.default_voice_anchor_id it is merely a local_anchor default choice within mode; ordinary cleanup_only requests must not be automatically upgraded to personal voice. Sample text, author profiles, highly distinctive phrases, or local registries must not be copied into public configurations, test fixtures, logs, or evaluation metadata.
3. Write the run plan
fix Before rewriting, the mode creates a candidate external run-plan.json:
{
"schema_version": 2,
"scene": "wechat_public_comment",
"voice_mode": "local_anchor",
"voice_anchor_id": "my-writing-anchor-v1",
"protected_spans": []
}
Constraints:
cleanup_onlyofvoice_anchor_idmust benull;provided_sampleUse the stable sample ID for this run; do not write the sample text;local_anchorUse a stable slug asvoice_anchor_id: explicit ID takes priority; if no ID is given, read fromassets/local-voice-anchors/config.jsonreaddefault_voice_anchor_id. Also require that the registry entry and the same-directory<voice_anchor_id>.mdboth exist locally;- When the local anchor is missing, stop voice calibration and fall back to
cleanup_onlyor ask the user to provide samples again; do not pretend it has been read; - Do not backfill scene, voice, or Protected Spans after rewriting.
Complete workflow
Step 1: Read-through, protection, and author evidence
Read the full text completely; do not rely only on regex or grep detection. First understand the problem the article addresses, its core judgments, target readers, and existing tone.
Before any rewriting, generate dual snapshots:
python3 scripts/protected_markdown_gate.py snapshot \
--input <源文件.md> \
--output <临时目录>/de-ai-protected-lines.json
python3 scripts/heading_preservation_gate.py snapshot \
--input <源文件.md> \
--output <临时目录>/de-ai-heading-lines.json
python3 scripts/delivery_gate.py snapshot \
--input <源文件.md> \
--run-plan <临时目录>/run-plan.json \
--output <临时目录>/de-ai-delivery-manifest.json
Write the following into protected_spans and protect verbatim:
- Statutes, judicial interpretations, case numbers, contract clause numbers;
- Full names of parties, institutions, law firms, and companies;
- Procedural terms, direct quotations, and formal citations;
- Numerals, dates, ratios, amounts, deadlines, and URLs;
- Other strings the user requests to preserve;
- Entire Markdown image syntax and the entire line it occupies.
At the same time, fill in the author evidence card in references/personal-style-guide.md for key judgments that require an "author's presence". When material is insufficient, mark AUTHOR_MATERIAL_NEEDED. Do not turn general knowledge into "I found", and do not fabricate real cases or writing experiences.
Do not register recurring thematic words, core concepts, or ordinary terms in the full text as protected_spanthat require exactly the same number of occurrences, for example, "abstract leakage" in the article's own theme. Such words should keep consistent names and retain necessary definitions, but when duplicate paragraphs are deleted, the number of occurrences may decrease. If, after rewriting, a snapshot is found to have mistakenly locked down a generic word, do not mechanically add it back just to pass the gate; discard that candidate, re-select true byte invariants from the read-only source draft and create a new snapshot, and record the reason for the restart.
A full heading line is a structural protection item. Even if a template term is hit within a heading, only a finding is recorded; it is not rewritten in this process.
Step 2: Label paragraph functions
Label each paragraph with one primary function:FACT / EXPERIENCE / JUDGMENT / MECHANISM / EXAMPLE / BOUNDARY / TRANSITION / SUMMARY。
Key checks:
- Whether three consecutive paragraphs are all transitions or summaries, with no new facts or mechanisms;
- Whether the first sentence of each paragraph uses evaluative words to announce that "this item is more important";
- Whether the next paragraph continues the object of the previous paragraph, or restarts by relying on a framework cue;
- Whether claims have sources, and whether inferences are written as facts.
Function labels serve only as an intermediate representation for rewriting; they are not written into the delivered main text, nor may they be converted into new second-level or third-level headings or numbering.
Before scanning and rewriting, also establish an out-of-candidateargument spine ledger. Record paragraph by paragraph the unique information that cannot be replaced by higher-level summaries:
源稿锚点:可定位短片段
唯一载荷:该段新增的对象、区分、因果环节、例外、反方、比较、风险放大因素或认识边界
在全文中的作用:它把上一段推进到哪里
处理:逐项保留 / 合并但保留全部载荷 / 可删除的重复
改稿落点:最终段落位置
The following content enters the spine ledger by default: paragraphs that propose the core distinction; intermediate links that advance an object to the next condition or consequence; distribution judgments such as "risk is not uniform / why a certain layer is more dangerous"; counterexamples, exceptions, opposing views, and cross-domain comparisons; multiple amplifying factors that do not replace one another; materials or epistemic boundaries that explain why the author reaches a conclusion.
Shorter, tidier higher-level summaries cannot replace these payloads. If the source draft first distinguishes risk distribution, then explains why the middle layer is more likely to be trusted, and then lists three amplifying factors, the revision cannot leave only "legal risk is higher." Each 逐项保留 item in the revised text must have a locatable landing point; if no landing point can be found, return to the source draft to restore the mechanism, rather than explaining in the report that it has already been summarized. The argument spine ledger constrains only the main text and does not enter the reader-facing main text.
Step 3: Two independent scans
Before starting, first declare the scope covered and not covered in this round.
Lexical and template layer
Read references/pollution-patterns.md, and scan for stance, contrast, transition, big words, vague frequency, jargon, imposed colloquialism, formatting, and process residue. Frequency only triggers review; it does not automatically determine modification.
Structural and paragraph layer
Independent scan:
- Consecutive identical function words, question words, passive constructions, and short paragraphs;
- Short punchy sentences appearing at fixed intervals every two or three paragraphs;
- Synonym rotation for the same object;
- Explicit lists changed into hidden lists;
最典型 / 最容易 / 也容易 / 类似的还有and other disguised parallelism;- Whether a group of analytical examples has been expanded item by item by the editor into paragraphs of the same length, same function, and same closing method;
- Whether the same semantic relation is repeated across paragraphs or sections after only changing the subject, verb, or transition word, for example repeatedly writing "tools can complete surface tasks, but judgment still must be made by humans";
- After a heading promises "N layers, N types, N steps," whether the main text structure has been incorrectly broken apart.
Step 4: First determine the function of the enumeration, then decide whether to protect or reorganize
Do not classify all main text with "multiple items" as functional enumeration. First answer two questions: Does the reader need to execute, check, compare, or track item by item? Do the order, number, or independent boundaries of the items carry the article's promise?
The following structures by default retain explicit numbering and parallel sentence patterns:
- Classifications, hierarchies, steps, checklists, responsibility allocation;
- Legal provisions, contract clauses, and fixed formats;
- Parallel structures set up to check inputs, outputs, subjects, or conditions.
If multiple items merely jointly prove one judgment, the reader does not need to work through them one by one; they belong toan analytical example groupand must not be automatically expanded into consecutive isomorphic paragraphs of “first, second, third” out of “fear of omission.” Handle them in the following order:
- First find relationships that already exist in the source draft: shared conditions, mutual influence, conflict, temporal sequence, risk allocation, review paths, or responsible entities;
- Outside the candidates, fill in
references/expression-transformations.md’s “relationship evidence card”; in addition to the respective anchors at both ends of the relationship, you must also transcribethe source-draft anchor of the relationship itself; - The anchor of the relationship itself must mention both ends at the same place in the source draft, or explicitly have the same specific variable constrain both ends. When there is only A’s material and B’s material and no connecting sentence in the original text, the relationship does not hold;
- “Necessary inference” only permits restating an already existing relationship in the source draft in different words; it must not supplement temporal order, procedural paths, or shared goals based on professional common sense. The model’s own legal common sense, industry conventions, and “what usually happens” do not count as source-draft material;
- Use relationships that pass the evidence card to organize at least two examples, so that the later passage carries forward the object or issue left by the previous passage;
- If the source draft does not have enough material to support a relationship, only compress the examples into one honest sentence or one paragraph of enumeration; do not fabricate clients, cases, negotiation processes, review conditions, causal consequences, or life scenarios;
- There is no requirement that every example have an explanation of equal length, the same paragraph opening, and the same conclusion.
The relationship layer must not become a license for content expansion. In order to “connect” two clauses, do not add transactional links, places of performance, payment milestones, procedural paths, business restrictions, consequences of technology use, or other professional analytical variables that do not appear in the source draft. If the user also requests supplementary professional content, it should be handed off to the upstream writing/research process; this Skill only marks it in the report AUTHOR_MATERIAL_NEEDED。
Relationship evidence cards, material sufficiency, title or navigation protection, scan scope, and evaluation conclusions all belong to information outside the candidates. They can only change how the main text is handled; they cannot become main-text content. The final draft must not contain explanations addressed to editors or evaluators such as “according to the source draft,” “the source draft’s navigation is still retained,” “the material is insufficient to connect,” or “this is not several inspection tasks”; when the material is insufficient, directly retain the independent examples or compressed enumeration, and write AUTHOR_MATERIAL_NEEDED only into the report.
Evaluation language such as “paraphrased repetition, paragraphs with the same function, consecutive isomorphism, capability-boundary candidates, gates or thresholds” must also not enter the main text. These are scanning concepts, not article concepts.
“They all belong to contract risk,” “they all need to be combined with specific cooperation,” “they all require judgment,” and “they all occur at the stage of cooperation deviation or performance” are only broad categories of the same kind, not relationships that can be written into the text. A real relationship must satisfy at least one of the following: the source draft explicitly uses the same specific variable to constrain both ends at the same time; one end changes the interpretation, effect, or handling order of the other end; the source draft explicitly gives the conflict or interaction between the two ends. If only one set of relationships passes the evidence card, use only that set, and do not continue pairing to satisfy quantity or paragraph rhythm.
It is still not enough for both ends to have anchors separately. For example, if the source draft discusses liquidated damages and jurisdiction separately, it cannot therefore be supplemented into “after a breach occurs, litigation begins, and jurisdiction continues to affect the procedure”; if the source draft separately discusses how intellectual property makes cooperation difficult to continue and how termination conditions affect exit, it also cannot automatically be synthesized into a shared relationship “around continuation or exit of cooperation.” Unless the source draft itself places both ends in the same relationship sentence, let them each stand on their own in the same paragraph.
A practical test is: would deleting an item break the completeness of the classification or operation? If yes, it is usually a functional enumeration; if it would only remove one argument, it is usually an analytical illustrative group. This test takes priority over the number of items and whether the original manuscript already has numbering.
Do not change "一是, 二是, 三是" into "最典型, 最容易, 也容易" just to avoid "parallelism." If the content is inherently a list, restore the numbering; if the author wants narration, it must be reorganized according to real scenes, causality, or time, not merely by changing sentence openings.
Restoring explicit numbering in the body does not equal adding new headings. When the original manuscript has no subheadings, do not upgrade each item to ## or ###; when the original manuscript already has headings, keep the heading lines as they are.
Protecting the enumerative form does not mean endorsing the classification logic. If the items are not on the same classification scale, have inconsistent granularity, or two sets of "N-way divisions" are forcibly claimed to correspond one-to-one, mark STRUCTURE_REVIEW and explain the misalignment; unless the user also authorizes argument reconstruction, the de-AI process should only report and not invent a new classification on its own.
Step 5: Perform the minimal sufficient rewrite
Within the existing heading framework, choose operations according to the problem:
- delete stance sentences that carry no independent information;
- merge synonymous judgments and consecutive short paragraphs;
- change abstract evaluations into objects, conditions, and consequences;
- restore explicit enumerations that were mistakenly damaged;
- change analytical examples from item-by-item isomorphism into paragraphs driven by real relationships;
- rebuild experiential paragraphs based on materials provided by the user;
- rewrite whole sentences or paragraphs only when necessary.
Do not replace forbidden words with fixed synonyms. Do not, for the sake of sentence-length variation, break the connections among conditions, exceptions, and conclusions. For specific operations, read references/expression-transformations.md。
Do not expand "rewrite the whole paragraph" into redoing chapter navigation. No matter how natural the body text becomes, as long as heading lines are added, deleted, renamed, promoted/demoted, or reordered, it is an out-of-bounds repair.
Step 6: Calibrate according to voice mode
cleanup_only: preserve the existing tone of the source manuscript; do not add first person, rhetorical questions, metaphors, conversational feel, or short-sentence quotas.provided_sample: read the authorized sample, extract the ten-dimensional profile and counterexamples; match only the dimensions suitable for the current scene.local_anchor: read the specified local private anchor; learn the sources of judgment, uncertainty, paragraph momentum, and functional enumeration, without copying original sentences, facts, or scene-specific subjects.
Author samples cannot make up for insufficient content. Voice Calibration only adjusts expression; it does not create factual depth.
Voice calibration also must not increase the strength of judgments. Compare the certainty of the source manuscript and the revised draft item by item:我不这么看 / 我仍有保留 / 可能 / 未必 / 取决于cannot be changed into这个判断错了 / 下得太早 / 必然 / 决定 / 一定会; when the source manuscript has no frequency range, do not add "已经不算少见、越来越多、通常如此." What VoiceAnchor provides is a way of judging, not a license to make the article's stance sound louder.
When provided_sample or local_anchor is enabled, run the newly added overlap gate after rewriting. It only blocks long continuous overlaps newly appearing relative to the source manuscript, does not count expressions already shared in the source manuscript as copying, and does not print private phrases in the default output:
python3 scripts/voice_anchor_copy_gate.py \
--source <源文件.md> \
--final <最终文件.md> \
--sample <作者样本或本机 anchor.md> \
--min-chars 14
Step 7: Post-rewrite artifact rescan
After rewriting, perform a separate round of reverse checking:
- whether a clear list has been turned into a fake ranking or hidden list;
- whether it has escaped from old forbidden words into new verbal tics;
- whether first person, metaphors, colloquialism, or short-sentence punchlines have been imposed;
- Whether author experiences, feelings, discussions, or changes in judgment are fabricated;
- Whether original sentences, highly identifiable phrases, or facts from the voice anchor are copied;
- Whether professional accuracy, necessary repetition, and paragraph logic are damaged for the sake of "naturalness";
- Whether an analytical exemplar group is expanded item by item into paragraphs of equal length, the same function, and the same closing method;
- Whether variables, review conditions, causality, or consequences not present in the source draft are added to build a relationship layer; whether each relationship evidence card can be traced to anchors at both ends of the source draft;
- Whether three or more paragraph openings appear with the same function and similar sentence patterns;
- Whether the same semantic relationship skeleton is used repeatedly across paragraphs and sections, with only the task name and transition words replaced.
- Whether reservations, possibilities, or unknowns in the source draft are changed into stronger verdicts, frequencies, and inevitable consequences.
- Whether internal analysis groupings are written as new headings, or the wording, hierarchy, numbering, and order of the original headings are changed.
- Whether candidate external processes such as "source draft, navigation retention, insufficient material, relationship evidence card, scan, or delivery" are written into the reader-facing body text; insufficient evidence must be manifested as restrained handling, not by explaining the revision process to the reader.
- Whether generic framework openers such as "first acknowledge a premise" are retained or added, without directly entering the facts or judgment.
- Whether, by omitting the AI subject, changing the limitation to "another task / the difficulty lies in / only corresponds to," the same capability boundary escapes rescanning.
- Whether multiple repeated judgments are compressed into short punchy lines such as "What X is is A, not B" or "the tool exits / reaches its boundary, leaving judgment and responsibility"; compression is not deduplication, and the ending should retain only one complete conclusion that is naturally reached from the preceding text.
- Whether the final section, after explaining value, follow-up tasks, and responsibility, compresses and summarizes once more with the same set of nouns; first mark each paragraph of the final section
JUDGMENT / MECHANISM / CONSEQUENCE / SUMMARY, with only oneSUMMARYallowed, and other paragraphs must provide new objects or mechanisms. - Whether contagious punchy lines detached from newly added mechanisms, such as "the most dangerous / terrifying / important time for AI is...," are retained; even if already present in the source draft, they are not automatically protected and should be deleted when they repeat the preceding text.
- Whether "smooth entry" is replaced with abstract entry metaphors such as "lower entry / low-friction entry"; instead, actual changes such as "no need to start from a blank document, lower startup cost, can discuss earlier" should be written directly.
- Whether the same body text repeatedly uses spatial schemas such as "entry / threshold / enter / return to the inside / penetrate / exit" across three or more paragraphs; the central concept should retain at most one or two necessary explanations, and the rest should be changed into facts, review actions, and consequences.
- Whether every unique payload in the argument spine ledger can be located in the final draft; whether a higher-level summary is used to replace risk distribution, intermediate mechanisms, counterexamples, or multiple amplifying factors.
When repair artifacts are found, return to Step 2–5 and do not continue with synonymous substitution.
For high-frequency skeletons such as "tool capability → turning point or limitation → human judgment / experience / responsibility," run the heuristic recheck again. The script simultaneously observes explicit subjects and implicit capability ends such as "first draft / appearance / complete wording / fill-in-the-blank / rule restatement / suggestion self-consistency."
Original candidates are only used to expand recall, not as a deletion quota. Explanatory items immediately following explicit navigation labels such as "layer N / type N / step N" are listed separately as functional_navigation_item, not counted toward the hard threshold for ordinary body text; these paragraphs inherently serve the function of item-by-item differentiation. The exemption only protects the classification structure, not synonymous repetition: if all five items close with the same "superficially doable—still requires human judgment" ending, they must still be manually rewritten so that each has its own object, conditions, mechanism, or consequence.
Public account comments apply four hard gates to ordinary body text: no more than 6 full-text counting candidates, no more than 2 per section, at most 1 adjacent same-function candidate, and at most 1 in the final section. Do not compress paragraphs containing specific objects, judgment sources, conditions, and consequences into subjectless summaries just to reduce the count; independent mechanisms should be retained—what repeats is the paragraph function and the closing direction, not the article's discussion of "errors, limitations, or judgments" itself. Script failure must be followed by continued revision; manual consolidation in the report must not be used to override it; after the script passes, a manual check is still required to verify whether the functional navigation items truly each have their own mechanism.
python3 scripts/semantic_repetition_gate.py \
--file <最终文件.md> \
--max-count 6 \
--max-per-section 2 \
--max-final-section 1 \
--max-adjacent 1
Step 8: Punctuation correction
Run only after body text rewriting is complete:
python3 scripts/fix_punctuation.py <文件路径>
The script must skip YAML, code blocks, inline code, URLs, Markdown links, and entire Markdown image lines. Any change to an image line is considered a failure.
Step 9: Scoring and delivery gates
Read references/quality-scoring.md, and score on naturalness, rhythm, professionalism, personality, and conciseness. Explanation criteria:
- Rhythm evaluates whether information advances naturally, and does not reward a fixed sequence of long and short sentences;
- Personality is evaluated under
cleanup_onlyfor whether the source draft's voice is preserved, and in voice mode for profile match; - The total score cannot override repair artifacts, fabricated author material, or damaged functional enumeration.
Generate the score-receipt.jsonbound to the final file SHA-256, scene, voice mode, anchor ID, and score, then run:
python3 scripts/protected_markdown_gate.py verify \
--manifest <临时目录>/de-ai-protected-lines.json \
--final <最终文件.md>
python3 scripts/heading_preservation_gate.py verify \
--manifest <临时目录>/de-ai-heading-lines.json \
--final <最终文件.md>
python3 scripts/delivery_gate.py verify \
--manifest <临时目录>/de-ai-delivery-manifest.json \
--final <最终文件.md> \
--score-receipt <临时目录>/score-receipt.json
python3 scripts/style_regression_gate.py <最终文件.md>
Delivery is allowed only when image protection, title protection, delivery binding, and the regression gates for fake rankings, editing process leakage, framework startup phrases, and compressed golden-sentence escape all exit 0; when voice is enabled, the newly added overlap gate exits 0; and the semantic skeleton recheck and manual relationship-layer rescan have no unhandled items.
Detect output format
Each finding contains at least:
锚点:原文位置或短片段
段落功能:该句本应承担什么
主污染类型:七类之一
问题:为什么像模板、隐藏列表或修复伪影
读者影响:会造成何种理解或信任问题
处理:删除 / 合并 / 直接陈述 / 补足 / 恢复结构 / 作者补料
Do not merely report "a certain word was hit." For retained items, state the function and reason.
Completion boundaries
- Script gates can only prove that candidate binding, protection items, and scoring steps were executed; they cannot prove that subjective scoring is correct.
- The title protection gate only proves that the text, level, numbering, and order of ATX heading lines are unchanged; it does not prove that the original heading system itself is reasonable; heading structure optimization belongs to other writing Skills.
- The distinction between analytical examples and functional enumeration depends on the article's task, and cannot be judged only by serial numbers or regular expressions.
- Semantic skeleton and long continuous overlap gates can only recall known risks; they cannot replace a full read-through, nor can they prove that there is no semantic imitation or factual contamination.
- Regex regression can only intercept known repair artifacts; it cannot replace a full read-through.
- When author material is missing, explicitly report
AUTHOR_MATERIAL_NEEDED, and do not claim that genuine emotion has been obtained. - When no real rewriting has been performed or there is no final file, do not generate a fake scoring receipt.