Being an oracle is weird

In some areas of computer science, “oracle” is used as a term for a magic box that delivers solutions to undecidable problems. Or, sometimes more generally for any machine that generates answers by a process you don’t understand. One of the roles I play with respect to the Battle For Wesnoth fantasy game is as an oracle that generates plausible fantasy names on demand.

Here’s a (very lightly edited) transaction of this kind that I took part in a short while ago. There’s something going on behind it that is odder than will be immediately apparent.

[22:27] <espreon> Espreon: Would you please generate an authentic name for an elvish city?
[22:28] <esr> Sure. Where is it? Are there names of nearby places? What kind of city is it?
[22:29] <espreon> It is in an off-map area of the Northern Forest (probably a part of the Lintainir Forest). Nearby names: Firecloud Peak… Noct… Dramalida
[22:29] <espreon> It was a capital city of that elvish civilization.
[22:30] <esr> Welcome to the city of Aranion
[22:30] <espreon> Thank you. :)
[22:30] <esr> It’s a gift :-)
[22:31] <esr> I actually don’t know how I do it.
[22:31] <espreon> May I also have a name for a mountain within that forest; it has an ancient crypt in which a great elvish ruler (I named him Tyurnio) rests?
[22:32] <esr> Do you want an Elvish name or a kenning in English?
[22:32] <espreon> Elvish please.
[22:32] <esr> Smallish mountain or large?
[22:32] <espreon> An English alternative would probably be needed too.
[22:33] <espreon> Small–medium…
[22:33] <esr> Mount Deranar, called in the tongue of men “Hero’s Rest”.
[22:34] <espreon> Meh, the ruler was a bit hasty and wrathful… but… meh…
[22:34] <esr> OK, thinking…
[22:35] <esr> Mount Thrakal, called in the tongue of men “Pridefang”
[22:36] <espreon> Excellent.

OK, now here’s what makes it odder than it looks. You’d think, reading this transcript, that I was running some kind of conscious algorithm and that my questions were directing me down a logic branch or setting parameters that I was aware of.

But no. Except for “Do you want an Elvish name or a kenning in English?” I actually had absolutely no idea why I asked the questions I asked. I listened to them coming out of my mouth as though I were a spectator. I also had no introspection at all about how the answers to my questions affected the generated names, nor did I actually know what I was going to generate until it sort of popped up in my attention from somewhere out of sight in my mind.

This is all the more bizarre because I’m pretty sure I know from first principles what my brain must be doing. There’s a stock technique for generating plausible sets of names that resemble a known corpus. You build a Markov-chain statistical model of how lexemes, or syllables, are coupled based on observed transition frequencies; then you just roll dice (word-based versions of this technique are often called travesty generators). Many years ago I was a developer on the classic dungeon-crawling game Nethack; it used this technique for generating names and probably still does.

It is almost certain that my brain is doing likewise, especially since I am observably capable of generating instantly and at will names that are recognizably Elvish, Dwarvish, or Orcish. This implies a strong likelihood that the reason I asked for nearby placenames was to get some handle on the local transition frequencies. But this is purely a deductive guess on my part; I can’t monitor the generator in my head at all!

Being an oracle in this way feels pretty weird when it’s happening. It’s almost disassociative.

A couple of other things are interesting to note. One is that Espreon instantly accepted my first name choice for the city. This is normal; I don’t think I’ve ever had a dev reject a name I generated because it sounded wrong for the language it was supposed to be in. So not only do I have a Markov chain in my head that generates names, it reliably generates names with phonotactics that others recognize as correct. This suggests that all post-Tolkien fantasy fans have learned very similar phonotactics that they’re able to apply for recognition, if not for generation.

Note how fast the generator works. I invented three names in 8 seconds, and a lot of the intervening latency was actually typing time. Usually it takes me at most a second or two to come up with something appropriate. Whatever I’m doing, it’s clearly not computationally expensive. I consider this weak supporting evidence that I’m running a Markov chain; it’s a fast, cheap algorithm.

I interpreted Espreon as rejecting “Hero’s Rest” because he felt that kenning didn’t have the atrnosphere he wanted. I’m guessing that “Pridefang” might be an echo of “Mount Fang”, Tolkien’s Westron name for Orthanc (the keep of Saruman), but that wasn’t in my consciousness at the time. I generated “Pridefang” first, then felt real pressure to come up with a different name to match the new kenning; it was like an actual sensation of tension or discomfort in my head, with considerable felt relief when I uttered “Thrakal”.

