Spouses want somebody who wants them...they don't want somebody who needs them. I told my wife, after telling me that she was thinking about divorce, "A divorce is not what I want for us. Not now, not ever. Never have. Now, more than ever, I am irrevocably committed to you and our marriage."
I also validated her feelings by saying "Incidentally, I can understand why you would not care about me anymore and be thinking about divorce after living with the 'old me' all those years."
Continue to pray, study, learn, and work on yourself. Don't beg. It's not attractive at all. It's a mistake to do it.
"Always go straight forward, and if you meet the devil, cut him in two and go between the pieces." - William Sturgis, clipper ship captain, 1830's.