The King and AI

A team of international scholars tackles a historical work of epic proportions.

February 11, 2026
King Alfonso X of Castile, as depicted in the 13th century manuscript Libro de los juegos. (Photo courtesy: Bridgeman Images)

​​​In the 13th century, an ambitious monarch named King Alfonso X of Castile commissioned a universal history of epic proportions — from the origins of the world, as narrated in the Bible, to the time of his kingship. What would come to be known as the General e Grand estoria would weave together Christian, Jewish, Islamic and apocryphal biblical interpretations with stories from the mythological and historiographical traditions of the classical Greek and Latin world. It would eventually total 6,000 pages and become the largest universal history written in medieval Europe – and one of the least known. 

​​More than 700 years later, Francisco Peña, a professor in the faculty of creative and critical studies at the University of British Columbia Okanagan, came across the General estoria when researching biblical characters for a book. “I realized how original it was and how different. It was very interesting because it was knowledgeable of many different sources that I was not aware had circulated in medieval Spain,” he says. “I could connect it to some sources that are familiar and also some ways of writing that were familiar for me.” He says he thought that it warranted deeper study, “but it’s huge.” 

The seed was planted, and Dr. Peña organized a small team of half a dozen scholars to begin tackling the voluminous project. In 2016, they received an Insight Development Grant from the Social Sciences and Humanities Research Council (SSHRC) to determine the feasibility of the project. Since then, the team has continued to grow and receive further funding. It now comprises almost 60 scholars and practitioners from 18 partner organizations and 33 institutions in at least 10 countries including Canada, Colombia, Egypt, Portugal, Spain, Tunisia, the United Kingdom and the United States. Dr. Peña is the principal investigator and a co-director, along with Katie Brown from the University of Exeter in England and Francisco Gago-Jover from the College of the Holy Cross in Worcester, Mass. In 2025, the Confluence of Religious Cultures in Medieval Historiography: A Digital Humanities Project received $2.1 million through a SSHRC Partnership Grant. 

A transfer of knowledge 

​​The General estoria is written in Medieval Spanish, which was unique at a time when most similar texts in Europe would have been in Latin. The writers and collaborators would have had to translate and adapt diverse religious and classical sources; while most were Latin, others were French and Arabic. “I had the idea of studying this text because it is the biggest universal history written in Europe in the medieval times, but, at the same time, it’s connected with all the transfer of knowledge that is happening at this time from the East to the West,” says Dr. Peña. “So we are here with a text that is really gathering many different sources, of which many of them have disappeared partially or entirely. And, at the same time, it’s a very relevant moment for transferring of knowledge, not only in the humanities, but also the sciences.” 

Francisco Peña, principal investigator of the Confluence of Religious Cultures in Medieval Historiography project, examines an illuminated manuscript along with Arianna Ormrod. (Photo: Tal Vardi)

​​There have been previous studies of the text, but this international research team’s undertaking is much more extensive.​ “I wanted to build a project that approaches the humanities in a different way, in a more collaborative way and more interdisciplinary way,” says Dr. Peña. The project brings together scholars from across multiple disciplines, including languages, history, textual analysis, archival studies, philology, digital technologies and more. “There’s always the temptation of the ego and I think that this kind of work, with groups of people, it shows you how little you know and how much you really need to interact to move forward. That’s the beauty of it,” he says.  

​​They are working collaboratively to create their own critical annotated edition of the text, aiming to reflect a more comprehensive understanding of its meaning, as intended by its authors. “What we are doing now is to study the book and creating all these things that will connect it with other sources,” says Dr. Peña, including translations, glossaries, bibliographic information and other annotations. They hope to connect it to other medieval texts, including those “that haven’t been edited yet, or we don’t have access to yet — not only in Spanish but also in Latin, Arabic, probably also in Cyrillic or Greek.”  

Previous editions were paper-based, which limited the space available for explanatory details and annotations. This project is creating a digital version using a digital platform called Colabora, previously developed by Dr. Peña and colleagues. The platform allows the team to work concurrently and collaboratively, across distance and discipline, to transcribe, digitize, translate and annotate the 6,000-page original text using a range of digital humanities tools — including artificial intelligence.  

