LISBON (Thomson Reuters Foundation) - Technology can hopefully reverse some of the harm caused to the planet by industrialization and help end disease and poverty, but artificial intelligence (AI) needs to be controlled, physicist Stephen Hawking said on Monday.

Hawking, a British cosmologist who was diagnosed with motor neuron disease aged 21, said technology could transform every aspect of life but cautioned that artificial intelligence poses new challenges.

He said artificial intelligence and robots are already threatening millions of jobs - but this new revolution could be used to help society and for the good of the world such as alleviating poverty and disease.

“The rise of AI could be the worst or the best thing that has happened for humanity,” Hawking said via telepresence at opening night of the 2017 Web Summit in Lisbon that is attended by about 60,000 people.

“We simply need to be aware of the dangers, identify them, employ the best possible practice and management and prepare for its consequences well in advance.”

Hawking’ s comments come during an escalating debate about the pro and cons of artificial intelligence, a term used to describe machines with a computer code that learns as it goes.

Silicon Valley entrepreneur Elon Musk, who is chief executive of electric car maker Tesla Inc and rocket company SpaceX, has warned that AI is a threat to humankind’s existence.

But Microsoft co-founder Bill Gates, in a rare interview recently, told the WSJ Magazine that there was nothing to panic about.

Hawking said everyone has a role to play in making sure that this generation and the next are fully engaged with the study of science at an early level to create “a better world for the whole human race”.

“We need to take learning beyond a theoretical discussion of how AI should be, and take action to make sure we plan for how it can be,” said Hawking, who communicates via a cheek muscle linked to a sensor and computerized voice system.

“You all have the potential to push the boundaries of what is accepted, or expected, and to think big. We stand on the threshold of a brave new world. It is an exciting - if precarious - place to be and you are the pioneers,” he said.