Early release · v0.1

Papers, read aloud with the page in front of you.

Rail Narrator reads a PDF aloud. The word being spoken is highlighted where it is printed, and the view follows it. Made for papers and technical documents, it can say what an equation means, in the paper’s own terms, instead of reading out symbols.

  • Desktop app for Linux; Windows as a preview
  • Free & open source (MIT)
  • Voices run on your computer
Rail Narrator reading a one-page note aloud: on the page the word being spoken, ‘quickly’, outlined in amber, and the passage being read selected in the script sidebar
01

Hear it

Listen to a page

A one-page note, narrated by Rail Narrator and saved with the document, as it would be on your computer. The highlight below is drawn from the word timings saved with the audio, the way the app draws it. Choose a voice, or how the maths is read.

The sample note: A short note on exponential smoothing, with an introduction, a section deriving the smoothing recursion with two numbered equations, and a section on choosing the constant
0:000:00
Voice
Maths

Press play, or click a sentence on the page.

The sample: smoothing-note.pdf, written for this page. How these recordings were made.

The script: every passage, as spoken
    02

    Maths for meaning

    One equation, three ways

    Text needs nothing more than a voice. Maths is read in one of three ways, and you choose which. Here is the same sentence and equation from the sample, as each one reads it.

    From the sample: The forecast for the next period is a weighted average of the newest observation and the previous forecast: y-hat t plus 1 equals lambda y t plus (1 minus lambda) y-hat t. Equation (1).

    With nothing set up

    An equation on a line of its own is announced, not read. A sentence with maths in it is read as printed, its subscripts and powers as maths (“y sub one”).

    The forecast for the next period is a weighted average of the newest observation and the previous forecast: This equation could not be read reliably.

    The formula model

    Reads the equation symbol by symbol. 594 MB, runs on your computer and sends nothing out.

    The forecast for the next period is a weighted average of the newest observation and the previous forecast: y hat sub t plus one equals lambda y sub t plus the quantity one minus lambda, end quantity, y hat sub t

    A language model

    Says what the maths means, in the paper’s own terms. Claude (here) or OpenAI with a key from your account, or a model on your own computer.

    The forecast for the next period is a weighted average of the newest observation and the previous forecast: the forecast y hat sub t plus one equals lambda times the newest observation y sub t, plus one minus lambda times the previous forecast y hat sub t.

    A language model needs one thing from you. Claude is chosen from the start and needs an API key from your Anthropic account; OpenAI, with a key from your OpenAI account, is the other choice. Either sends each passage with maths to that company, as a picture of that part of the page with the text around it, and is paid for by use. A model on your own computer, through any OpenAI-compatible server (llama.cpp’s llama-server, Ollama, LM Studio), sends nothing out and costs nothing. A passage spoken in other words than the page’s is highlighted in violet, so it is plain that what you hear is not what is printed. Reading maths says what each choice downloads, sends and costs.

    03

    What it does

    A narrator that knows where it is on the page

    It reads the page’s structure first, so what you hear and what you see stay together.

    Reading aloud

    Your eyes and ears in the same place

    The passage being read is highlighted where it is printed. With a voice that times its words, the highlight moves word by word; the view follows the reading at any zoom.

    Scroll away to look at a figure, and following pauses, then picks up again. Click any sentence to read from there. The script of every passage is in the sidebar.

    Rail Narrator reading: the word ‘quickly’ outlined in amber on the page, with the passage being read selected in the script sidebar

    Maths

    Equations, explained as they are read

    A language model looks at each equation and each sentence with maths in it, and the narrator says what it means. The maths is interpreted just before it is read, a few passages ahead, so a document opens at once.

    Maths review shows what was recognised and what will be spoken, side by side. Correct it in your own words, or ask again.

    A sentence and equation (1) highlighted in violet while their meaning is spoken, and the Maths review sidebar showing the spoken version and that a language model wrote it

    Notes

    Take notes without losing your place

    Press N to note what was just read, or H to highlight it without stopping. Annotate mode (Ctrl+E) adds highlighters, underline, strikeout, sticky notes, a pen and boxes.

    Your notes are kept beside the PDF, never written into it. Export them as Markdown, as an annotated copy of the PDF, or for RailReader2. Open a revised version of the paper and they follow you, placed by the words they quote.

    Two highlights on the page, one with a note, listed in the Review notes sidebar with the words they quote

    Set-up

    Nothing fetched until you say so

    Rail Narrator comes without speech models. The first time it starts, a set-up window takes you through a voice, the layout model and maths, and lists every download with its size, its licence and where it comes from. Nothing is fetched before its last button.

    Speech, layout and formula models run on your computer. Passages with maths go to Claude or OpenAI only once you give it a key, with a link to where one is made; choose no language model, or one of your own, and nothing leaves your computer.

    The set-up window’s maths step: no language model, or one (Claude unless you choose another), with a link to where a key is made

    And also

    Skips what you would skip

    Contents pages and a first page’s affiliations are passed over. With the layout model, so are running heads, page numbers, footnotes, references, figures and table cells; the sample above skips its header, page number and references.

    Narrate a whole document ahead

    File → Save narration with document… prepares every passage once and keeps it beside the PDF. From then on it plays with no language model and no speech engine; the player above plays such files.

    Audiobooks

    File → Export audiobook (M4B)… turns a saved narration into an audiobook with a chapter at each heading (needs ffmpeg, which you install).

    Two speech engines

    Phonon (71 MB): fast, 25 British and American voices, each word highlighted as it is spoken. Kokoro (164 MB): another set of voices, slower, with word timing as an extra download.

    Word timing that is measured

    A word is highlighted only when its timing comes from the voice model itself or from a forced aligner. Where neither has it, the whole sentence is highlighted instead; a time is never guessed from the letters.

    From the command line

    rail-narrator narrate paper.pdf prepares the narration; rail-narrator export paper.pdf writes the audiobook.

    Colour filters

    High contrast, amber and invert, on the page only, as in RailReader2. Press C to cycle. Settings also has a high-contrast highlight.

    Outline and sections

    The PDF’s own outline is in the sidebar: choose a heading to read from it. The status bar names the section being read.

    Speed and position

    Play faster or slower without changing the voice’s pitch. Close a document and it opens where you stopped.

    A companion to RailReader2, the rail-reading PDF viewer, and built on the same engine, RailReaderCore.

    04

    Five minutes

    Getting Started

    1. Linux: download rail-narrator-x86_64.AppImage from the releases page, make it executable (chmod +x rail-narrator-x86_64.AppImage) and run it. It includes everything it needs, sound included. An archive is there too; it needs PortAudio (libportaudio2 on Debian and Ubuntu, portaudio on Fedora). Either needs a Linux from 2022 or later (Ubuntu 22.04, Debian 12, Fedora 36).
    2. Windows (preview): run rail-narrator-setup-x64.exe. It installs for your user and needs no administrator rights; or unzip the win-x64 zip anywhere. Neither is code-signed, so SmartScreen may warn you: choose More info, then Run anyway.
    3. Set up: the first start takes you through a voice (Phonon, 71 MB, recommended), the layout model (69 MB, recommended) and maths, then downloads what you chose. For maths said in plain words, paste a key for Claude or OpenAI there or later in Settings → Maths. You can skip it and come back from Help → Set up Rail Narrator…
    4. Open a PDF with File → Open PDF… (Ctrl+O), or drop one on the window, and press Space. A document is never read aloud until you ask.

    An early release. It works end to end on Linux, where it was developed. The Windows build is built and tested automatically, but nobody has yet run it on a Windows PC: please report what you find. English only, for now. Scanned PDFs are read through OCR, which has been tried on only a few scans. What has been verified, and how it was measured.

    05

    At your fingertips

    Keyboard Shortcuts

    Press F1 in the app for the full list.

    KeyAction
    Reading
    SpacePlay or pause
    Ctrl+Right / Ctrl+LeftNext or previous passage
    Ctrl+RReplay the passage
    Click a passageRead from there
    EscapeBack to the reading after browsing; otherwise pause
    Following
    Ctrl+FFollow the reading on or off
    F9Resume following after browsing
    Notes
    N / Shift+NPause and write a note on the sentence just read / the whole passage
    H / Shift+HHighlight the sentence just read / the whole passage, without stopping
    Ctrl+Up / Ctrl+DownMove the new note or the selected mark to the sentence before or after (with Shift, take it in as well)
    Ctrl+EnterIn a note: save it and read on
    Ctrl+EAnnotate mode on or off
    1 to 5In annotate mode: choose a colour
    Ctrl+Z / Ctrl+Shift+ZUndo or redo an annotation
    Page
    Page Down / Page UpNext or previous page (pauses following)
    Ctrl+GGo to a page
    Ctrl+= / Ctrl+-Zoom in or out
    CNext colour filter
    Window
    Ctrl+OOpen a PDF (or drop one on the window)
    F6Sidebar: outline, script, maths review, notes
    Ctrl+,Settings
    F1All keyboard shortcuts
    06

    The fine print

    How these recordings were made

    The sample note was written for this page and typeset with LaTeX. Each recording is the file Rail Narrator saved with rail-narrator narrate smoothing-note.pdf, with the Docling Heron layout model; the formula model read the equations where it is named, and Claude (claude-opus-5-5) where it is named, asked afresh for each voice, so the voices word the maths differently. For the web its audio was brought to one loudness (−16 LUFS, so that changing voice does not change the volume) and converted to MP3. Nothing was cut, re-ordered or re-recorded, and the timings are the app’s own.

    The word highlights are the timings saved with each passage: from the voice model’s own attention (Phonon) or its phoneme durations (Kokoro). No forced aligner was installed. A passage without word timing (a maths passage, or one the engine could not time word for word) is highlighted whole, as in the app.

    Without a language model, a sentence with maths in it is read as printed, with the subscripts and powers found on the page read as such: “observations y sub one, …, y sub n”. A language model says what the sentence means instead, in words that can differ from one run to the next. The script lists every passage exactly as spoken.