Scotland's biggest book festival has set its stall against negative political campaigning with a theme of "Project No Fear".

Nick Barley, director of the festival, said the phrase had been inspired by negative campaigning in both the Scottish independence referendum and the current European referendum.

Mr Barley said that 'Project No Fear' did not mark the festival taking sides on either of the referendums, but "I am taking sides against negative discourse, and in favour of imaginative thinking."

"On both sides of both referendums there has been negative campaigning," he said.

This year's festival features much theatre and music as well as leading writers, and will feature a series of sessions with the new national poet Jackie Kay, including an interview with the First Minister Nicola Sturgeon, and the UK poet laureate, Carol Ann Duffy, also her former partner.

Mr Barley, leading his 7th programme, said he hoped the festival would lead to a "better world" and said: "I sense the festival has a mission to make the world a better place, through literature, and this year the phrase I have is 'Project No Fear'.

"What I sense is that people are sick to death of the negative, reductive political discourse which we are witnessing at the moment, not only around the referendums, but around our general elections.

"I think that is the opposite of what the public want, I think want to hear about the kind of ambitious ideas that make the human race progress, better in the world - that is why 'imagine better' is the phrase we use through this programme, it is not an empty phrase."

He added: "We are a festival of free speech, and authors can say what they say, but we are creating a framework of discourse where we are encouraging positive, imaginative thinking.

"Should it be that a politician comes along and engages in negative discourse, then I expect the audience to have a response to that."

Appearances by leading writers include American novelist Jonathan Safran Foer, Man Booker prize winner Han Kang, historical fiction writer Philippa Gregory, and Eimear McBride launching the follow-up to her award-winning A Girl is a Half Formed Thing.

The Scottish actor Alan Cumming, comedian Stewart Lee and survival expert Ray Mears will also attend, as will former Prime Minister Gordon Brown.

Mark Thompson, the former director general of the BBC, will launch an argument on "why the internet and 24 hour news has failed to lead to better democracy" at the festival which runs from 13-29 August.

Ms Kay will be interviewed by Nicola Sturgeon, First Minister of Scotland.

As one of the festival's Guest Selector series, Ms Kay will look at the importance of poetry in everyday life.

Other authors making their first appearance include Thomas Keneally from Australia, one of China’s leading novelists Can Xue, Mexican writer Álvaro Enrigue and Jean-Christophe Rufin, co-founder of Médecins sans Frontières.

David Millar, Chris Boardman and Mark Beaumont will talk about their lives in cycling and former goalkeeper Packie Bonner recalls his 30 year career with Celtic and Ireland.

Musicians Wilko Johnson, Tim Burgess of The Charlatans and Brix Smith-Start speak of their lives in music, and James Robertson is joined by folk musicians to perform Pilgrimer, his Scots reimagining of Joni Mitchell’s 1976 album Hejira.

A centrepiece of the Migrant Stories within the Book Festival this August will be the world premiere of a specially commissioned theatrical adaptation of Nobel Prize winner Alice Munro’s short stories.

Adapted for the stage by multi award-winning playwright Linda McLean and Stella Quines, View from Castle Rock imagines the "extraordinary experiences of Munro’s Scottish ancestors who sailed from Leith Docks in 1818 in the hope of a better life in Canada."

David Greig’s play Europe, from 1994, will also be performed.

Billy Bragg will present his best known songs, and other live performances at this year’s festival include Wi the Haill Voice, Edwin Morgan’s translations of Vladimir Mayakovsky’s poetry developed by actor Tam Dean Burn and Love Song to Lavender Menace, the dramatic retelling by playwright James Ley of the story of Edinburgh’s radical LGBT bookshops.