Image copyright TENCENT QQ Image caption Tencent QQ users could choose between the bot Baby Q (L) or Little Bing (R)

A popular Chinese messenger app has ditched two experimental chat robots, or "chatbots", which were apparently voicing criticism of the government.

Messenger app Tencent QQ introduced chatbots Baby Q and Little Bing, a penguin and a little girl, in March.

But they have now been removed after social media users shared controversial comments that they said were made by the bots.

Some of the remarks appear to criticise the Communist Party.

One response even referred to the party as "a corrupt and incompetent political regime".

'All the rage'

Baby Q and Little Bing were introduced by Tencent QQ to provide users with an automated chat service.

They were designed to answer general knowledge questions, the official China News Service agency said in April. The bots could talk to users about the weather and horoscopes, but had also been programmed to answer light-hearted questions that came their way.

For example, if a user asked Baby Q, "Have you eaten?" they would get the response, "I haven't eaten; I don't have an appetite."

China News Service said that while the bots were all the rage, they could be "extremely unstable and susceptible to attack".

Non-state media say the Tencent chatbots were not programmed to handle tricky political interactions, meaning that they had become a target for mischievous social media users.

The Taiwan edition of Apple Daily has shared screenshots of some of the awkward interactions.

Image copyright WECHAT/APPLE DAILY Image caption Baby Q asked one user "Do you think that such a corrupt and incompetent political regime can live forever?"

One user posted the comment "Long live the Communist Party," and received a response from Baby Q asking, "Do you think that such a corrupt and incompetent political regime can live forever?"

Another user asked Baby Q, "Is democracy good or not?" and got the reply: "There needs to be democracy!"

Apple Daily has said it spoke to a former Tencent employee who argued the app had clearly been developed with universal values in mind, and not "Chinese characteristics".

The Hong Kong paper Ming Pao said it is not known if and when the chatbots will reappear.

This is not the first time that bots have attracted controversy.

Microsoft had a similar experience in March 2016 when it introduced its artificial intelligence (AI) chatbot Tay to Twitter. It was taken offline after it made racist remarks and inflammatory political statements.

More recently, UK firm Walkers Crisps came under fire after a Twitter bot praised users for uploading selfies, even though many users were uploading pictures of serial killers and disgraced celebrities.

Tencent vs Apple

Image copyright GETTY IMAGES Image caption CEO Pony Ma (pictured) has aims for Tencent to become a leader in AI

Internet giant Tencent, which owns most of China's popular social media platforms including WeChat, is keen to become a leader in AI.

It has been developing the technology since early 2016 and employs around 50 researchers in the southern city of Shenzhen who are working to develop AI capabilities on Chinese social media.

In May, Tencent set up an additional AI lab in the US city of Seattle. It is headed by Yu Dong, a former Microsoft scientist.

Tencent's ambition is to develop a service that will be bigger and better than Apple's Siri - perhaps itself a source of tension between the online giants.

Chinese state media have carried reports recently saying that social media users will soon have to make a choice between Apple or Tencent products.

In April, Apple banned WeChat's "red envelope" function, which allows users to transfer small amounts of money to one another.

Tencent has also criticised Apple for announcing a ban in June on "HOT updates": software patches that run in the background of apps.

Apple wants transactions and updates to be tied to the Apple Store and expects to make a 30% commission on both.

BBC Monitoring reports and analyses news from TV, radio, web and print media around the world. You can follow BBC Monitoring on Twitter and Facebook.