Media playback is unsupported on your device Media caption Nafissatou Diallo appeared outside court with her lawyer after the hearing

Former International Monetary Fund chief Dominique Strauss-Kahn has signed a settlement with a hotel maid who accused him of sexual assault, a New York judge says.

Details of the 63-year-old's agreement with Nafissatou Diallo will remain confidential, the judge added.

Mr Strauss-Kahn was held in New York in May 2011 after Ms Diallo, 33, said he assaulted her in his hotel suite.

Prosecutors later dropped charges amid concerns about her credibility.

The incident was widely seen as having ruined Mr Strauss-Kahn's chance of becoming the Socialist presidential candidate in his native France.

New York State Supreme Court Justice Douglas McKeon announced on Monday that after lengthy negotiations, the parties "came together and put terms of a settlement on the record".

At the scene Now that there has been a settlement, we will probably never know exactly what transpired between the head of the IMF and the immigrant hotel maid from Guinea at the hotel Sofitel in Manhattan. There was forensic evidence of a sexual encounter of some kind. Mr Strauss-Kahn insisted it was consensual, Ms Diallo said he attempted to rape her. The criminal case collapsed after the prosecution said Ms Diallo had credibility issues. Now her attempt to bring a civil case has been settled for an undisclosed amount. Two very different lives have been turned upside down by the encounter, and Mr Strauss-Kahn's ambitions to be president of France lie in ruins.

The amount of the settlement was kept confidential.

Mr Strauss-Khan did not attend the hearing, but Ms Diallo was in court.

After the settlement, the judge thanked all parties and said it was a "privilege to work with all of you".

Outside the courtroom, Ms Diallo made a short statement: "I thank everybody all over the world and everybody at the court, and God bless you all."

Her lawyer, Kenneth Thompson, said afterwards that she was "ready to move on".

In May 2011, Ms Diallo, a Guinean immigrant with a teenage daughter, said Mr Strauss-Kahn had forced her to perform oral sex when she went to clean his hotel room.

He was arrested, charged with attempted rape and forced to resign from his post at the International Monetary Fund.

Mr Strauss-Kahn had previously admitted to a "moral failing", but insisted their sexual encounter was consensual.

In the wake of Ms Diallo's accusations, other women came forward with sexual assault allegations against him.