Graph Books

Graph Books

As a lifelong fan of Dante and Italy, I tried to learn Italian many times to read the Commedia, and it never stuck. Have to go live in Italy for that. The closest I ever got was to become a director of Open-Source Science at IBM, reporting to Anthony Annunziata, an Italian American, with the org in Zurich lead by Alessandro Curioni, and actual Italian (albeit turned Swiss.:). I go to Venice a few times a year to be in my happy place…

And so for years ai was buying the Commedia in all shapes or forms, in Russian and English translations, in bilingual editions, in critical editions. The new translations are exciting — by Palma and James, by Илюшин и Лемперт (need to track down the latter still). So when First Pair Press has created the Obsidian Vault format to deliver books as graphs, it was only a matter of time until the Commedia would become one.

The First Pair Obsidian Vault format can contain a bespoke reader. For books, it’s a fast navbar, but also the interlinked evidence. For a book about a codebase, like Sail, in Rust, we include the whole thing. When the books shows a code excerpt, it links into the whole codebase, right there in the vault. Obsidian hypertext setup is perfect for this.

When a book about Cicero quotes him, we show both the original Latin and an established English translation. Both sources are in the vault.

Obsidian is rather new. The first editor capable of building and delivering books in hypertext is Emacs. Its Texinfo standard is the original hypertext. Emacs ships with its own Info manual, and numerous GNU projects add their own in the Info format. I played with it back in the 1990s!

So when I visited Prof Mark Liberman at Penn, and he told me how he learned Spanish for a talk by loading Spanish books and dictionaries into Emacs and building a custom reader, showing every word’s meaning, I knew what to do.

I put the same content in both the vault and the info. There’s a dozen or so public domain translations of the Commedia, in both English and Russian, the languages I know reasonably well to enjoy the nuances and differences between the translations. English has no agreement or gender as Russian, and the rhythm is harder to recreate, but Palma does a fantastic job while James is always enjoyable. Лозинский is a classic, Мин (Мниь) can be read in both the old and new Russian orthography, and Илюшин is a refreshing modern innovator.

You can select an English, a Russian, or both translations. You can add another one in either language, or both. The stanzas will be aligned under the original one.

For any word of the original, its dictionary definition can be shown in the reader. Furthermore, you can move forward and backward word by word, and the dictionary window will update. The languages in the dictionary will mirror those selected for translations.

Since Dante’s text has many quirks — apocope, elisions, archaic endings — Russian dictionary was harder to fill, but we worked through English where possible and resolved as much as we could.

And then the Emacs fun began. I’ve recreated everything that Obsidian could do, including multiple translations, dictionaries, etc. A desktop Emacs comes with a powerful GUI, menus, and is an easy platform to recreate a vault.

But on the iPhone, the only option I found is iSH, a Linux distribution in a terminal. So I built the reader with xterm-mouse support. If you click on a word, it opens in the dictionary buffer. You can cycle through the translation in the language under the cursor with Tr-next/prev. You can add the 2nd translation in the current language with 2nd, or remove it. You can move through source words with w Next, or cantos with c.

However iSH catches the tap to open the software keyboard. There was no way to circumvent in elisp. So we hacked iSH itself with Fable, adding a Hide Keyboard setting. You have to double tap to return it to the reader.

And while at it, why not improve the app itself? I added pinch to zoom, like Blink Mosh, my favorite terminal client, its font, PragmataPro, eminently readable at any size, and added four fixed arrows next to the gesture pad because there was room. I sent the patch to iSH but will distribute my fork as 1Unix. The golden era of Emacs is here!


published with omnighost · SHA-256 4be012dd86a928cc5f370e31fa089ac55028c82ff31684abc4773a333b3ce630