mechanical-preprocess

Scan book manuscript chapters and apply rule-based mechanical text replacements.

92|28|Updated Apr 13, 2026
One-click install
npx skills add https://github.com/felipelobomotta-blip/book-genesis-v4 --skill mechanical-preprocess-felipelobomotta-blip
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: mechanical-preprocess
Source: https://github.com/felipelobomotta-blip/book-genesis-v4/tree/main/skills/deprecated/mechanical-preprocess
Command: npx skills add https://github.com/felipelobomotta-blip/book-genesis-v4 --skill mechanical-preprocess-felipelobomotta-blip

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes assets (resource) components.

What problem does it solve?

This Skill prevents long-form manuscript edits from drifting by handling mechanical cleanup (like em-dash issues, forbidden-word checks, and repetitive structure patterns) in a deterministic, chapter-by-chapter way before AI passes do higher-level rewriting.

Core Features & Use Cases

  • Deterministic chapter scanning (bash-first): Produces a structured mechanical scan report (counts and flags) across all chapters to quantify issues like em-dashes, formulaic constructions, forbidden words, repetition signals, and adverb density.
  • Safe replacements via controlled bash rules: Applies only “always safe” fixes (e.g., specific em-dash clause separators, unambiguous forbidden-word substitutions, whitespace normalization) and generates diffs for every change.
  • Diff-only AI review for ambiguous cases: Feeds an AI agent only the diffs (not full chapters) to approve, revert, or modify changes—preserving meaning and voice.

Quick Start

Run mechanical-preprocess after your full manuscript draft is in chapters/, with voice-dna.md and foundation.md present, to produce cleaned chapters plus diffs and a mechanical preprocess report.

Frequently Asked Questions about mechanical-preprocess

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate manuscript cleanup before AI editing to prevent context drift?

Automating manuscript cleanup before AI editing requires deterministic, rule-based text scanning to fix mechanical artifacts like em-dashes and forbidden words chapter-by-chapter. This approach generates diffs for every change, preserving meaning and preventing attention drift in long-form writing pipelines.

What is the best way to check adverb density and forbidden words across book chapters?

Checking adverb density and forbidden words across book chapters is done through a structured mechanical scan that quantifies repetition signals and formulaic constructions. This deterministic scan produces a report with counts and flags for each chapter to highlight issues before higher-level rewriting.

How do I safely normalize em-dashes and whitespace in a manuscript without losing voice?

Safely normalizing em-dashes and whitespace in a manuscript is achieved by applying controlled bash rules that only execute 'always safe' replacements. It generates diffs for every mechanical change and routes ambiguous fixes to a diff-only AI approval loop to preserve voice.

Can I run deterministic text cleanup on a long-form manuscript using bash scripts?

Running deterministic text cleanup on a long-form manuscript with bash scripts is fully supported. This bash-first approach targets context overflow and repetitive artifacts by scanning chapter files alongside voice policy and genre context to safely apply mechanical replacements.

Why does my AI manuscript edit drift or lose consistency in long chapters?

AI manuscript edits drift in long chapters due to context overflow and repetitive mechanical artifacts degrading consistency. Handling mechanical cleanup deterministically before the AI rewriting pass prevents this drift by reducing the noise the AI agent processes.

Do I need voice policy and genre context files to preprocess a book manuscript?

Voice policy and genre context files are required to preprocess a book manuscript. The cleanup process needs chapter files plus a voice DNA file and foundation context to ensure safe, rule-based replacements preserve the author's intended meaning and style.