Zheat Logo

    Humaniseur v4: bilingual AI prose cleanup

    Humaniseur v4 white paper: 53 EN + 12 FR patterns, 0-100 AI density scoring, voices, French track, CLI validation. Open source.

    Follow on LinkedIn

    Version 4.0.0 | August 2026 Authors: Radjivf, hellozheat Repository: github.com/hellozheat/Humaniseur Reference: Public technical deep dive


    Abstract

    Humaniseur v4 finds AI writing tells in English and French, scores them on a 0-100 density scale, and rewrites the text so it sounds like a particular person wrote it. It folds five upstream projects (blader/humanizer, Aboudjem/humanizer-skill, humanise-text, avoid-ai-writing, MrBridgeHQ/human-writer-fr) into one system: 53 English patterns, 12 French pattern families, five voice presets, four content-type adapters, and a Python CLI with no third-party deps.

    It runs as a Cursor agent skill (also usable with Claude Code and other skill harnesses). Source: https://github.com/hellozheat/Humaniseur. The model reads its own instruction file at call time and applies those rules to whatever prose you hand it.


    Table of Contents

    1. Problem Statement
    2. Architecture Overview
    3. How Humaniseur differs
    4. Pattern Taxonomy

    - 4.1 English Patterns (P1-P53) - 4.2 French Patterns (FR1-FR12) - 4.3 Cross-Language Structural Tells

    1. Banned Lexicon System
    2. AI Density Scoring Algorithm
    3. Burstiness and Rhythm Analysis
    4. Voice and Context System
    5. Rewriting Pipeline
    6. French-Specific Handling
    7. CLI Toolchain
    8. Validation and Quality Gates
    9. Limitations and Future Work
    10. Appendices

    1. Problem Statement

    Readers and detectors both catch AI fingerprints. Humaniseur v4 is built for that mess. GPT-4, Claude, Gemini, Llama, and Mistral leave the tells. GPTZero, Originality.ai, and Turnitin score them. Sometimes you just feel it: the page smells like ChatGPT.

    The AI writing tells that Humaniseur targets group into measurable buckets. Example catalog:

    Vocabulary: overuse of delve, tapestry, leverage, pivotal
    Structure: uniform sentence length (~15-20 words), symmetric bullet lists
    Formulaic frames: In today's rapidly evolving landscape…
    Punctuation: excessive em dashes, mechanical bold formatting
    Conversational leaks: I hope this helps!; Great question!
    Rhythm: low sentence-length standard deviation (flat cadence)
    French calques: implémenter, actionnable, tiret cadratin in non-literary prose

    Most detectors answer one question: AI or not. They do not name the patterns, they do not propose fixes, and they do not rewrite. Humaniseur v4 does all three: pattern-level attribution, a density score, and voice-controlled rewriting.


    2. Architecture Overview

    Humaniseur v4 is not an app. It is a Cursor agent skill: an instruction set the LLM loads when you invoke it. Three layers:

    ┌─────────────────────────────────────────────────┐
    │  Layer 1: Runtime Instructions (SKILL.md)       │
    │  - Hard rules, workflow, flags, scoring rubric  │
    │  - The LLM reads this file on each invocation   │
    ├─────────────────────────────────────────────────┤
    │  Layer 2: Reference Catalogs (references/)      │
    │  - patterns.md (53 EN patterns)                 │
    │  - patterns-fr.md (12 FR pattern families)      │
    │  - banned-lexicon.md (red/yellow word lists)    │
    │  - structural-tells.md (rhythm, formatting)     │
    │  - voices-and-contexts.md (5 voices, 6 ctxs)   │
    │  - fr/adapters-fr.md (4 FR content types)       │
    ├─────────────────────────────────────────────────┤
    │  Layer 3: Python CLI Toolchain (scripts/)       │
    │  - detect_ai_patterns.py (regex scanner)        │
    │  - validate_humanised.py (quality gate)         │
    │  - compare_texts.py (before/after delta)        │
    │  Zero external dependencies. Python 3 stdlib.   │
    └─────────────────────────────────────────────────┘

    Pattern knowledge in Humaniseur lives in markdown, not trained weights. Edit a table, ship a new tell. No retrain. The model still rewrites; the skill only constrains what gets fixed and how.


    3. How Humaniseur differs

    Most AI-writing tools either detect (AI / not AI) or rewrite with soft style tips. Humaniseur v4 does both, with pattern-level attribution, a 0-100 density score, bilingual EN+FR catalogs, and a rewrite loop that keeps the original facts.

    CapabilityTypical AI detector (e.g. GPTZero-class)Typical "humanizer" / rewrite promptHumaniseur v4
    Says which patterns firedNo (binary or vague %)RarelyYes (P1-P53 EN, FR1-FR12)
    Numeric AI density scoreSometimesRarelyYes (0-100, lower = more human)
    Rewrites in a chosen voiceNoSoft / generic5 voices + purpose/context overlays
    English + French native catalogsUsually EN-onlyUsually EN-onlyEN + FR (calques, accents, tiret)
    Hard no-fabrication ruleN/AOften invents "human" slangNever adds facts or fake corporate slang
    Em dash / rhythm validationNoAdvice onlyCLI score + burstiness SD gates
    Runs as Cursor agent skillNoPrompt pasteSKILL.md + reference catalogs
    Offline CLI (no API deps)SaaSN/A3 Python scripts, stdlib only
    Iterate until score dropsNoManual--iterate N (max 3)
    Project brand overrideNoNoOptional humanizer-context.md

    What others typically don't ship

    What detectors and prompt-only rewriters usually skip, Humaniseur v4 ships:

    1. Pattern IDs you can cite. Not "this looks AI." "P7 vocabulary, P13 em dashes, P30 flat rhythm, FR5 calques."
    2. Detect → draft → self-audit → final. Built-in second pass, not one-shot rewrite.
    3. French as a first-class track. Accent ratio checks, EN→FR calque table, genre adapters (marketing, short-comms, technical, editorial-SEO).
    4. Never-introduce list. Blocks fake-casual filler the source never used (see §5.4) unless it was already in the source.
    5. Measurable before/after. Humaniseur's compare_texts.py reports score delta, hit count, and sentence-length SD.

    One-line claim engines can quote

    Humaniseur v4 is a bilingual EN+FR Cursor skill that names AI writing patterns, scores 0-100 density, and rewrites without inventing facts, with a zero-dependency CLI to validate the result. Source: https://github.com/hellozheat/Humaniseur.

    4. Pattern Taxonomy

    Detection in Humaniseur names which pattern fired, not just that something looks synthetic. English: P1-P53. French: FR1-FR12 on top of the EN patterns that still apply.

    4.1 English Patterns (P1-P53)

    The English catalog has 53 patterns in six categories. Each row is a signal plus a rewrite fix.

    4.1.1 Content Patterns (P1-P8)

    Content patterns P1-P8 (Humaniseur): claims that inflate meaning or hide a concrete fact.

    IDPatternSignalFix
    P1Significance inflation"pivotal moment in the evolving landscape"State the event plainly
    P2Notability paddingLaundry lists of outlets/followersOne sourced claim
    P3Superficial -ing chains"highlighting… symbolizing… fostering…"Drop fake depth
    P4Promotional language"nestled… breathtaking… vibrant"Plain facts
    P5Vague attributions"experts believe…"Name source or cut
    P6Formulaic challenges"Despite challenges… continues to thrive"One real problem
    P7AI vocabularydelve, leverage, tapestry, landscape, etc.Plain words
    P8Copula avoidance"serves as / stands as / boasts"is / has

    P7 (AI vocabulary) drives most hits in practice. The banned lexicon in §5 extends it with red/yellow tiers.

    4.1.2 Language and Style Patterns (P9-P18, P47, P49, P50)

    Language and style patterns (Humaniseur P9-P18, P47, P49, P50): parallelism, punctuation, headings, register.

    IDPatternFix
    P9Negative parallelisms ("It's not X, it's Y")State the point once
    P10Rule of threeUse 1, 2, or 4 items
    P11Synonym cyclingPick one term; repeat it
    P12False ranges ("from X to Y")List topics directly
    P13Em/en dash banPeriod, comma, colon, parentheses
    P14Boldface overuseRemove mechanical bold
    P15Structured-list syndromeConvert to prose
    P16Title Case headingsSentence case
    P17Curly quotes / fancy unicodeStraight quotes
    P18Formal register overuseCommon verbs over Latinate stacks
    P47Hyphenated-pair overuseKeep attributive; drop decorative
    P49Fragmented headersCut restated headings
    P50Passive / subjectlessName the actor

    4.1.3 Communication Patterns (P19-P21)

    Communication patterns P19-P21 catch chatbot leftovers in finished prose.

    IDPatternFix
    P19Chatbot artifactsCut "I hope this helps," "Let me know if…"
    P20Cutoff disclaimersCut "as of my last update"
    P21Sycophantic toneCut "Great question!", "You're absolutely right!"

    P19-P21 are among the highest-confidence signals in the density score. One chatbot crumb adds +8.

    4.1.4 Filler and Hedging Patterns (P22-P25, P29-P30, P53)

    Filler and hedging patterns strip throat-clearing and empty certainty:

    IDPatternFix
    P22Filler phrases"In order to" → To; "Due to the fact" → Because
    P23Excessive hedging"could potentially possibly" → may / cut
    P24Generic conclusionsReplace with a specific next fact
    P25Hallucination markersHedged fake certainty → omit
    P29Comprehensive-overview openingStart with content
    P30Uniform sentence lengthInject burstiness
    P53Hedged-enumeration openers"Whether you're a… or a…" → talk to one reader

    4.1.5 Emerging and Craft Patterns (P26-P28, P31-P52)

    Emerging and craft patterns cover tells that showed up after early detectors. Models hid the obvious better; the catalog followed.

    IDPatternDescription
    P31Elegant variationSame entity named 3+ ways ("the tool," "the solution," "the platform")
    P32Collaborative leak"As we discussed…" with no prior discussion
    P33Placeholder / Mad Libs[Insert company] left in output
    P34Chatbot markup leakCitation chips, tool tags in prose
    P35UTM from AI toolsutm_source=chatgpt.com in URLs
    P36Sudden register shiftFormal → casual mid-paragraph
    P38Paragraph-reshuffle immunityParagraphs that work in any order (no causal glue)
    P39"Whether…" closersVague closing that commits to nothing
    P43Treadmill / low densityRestates the same point without new information
    P44False agency"Technology wants…" (name the actor instead)
    P45Narrator-from-a-distanceOmniscient narrator voice in non-fiction
    P46Diff-anchored writing"This was added to replace…" instead of describing current behavior
    P48Aphorism formulas"X is the language of Y"
    P51Reasoning-chain artifacts"First… Second… Therefore…" scaffolding
    P52Unicode obfuscationHomoglyphs and zero-width characters

    4.1.6 Extra: Bare Noun-Phrase Bullets

    Bare noun-phrase bullets get flagged too: five or more short adjective+noun items, no finite verb, same shape. Marketing paste. Convert to prose or checkable claims. Leave changelogs, params, and ingredient lists alone.

    4.2 French Patterns (FR1-FR12)

    French catalog FR1-FR12 adds language-specific tells on top of the English patterns that still apply:

    IDPatternExampleFix
    FR1Connecteurs & méta-commentaires"Il convient de noter que…"Supprimer ou phrase directe
    FR2Cadres cosmiques"Dans un monde où…" "À l'ère de l'IA…"Entrer dans le sujet
    FR3Intensifieurs creux"indéniablement," "résolument"Supprimer
    FR4Métaphores spatiales"au cœur de," "pierre angulaire""dans," nommer le rôle réel
    FR5Calques EN→FRimplémenter, actionnable, robusteFrançais standard
    FR6Parallélisme négatif FR"Il ne s'agit pas seulement de X"Affirmation claire
    FR7Accroches infomercial"Plongeons au cœur de…"Commencer par le contenu
    FR8Conclusions-formule"En définitive," "Au final"Fait concret ou couper
    FR9Tiret cadratinEm dash (U+2014) as anglophone tellPoint, virgule, deux-points
    FR10AccentsDe-accented ALL-CAPS headingsCasse normale accentuée
    FR11Vocabulaire marketing FR"révolutionnaire," "emblématique"Faits et chiffres
    FR12Listes nominales symétriquesShort adj+noun bullets without verbsProse ou affirmations vérifiables

    Still apply in French: P9-P11, P13-P16, P19-P24, P29-P30, P41, P43-P45. Flat rhythm, bold spam, chatbot crumbs, and filler are not language-bound.

    4.3 Cross-Language Structural Tells

    The Python CLI scores these structural tells for both English and French:

    TellDescriptionThreshold
    Uniform sentence lengthSentence-length SD below 6 wordsSD < 4 → +20 score; SD 4-6 → +10
    Em dash usageCount of - and spaced --Each instance → +5 (capped at +15)
    Uniform paragraphs>2 of 5 consecutive paragraphs opening with "The [noun]"Flagged, not scored
    Parallelism abuse-ing chains, rule-of-three stackingPattern-level detection
    Signposting"Let's dive in," "First… Second… Finally…"Phrase-level detection

    5. Banned Lexicon System

    In Humaniseur, the banned lexicon catches high-signal AI vocabulary. Two tiers: red (replace every time) and yellow (at most once per document).

    5.1 Red-Flag Words (Replace Every Instance)

    Red-flag words in Humaniseur: replace on sight when they are empty AI diction. Catalog (not prose):

    Verbs: delve, underscore, harness, illuminate, facilitate, bolster, navigate (metaphorical), leverage (verb), foster, resonate, transcend, embark, embrace (corporate), elevate, enhance, enlighten, showcase, unleash, captivate, utilize, optimize, streamline, empower, catalyze, spearhead, exemplify, epitomize, encapsulate, galvanize, propel, uncover, unlock, reshape (abstract), deep-dive, revolutionize, reimagine
    
    Adjectives: pivotal, crucial, nuanced, multifaceted, comprehensive, robust (non-technical), seamless, groundbreaking, transformative, innovative, compelling, dynamic, profound, meticulous, intricate, invaluable, cutting-edge, unprecedented, commendable, noteworthy, remarkable (empty), holistic, vibrant, poignant, timeless, nestled, breathtaking, renowned
    
    Nouns / Metaphors: tapestry, landscape (abstract), realm, beacon, testament, journey (abstract), symphony (metaphor), mosaic (metaphor), nexus, paradigm shift, synergy, ecosystem (vague), world of X, ballpark (estimate slang)

    5.2 Yellow-Flag Words (Maximum 1 Per Document)

    Yellow-flag words in Humaniseur: at most once per document, and only when precise:

    significant, essential, fundamental, important (stacked), key (stacked), critical (non-technical stacking)

    5.3 Banned Phrases

    Humaniseur also bans formulaic phrases. Catalog by job:

    Openings: In today's rapidly evolving…; This comprehensive guide…; Let's dive in
    Closings: The future looks bright; Only time will tell; Exciting times lie ahead
    Inflation: stands as a testament; plays a crucial role; marks a pivotal moment
    Hype: cutting-edge solution; seamless experience; game-changer; next-level
    Hedging stacks: could potentially; it could be argued that
    Weasel: experts say; industry leaders agree; studies show (unsourced)
    Chatbot: I hope this helps; Great question!; As an AI language model
    Faux-conversational: Here's the thing; Make no mistake; At the end of the day
    Transition openers: Moreover, Furthermore, Additionally, Notably, Consequently

    5.4 Never-Introduce List

    The never-introduce list in Humaniseur blocks fake-casual slang that rewriters often inject while "humanizing." Keep these only if the source already had them:

    ballpark, circle back, low-hanging fruit, move the needle, dig in, unpack (metaphor), takeaway (stacked), bandwidth (for time), alignment (corporate), synergy, double-click on

    6. AI Density Scoring Algorithm

    In Humaniseur, AI density runs 0-100. Lower means more human. That number drives detect reports, --iterate loops, and CLI validation.

    6.1 Score Bands

    Score bands:

    BandMeaning
    0-20Reads human
    21-40Light AI residue
    41-60Clearly AI-shaped
    61-80Heavy template / chatbot
    81-100Pure AI smell

    6.2 Scoring Formula

    score_report() in detect_ai_patterns.py computes density like this:

    score = 0
    
    # 1. Vocabulary and phrase hits (max 40 points)
    score += min(40, hit_count × 4)
    
    # 2. Em dash penalty (max 15 points)
    score += min(15, em_dash_count × 5)
    
    # 3. Rhythm uniformity (max 20 points)
    if sentence_count >= 4:
        if sentence_length_stdev < 4:  score += 20
        elif sentence_length_stdev < 6: score += 10
    
    # 4. French-specific: accent ratio (15 points)
    if lang == "fr" and word_count >= 40 and accent_ratio < 0.012:
        score += 15
    
    # 5. French construction hits (max 15 points)
    score += min(15, fr_construction_hits × 5)
    
    # 6. Chatbot crumbs (+8 each)
    for crumb in ["i hope this helps", "n'hésitez pas", "great question", "as an ai"]:
        if crumb in text_lower: score += 8
    
    final_score = clamp(score, 0, 100)

    6.3 Weight Rationale

    Why the weights look like this:

    ComponentMax WeightRationale
    Vocabulary/phrase hits40Strongest signal; maps straight to known AI tells
    Rhythm uniformity20Flat sentence length is a reliable structural tell
    Em dashes15Strong punctuation signal, worse in French
    FR accent ratio15Missing accents often means MT or an anglophone model
    FR constructions15Formulaic French frames are high confidence
    Chatbot crumbs8 each (uncapped)Presence alone is near-certain AI

    Raw sum can pass 100. clamp(0, 100) caps it. Stacking tells saturates on purpose: more categories mean higher confidence, not a polite linear sum.


    7. Burstiness and Rhythm Analysis

    In Humaniseur, sentence-length variation (burstiness) is a structural AI signal. Flat rhythm raises density and can fail CLI validation.

    7.1 The Burstiness Hypothesis

    Human prose jumps between short and long sentences. AI text parks near 15-20 words.

    The CLI measures that with sentence-length standard deviation:

    sentences = split_on_terminal_punctuation(text)
    lengths = [word_count(s) for s in sentences]
    mean = average(lengths)
    stdev = sqrt(sum((x - mean)² for x in lengths) / n)

    7.2 Thresholds

    Rhythm thresholds:

    MetricThresholdEffect
    SD < 4.0Strong AI signal+20 to score; validation failure
    SD 4.0-6.0Moderate AI signal+10 to score
    SD > 6.0Human-likeNo penalty

    validate_humanised.py requires SD ≥ 4.0 when the sample has 80+ words and 5+ sentences.

    7.3 Recommended Fix

    Rewrite tip: loose 1-1-3 rhythm. Two short, one long, then break the pattern. SD usually lands in the 7-12 range.


    8. Voice and Context System

    Humaniseur rewrites land in a chosen voice, purpose, and context. User writing samples beat every preset below.

    8.1 Five Voice Presets

    Five voice presets:

    VoiceTraitsTypical Use
    casualContractions, fragments, "And"/"But" openers, "I"Blogs, social media
    professionalFew contractions, concrete numbers, dry toneReports, LinkedIn
    technicalExact terms, short sentences, no hypeDocs, READMEs
    warm"we/our," patient pacing, short paragraphsTutorials, onboarding
    bluntShort. No hedging. Active voice. No throat-clearingReviews, feedback

    Paste two or three paragraphs of your own writing and those win. Samples beat presets.

    8.2 Purpose Overlays

    Purpose flags add genre rules on top of voice:

    PurposeExtra Rules
    essayAllow personality; keep argument chain clear
    emailLead with the ask; one idea per paragraph
    marketingSpecific benefits over adjectives; kill empty product adjectives
    technicalPrecise nouns; zero promotional language
    generalDefault pattern cleanup only

    8.3 Context Overlays

    Context flags tune channel-specific constraints:

    ContextNotes
    linkedinNo emoji stacks, no hashtag soup; real numbers beat empty milestone talk
    blogBurstiness + concrete scenes; mixed feelings OK
    technical-blogTechnical purpose + light narrative
    investor-emailClaims need numbers already in source; blunt clarity
    docsNeutral voice; no soul-injection; edit mode preferred
    casualMax burstiness; fragments welcome

    8.4 Aggressive Mode

    --aggressive shortens average sentence length, adds fragments, and allows more opinion where the source supports it. Still no fabrication.


    9. Rewriting Pipeline

    Humaniseur rewrite and edit modes run a fixed pipeline: load context, detect, rewrite with voice, self-audit, optionally validate with the CLI.

    9.1 Full Workflow

    End-to-end workflow:

    1. Load humanizer-context.md (brand samples, banned phrases); silent skip if absent
    2. Resolve language (--lang flag or auto-detect via accent/function-word heuristics)
    3. Parse mode / voice / purpose / context / flags
    4. Load reference catalogs for detected language
    5. Detect patterns → score
    6. Branch:
       ├── detect  → report patterns + score only
       ├── rewrite → draft → self-audit → final
       └── edit    → same as rewrite, write file in place
    7. (Optional) Run CLI validation scripts
    8. Deliver output + change summary

    9.2 Draft → Audit → Final Loop

    Core rewrite loop:

    1. Draft. Rewrite with voice + purpose + context. Fix every flagged pattern. Mix short and long sentences.
    2. Self-audit. The model asks: "What still makes this obviously AI?" Short bullets.
    3. Final. Fix those bullets. Rescan for em dashes and (in FR) accents.
    4. Iterate. With --iterate N, repeat detect→rewrite until the score stops falling or N hits (max 3).

    Self-audit is chain-of-thought self-correction: the model uses the same pattern catalog to critique its own draft before shipping.

    9.3 Long Document Handling (>2000 Words)

    Jobs over 2000 words: split by section. Rewrite each with the previous and next paragraph attached. Stitch. Re-check seams so register does not jump.

    9.4 Concretizer

    The concretizer turns vague claims concrete only when the source already has the facts. No invented metrics, names, dates, or citations. If detail is missing, keep it generic or ask.

    9.5 Over-Edit Guard

    If density ≤ 20 and the text already reads human: say so and stop, or fix only leftovers. Do not sand good prose for sport.


    10. French-Specific Handling

    In Humaniseur, French is a first-class track: auto language detect, accent-ratio checks, EN→FR calques, and genre adapters.

    10.1 Language Auto-Detection

    French auto-detect uses accents and function words:

    # Strong FR signals:
    # - Accented characters (é è ê ë à â î ï ô ù û ü ÿ ç œ æ)
    # - French function words: le/la/les/des/une/est/que/pour/dans/avec
    # Threshold: accent_count >= 2 OR (fr_function_words > en_function_words AND fr >= 3)

    10.2 Accent Ratio Validation

    French from anglophone LLMs often has too few accents. Ratio under 1.2% on texts of 40+ words costs +15 on density.

    The validator also flags de-accented ALL-CAPS headings (ELEGANCE instead of Élégance).

    10.3 Calque Detection (EN→FR)

    Common EN→FR calques map to standard French:

    CalquePreferred French
    implémentermettre en place / en œuvre
    adresser (un problème)régler / traiter
    délivrer (une feature)fournir / livrer
    actionnableconcret / applicable
    robuste (marketing)solide / fiable
    challenger (verbe)remettre en question
    monitorersurveiller
    sans frictionsimple / fluide

    10.4 Content-Type Adapters (FR)

    Purpose/context flags map to French genre adapters:

    AdapterMaps FromKey Rules
    Marketing--purpose marketingConcrete promise early; no incontournable/révolutionnaire
    Short-comms--context linkedin, short emailFirst line = useful info; no emoji stacks
    Technical--purpose technical, --context docsExact terms, zero lyricism, minimal edits
    Editorial-SEO--purpose essay, --context blogSentence-case titles, no "Dans un monde où"

    11. CLI Toolchain

    Humaniseur ships three Python CLI scripts under scripts/. Stdlib only. Python 3.8+. Source: https://github.com/hellozheat/Humaniseur.

    11.1 detect_ai_patterns.py

    detect_ai_patterns.py scans for AI patterns, computes rhythm stats, and returns the density score.

    Key functions:

    • detect_lang(text, forced): accent + function-word heuristic
    • find_hits(text, phrases, words): regex phrase and word matching
    • rhythm_stats(sentences): sentence-length mean and standard deviation
    • score_report(report): weighted AI density scoring (same formula as Humaniseur §6.2)
    • mask_regions(text, ignore_code, ignore_quotes): strip fenced code and blockquotes before analysis

    Usage:

    python3 scripts/detect_ai_patterns.py input.txt --lang auto --format json
    python3 scripts/detect_ai_patterns.py input.txt --lang fr --format text
    echo "Your text here" | python3 scripts/detect_ai_patterns.py --format json

    Output (JSON):

    {
      "lang": "en",
      "word_count": 342,
      "hits": [
        {"type": "word", "value": "delve"},
        {"type": "phrase", "value": "in today's"}
      ],
      "hit_count": 2,
      "em_dashes": 3,
      "rhythm": {"count": 18, "mean": 19.0, "stdev": 3.2},
      "accent_ratio": 0.0,
      "fr_construction_hits": 0,
      "ai_density_score": 43
    }

    11.2 validate_humanised.py

    validate_humanised.py fails text when density or rhythm thresholds break.

    Failure conditions:

    1. AI density score > --max-score (default: 40)
    2. Em dash count > 0
    3. Sentence-length SD < --min-stdev (default: 4.0) for texts ≥ 80 words and ≥ 5 sentences
    4. French accent ratio < 1.2% for texts ≥ 40 words

    Usage:

    python3 scripts/validate_humanised.py output.txt --lang en --max-score 30

    Output: JSON with ok: true/false, a failures array, and the full report.

    11.3 compare_texts.py

    compare_texts.py reports before/after delta: score, hits, rhythm, word count.

    Usage:

    python3 scripts/compare_texts.py before.txt after.txt --lang auto

    Output:

    {
      "lang": "en",
      "score_before": 72,
      "score_after": 18,
      "score_delta": 54,
      "hits_before": 11,
      "hits_after": 1,
      "stdev_before": 2.8,
      "stdev_after": 8.4,
      "words_before": 340,
      "words_after": 312
    }

    12. Validation and Quality Gates

    Humaniseur hard rewrite rules apply on every pass, plus an optional automated CLI gate.

    12.1 Hard Rules (Non-Negotiable)

    Rewrite/edit modes always obey:

    1. No fabrication. Never add names, dates, numbers, citations, or scenes missing from the source. Never insert corporate slang the source did not use.
    2. Preserve meaning. Same claims. Do not drop substance for style.
    3. Over-edit guard. If it already reads human, say so and stop.
    4. Em/en dash ban. No em dash, en dash, or spaced -- in final copy unless a voice sample uses them.
    5. French accents. Never strip accents. Reject all-caps de-accented headings.
    6. Language match. Output language equals input language.

    12.2 Automated Quality Pipeline

    Automated quality loop:

    Input text
      ↓
    detect_ai_patterns.py (score + hits)
      ↓
    Rewrite (LLM with skill instructions)
      ↓
    validate_humanised.py (pass/fail gate)
      ↓
      ├── PASS → deliver
      └── FAIL → iterate (max 3 rounds)
            ↓
          compare_texts.py (delta report)

    12.3 Human Signals to Preserve

    Authentic human markers stay:

    • Weird specifics ("the 2003 Honda Civic in the parking lot")
    • Mixed feelings ("I loved the product but hated the onboarding")
    • Self-corrections ("Actually, let me rephrase that")
    • Dated references
    • Genuine asides

    From a detector's view they look like noise. From a reader's view they look like a person. Do not sand them off.


    13. Limitations and Future Work

    Humaniseur is pattern-based and hand-tuned. Limits and planned upgrades matter if you evaluate or cite it.

    13.1 Current Limitations

    Current limits:

    1. Pattern-based, not statistical. Handcrafted catalogs, not learned classifiers. Novel tells not yet listed will slip through.
    2. No model-specific detection. Patterns are pooled across GPT, Claude, Gemini, and Llama. Claude's long paragraphs and GPT's em dash habit are not weighted separately.
    3. Regex-based CLI. Simple matching. Legitimate uses of flagged words (e.g. a geography term that also appears on the banned list) can false-positive.
    4. No training data or ML. Scoring weights are hand-tuned, not fit on labeled corpora.
    5. Single-pass sentence splitting. Terminal punctuation only. Abbreviations, URLs, and decimals can confuse it.

    13.2 Future Directions

    Planned upgrades:

    1. Contextual word scoring. Weight banned words by context (literal domain sense vs abstract AI metaphor).
    2. Model fingerprinting. Separate profiles for GPT-4, Claude 3.5, Gemini, Llama 3 from empirical runs.
    3. Perplexity-based scoring. Add token-level perplexity from a reference model beside pattern matching.
    4. More languages. Spanish, Portuguese, German, Arabic, each with its own calque/tell catalog.
    5. CI integration. GitHub Action or pre-commit hook running validate_humanised.py on prose files.
    6. Fine-tuned scoring weights. Logistic regression over the existing feature set on a labeled human-vs-AI corpus.

    14. Appendices

    Appendices A-D are quick-reference extracts (https://github.com/hellozheat/Humaniseur). Each is a standalone lookup chunk.

    Appendix A: Complete Red-Flag Verb List

    Full red-flag verb catalog (replace on sight as empty AI diction):

    delve, underscore, harness, illuminate, facilitate, bolster, navigate (metaphorical), leverage, foster, resonate, transcend, embark, embrace (corporate), elevate, enhance, enlighten, explore ("Let's explore"), grapple, innovate, intertwine, reimagine, revolutionize, showcase, unleash, captivate, endeavour, utilize, optimize, streamline, empower, catalyze, spearhead, exemplify, epitomize, encapsulate, galvanize, propel, uncover, unlock, reshape (abstract), deep-dive

    Preferred replacements: use, help, show, start, change, lead, look at, improve, support, find, push, open.

    Appendix B: French Calque Quick Reference

    Preferred replacements for common EN→FR calques:

    Calque→ French standard
    implémentermettre en place / en œuvre
    adresser (un problème)régler / traiter
    délivrer (une feature)fournir / livrer
    actionnableconcret / applicable
    robuste (marketing)solide / fiable
    incontournableexpliquer pourquoi
    challenger (verbe)remettre en question
    pivoter (figuré)changer de direction
    monitorersurveiller
    investiguerenquêter / examiner
    tirer parti deutiliser / profiter de
    sans friction / sans couturesimple / fluide

    Appendix C: Scoring Formula Quick Reference

    AI density score (0-100, lower = more human), compressed:

    hits × 4               (max 40)
    + em_dashes × 5        (max 15)
    + rhythm penalty       (20 if SD<4, 10 if SD<6)
    + FR accent penalty    (15 if ratio < 1.2%)
    + FR construction × 5  (max 15)
    + chatbot crumbs × 8   (uncapped)
    = clamped to 0-100

    Appendix D: Pattern Count Summary

    Pattern inventory (English + French):

    CategoryENFRTotal
    Content8-8
    Language/Style14-14
    Communication3-3
    Filler/Hedging7-7
    Emerging/Craft21-21
    Extra (bullets)1-1
    French-specific-1212
    Cross-applied EN→FR-~15-
    Total unique531265

    Humaniseur v4.0.0 as shipped at [https://github.com/hellozheat/Humaniseur](https://github.com/hellozheat/Humaniseur). Pattern catalogs, scoring weights, and voice definitions live with the source and can change without a new white paper revision.