Hypnagogia is the transition between wakefulness and sleep. During this state, it's common to experience visual, audio, or other types of hallucinations. It's also common to experience muscle jerks and sleep paralysis. Some people purposefully try to induce to hypnagogia to stimulate creativity.
i do this thingy at night its so great!