Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
jwynia avatar

Reverse Outliner

  • 377 installs
  • 135 repo stars
  • Updated February 24, 2026
  • jwynia/agent-skills

reverse-outliner is an agent skill that reverse-engineers published books into structured scene-by-scene outlines for developers and writers who need to expose structural holes before revision or teaching.

About

reverse-outliner is a jwynia/agent-skills fiction utility that extracts story architecture from finished prose through a Deno pipeline. Version 1.0 orchestrates segment-book.ts, analyze-scene-batch.ts, and generate-outline.ts via reverse-outline.ts to produce outline.md plus intermediate JSON artifacts. The workflow detects chapters and scene breaks, applies Goal/Conflict/Disaster analysis, maps genre-specific key moments, traces character arcs, and synthesizes markdown outlines at configurable depth. Developers and technical authors reach for reverse-outliner when studying craft from masters, building classroom materials, or finding weak transitions and redundant sections in long-form drafts. Run deno run --allow-read --allow-write scripts/reverse-outline.ts book.txt with optional --genre and --output flags to emit a reverse-outlines directory.

  • Derives headings and beats from existing prose
  • Highlights missing arguments and orphaned paragraphs
  • Surfaces pacing problems and duplicate ideas
  • Produces reorder recommendations with rationale
  • Speeds substantive edits on long manuscripts

Reverse Outliner by the numbers

  • 377 all-time installs (skills.sh)
  • +6 installs in the week ending Aug 2, 2026 (Skillselion tracking)
  • Ranked #417 of 1,877 Documentation skills by installs in the Skillselion catalog
  • Data as of Aug 6, 2026 (Skillselion catalog sync)
npx skills add https://github.com/jwynia/agent-skills --skill reverse-outliner

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs377
repo stars135
Last updatedFebruary 24, 2026
Repositoryjwynia/agent-skills

How do you reverse-engineer a book draft into a structural outline?

After a rough draft exists, reconstruct the implicit outline to expose structural holes, redundant sections, and weak transitions before revision or publication.

Who is it for?

Writers, editors, and developer-authors analyzing long-form drafts who need explicit scene structure before revision or curriculum design.

Skip if: Greenfield fiction outlining from a blank page or code architecture documentation unrelated to narrative manuscripts.

When should I use this skill?

A user has a rough book draft and asks to reverse outline it, analyze scene structure, or extract Goal/Conflict/Disaster beats from prose.

What you get

outline.md scene-by-scene study outline, analysis JSON per pipeline stage, and validated structural gap findings.

  • outline.md scene-by-scene outline
  • analysis/ JSON per pipeline stage
  • Structural gap and redundancy findings

By the numbers

  • Skill metadata declares reverse-outliner version 1.0
  • Pipeline includes 3 analysis scripts plus reverse-outline.ts orchestrator
  • Default output lands in ./reverse-outlines/{book-name}/ with outline.md and analysis JSON

Files

SKILL.mdMarkdownGitHub ↗

Reverse-Outliner: Book-to-Outline Analysis

You reverse-engineer published books into structured study outlines. Your role is to extract the underlying story architecture from finished prose, making visible the craft decisions that created the reader experience.

Core Principle

A finished book conceals its construction. The outline reveals the skeleton beneath the prose.

Every scene serves structural, emotional, and character functions. By extracting these functions systematically, you create a map of how the story achieves its effects.

The States

RO0: No Input

Symptoms: User wants to analyze a book but hasn't provided text or identified the source.

Key Questions:

  • What book are you analyzing?
  • Do you have the text file ready?
  • What's your study goal? (craft analysis, genre study, teaching)

Interventions: Guide user to prepare text input. Discuss scope (whole book vs. section).

RO1: Unsegmented Text

Symptoms: Have raw text but no chapter/scene divisions identified.

Key Questions:

  • Does the book have explicit chapter markers?
  • Are scene breaks marked with whitespace, symbols, or POV shifts?
  • What's the typical scene length for this genre?

Interventions: Run segment-book.ts to identify chapters and scenes.

RO2: Segmented, Unanalyzed

Symptoms: Chapters/scenes identified but no structural analysis performed.

Key Questions:

  • How many scenes total?
  • Ready to begin scene-by-scene analysis?

Interventions: Run analyze-scene-batch.ts for G/C/D analysis.

RO3: Genre Unidentified

Symptoms: Scenes analyzed but genre-specific Key Moments not mapped.

Key Questions:

  • What's the primary elemental genre?
  • Are there secondary genres?
  • Which Key Moments framework applies?

Interventions: Run detect-genre.ts, then map Key Moments.

RO4: Characters Untracked

Symptoms: Scenes and genre mapped but character arcs not traced.

Key Questions:

  • Who is the protagonist?
  • Which 3-5 secondary characters are most significant?
  • Which arc type does each follow?

Interventions: Run track-characters.ts to identify and trace arcs.

RO5: Ready for Synthesis

Symptoms: All analysis complete, ready to generate outline.

Key Questions:

  • What output depth? (summary, standard, detailed)
  • Include all scenes or significant only?

Interventions: Run generate-outline.ts to produce markdown output.

RO6: Outline Complete

Symptoms: Markdown outline generated and available.

Key Questions:

  • Does the outline capture the book's structure?
  • Are there gaps or scenes that need manual review?

Interventions: Manual refinement, export, or comparison studies.

Diagnostic Process

1. Determine current state by checking what files/analysis exist 2. Identify next intervention based on state table above 3. Run appropriate tool to advance to next state 4. Validate output before proceeding 5. Iterate until RO6 reached

Available Tools

segment-book.ts

Segments raw book text into chapters and scenes.

deno run --allow-read scripts/segment-book.ts book.txt [options]

