See if it is pain related first, then have a trainer evaluate yourself on the horse and see if something about your equitation is confusing the horse.
Check to see if the problem is being cased by anything (ill-fitting tack, physical issues), that could be causing pain.
Try and ride through it, if you don't think that is not just behavioural, try things such as a different bit, refiting the saddle, if nothing improves try to see if it is medical and ask you bet for advice on going forward
Try riding them through it and do some in hand and try getting them over there badness in hand then slowly get on :)
Lungs first, don't put yourself at risk!
I usually ride mine anyway and try to get them to calm down but if worst comes to worst I would lunge him/her