Sheffield Crown Court heard how Darren Heads, 46, became friends with the complainant, who also has learning difficulties, around October last year when the pair met through a mutual friend.
Following a night out together in Doncaster town centre on December 3, Heads, aware of the fact the woman was homeless, invited her to come and stay with him at his home in New Swaithe Close, Bentley.
Neil Coxon, prosecuting, told the court that Heads invited the woman to stay with him on a platonic basis and allowed her to sleep in his bed, while he used the sofa.
After almost a week of living together peacefully, things changed on the morning of December 9 when the complainant was attacked as she was sat on the sofa, using Heads' laptop to speak to friends over the internet.
Mr Coxon said: "She said that all of a sudden she felt a really hard blow to the head. She realised it was the defendant, who was stood there with a rolling pin in his hand. She says he must have hit her with it.
"She got straight up and ran towards the bedroom and got her clothes. The defendant followed her."
Mr Coxon added: "He hit her to the front of the head. She said he hit her several times, describing the pain as horrendous."
The woman eventually managed to escape the flat and set about finding someone to help her contact the emergency services. As she enlisted the help of a woman on the street, Heads was in the process of calling the police from inside his flat - claiming the complainant had attacked him.
However when police arrived on the scene and found the complainant bleeding profusely, and saw spots of blood on the rolling pin in Heads' flat he was arrested and taken for questioning.
He later pleaded guilty to an offence of wounding.
The complainant was taken to Doncaster Royal Infirmary where she was treated for three deep cuts to her face and one to the back of her head. She was given 22 stitches for the four wounds.
In a victim personal statement, read out in court, the complainant said: "This incident has left me feeling scared of Darren. I don't want to go anywhere near him again.
"I thought he was my friend."
She added: "I'm now going to have scars on my face that are going to be with me for the rest of my life. I'm not sure how they are going to look. I don't understand why he would do this to me."
Defending, Tamara Pawson, told the court that Heads could not remember much of what had happened.
She added: "This was an uncharacteristic outburst of violence, those are words from the psychiatrist."
Ms Pawson described the detrimental effect mental health professionals and the author of the pre-sentence report suggested a prison sentence could have on Heads, due to his learning difficulties rendering him far more vulnerable than most inmates.
Judge Michael Slater sentenced Heads to two years in prison, suspended for two years.
He told Heads that a pyschiatric report from Dr Mendelson, the pre-sentence report as well as numerous character references from mental health professionals who stated that Heads did not have a history of violence had informed his decision.
He said: "It would be extremely damaging for your health and wellbeing, given your vulnerabilities, if you were sent to prison.
"I'd go further than that, in my view, it would destroy you.
"I'm told you are extremely remorseful for what you have done to the complainant."
Judge Slater also ordered Heads to complete a 20-day rehabilitation activity requirement and granted a restraining order which bans him from contacting the complainant.