Hi there- Ambien comes with its own problems and with a child in the house, I wouldn't take it. Google "side effects of ambien" and you'll read all about it.
Did you taper off the Xanax? It's dangerous to stop cold turkey but at 18 days, you may be out of the woods. The best thing to do is to get with your doctor who may have some thoughts about this. If you want to try a safe, all natural sleep aid, I've had good luck with Alteril. It's OTC and its in most stores like Walmart, Walgreens. Good luck!
Personally, I do not recommend ambien. It seems like your mind is sensitive already, and ambien may make your nights even worse. I never hallucinationed, but I did sleep walk, did things I don't remember and it created much more anxiety for me the next day. Does your doctor know about what you are seeing at night?
Benzodiazepine withdrawal could be very dangerous and has high risks of seizures. Ambien has numerous side effects as well including hallucinations. You should consult with a doctor before managing any prescription intake of withdrawal .