Expanding historical research with AI 

Historians have long used digital and statistical tools but, in recent years, AI has become a game-changer. ​William J. Turkel, a history professor at the University of Western Ontario, was named one of UWO’s first Generative AI Teaching Fellows in 2025. ​“If you jump back a couple of hundred years, someone could spend a whole lifetime writing a concordance for the works of Shakespeare,” says Dr. Turkel. “They would go through and find every single word that was used by Shakespeare and show you the context in which he used it and then arrange them alphabetically. This was such a valuable tool that people would literally spend a lifetime creating one of them.” Today, he says, “someone who doesn’t know how to program could sit down with ChatGPT and talk themselves through a concordance program in a few minutes.”  

Dr. Turkel sees a mixed reception for AI’s use from his colleagues. “One thing that is very common,” he says, “there seems to be a real kind of wish that this is going to be un-invented.” On the other hand, some historians are experimenting and exploring the technology. “They’ve discovered it can do almost science-fiction kinds of things, like transcribe 18th century handwriting better than our best models of a few years ago. …There are so many things we’re not even thinking about that we could be doing already. Then there’s the question of how our understanding of the past, the evidence that we use to understand the past, is changing now and will change rapidly in the near future.”  

As Dr. Peña and the project team grapple with their own pursuit to gain a deeper understanding ​​of history through the General estoria, they are experimenting with how AI can help them tackle its vast amount of medieval text. One area they know AI can help is by transcribing the handwritten pages.

Medieval text can be exceptionally tedious to transcribe. In addition to its ornate calligraphy, the text was often written as a single block, without paragraph breaks and sometimes even without spaces between words. A variety of abbreviations and special characters were frequently used, and spellings were typically not standardized. A human could take a few days to transcribe one page, says Dr. Peña, but “when you train the AI to one specific text of medieval writing, then it figures it out very fast.” A member of the project team, who has previously translated other medieval texts using AI, is testing it on one of the General estoria manuscripts.

A page from the General e grand estoria. (Photo: Manuscrito de la Biblioteca del Escorial / Wikimedia Commons)

The team is also looking into how AI could help them identify the different sources and voices woven through the text. “We know that these 6,000 pages were not written by the king. That is for sure. He was too busy, fighting his own family and many other different kings,” says Dr. Peña. Alfonso X commissioned the text, but a diverse team of individuals from Christian, Jewish and Muslim backgrounds were its writers – and they, in turn, drew from an even more diverse range of source material. The result is a text that is both polyphonic, while sometimes also contradictory. 

“It’s fascinating. You have one passage where they portray the Muslim very negatively and then you have one that they’re portrayed fantastically,” says Dr. Peña. Different viewpoints, perspectives and people are all mixed into the General estoria. “It’s so important to detect the voices, knowing where they are located and who they are — and to also show the complexity of this work and the complexity of reality itself.” 

Detecting each writer isn’t as simple as identifying unique handwriting. In medieval times, often “the one who writes is not really the one who writes. It was somewhat dictated. So, you cannot detect the different voices through the writing. It has to be through the style,” says Dr. Peña. “For example, the way he locates the different elements of the sentence, the different words that he uses that can be connected with the specific areas of the Iberian Peninsula.”  

To analyze these stylistic differences, scholars use a program based in stylometry. Stylometry uses statistical analysis to identify authorship. However, the General estoria has proven “tricky”, say Dr. Peña. It appears that in some cases authorship changes from one page to another, while in others it changes inside of a specific text. “We will have to train it somehow and, for that, we could use artificial intelligence to train the analysis of the voices.” 

​​​A pilot project is using custom GPT to compare the General estoria with other classical, biblical Christian, Latin, Arabic, Hebrew and vernacular histories that preceded it. Designed to look for potential textual and thematic similarities, it could help identify original source materials, as well as potentially help identify the contributions of distinct writers. It is being tested in conjunction with an application focused on bibliographic assistance, which uses AI along with curated bibliographies and project outputs to help scholars identify related research and literature, summarise key arguments and better search the General estoria text​​. “Putting it together, eventually we will start being able to separate the different parts of this,” says Dr. Peña.​​ “For example, if you are doing research and you want to know what has been written by one specific scribe or a collaborator, you will be able to do it in the platform.”  

