how i built an automated ebook production platform—and you can, too! - nellie mckesson -...

78
How I Built an Automated Ebook Production Toolchain (and You Can Too!) Nellie McKesson, Macmillan Publishers

Upload: booknet-canada

Post on 11-Apr-2017

208 views

Category:

Technology


0 download

TRANSCRIPT

How I Built an Automated Ebook

Production Toolchain (and You Can Too!)

Nellie McKesson, Macmillan Publishers

Output fileInput file Somescripts

What is Automation?

EPUBMicrosoft Word InDesign

The Traditional Workflow:

EPUBMicrosoft Word InDesign

In-House External Vendor

The Existing Process:

Make ebooks in house, minimize overhead

💰🕖👥

What's the larger goal? What are the initial requirements? What things might change? What things will always be the same? Is there anything already built that I can use? Who is going to be running the tool?

What’s the larger goal?

Build an automated ebook production tool that can scale

The Requirements

Output fileInput file Trans-formations

EPUBInput file Trans-formations

EPUBInput file 🔓Trans-formations

EPUBMarkup

XML, HTML

🔓Trans-formations

EPUBMarkup

XML, HTML

Non-starter (too much overhead)

🔓Trans-formations

EPUBWord 🔓🔓 Trans-formations

What might change?

Design for volatility

EPUBWord

???Trans-

formations

EPUBWord

??????Trans-

formations

EPUBWord?????????

Trans-formations

🙇

Consistency and

Predictability

<title>ALICE’S ADVENTURES IN WONDERLAND <author>Lewis Carroll

<chapter-title>CHAPTER 1. Down the Rabbit-Hole

<text-standard>Alice was beginning to get very tired of sitting by her sister on the bank, and of having nothing to do: once or twice she had peeped into the book her sister was reading, but it had no pictures or conversations in it, ‘and what is the use of a book,’ thought Alice ‘without pictures or conversations?’

Tagging, the Old Way

.docx = XML

Styles in Word

EPUBWord??????

Trans-formations

Workflow or

Automation?

EPUBWord Trans-formations

EPUBWord

These transformations always stay the same

Trans-formations

Is there anything already built that I can use?

?

Markup

HTML

HTML = XML

HTML = EPUBHTML = Web

HTML + CSS = Print

HTML = XML

HTML = EPUBHTML = Web

HTML + CSS = Print

HTML = XML

HTML = EPUBHTML = Web

HTML + CSS = Print

HTML = XML

HTML = EPUBHTML = Web

HTML + CSS = Print

HTML = XML

HTML = EPUBHTML = Web

HTML + CSS = Print

We need to standardize

A standard is a set of rules

“HTMLBook is an open, XHTML5-based standard for the authoring and production

of both print and digital books.”

http://oreillymedia.github.io/HTMLBook/

Why HTMLBook:

• Familiarity

• Well-tested and actively updated

• Open-source

EPUBWord

HTMLBookScripts

HTMLBook

EPUBWord HTMLBook

EPUBWord HTMLBook

🔒 🔒

HTMLBookScripts

EPUBWord HTMLBook🔓

EPUBWord

HTMLBookScripts

HTMLBook

???

???

Word EPUB

Wor

d

?? ?? HTM

LBoo

k

HTM

LBoo

k

EPU

B

EPUB

HTMLBookScripts

HTMLBookHTMLWord

EPUB

HTMLBookScripts

HTMLBookHTMLWord

???

???

mammoth.js

EPUB

HTMLBookScripts

HTMLBookHTMLWord

mammoth.js

EPUBHTMLBookHTMLWord

Consistentlystyled

paragraphs

Word stylespreserved as

HTML class names

Rules:

IF class = “ChapterTitle” THEN convert to <h1>

Class name

What to do with it

File 1: Transformations:

IF class = [Read class names from other file] THEN convert to <h1>

File 2: List of Class Names:

Heading styles: ChapterTitlePrefaceTitleAppendixTitle…

EPUB

HTMLBookScripts

HTMLBookHTMLWord

mammoth.js

whatto

lookfor:

list of class

names

whatto dowithwhatyoufind:

trans-forms

Extract and

Isolate

EPUB

HTMLBookScripts

HTMLBookHTMLWord

mammoth.js

List of class

names

trans-forms

EPUB

HTMLBookScripts

HTMLBookHTMLWord

mammoth.js

List of class

names

trans-forms

EPUB

HTMLBookScripts

HTMLBookHTMLWord

mammoth.js

List of class

names

trans-forms

Use your best judgment

HTMLBookScripts

HTMLBookWord

mammoth.js

Listof

classnames

trans-forms

EPUBHTML HTMLBook

Tran

sfor

m

HTMLBook

HTMLBook

Tran

sfor

m

HTMLBook

HTMLBook

HTMLBook

Tran

sfor

m

Tran

sfor

mTr

ansf

orm

HTMLBookScripts

HTMLBookWord

mammoth.js

EPUBHTML HTMLBook

Tran

sfor

mListof

classnames

trans-forms

HTMLBookScripts.xsl

HTMLBookWord

mammoth.js

EPUBHTML HTMLBook

Tran

sfor

m.js

JavaScript + node.js XSLRuby

Listof

classnames.json

trans-forms

.js

📁 📁

Word file IN EPUB OUT

Design

Corrections

EPUBMicrosoft Word InDesign

ReviewMake

changes

Initial Scope Limitations

✅ New imprint

✅ E-only books

✅ Egalleys

⛔ Traditional print books

Some lessons:

You don’t always need to automate everything: sometimes workflow is the solution

You don't need to build everything from scratch

Build a system of interconnecting tools

Solve small problems, one at a time

Design for change

@nelliemckesson

Thanks!