Donald Trump's 1987 bestselling memoir, "The Art of the Deal," helped introduce the future presidential candidate to the public and define him as a crafty, self-made and wildly successful businessman.

But as Trump prepares to formally accept the Republican nomination in Cleveland, the man who actually wrote "The Art of the Deal" – Trump's ghostwriter, Tony Schwartz – says he deeply regrets his role in constructing Trump's public persona.

Speaking out for the first time, Schwartz, who now runs a consulting firm, now says the man he observed at close range for 18 months has little in common with the person described in the book.

"I put lipstick on a pig," he told Jane Mayer in an interview in The New Yorker . "I feel a deep sense of remorse that I contributed to presenting Trump in a way that brought him wider attention and made him more appealing than he is."

Explaining why he chose to break his silence now, Schwartz said he was terrified about what could happen if the real estate mogul is elected in November.

"I genuinely believe that if Trump wins and gets the nuclear codes there is an excellent possibility it will lead to the end of civilization," Schwartz said, adding that if he were writing Trump's autobiography today, he would instead call it "The Sociopath."

In the interview, Schwartz explained how he put a positive spin on Trump's personality.

Writing at the time in private journals, he described Trump as "hateful … a one-dimensional blowhard" and told The New Yorker he disguised Trump's obsessions with money and attention. So, for the book, Schwartz conjured up false images of a warm family man with many friends and ignored contradicting details that exposed his real estate dealings as financially unstable and largely dependent on his father's success.

"All he is is 'stomp, stomp, stomp' – recognition from outside, bigger, more, a whole series of things that go nowhere in particular," Schwartz wrote in his journal on Oct. 21, 1986, an observation he told The New Yorker disproves the speculation that Trump's campaign is a performance that disguises a more thoughtful and nuanced person behind the scenes.

"There isn't," Schwartz said. "There is no private Trump."

In studying Trump, Schwartz said, he struggled to pin him down for conversations that lasted more than a few minutes, and that the real estate tycoon would often get fidgety, impatient and irritable.

"He has no attention span," Schwartz said. "Trump has been written about a thousand ways from Sunday, but this fundamental aspect of who he is doesn't seem to be fully understood … It's impossible to keep him focussed on any topic, other than his own self-aggrandizement, for more than a few minutes, and even then … If he had to be briefed on a crisis in the Situation Room, it's impossible to imagine him paying attention over a long period of time."

Schwartz describes Trump as having "a stunning level of superficial knowledge and plain ignorance" and seriously doubts he "has ever read a book straight through in his entire adult life."

Trump does not dispute this characterization, telling The Washington Post in an interview published Monday that he does not need to read because he makes decisions "with very little knowledge other than the knowledge I had, plus the words 'common sense,' because I have a lot of common sense and a lot of business ability."

Beyond Trump's practiced ignorance, Schwartz said, he discovered what he calls Trump's "second nature" – a habit of lying. In "The Art of the Deal," Schwartz put a positive spin on the many gaps he found between Trump's accounts for his deals and others' versions of events. Schwartz invented the term "truthful hyperbole," a rhetorical tool Trump and his attorneys have frequently fallen back on when challenged in the press or in court.

"More than anyone else I have ever met, Trump has the ability to convince himself that whatever he is saying at any given moment is true, or sort of true, or at least ought to be true," Schwartz said. "He lied strategically. He had a complete lack of conscience about it."

Schwartz opened "The Art of the Deal" with claims that Trump wasn't in the deal-making business to make money.

"I don't do it for the money," Trump declares in the opening passage of the book. "I've got enough, much more than I'll ever need. I do it to do it. Deals are my art form."

But that, Schwartz now says, is a lie.

"Of course he's in it for the money," he said. "One of the most deep and basic needs he has is to prove that 'I'm richer than you.'"

His need for attention and praise, likewise, is "completely compulsive," Schwartz said.

"He's managed to keep increasing the dose for 40 years," Schwartz said. "The only thing left was running for president. If he could run for emperor of the world, he would."

Asked to respond to Schwartz's claims, Trump told The New Yorker that he, not Schwartz, had done the writing for "The Art of the Deal," something that Howard Kaminsky, then the head of publisher Random House, denied. "Trump didn't write a postcard for us!" Kaminsky said.

"I made Tony rich. He owes a lot to me," Trump told The New Yorker, dismissing Schwartz's criticism. "I helped him when he didn't have two cents in his pocket. It's great disloyalty. I guess he thinks it's good for him – but he'll find out it's not good for him."

Trump called Schwartz immediately after speaking to The New Yorker's Mayer, accusing him of cashing in on "The Art of the Deal" and warning he could have sued him.

Schwartz – who turned down Trump's offer to hire him to ghostwrite a sequel and who earned a shared byline, half of the advance and half of the royalties for "The Art of the Deal" – says he doesn't "take it personally" that Trump is upset with him "because the truth is he didn't mean it personally."

"People are dispensable and disposable in Trump's world," he said.

Schwartz, has pledged to donate his earnings from the book this year to charities that work in direct opposition to some of Trump's campaign proposals: the National Immigration Law Center, Human Rights Watch, the Center for the Victims of Torture, the National Immigration Forum, and the Tahirih Justice Center.