Hu Jintao, 69, delivered his final speech, declaring a “victorious conclusion” to the 18th Party Congress and calling on delegates to rise as a military band launched into the Internationale.

China’s new leaders, with 59-year-old Mr Xi at their helm, will be unveiled on Thursday in the East Hall of the Great Hall of the People, in only the second orderly transfer of power since the Chairman Mao swept to power in 1949.

After a year of scandals, Mr Hu urged Party members to “strive to be role models”. “We must keep firmly in mind our sacred duties,” he said.

To curb the systemic corruption eating the Communist party from within, one of the Party’s most capable and respected senior officials was on Wednesday elected to its internal discipline commission.

Wang Qishan, 64, has long had a reputation as the Party’s troubleshooter.

Mr Wang adroitly managed a debt crisis in Guangdong in the 1990s and was parachuted into Beijing to respond to an outbreak of the SARS disease in 2003.

After the global financial crisis, Mr Wang was credited with helping to draft the plan that kept the Chinese economy on track.

Some hoped he would be put in charge of reforming the Chinese economy, but his likely role at the top of the Party’s anti-corruption body could be an indication that the fight against graft will be intensified in the years ahead.

As the Congress drew to a close, the state media published photographs from around China showing carefully arranged phalanxes of workers, policemen, soldiers and loyal Party members watching Mr Hu on television and applauding his words.

In the Great Hall of the People, meanwhile, the Party was showing off its “democracy”.

Unanimous votes rang out in favour of new political and disciplinary reports, and to approve a new constitution.

And while the Party has trumpeted its internal election process, it declined to give delegates any choice in who would form its new 205-strong Central Committee: the number of candidates exactly matched the available places.

One important change to the Party’s constitution saw “the need to promote ecological progress” written into the document. The Party has paid particular attention to environmental problems over the Congress.

“There is a consensus on environmental protection from top to bottom,” said Zhou Shengxian, the Environment minister. “We will achieve protection through development and achieve development through protection. This is the new path. We cannot copy the path travelled by developed countries of polluting first and then cleaning up. This will not work in China”.

Outside, delegates dodged difficult questions and trilled their delight at how the Congress had played out.

“I have strong faith that we will turn China into the happiest, most peaceful, harmonious and best possible nation,” gushed Yang Jian, a public security official from Xinjiang.

“The Congress was outstandingly good!” said Dolma Tso, a Tibetan delegate from Qinghai.

While China’s new leaders will be confirmed on Thursday they will not formally assume their government roles until next March, when China’s parliament, the National People’s Congress, rubber-stamps their promotions.