The rise of robots has long been a topic for sci-fi best sellers and video games and, as of this week, a threat officially taken seriously by central bankers.
The bankers are not yet ready to buy into dystopian visions in which robots render humans superfluous. But, at an exclusive gathering at a golf resort near Lisbon, the big minds of monetary policy were seriously discussing the risk that artificial intelligence could eliminate jobs on a scale that would dwarf previous waves of technological change.
"There is no question we are in an era of people asking, 'Is the Robocalypse upon us?'" David Autor, a professor of economics at the Massachusetts Institute of Technology, told an audience on Tuesday that included Mario Draghi, the president of the European Central Bank, James Bullard, president of the Federal Reserve Bank of St. Louis, and dozens of other top central bankers and economists.
The discussion occurred as economists were more optimistic than they had been for a decade about growth. Mr. Draghi used the occasion to signal that the European Central Bank is edging closer to the day when it will begin paring measures intended to keep interest rates very low and bolster the economy.
"All the signs now point to a strengthening and broadening recovery in the euro area," Mr. Draghi said. His comments pushed the euro to almost its highest level in a year, though it later gave up some of the gains.
But along with the optimism is a fear that the economic expansion might bypass large swaths of the population, in part because a growing number of jobs could be replaced by computers capable of learning — artificial intelligence.
Policy makers and economists conceded that they have not paid enough attention to how much technology has hurt the earning power of some segments of society, or planned to address the concerns of those who have lost out. That has, in part, nourished the political populism that contributed to Britain's vote a year ago to leave the European Union, and the election of President Trump.
"Generally speaking, economic growth is a good thing," Ben S. Bernanke, former chairman of the Federal Reserve, said at the forum. "But, as recent political developments have brought home, growth is not always enough."
In the past, technical advances caused temporary disruptions but ultimately improved living standards, creating new categories of employment along the way. Farm machinery displaced farmworkers but eventually they found better paying jobs, and today their great-grandchildren may design video games.
But artificial intelligence threatens broad categories of jobs previously seen as safe from automation, such as legal assistants, corporate auditors and investment managers. Large groups of people could become obsolete, suffering the same fate as plow horses after the invention of the tractor.
"More and more, we are seeing economists saying, 'This time could be different,'" said Mr. Autor, who presented a paper on the subject that he wrote with Anna Salomons, an associate professor at the Utrecht University School of Economics in the Netherlands.
Central bankers have begun examining the effect of technology on employment because it might help solve several economic quandaries.
Why is workers' share of total earnings declining, even though unemployment is at record lows and corporate profits at record highs? Why is productivity — the amount that a given worker produces — stuck in neutral?
"The mere fact that we are organizing this conference here in Sintra testifies to our interest in that discussion," Benoît Cœuré, a member of the European Central Bank's executive board, said in an interview, referring to the "Robocalypse" debate.
Of particular interest to the European Central Bank is why faster economic growth has not caused wages and prices to rise. The central bank has pulled out all the stops to stimulate the eurozone economy, cutting interest rates to zero and even below, while printing money. Four years of growth have led to the creation of 6.4 million jobs. Yet inflation remains well below the bank's official target of below, but close to, 2 percent.
One explanation is that more work is being done by advanced computers, with the rewards flowing to the narrow elite that owns them.
Still, among the economists in Sintra there was plenty of skepticism about whether the Robocalypse is nigh.
Since the beginning of the industrial age, almost every major technological innovation has led to dire predictions that humans were being permanently replaced by machines.
While some kinds of jobs were lost forever, greater efficiency led to more affordable goods and other industries soaked up the excess workers. Few people alive today would want to return to the late 1800s, when 40 percent of Americans worked on farms.
Robocalypse advocates underestimate the power of scientific advances to beget more scientific advances, said Joel Mokyr, a professor at Northwestern University who studies the history of economics.
"Think about what computers are doing to our ability to discover science," Professor Mokyr said during a panel discussion, citing computers that can solve equations that have baffled mathematicians for decades. There may be breakthroughs that "we can't even begin to imagine."
There are other explanations for stagnant wages besides technology.
Companies in Japan, the United States and Europe are sitting on hoards of cash, doling out the money to shareholders rather than investing in new buildings, equipment or innovative products. Just why is another topic of debate.
Hal Varian, the chief economist at Google — whose self-driving technology may someday make taxi drivers unnecessary — said that the plunging cost of information technology "has virtually eliminated the fixed cost of entering a business." Companies can rent software and computing power over the internet.
And flat wages reflect the large number of women who have entered the work force in recent decades as well as the post World War II baby boom, Mr. Varian said, adding that those trends have run their course. "We are going to see a higher share going to labor," he said.
Yet already, disruptions caused by technology help account for rampant pessimism among working-class and middle-class people across the developed world.
Mr. Bernanke referred to polls showing that about twice as many Americans say the United States is on the wrong track than say the country is moving in the right direction.
As a result, "last November Americans elected as president a candidate with a dystopian view of the economy," Mr. Bernanke said.
Mr. Autor, co-author of the Robocalypse paper, concluded that it was too early to say that robots are coming for people's jobs. But it could still happen in the future.
"I say not Robocalypse now," Mr. Autor said, "perhaps Robocalypse later."