Being an oracle is weird
<p>In some areas of computer science, &#8220;oracle&#8221; 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&#8217;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.  </p>
<p>Here&#8217;s a (very lightly edited) transaction of this kind that I took part in a short while ago.  There&#8217;s something going on behind it that is odder than will be immediately apparent.</p>
<p><span id="more-1729"></span></p>
<blockquote><p>
[22:27]	&lt;espreon&gt;	Espreon: Would you please generate an authentic name for an elvish city?<br />
[22:28]	&lt;esr&gt;	Sure. Where is it? Are there names of nearby places? What kind of city is it?<br />
[22:29]	&lt;espreon&gt;	It is in an off-map area of the Northern Forest (probably a part of the Lintainir Forest). Nearby names: Firecloud Peak&#8230; Noct&#8230; Dramalida<br />
[22:29]	&lt;espreon&gt;	It was a capital city of that elvish civilization.<br />
[22:30]	&lt;esr&gt;	Welcome to the city of Aranion<br />
[22:30]	&lt;espreon&gt;	Thank you. :)<br />
[22:30]	&lt;esr&gt;	It&#8217;s a gift :-)<br />
[22:31]	&lt;esr&gt;	I actually don&#8217;t know how I do it.<br />
[22:31]	&lt;espreon&gt;	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?<br />
[22:32]	&lt;esr&gt;	Do you want an Elvish name or a kenning in English?<br />
[22:32]	&lt;espreon&gt;	Elvish please.<br />
[22:32]	&lt;esr&gt;	Smallish mountain or large?<br />
[22:32]	&lt;espreon&gt;	An English alternative would probably be needed too.<br />
[22:33]	&lt;espreon&gt;	Smallâ€“medium&#8230;<br />
[22:33]	&lt;esr&gt;	Mount Deranar, called in the tongue of men &#8220;Hero&#8217;s Rest&#8221;.<br />
[22:34]	&lt;espreon&gt;	Meh, the ruler was a bit hasty and wrathful&#8230; but&#8230; meh&#8230;<br />
[22:34]	&lt;esr&gt;	OK, thinking&#8230;<br />
[22:35]	&lt;esr&gt; 	Mount Thrakal, called in the tongue of men &#8220;Pridefang&#8221;<br />
[22:36]	&lt;espreon&gt;	Excellent.
</p></blockquote>
<p>OK, now here&#8217;s what makes it odder than it looks. You&#8217;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.</p>
<p>But no. Except for &#8220;Do you want an Elvish name or a kenning in English?&#8221; I actually had <em>absolutely no idea</em> 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.</p>
<p>This is all the more bizarre because I&#8217;m pretty sure I know from first principles what my brain must be doing. There&#8217;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.  </p>
<p>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&#8217;t monitor the generator in my head at all!  </p>
<p>Being an oracle in this way feels pretty weird when it&#8217;s happening.  It&#8217;s almost disassociative.</p>
<p>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&#8217;t think I&#8217;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 <em>phonotactics that others recognize as correct</em>.  This suggests that all post-Tolkien fantasy fans have learned very similar phonotactics that they&#8217;re able to apply for recognition, if not for generation.</p>
<p>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&#8217;m doing, it&#8217;s clearly not computationally expensive.  I consider this weak supporting evidence that I&#8217;m running a Markov chain; it&#8217;s a fast, cheap algorithm.</p>
<p>I interpreted Espreon as rejecting &#8220;Hero&#8217;s Rest&#8221; because he felt that kenning didn&#8217;t have the atrnosphere he wanted.   I&#8217;m guessing that &#8220;Pridefang&#8221; might be an echo of &#8220;Mount Fang&#8221;, Tolkien&#8217;s Westron name for Orthanc (the keep of Saruman), but that wasn&#8217;t in my consciousness at the time.  I generated &#8220;Pridefang&#8221; first, then felt real pressure to come up with a <em>different</em> 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 &#8220;Thrakal&#8221;.</p>
<p>I think &#8220;Thrakal&#8221; might actually be a Dwarvish name; there&#8217;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.)</p>
<p>I&#8217;m completely clueless about why the size of the mountain was relevant.  I&#8217;d love to know, or even have a plausible guess, about how I used that information.</p>