I think “Thrakal” might actually be a Dwarvish name; there’s a pattern in Wesnothian Human and Elvish languages of using Dwarvish borrowings or calques for names of mountains and mountain ranges, and this one matches Dwarvish phonotactics. (The elves, on the other hand, tend to toponymically own the rivers.)

I’m completely clueless about why the size of the mountain was relevant. I’d love to know, or even have a plausible guess, about how I used that information.

34 comments

  1. Were you asking the questions consciously, or was that “oracular” too? I know that when I do similar stuff, I like getting a feel for what’s going on, and so asking a few setting-establishing questions is normal. I don’t generally have a goal in mind asking them, just looking for a better sense of what the other person wants, what’s going on in the setting before I got there. Hence a lot of the questions are fairly random, just aimed at generic exposition rather than any particular set of facts. Is that similar to your experience?

  2. I don’t remember any Markov-generated names in Nethack, but it’s possible that I simply assumed they were drawn from a medium-sized static list, when they were actually being rolled up. I assume that would be names of deceased adventurers; the only other pseudorandom names I can recall are those of shopkeepers, and those are all drawn from lists.

  3. Ah, but that’s the joy of watching right brain, creative thinking at work. Watching it happen, and then trying to figure out where in hell it came from in the firs tplace.

  4. A really neat ability to have, speaking as someone who needlessly agonizes over names when I try my hand at fiction. I’m glad you’re applying it to Wesnoth and not fantasy literature, though. There’s enough Tolkien mimicry out there already. For example, the Forgotten Realms setting, the Wheel of Time series, and the Eragon books (which I haven’t read) each have a Spine or Spine of the World mountain chain in them.

    I understand that for Wesnoth you aim for the Tolkienesque feel, but if you were trying to write original fantasy, how would you go about making names both fantastic and original? I notice that some writers base their names on the feel of real-world cultures, including obscure ones. Is there any other way to do it? Can you use this “feel” for fantastic place names?

  5. Dissociation is eerily powerful. When I get stuck on a problem at work, sometimes I’ll step back and ask: what would someone competent do? By conceptually making it someone else’s problem, it’s somehow easier to see the answer.

  6. >Were you asking the questions consciously, or was that “oracular” too?

    I didn’t know I was going to ask them until I did. That is, I have no awareness of the process or algorithm I used to generate the questions.

    >Hence a lot of the questions are fairly random, just aimed at generic exposition rather than any particular set of facts. Is that similar to your experience?

    Yes.

  7. I wonder; if you took all your generated names, and sorted them by ‘language’, would they exhibit Tolkien’s linguistic correctness or would they be gibberish?

    I’ll put $10 on the latter ;)

  8. >For example, the Forgotten Realms setting, the Wheel of Time series, and the Eragon books (which I haven’t read) each have a Spine or Spine of the World mountain chain in them.

    The game’s Great Continent has a large range called the Heart Mountains. This is supposed to be a calque of the Dwarvish name.

    It’s deliberate that we try not to be too original. It’s a game, not a novel; our players don’t want to go to a large amount of mental effort to grasp the setting, they have battles to fight.

    >Can you use this “feel” for fantastic place names?

    I’ve actually done this for unpublished fiction and for RPGs. I can easily travesty either the sound pattern of an existing language, or I can invent consistent names that don’t quite sound like any known language. Both are easy but the latter requires a bit more effort.

    Note: The Eragon books, while derivative, are pretty amazingly good considering the author was 15 when he wrote the first one. Most adult fantasists never do as well.

  9. > I understand that for Wesnoth you aim for the Tolkienesque feel, but if you were trying to write original fantasy, how would you go about making names both fantastic and original?

    I went with the explicit conlang phonology route for my perpetually written setting/novel thing; the standard “Biricicanian” names include “Wegeja”, “Misilar”, “Endrefi”, “Amaxyal”, “Cerrak” (the ‘c’ is a voiceless palatal plosive). It is mostly oracular, but I keep names conforming to the intentionally improbable vowel harmony and heavy rhythm.

    Of course, I minimally account for the occasional different language family popping up every now and then; these are mostly rules of thumb. Daroetian has vaguely Germanic phonology, yet is clearly not (e.g. “Foervafenheem”).

    But my schema is meant to sound somewhat non-human and I can only find two people who can pronounce it with any pretense of correctness. :)

  10. It’s deliberate that we try not to be too original. It’s a game, not a novel; our players don’t want to go to a large amount of mental effort to grasp the setting, they have battles to fight.

    Would that more game designers adopted Wesnoth’s philosophy. These days a strong trend in computer/video game design appears to be to deliver average to clunky game mechanics and a thuddingly preachy narrative. The title of one such game, No More Heroes, is indicative of the creator’s philosophical agenda.

  11. @Jeff Read: Agreed, with an addendum: many game designers these days are more concerned with a story than they are with game mechanics. Good game mechanics are, IMHO, central to something playable and fun. You can have a story if you want, but keep it short and out of the way; and if you skimp on the game mechanics it won’t be something I’d be interested in playing at all.

  12. > You can have a story if you want, but keep it short and out of the way;

    You aren’t my daughters. They read the characters’s lines to each other as if they were the voice talent. I am amazed at the differences in the way we play computer games. I think I’ve ever seen them adding dialog to a game without it. Their favorites do not appear to have “a thuddingly preachy narrative” though.

    Yours,
    Tom

  13. I’m glad you decided “Thrakal” sounded Dwarvish after the fact — it’s exactly what I thought as I was reading the transcript.

    And if I remember my Tolkien Elvish roots correctly, “Aranion” could be translated as “Holy Land” — I had a D&D paladin character once named “Aranor” (Holy Sun).

  14. We do try to write strong story, that’s nothing but good. One of my jobs is script-doctoring campaigns that we’re mainline to improve the story values. (Yes, I’m good at this.)

    The trap is making the background of the story so distant from well-established fantasy tropes that players have to spend serious effort understanding it before they can play. That would be a lose. A campaign can take players to a novel place, but it can’t start at a novel place.

  15. > A campaign can take players to a novel place, but it can’t start at a novel place.

    I presume this is why you were working on Under the Burning Suns?

    1. >I presume this is why you were working on Under the Burning Suns?

      No, I was working on it mainly to fix the archaic and rather broken markup in it. The prose and story was pretty good already.

      I see why you asked, though. UtBS pushes our envelope for odd startup conditions. That’s part of the reason we label it as an advanced campaign.

  16. @esr: That’s one of the best descriptions of channeling I’ve ever read. :) Mind if I include it in my lesson materials on the topic?

    ESR says: Heh. Go right ahead.

  17. Sonic the Hedgehog, mostly.

    Same thing, really, nowadays.

    One indicator that I use is that if a Sonic game comes out with a plot more substantial than “there’s a crazy fat motherfucker out there turning your friends into robots; go fuck him up” then Sega is still down with its chronic case of DOING IT WRONG.

    The upcoming Sonic the Hedgehog 4 DLC game appears to ameliorate this vastly.

  18. Well, Jeff, my girls even like fan made Sonic games which have been turned into RPG’s.

    Gaming is not like it was when I was young.

    It’s way more kewl.

    Yours,
    Tom

  19. Nah, your brain is way better than what you describe. It pulls them very opaquely out of seemingly random patters. Its very impressive, and very logic-free. The right brain is an incredible thing.

  20. Hey Eric:

    I once had a D+D character named “Thangru.”

    He was a 23 level magic-user. (Back when they were still called that.)

    What associations, if any, does that name conjure up?

    1. >What associations, if any, does [Thangru] conjure up?

      Sounds Mongolian or Altaic to me. Definitely not Elvish.

  21. Does it require doing some sort of meditation or relaxation beforehand or something?

    BTW it’s probably pattern recognition that happens beyond the level of the conscious mind.

  22. Slightly relevant: I’d be usually ashamed to ask this sort of question, but… what do you guys think, esp. ESR, all sorts of fortune-telling are completely crap, or can you imagine that some sort of meditative trance over Tarot cards or astrological signs or anything that can actually tap into the normally unused resources of the brain, into the place that stores information we received through our senses but was filtered out by the normal consciousness, and from such subtle bits of information it could actually derive some sort of a useful prediction?

  23. @Shenpen: Loaded question. The term “fortune-telling” implies a telling of the future. We do not have epistemological access to the future. We do, however, have epistemological access to the past. Also, as far as “normally unused resources of the brain” — it’s debatable if there are any “normally unused resources of the brain”. Much about how the brain operates is still, as yet, unknown.

    Personally, I perceive the tarot, runes, or other means of divination (in which, I do not include astrology — that’s a horse of a different color, which requires a separate explanation) is that they are basically a psychological “hack” to unlock knowledge from the brain which we are currently, for some reason or another, not paying attention to or at least not immediately aware of.

    Think of this: we each carry around with us billions and billions of pieces of information. And we’re constantly taking in lots of pieces of new information about our surroundings: sounds, colors, objects, smells, the state of our bodies, etc.: everything we can perceive with our senses, including our own “internal” senses. (Hunger, for example, is a “sense,” though not one of the traditional five senses.)

    Yet, at any given moment, we’re only immediately aware of a few bits and pieces of that information, depending on our context. All of that information can be very hard to sort through, and we may already know something without knowing that we know that.

    We can “tell the future” because of patterns from our past experiences. Unfortunately, we’re not always thinking things through, and we’re not always aware of what these patterns are telling us about something we’re doing now. People tend to repeat the same mistakes over and over. Only when the consequences of commiting that same mistake are severe enough to we learn our lesson not to repeat that same mistake.

    What tarot does is help us to unlock that latent knowledge and bring it to the forefront of our minds. Then, with our full awareness aimed at the question at hand, we can better decide a correct course of action.

    I’m very fond of saying that “tarot often tells you what you already know.” That’s actually a little white lie. If I wanted to be truthful, I should really say “tarot always tells you what you already know when it tells you anything at all.”

    I have far less “faith” in astrology. With astrology, it does sometimes seem that people generally conform to their signs. But only in a very general sense. And that’s the key right there: astrology “works” for many people because astrology says only very general things that could apply to almost anybody.

    ESR says: I have the same theory of divination Morgan expresses here. I couldn’t have put it any better.

  24. I wanted to make a tarot deck—maybe I still will—with things that I wanted to remind/jar myself with from time to time. Like a card named »Unix was written with ed« to remember to not blame my tools too much; or »The Lisp«—which could bring about all manners of associations. (Only a few of the cards were CS related.)

  25. Eric,

    re: that name Thangru.

    You’re right, it definitely does not sound Elvish, it’s too….. rough sounding, somehow.

    It sounds dwarvish to me, although the -gru at the end somehow sounds demonic or devilish.

  26. ESR, in your intitial blog entry, you wrote:
    >>I am observably capable of generating instantly and at will names that are recognizably Elvish, Dwarvish, or Orcish. …

    >>So not only do I have a Markov chain in my head that generates names, it reliably generates names with phonotactics that others recognize as correct. This suggests that all post-Tolkien fantasy fans have learned very similar phonotactics that they’re able to apply for recognition, if not for generation.<>I wonder; if you took all your generated names, and sorted them by ‘language’, would they exhibit Tolkien’s linguistic correctness or would they be gibberish? I’ll put $10 on the latter ;)<<

    It might well be gibberish–correct sounding gibberish, but it would be gibberish to any one who actually speakes one of Tolkien's Elvish languages. (Yes, I have met some of these people.)

    A Gaelic sort of name for a D&D city that I came with was "Tir Nan Tu" about 28 years ago. It was the common name among humans of an old Elvish city, probably not the genuine name.

    Here's a "Spanish sounding" place-name example "coza de montana" or "Mountain of Coza." It is important to understand that I do not speak or read Spanish, no more than I speak an Elvish tongue.

    I know "montana" is mountain, but I don't know what a "coza" would be.

    A person who had heard or seen written the Spanish language might agree that this sounds "plauseable" or "right." The trick is to repeat phoenic patturns found in the language.

    I can not do this quickly, naturally, or easily of the top of my head. I have to sit around studing the written words to come up with something sounding "plauseable" or "right."

    Playing with language like this is fun! Or at least I think so.

    Any one really speak Spanish? "Un cucu atacó salvajemente a Antonio de Antioque, la nobleza portugusa." Who from where got attacked by what?

  27. @ESR said: I’m completely clueless about why the size of the mountain was relevant. I’d love to know, or even have a plausible guess, about how I used that information.

    This is how I would use such information, so YMMV. “Smallish mountain or large?” is analogous to “What kind of city is it?” Both of them have meaning for the tone of name within the various language at least within tropes used to assist gamers. That is, a capital city should be expected to sound more regal than a mere village. Example: Minas Anor sounds less regal than Osgiliath. Mt. Everest sounds cooler than Mt. Hood, and Krakatoa sounds vaguely ominous. In this case, you had a smallish mountain, so it didn’t get as grandiose a name as a larger one would be.

    Of course, violating these general rules for effect can work, for instance calling the largest mountain Khrul, where the incongruity between name and importance accentuates both. Or giving a very long name in satire or jest to a small village or creek.

Leave a Reply to Dallas J. Haugh Cancel reply

Your email address will not be published. Required fields are marked *