A 17-year-old West Virginia high school student is showing his love for technology and music by using lyrics from Kanye West to program his own artificial intelligence to rap on its own.
Robbie Barrat created the robot after his high school’s programming club argued over A.I.s’ ability to accomplish tasks better than humans. He argued in favor of technology, and the club gave him a week before their next meeting to prove it.
“It’s a neural network that has been trained on rap songs and can use any lyrics you feed it and write a new song,” Barrat explained. “It now writes word by word as opposed to line by line.”
He added that he programmed the robot with Linux, an open-source operating system, and PyBrain, a neural network that uses the programming language Python. The current version uses 6,000 lines from the “Stronger” singer, and while it has its own cadence, it pauses between each word and doesn’t have the emotion behind its voice that Kanye has.
However, the pauses from the robot are designed for rhythm and effect.
“Originally it just rearranged existing rap lyrics, but now it can actually write word-by-word,” the student told Quartz.
Barrat has become the latest programmer to use A.I. to make music and write songs, joining tech giants like Google, which taught a robot to play the piano earlier this year, and Sony, which gave birth to an A.I. that composed two songs last year.
The teenager also talked about how much fun he is having working on the technology when he gets home from school.
“It’s not like I’m being assigned these for school, it’s just that I like to work on projects that incorporate math, computer science, and more artistic elements,” Barrat said. “I got a neural network to write piano melodies. I’ve been trying to get [neural networks] to generate abstract art. I don’t know if you can call teaching a neural network to make rap songs artistic, but I like to think that you can.”