HBO

Fans of Game of Thrones now know the character of Daenerys Targaryen (played by Emilia Clarke) has truly arrived. Sure, the erstwhile heir to the Iron Throne has already eaten a horse’s heart raw, wandered barren wastelands and escaped a gaggle of amphibian-faced warlocks. But at the end of the fourth episode of season three, Daenerys utters words for the first time in her mother tongue of High Valyrian — and, in so doing, takes command of an army, orders a shock-and-awe dragon strike and emerges the Stormborn Queen she was meant to be. Never, as my TV-critic colleague Jim Poniewozik wrote, has she “been more compellingly terrifying.”

A big reason for that (at least, judging from fan reactions on Twitter) is the awesome authority this language seems to give her. It’s new, of course, to viewers, but not in the universe of Game of Thrones: in the books of George R.R. Martin, High Valyrian was the language of an all-conquering empire that fell into cataclysmic ruin; the Targaryens carry its legacy.

But unlike J.R.R. Tolkien — The Lord of the Rings author was also an Oxford philologist — Martin never devised actual languages for his fantasy world. For HBO’s show, the task fell to David Peterson, a California-based linguistics scholar and president of the Language Creation Society, a group of linguists who invent languages as a hobby and sometimes discuss them on a podcast; some fellow “conlangers,” as they are known, have also crafted languages for other sci-fi films and TV shows. In a phone interview with TIME last week, Peterson said he was given a largely free hand in constructing High Valyrian and Dothraki, the tongue of the book’s fearsome horse-riding nomads heard earlier in the series.“[Martin] is delighted by the fact they’re there,” says Peterson. “But he’s not really super interested in the languages in and of themselves.”

Peterson, it turns out, got the job through a form of linguistic trial by combat — an exhaustive competition, held by the show producers prior to production, that pitted him against rival language creators. He spent a month tirelessly assembling his concept of Dothraki, incorporating phrases and words mentioned in the books into a deeper language system, supplemented by 300 pages of his own material. “I also made a one-page little summary with factoids,” he says. Peterson’s Dothraki won out, and he has remained HBO’s chosen conlanger for the show.

For High Valyrian, he followed a similar process, though with considerably fewer existing proper nouns and phrases to build on. But he was aided by two Valyrian idioms routinely trotted out in both the books and the show: valar morghulis — “all men must die” — and valar dohaeris — “all men must serve.” That both phrases end with “-is,” a suffix that suggests the modal verb “must,” proved useful. “I developed the entire conjugation system based on those two verbs,” says Peterson. “Only when I couldn’t squeeze any more out of the books did I start the process of creating a set of typological rules and building from there.”

HBO

Language creators don’t structure their creations on the grammatical skeletons of real languages — rather, their academic understanding of how real languages work allows them to come up with new rules for their own inventions. “Language can do much more than it actually does in the real world,” says Peterson. He equates the difference between Dothraki and High Valyrian to that between Russian and Sanskrit, but that analogy is no guide to the pronunciations, syntax or tenses he’s woven into his creations.

Even after “the grammar gets to a point where it’s pretty solidified,” says Peterson, developing the language’s lexicon remains “a lifelong project.” High Valyrian, in Martin’s view, is meant be a kind of Latin for Essos, the vast continent separated by the Narrow Sea from Westeros, where the bulk of Game of Thrones action takes place. It’s a language, as Peterson puts it, that has been “built up over time, and then [its civilization] was destroyed and then it became altered.”

The High Valyrian that Daenerys speaks, for example, is different from that of her interlocutors in the slave city of Astapor, whose argot is a latter-day mix of Valyrian with the other tongues of Slaver’s Bay. Peterson stresses that a key part of inventing a language is establishing its own internal historical logic. “I made sure the language was evolved over a period of time, so that it sounded authentic and had the hallmarks of a natural language,” he says. Like any real language, Peterson’s High Valyrian and Dothraki carry in their morphology centuries of change, migration and encounters with new technology.

Despite his intense engagement with the lore of Game of Thrones, Peterson has yet to visit the set. The dialect coaches employed by HBO — originally to help differentiate between the types of English spoken by the various nobles and small folk of Westeros — work with MP3s he records of the spoken language. Though it’s alien to everyone, Peterson says the end product “looks fantastic.” Martin now occasionally e-mails him for High Valyrian translations, which will presumably appear in the remaining two installments of his seven-volume Song of Ice and Fire series.

Given the worldwide obsession that surrounds both Martin’s books and HBO’s show, Peterson plays a curious role at the heart of things. He’s a self-described “snooty English major,” with little background or interest in the realms of high fantasy. He has created dozens of languages and struggles to speak impromptu sentences in either Dothraki or High Valyrian — even though they are entirely of his making. He does, though, indulge TIME’s request for some translations. “Fire and blood” — the motto of House Targaryen — is perzys ānogār in High Valyrian. “Winter is coming” — the oft-referenced clarion call of House Stark — would be sōnar māzis, though it’s highly unlikely any of the First Men of northern Westeros would have known a lick of High Valyrian (I mean, really).

Peterson admits one of his favorite expressions is a sentence in Dothraki: Mori allayafi anna, jin alegra, he says, over the phone. “It’s how a Dothraki person would just say ‘I like ducks,’ but, if you break it down, he’s actually saying ‘I like them, these ducks.'” He would know.