Lucid dreaming alarm cues will play once the app detects you are dreaming (in REM phase).
Even we cannot use an EEG (Electroencephalogram), we still get a very good picture of your REM phases from your activity with a high match rate. You can read about how we do it in https://sleep.urbandroid.org/how-do-we-measure-your-dreams/
This is a companion discussion topic for the original entry at https://sleep.urbandroid.org/docs/sleep/lucid_dreaming.html