My advise is not to simply write a solo and then play it back after you write the whole thing. Instead, actually play the horn as if you were soloing. But instead of trying to solo over the whole form, just try to find a nice phrase that works over the first few chords. Do this rubato, out of tempo. It gives your brain a chance to think. Just repeat until you find something you like, when you've got it, put pencil to paper. Then move on to the next phrase and the next, building on what you've already written until you have a complete solo. If you get stuck, look to transcriptions to see what others have done.