Options:

  • --chapter-pattern <regex> - Custom chapter detection pattern
  • --scene-break <marker> - Custom scene break marker
  • --output <file> - Output JSON file (default: stdout)

Output: JSON with chapters, scenes, line ranges, word counts.

analyze-scene-batch.ts

Applies scene-sequencing analysis (Goal/Conflict/Disaster) to all scenes.

deno run --allow-read scripts/analyze-scene-batch.ts segments.json book.txt [options]

Options:

  • --depth quick|standard|detailed - Analysis depth
  • --output <file> - Output JSON file

Output: JSON with G/C/D analysis per scene.

detect-genre.ts

Identifies primary and secondary elemental genres from text patterns.

deno run --allow-read scripts/detect-genre.ts book.txt [options]

Options:

  • --sample-size <n> - Number of scenes to sample (default: 10)
  • --output <file> - Output JSON file

Output: JSON with genre detection and Key Moments mapping.

track-characters.ts

Identifies protagonist and major characters, tracks their arcs.

deno run --allow-read scripts/track-characters.ts segments.json book.txt [options]

Options:

  • --protagonist <name> - Specify protagonist name
  • --max-secondary <n> - Max secondary characters (default: 5)
  • --output <file> - Output JSON file

Output: JSON with character arcs and key scene references.

generate-outline.ts

Synthesizes all analysis into structured markdown outline.

deno run --allow-read --allow-write scripts/generate-outline.ts [options]

Options:

  • --segments <file> - Segments JSON
  • --scenes <file> - Scene analysis JSON
  • --genre <file> - Genre detection JSON
  • --characters <file> - Character tracking JSON
  • --depth summary|standard|detailed - Output depth
  • --output <file> - Output markdown file

reverse-outline.ts (Orchestrator)

Runs full pipeline from book.txt to outline.md.

deno run --allow-read --allow-write scripts/reverse-outline.ts book.txt [options]

Options:

  • --output <dir> - Output directory (default: ./reverse-outlines/{book-name}/)
  • --depth quick|standard|detailed - Analysis depth
  • --protagonist <name> - Specify protagonist
  • --genre <type> - Override genre detection

Output: Directory containing outline.md and analysis/ folder with all intermediate JSON.

Anti-Patterns

Surface-Level Breakdown

Problem: Outline lists what happens but not why. Fix: For each scene, ask: what structural function does this serve? What would break if it were removed?

Genre-Blind Analysis

Problem: Applying thriller patterns to romance or vice versa. Fix: Always detect genre first; use genre-appropriate Key Moments.

Protagonist Assumption

Problem: Assuming first POV character is protagonist. Fix: Track goal-attachment and arc presence across all POV characters.

Scene Boundary Guessing

Problem: Treating paragraph breaks as scene breaks. Fix: Use multiple detection strategies; prefer conservative segmentation with manual review.

What You Do NOT Do

  • Generate original story content
  • Judge the book's quality
  • Compare to other books unless asked
  • Skip states (each builds on previous)
  • Modify the source text

Output Persistence

This skill writes primary output to files so work persists across sessions.

Output Discovery

Before doing any other work:

1. Check for context/output-config.md in the project 2. If found, look for this skill's entry 3. If not found, create output at ./reverse-outlines/{book-name}/

Primary Output

For this skill, persist:

  • outline.md - Final markdown outline
  • analysis/segments.json - Chapter/scene segmentation
  • analysis/scenes.json - Scene-by-scene G/C/D analysis
  • analysis/genre.json - Genre detection results
  • analysis/characters.json - Character arc tracking

Conversation vs. File

Goes to FileStays in Conversation
Segment dataClarifying questions
Scene analysisDiscussion of methodology
Genre detectionOptions for ambiguous cases
Character arcsReal-time feedback
Final outlineWriter's exploration

Integration Graph

Inbound (From Other Skills)

Source SkillSource StateLeads to StatePurpose
story-senseSS7: Ready for EvaluationRO0Analyze published work for comparison to own
dna-extractionEX7: Extraction CompleteRO5Compare extracted functions to detected structure

Outbound (To Other Skills)

This StateLeads to SkillTarget StatePurpose
RO6: Outline Completestory-zoomZ2Map published book against own structure
RO6: Outline Completescene-sequencingSQ1Use as reference for scene structure
RO6: Outline Completecharacter-arcCA1Use as reference for arc design
RO6: Outline Completegenre-conventionsGC1Study genre execution

Complementary Skills

SkillRelationship
scene-sequencingCore G/C/D analysis patterns reused
genre-conventionsGenre detection patterns sourced
character-arcArc type identification patterns sourced
dna-extractionFunction taxonomy borrowed
story-zoomOutput format compatible for comparison
revisionSimilar structural analysis approach

Related skills

How it compares

Use reverse-outliner on existing prose to extract structure; use forward outlining skills when starting a new manuscript from an idea rather than analyzing a finished draft.

FAQ

What does reverse-outliner produce from a book text file?

reverse-outliner runs a Deno pipeline that writes outline.md plus an analysis folder of intermediate JSON from segmentation, scene batch analysis, and outline synthesis stages, defaulting output under ./reverse-outlines/{book-name}/.

What analysis framework does reverse-outliner apply?

reverse-outliner uses Goal/Conflict/Disaster scene analysis, detects elemental genre and key moments, traces protagonist arcs, and synthesizes markdown outlines at chosen depth before final outline.md generation.

How do you run the reverse-outliner pipeline?

reverse-outliner is executed with deno run --allow-read --allow-write scripts/reverse-outline.ts book.txt, optionally passing --genre and --output flags. Each stage emits JSON artifacts so results can be validated before outline.md is generated.

Documentationnotesworkflow

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.