When Francois Hollande decided to run in this year's presidential race he made two promises. The first was to lose weight. The second was to give up cracking jokes.
He figured he wasn't going to rally the left with the silhouette of a provincial bank manager.
Nor was he going to look like the man to steer them through the storms of the European debt crisis if he didn't seem to be serious.
The first promise he kept. He lost 15kg (2st 5lb) and had to buy a new set of clothes.
The second, he didn't.
After several months of keeping the lid on it "Mister Little Jokes", as Nicolas Sarkozy sneeringly calls him, is at it again.
The Hollande campaign has decided that their candidate's sense of humour, though a tricky, unpredictable weapon to handle, could be what is needed to destabilise his main rival in the upcoming and possibly decisive face-to-face TV debates.
This is a story that political commentator Helene Jouan tells in a book she has just published called The Little Illustrated Hollande, which gathers a political lifetime of Hollande "bons mots" and seeks to explain the Socialist candidate's sense of humour.
Humour, says Ms Jouan, is an essential part of his political persona and, significantly, was what got him noticed when he was starting out in his political career.
It was 1981. Francois Hollande was 26. And he was sent to oppose Jacques Chirac in parliamentary elections in the seasoned politician's rural constituency in Correze. Mr Chirac was the leader of his party. He had already been prime minister and had made a bid for the presidency. Mr Hollande was a nobody.
When Mr Chirac saw Mr Hollande arriving at the station all alone with his suitcase, he said: "they send me an opponent no more well known than President Mitterrand's labrador."
A few days later, Mr Hollande invited himself to one of Mr Chirac's meetings, raised his hand to ask a question and said "I am Francois Hollande; I am a candidate; the one you compared to Francois Mitterrand's labrador".
"That got him talked about," says Ms Jouan. "As a politician he had come into existence."
His career as a wit and raconteur was just beginning too. His humour has made him a remarkable public figure and his public speaking is as much after-dinner speech as political address.
Mr Chirac, his old adversary, was for many years the butt of his jokes and the twice-president's supposed laziness a favourite theme.
"When it comes to the reduction of hours in the working week," Mr Hollande quipped, "we Socialists never dreamed of anything quite so radical".
But Mr Hollande is at his best with his elaborate and lengthy sketches, usually well-rehearsed in front of a friendly home audience in Correze.
One memorable sketch mocked a Sarkozy scheme to make housing, as well as nursery and nursing home places, a legal right. Mr Hollande took the imaginary example of a homeless person in the well-to-do Paris suburb of Neuilly, which has become a Sarkozy family fiefdom.
All that homeless person had to do, he explained, was get in touch with his lawyer, who would then form a commission which could then initiate court proceedings. After five years, the homeless person would obtain a council flat… in Gennevilliers - a far less glamorous suburb.
His audience thought it was all over, but he was just getting started.
Next, he continued, because you have a child, you try to get a place in a nursery which, after further lengthy legal action, you finally obtain when your child has already moved on to school.
Finally, you try to find a place in a nursing home. There are no places available. No problem! All you have to do is get in touch with your lawyer (the same one you used when you were looking for a nursery place), who will form a commission which will launch legal proceedings. "And after five years, if you believe in that sort of thing, you'll get a place… in heaven!"
If satirists bothered with the nitty-gritty of politics, this is the sort of thing they'd come up with. And even some professional comedians are impressed. Such as Gaspard Proust, a 35-year-old stand-up comedian and film actor.
"He's very good," says Mr Proust. "I even kept an article of his in my notes because it was so funny. And he's the only politician who writes his own lines."
Mr Proust also likes the fact that Mr Hollande is an unlikely comedian. "You look at me and you say 'this guy will never make me laugh'. It's the same with Francois Hollande. But that's a good thing, because people are more easily surprised."
The battle of personalities between Mr Hollande and Mr Sarkozy has become as fascinating as the battle of ideas.
The political editor of France Info radio, Marie-Eve Malouines, has published biographies of both men. Her latest is called Francois Hollande: the strength of Mister Nice.
She sees Mr Hollande's joviality as an aspect of a kindness she links with his Catholic school upbringing and the conciliatory nature of his social democratic brand of politics.
"Ever since he was a little boy he's used his humour to avoid conflict, to be the good guy, to be friends with everyone, and to avoid questions," she says.
So how will this play with the French electorate?
"That is the big question," says Ms Malouines. "In France we like our presidents tough. Francois Hollande thinks that now, because of the economic crisis, the French might want a different sort of leader. He thinks people want to pull together around a president who is kind." But on that point, she says, he may be quite wrong.
The French will vote in the first round on 22 April, with the two highest scorers going through to the second and final round on 6 May.