Unfortunately, there is no practical way to decipher between normal REM sleep and sleep paralysis. This is because in normal REM sleep you experience the same paralysis as in sleep paralysis; the only difference is your level of consciousness at the time. So there's no way to develop a sensor that an app could use to address this issue.
This also may be of interest to you: I have a service dog whose primary task is medical alert. He is actually able to "smell" fluctuations in catecholamine (adrenaline and noradrenaline, aka. epinephrine and norepinephrine) levels in my body which occur when I'm having certain cardiovascular problems, and bark to warn me an episode is imminent or to alert people around me that I'm in need of medical assistance. However, when I have episodes of sleep paralysis or cataplexy (similar to sleep paralysis except the onset occurs during the day not when you're in bed, so you suddenly lose muscle tone and collapse), he pays no mind to it at all. From his perspective, I'm just taking a nap.
I hope that helps in understanding this phenomenon better. There are some things that can help with sleep paralysis: avoid sleeping on your back, wake up at the same time every day (within a 30 minute range) even on weekends and regardless of how early or late you got to sleep, don't do anything in your bed besides sleep and sex, don't stay in bed longer that 20 minutes trying to fall asleep (get up and do a quiet activity in dim lighting until you get drowsy, then try again ... but estimate what *feels* like 20 minutes to you, as watching the clock is also a no-no), and finally, talk to your doctor about these symptoms as there are medications that can help some people with this and in some people it can be a symptom of an underlying sleep disorder.
Best, H.
Nice idea. If a smartphone could be rigged with sensors to detect when you're getting stressed in your sleep and trigger an alarm. I'd pay whatever they wanted for something that could snap me out of that %$%$##$@ state.
You may be speaking a language younger people will understand, but I assume you are not talking about a computer application. If you're talking about dealing with the issue when you wake up, that's another matter.
I understand we all enter an paralysis state when we are asleep, but most of us, even me, are blessed with the paralysis going away the same time we wake up.
If it is possible to be awake but unable to move, I think mental concentration on waking up may help.
Good luck, gee I've already typed 10 times what you put in your post, maybe more information from you would also help...but I doubt I can and anything more.