Barack Obama yesterday tore into woke culture and notions of purity in an apparent warning to liberal factions amid a tense Democrat race to challenge Trump in 2020.

Barack was joined by his wife Michelle on Tuesday at their annual Obama Foundation summit in Chicago, where the former first lady also told attendees: 'I can't make people not afraid of black people.'

Barack, speaking separately, said: 'This idea of purity and you're never compromised and you're always politically woke and all that stuff, you should get over that quickly.

'The world is messy. There are ambiguities. People who do really good stuff have flaws ...

Barack Obama said: 'This idea of purity and you're never compromised and you're always politically woke and all that stuff, you should get over that quickly'

Michelle Obama was joined on stage by her brother and spoke about her childhood and compared her experiences to what immigrants today face

'Like if I tweet or hashtag about how you didn't do something right or used the wrong verb or then, I can sit back and feel good about myself: "Man, you see how woke I was? I called you out."

'You know that's not activism, that's not bringing about change.'

Responding to the comments, Jen Paski, a former Obama aide, told CNN's Don Lemon she believed the comments were pointed at those challenging President Donald Trump in 2020.

'At times the reaction to Donald Trump has been to put out the purity tests that say if you don't meet these bars and are not with me on every issue and don't check every box, you can't be a part of the party.' Paski said.

'If we are launching purity tests and say "You can't be a part of us," we'll have such a small party, we won't be able to win.'

Those comments echo the sentiments of White House hopeful Andrew Yang, who tweeted in June, 'I understand the impulse, but identity politics are a great way to lose elections. We need to bring people together.'

Michelle Obama spoke separately alongside her brother, Craig Robinson, about their childhood and Michelle compared her experiences to those which immigrants face today.

She said she wanted to remind white people that they were running from 'us', and that they're still running.

Michelle added that 'artificial things', like the color of a person's skin and the texture of their hair, can divide countries.

'I can't make people not afraid of black people. I don't know what's going on, I can't explain what's happening in your head - but maybe if I show up every day as a human, a good human, maybe that work will pick away at the scabs of your discrimination.'

Michelle and Barack Obama were both speaking at the Illinois Institute of Technology where their three-day summit will feature talks by activists, including Ava DuVernay and singer Mavis Staples.

The summit is being held in the city as the couple outline their vision for the Obama Presidential Center.

Former President Barack Obama and first lady Michelle Obama appear on stage together after the Obama Foundation Summit at the Illinois Institute of Technology in Chicago on Tuesday

Michelle Obama (right) sits on her mother Marian Robinson's lap, while her dad Fraser holds her brother Craig. The family moved to the South Side of Chicago in the 1970s

The Obamas in front of the White House during President Barack Obama's second term in office. Michelle Obama said: 'Being the first black First Family gave America and the world the opportunity to see the truth of who we are as black people'

The center is planned along the lakefront of Chicago's South Side. It's near where Obama started his political career and lived with his family.

The $500 million center is expected to house a public library branch, house multimedia collections and have community programs, among other things.

President Obama, 58, who opened the summit at a dinner on Monday, said the South Side was the right place for the couple's post-White House foundation, and eventual presidential library.

'It was natural for Michelle and I to say, "Well, we should do it in this place," where I became a man and where Michelle grew up, and where our children were born,' he said.