EXCLUSIVE

Demi Lovato was found unconscious in her bed after a long night of partying, and a panicked assistant called 911 ... TMZ has learned.

Sources familiar with the matter tell us ... Demi had invited some of her friends back to her house early Tuesday morning after a party on the Sunset Strip to celebrate the birthday of one of her backup dancers.

It's unclear how long the party lasted, but Demi went to sleep and, at around 11 AM Tuesday one of her assistants became concerned because Demi hadn't come out of her bedroom. The assistant entered the room and found Demi unresponsive, tried waking her and when she couldn't ... she called 911.

When paramedics arrived Demi was still unconscious. Someone at the home told paramedics Demi had been partying all night, and we're told EMTs then determined they were dealing with an overdose. They quickly administered Narcan -- an antidote to opioid ODs.