ORONO, Maine — In the front row, an energetic redhead named Sean raises his hand and bounces in his seat, pleading for the chance to speak about something unrelated to the lesson — again.

In the back row, an uninterested girl named Cindy texts on her cell phone, and doesn’t try very hard to hide it.

It’s one of many challenges faced by every educator: Recognizing the personality and engagement level of each student and trying to keep them focused on learning. In the past, the only way to learn that skill was to get in the classroom as an intern or teaching assistant, experiencing trial and error in front of real kids.

The University of Maine is among about 65 colleges and universities in the country trying something a little different in 2015 — putting its budding teachers in front of virtual students, or avatars, simulating classroom situations.

The program is called TeachLivE, which began development a decade ago at the University of Central Florida in a partnership between the university’s education and technology schools. Last year, a company called Mursion purchased the rights to commercialize the technology.

“A lot of teachers sink or swim when they step out there,” said Brentt Brown, Mursion’s communications director. Studies have given widely varied accounts of how many teachers make it through their first five years as educators. Some have said the national attrition rate is around 40 or 50 percent, while more recent estimates have put the number around 17 percent.

The company says putting education students in classroom situations before they step into an actual classroom can have big advantages and help them determine whether they want to continue on the path toward becoming an educator.

More than 50 University of Maine education professors watched a live demonstration of TeachLivE during a recent meeting. A TeachLivE lab for students, with an 80-inch screen and new computer, is being set up in Room 207 of Shibles Hall and is expected to open next month.

The demonstration showed five virtual students sitting in a virtual classroom. Susan Gardner, interim dean of the UMaine College of Education, called on volunteers to introduce themselves to the class as if it was the first day of school.

Ian Mette, assistant professor of education leadership, noticed the girl in the back on her phone.

“I see some of you are having a tough time focusing, like you in the back with the phone,” he said.

Another professor, when her turn came to lead the class, took a slightly different approach, pulling out her own cell phone and pretending to respond to a message to show how rude it was.

The virtual students respond through a technician, who used a different voice to represent each of the avatars. Technicians also are responsible for controlling the students’ actions and movements, from Cindy’s texting to Sean’s hand raising.

Mursion can program the computer-generated images of students to do anything from dozing off to throwing a spitball, according to Brown. More actions can be programmed at a school’s request.

There are other simulations available as well. For example, a principal can sit down with an avatar simulating a parent upset with the school’s decision to suspend their child for getting in a fight.

Mursion also has simulators for other fields, especially in the hospitality industry, where people training to work at a hotel or restaurant can learn how to deal with an unruly customer without angering an actual person.

“It feels very real,” Gardner said, adding she sees a lot of potential for helping future teachers learn and practice techniques. The school has signed a first-year contract with Mursion valued at about $5,000 to launch the program at UMaine.

“Teaching is one of those professions that, often, people underestimate how challenging it can be,” Gardner said. “Just knowing the content is not enough to be a good teacher.”

Follow Nick McCrea on Twitter at @nmccrea213.