Taking a critical approach 

​​While it is hoped that AI will help speed up some aspects of the project and enable others, the process still requires human insight and expertise. “We always need to review,” says Dr. Peña. The project has also exposed some weaknesses of artificial intelligence, he says, — for example, translation.  

“We have to create a specific voice to communicate this text and a voice of the knowledge of the text itself. To move from a medieval Spanish into a modern language and transmit that specific personality is not something that I think right now artificial intelligence can do.” A project translation team comprised of researchers and trainees is collaboratively translating the text into modern English and modern French. It is expected that AI will then help translate these translations into other modern languages. 

As AI becomes more pervasive, deciding when to use it — or not use it — becomes more complicated. ​ ​L.K. Bertram, a professor of history at the University of Toronto, specializes in history, social media disinformation and the AI shift. ​​​​ In 2018, Dr. Bertram created an open classroom on Instagram about sex work and its history. ​​“I’ve always felt like societies can’t make good decisions about the present if they don’t have accurate information about the past, and the history of sex work, and sex work generally, there’s so much disinformation about it,” she says. She shared bite-sized lesson, and “it really took off, it was amazing.” But because of the content that she was sharing, the classrooms started to get policed by the algorithm platforms, “like it was a prostitution account.” Instagram shut down her classroom. Although she managed to put it up again and find ways to avoid the algorithm policing, “it was that front row seat to being on the wrong side of algorithmic tools that made me really push myself into asking more questions,” says Dr. Bertram.

A page from the General e grand estoria. (Photo courtesy: Real Academia Española)

​​​Whether it’s an algorithmic AI or the even more controversial generative AI, “there’s a rapidly growing public sense of unease around AI generally and the lack of honesty and industry transparency about these tools and their potential impact and risks,” says Dr. Bertram. “We could absolutely have secure, high-quality AI tools that save time, advance research and education, and help people live longer, healthier, happier lives, but this is not what is actually happening right now. Many AI companies expect us to pay for AI tools with things that are way too valuable: our privacy, our kids mental health and quality of education, our rights to our work and intellectual property, and even potentially our personal and national security. It’s time to make AI that works for people and not the other way around.”

For the General estoria project, a digital team will evaluate the results of the AI projects, says Dr. Peña. “After that, we will see what are the things that we are going to be incorporating.” If AI is helpful, he remarks, “we are not going to reject it. We are going to incorporate it because it can help us. But, first let’s check it.” 

A globalization of knowledge 

The project team is working to create a first-ever, complete, digital, annotated edition of the General estoria — one that is interactive and openly accessible. Over the project’s seven years of funding, they plan to provide training and mentorship opportunities to students from multiple disciplines, engage with a variety of international partners and mobilize resources for educators, museums and other public audiences. Dr. Peña says he is excited by the fact that there is much to learn from this text. “It’s kind of a permutation. The more you know it, the more things you see,” he says. “It gets wider.” 

He is also excited by the structure of the project itself, as a methodology in the humanities. “It’s not my project anymore, it’s our project. … It is not Francisco Peña’s edition of the General estoria because it’s not mine. I cannot claim something that is not mine.”  

Back in the 13th century, the idea of authorship was not the same as it is today. ​​While Alfonso X didn’t write the General estoria, his name will forever be attached to it — its writers remaining anonymous.​​ The king, later known as Alfonso the Wise, envisioned the General estoria as a universal history stretching from Genesis to his reign. But the final years of his life were complicated by a civil war and a rebellion by his eldest son. With his death in 1284, the project was abandoned, incomplete – its six volumes only reaching the New Testament. Seven hundred years later, it lives on, enabled by technologies unimaginable to the king and by the curiosity of scholars, keen to uncover the knowledge and lost voices contained within its pages. 

The weekly read
for Canadian higher ed professionals
Join thousands of subscribers who receive career advice, news, opinion columns and feature stories from University Affairs.