
\documentclass[12pt]{article}
\usepackage[T2A,OT1]{fontenc}
\usepackage[default]{cantarell}
\usepackage[a4paper, top=20mm, bottom=20mm, left=20mm, right=20mm]{geometry}
\usepackage[utf8]{inputenc}
\usepackage[russian, english]{babel}
\usepackage{tabu}
\usepackage{hyperref}
\usepackage{parskip}
\usepackage{graphicx}
\usepackage{tabularx}
\usepackage{float}
\floatstyle{boxed}
\restylefloat{figure}
\usepackage{setspace}
\onehalfspacing
\author{Artyom Bologov}
\date{\today}
\title{Towards Better Word}
\makeatletter
\def\endenv{\expandafter\end\expandafter{\@currenvir}}
\makeatother
\begin{document}
\maketitle

\includegraphics[width=\textwidth,height=\textheight,keepaspectratio]{./assets/better-word.png}

Armenian has 39 letters
And even some more if you take some historic ones.
(My favorite one is ‘ԱՒ’, doing a sound in between ‘A’ and ‘W’.)
It’s a lot.
With such an amount, even the language as phonetically diverse as Armenian… has some letters unused.
Well, not unused, but rare.
Some almost exclusively allocated to represent loan word sounds, like English soft ‘p’ or plain ‘o’
(The letters in question are ‘Փ’ and ‘Օ’.)

I don’t find that bad or worthy of a language reform.
More than anything, I’m ready to embrace this diversity.
(However hard learning Armenian alphabet and phonetics was.)

I find it more surprising that some languages don’t do that.
Toki Pona is extremely minimalist in its sound set, which might be good for a conlang.
But it’s terrible for loan words.
And loan words are an important way to extend the language, almost for free.
I realize that this is not a goal for Toki Pona, but the problem is there.
Inflexibility when exposed to other languages.

Now where am I getting with that…
Right! Text editing!

Open your code editor and input this sequence of symbols into the buffer (copy-pasting is allowed):

\begin{figure}[h!]\begin{verbatim}
ident_name-re-enacted@here
\end{verbatim}\caption{test test test}\end{figure}

What happens if you put the cursor at the start of this sequence and do forward-word (vi <kbd>w</kbd>, Emacs <kbd>M-f</kbd> key)?
It will most inevitably land on the first dash.
Press it again? Next dash.
Press again? At-sign.
But… why didn’t is stop at the underscore?

That’s the concept of “word.”
It’s quite rich in linguistic associations, so it must be something smart.
Yet it’s boring in text editing: “word” is a sequence of alphanumeric and underscores.
That’s it.

You can see this notion of “word” everywhere:

\begin{itemize}\item Most text editing widgets in most GUI frameworks
\item Browser text boxes (I’ll let you in on a secret: these are the same as GUI text widgets)
\item Regex (Perl et al. \verb|\w| char class)
\item Hashtags
\item Usernames
\end{itemize}

This awful notion permeates everywhere.
It doesn’t account for any language but C (which vi was apparently written in/for.)
Even though most C-family languages have diverging notion of identifier / word / movement unit.
Here’s what’s allowed in identifiers in some programming languages:

\begin{description}\item[JavaScript]
C-like, but with \verb|$| allowed (remember jQuery?)
\item[Perl]
Sigils starting identifiers! Like \verb|$scalar|, \verb|@array|, \verb|%hash|, and \verb|\&fn|. (As an added irony, these are not recognized as integral words by Perl’s own \verb|\w| regex)
\item[BASIC]
Type-postfixed vars: \verb|string$|, \verb|double#|, \verb|float!|, and \verb|integer%|.
\item[Lisp-family]
\verb||Anything||, but conventionally \verb|d-a-s-h-e-d|, \verb|destructive!|, \verb|predicate?|, \verb|%internal%|, and \verb|*global*|
\item[CSS]
\href{https://developer.mozilla.org/en-US/docs/Web/CSS/custom-ident}{@nγ✝нiΝ9!}
\end{description}

See where I’m getting with this Armenian vs. Toki Pona argument?
Text editing word concept is inflexible when encountering the diversity of naming systems.
We need better.

“S-expressions!” shouts a Lisp freak in me.
And that’s a really good solution, because it implies a structure that “words” don’t have.
All the text you work on has structure, and yet you’re not using it.
Waste of resource.

But I think that s-expressions are not enough to dismantle “words.”
We need a better concept for atomic symbols / identifiers in our code / texts.
I introduce you to a Better Word™:

\begin{figure}[h!]\begin{verbatim}
\([[:alnum:]!#$%&*+/:;=?@^_`|~-]\{1,\}\)
\end{verbatim}\caption{POSIX regex for a Better Word}\end{figure}

There are multiple complaints you can make about it that I expect:

\begin{itemize}\item “But why include exclamation and question marks? There are terminators in prose”
\item “Arithmetic operators should separate words. Yes, even dash, even in Lisp”
\item “Words cannot consist entirely of digits, these are numbers”
\item “Why not include dots and commas?”
\end{itemize}

But the mere fact of us thinking that shows: the concept of “word” is up to debate.
(If the “word” is indisputable to you, then you’re likely a vi+C—two separate words, no doubt!—extremist and I’m sorry for you.)
“Words” are inflexible, much like phonetic simplicity of Toki Pona.
Let’s change that.
If not with Better Word™, then with something else.
Because languages and tools are ours to shape, not vice versa.


\par\noindent\rule{\textwidth}{0.4pt}
Copyright 2022-2025 Artyom Bologov (aartaka).
Any and all opinions listed here are my own and not representative of my employers; future, past and present.

\end{document}
