In the ever-evolving world of Artificial Intelligence (AI), Saheed Azeez, a Mechanical Engineering student at the University of Lagos (UNILAG), has added his name to the annals of history by building a fascinating text-to-speech model with a singular twist.
Called YarnGPT (a name obviously inspired by OpenAI’s ChatGPT), the model reads out texts in clear Nigerian accents.
Since we are in the AI tech race, Azeez found a way to make his model different: it has all the nuances and complexities of Nigerian languages.
Spurred by an interest in robotics
Saheed Azeez has always had an interest in robotics and decided to study Mechanical Engineering as he thought it would make his dream of building robots come true.
“I’ve always been interested in robotics and how things work. So when it was time for me to write JAMB and pick a course of study, I had the option of selecting from Mechanical, Computer, Electrical, or Systems Engineering, and because I didn’t have anybody around me who studied Mechanical Engineering, I decided to go with that.
“I was also interested in building robots. I had thought that Mechanical Engineering would teach me how to build robots someday,” he shared on the UNILAG website.
Inspiration
Azeez disclosed that he got the idea for YarnGPT when he noticed many text-to-speech models with no support for African languages.
“I have seen many text-to-speech systems with no support for African languages, and I have also seen some other text-to-speech models that work with other accents.
“I, therefore, just wanted to build something like that for Nigerian use. Also, I interviewed for a tech company that built something around that, and I didn’t do well in the interview. That spurred me to build this.”
Building YarnGPT
Azeez revealed that the main technology used for building his AI model was Python, attributing the choice to its vast libraries.
“I primarily used Python as the main technology for this project due to its numerous libraries, which greatly simplify the process. Rather than writing code from scratch, these libraries, created by various developers, serve as pre-written code that can be applied to one’s project. It saves time and effort by using the existing work of others.”
“My project involved two major processes. The first was gathering data. The second was to build the model.
“To build a machine learning model, it is essential to collect data that the model can learn from. For this project, I needed to gather text-to-speech data specifically for Nigerians and then build the model.
“Initially, I searched for open-source Nigerian speech-to-text datasets online but found them lacking in quantity and quality.
“Open-source datasets are publicly available data that people have worked on and shared online. Unfortunately, the datasets I found were not sufficient or high-quality enough for this project.
“So the major chunk of data used in this project was data from movies – their audio and transcriptions,” he added.
Navigating Nigeria’s numerous dialects and languages
To deal with the challenge of YarnGPT having to navigate Nigeria’s dialects and languages, Azeez added male and female voices to the model.
“One can actually check it out and choose what voices relate to one’s project better,” he stated.
Potential applications
For Azeez, one application that comes to mind is Audiobooks. He said that most of the ones he has read are in the American accent, so YarnGPT could really help Nigerians in that regard.
“Imagine an audiobook in a Nigerian accent. Most audiobooks I’ve read are usually in the American accent.
“So I feel like it has potential application in that space. Another potential application I see is in terms of education. For example, you can build a system that reads lectures to students in Nigerian-accented English.
“I feel like that would be easier because it will sound familiar to the student, thus making it easier to learn.”
Commercialisation vs open source
Azeez made it clear that he always intended for YarnGPT to help people, so making it open source was an easy decision to make.
However, he did not rule out commercialising the model in the future.
“I’ve actually had a lot of questions around this, but I would, at this point, prefer for it to be open source because it was something I built for myself in the comfort of my home. There are people who this app will really help, and I want it to be of help to these people.
“Maybe in the future I could build a better version, and maybe it could be commercial. Nonetheless, I’m building a better version.”

Follow Us on Google