She's a non-violent offender, and from what you're telling me it's her first time offense, it wouldn't be hard to keep her out of jail even on an possession with intent to distribute. She doesn't sound like a drug kingpin, she sounds like a small time addict and while it would end up with a mark on her record chances of her getting the help you say she needs are slim.
Jail isn't for drug addicts and crazy people, man. That's what rehab is for. Getting a judge to impose a rehab sentence is next to impossible for a first time offender. You don't want your friend arrested, it amounts to a night or two in jail and a slap on the wrist. The best you could hope for is that she fulfill the terms of her probation (which will likely be attending meetings, getting drug tested etc) and she gets better that way. You already said you didn't want her arrested, the ideal situation for an addict is not to end up in jail.