I created an automatic accessible EPUB3 generation tool
I have created and released on GitHub a tool called KERT that automatically generates accessible EPUB3/DAISY4 files equipped with a "Media Overlays (audio-synchronized highlighting)" feature.
Its name is KERT
I named this tool KERT.
KERT is an abbreviation for Konverter für EPUB-Ressourcen und Text.
Overview: Purpose of KERT
KERT is a tool that automatically generates EPUB3/DAISY4 files with "Media Overlays (audio-synchronized highlighting)" from text files.
I developed it with the goal of streamlining the process of synchronizing audio and text in the production of accessible e-books. The KERT core (GPL license) and all speech synthesis engines used are available for free, allowing for the construction of a production environment with low implementation costs.
Automation of the production process (audio synchronization/SMIL generation)
When producing books with Media Overlays, a very labor-intensive step is the creation of "SMIL files," which define the correspondence between audio and text.
KERT automatically processes the following steps in one go.
Speech synthesis: Generate audio files from input text
Audio alignment: Automatically calculate speech timing using an open-source analysis tool (Montreal Forced Aligner: MFA)
File composition: Automatically generate XHTML and SMIL files based on analysis results
Packaging: Assemble into EPUB format
This eliminates the need for producers to manually measure timing or write complex code.
Input formats and supported syntax
For input, you can use text files based on CommonMark, a type of Markdown format, or XML files. With simple notation, you can specify elements necessary for e-books, such as the following:
Basic formatting: Chapter structure using headings, ruby, bold, underline, boxes, and superscripts/subscripts
Audio control: A "reading replacement" feature that allows you to specify text for reading aloud separately from the displayed text. By explicitly specifying on the text file side how to avoid misreadings that often occur with OS-standard speech synthesis (TTS), you can achieve accurate reading.
Structuring: Integrated generation from multiple files and automatic creation of a table of contents (nav.xhtml) based on headings
Metadata: Description of accessibility-related metadata in addition to title and author
Supported languages and speech synthesis engines
Currently, it supports three languages: Japanese, American English, and German.
Japanese uses "VOICEVOX," while English and German use the OS-standard (macOS/Windows) speech synthesis engines. While OS-standard engines can be used without installing additional software, they can sometimes misread proper nouns or words depending on the context; however, KERT can maintain quality by using the aforementioned "reading replacement" specification. Additionally, other languages supported by MFA (French, Spanish, etc.) can also be supported by adding settings.
Verification and functional testing of output files
For the generated EPUB3 files, I have confirmed their operation and specification compliance using the following environments and tools.
Playback verification: Thorium Reader (Media Overlays playback)
Specification check: Ace by DAISY (EPUB3 accessibility checker)
Operating environment and usage instructions
This tool runs on macOS Sequoia/Tahoe and Windows 11.
Installation of Python, Montreal Forced Aligner, FFmpeg, etc., is required for execution, but since the actual operation is performed in an interactive format on the command line (answering questions about language, file paths, etc.), I have designed it so that it can be used as long as you have basic command-line skills.
Where to obtain the program
KERT is available on GitHub.
https://github.com/quwano/KERT
The Japanese README, which includes setup instructions, explanations of each format notation, and execution examples, can be found below.
https://github.com/quwano/KERT/blob/main/README_ja.md
For license and rights information, please refer to the following.https://github.com/quwano/KERT/blob/main/LICENSE_ja.md
