Publication details
Nápadovník jmen pro tvůrčí psaní v LuaTeXu
Title in English | Character Name Generator for Creative Writing in LuaTeX |
---|---|
Authors | |
Year of publication | 2023 |
Type | Article in Periodical |
Magazine / Source | Zpravodaj CSTUG |
MU Faculty or unit | |
Citation | |
Web | DOI |
Doi | http://dx.doi.org/10.5300/2023-1-2/3 |
Keywords | creative writing; trie; language models; LuaTeX; Lua; expl3; xparse |
Description | A famous dictum of the computer scientist Phil Karlton says that there are only two difficult things in computer science: cache invalidation and naming things. This is also true in creative writing, where authors have to come up not just with a story and a setting but also the names of all their fictional characters. In this article, we develop a language model in LuaTeX, which allows authors to automatically generate names for their characters. Besides creative writing, we also discuss other uses of language models in LuaTeX, namely the automatic switching of hyphenation patterns based on the current language and blind text generation. For the TeXnically-minded users, the article acts as an introduction to the programming languages of Lua and expl3, and also the xparse LaTeX package for defining document commands in LaTeX. |