Lin Yu'er, a patient at Red Star Mental Hospital diagnosed with severe delusions and hallucinations, mysteriously vanishes one night. Her attending physician, Zhang Momo, who holds the position of hospital director, initially assumes the patient has simply escaped. However, Zhang Momo soon finds herself transported into the body of a maid assigned to the Marquis of Zhaoping's household, specifically to care for the Marquis's wife, Lin Yu'er. Upon arrival, Zhang Momo discovers that the Lin Yu'er of this ancient world is not merely eccentric but suffers from profound mental instability, believing herself to be the heir to the Demon Realm. The new Zhang Momo must navigate this dangerous environment by playing along with the madwoman's delusions to prevent her from causing further chaos or drawing the wrath of the Marquis.
The core conflict arises from the tension between Lin Yu'er's fractured reality and the political intrigue of the Marquis's household. Lin Yu'er, convinced she is a Demon Princess in exile, views her attendants as magic weapons and her husband, He Jiulin, as a powerful figure from whom she must steal energy to repair a teleportation array. Zhang Momo, utilizing her medical expertise and psychological insight, manages the situation by reinforcing these delusions strategically. She introduces a companion maid named Du Du and helps Lin Yu'er construct a coherent narrative that allows the household to function without scandal. The arrival of concubines, particularly the arrogant Yue Yiniang, triggers violent outbursts from Lin Yu'er, who responds with unexpected physical prowess, knocking opponents unconscious with silver chopsticks. These incidents draw the attention of He Jiulin, a man of high status who is himself afflicted by a recurring, mysterious poison.
A significant turning point occurs when He Jiulin's subordinate, Chang Sui, begs Lin Yu'er for an antidote to the Marquis's illness. Lin Yu'er, driven by her hoarding tendencies and Freudian syndrome, discovers a hidden box of pills under her bed, only to eat them herself, believing them to be her own treasure. Despite this, He Jiulin's condition mysteriously stabilizes after Lin Yu'er attempts to treat him with her fabricated demonic powers, leading him to suspect she possesses genuine supernatural abilities. He Jiulin, who has been secretly guarding Lin Yu'er due to political threats from rival factions, becomes increasingly intrigued by her unpredictable nature. He begins to protect her from the other concubines, punishing those who offend her and ordering that all visitors bring gifts.
As the story progresses, Lin Yu'er's auditory hallucinations prove to be more than mere symptoms. She hears the cries of a murdered woman from a nearby well, providing details that lead to the discovery of a corpse and the arrest of a suspect. This event elevates her status from a mere madwoman to a figure of eerie significance, feared and respected by the household staff. Meanwhile, He Jiulin continues to observe her from a distance, sending spies and analyzing her behavior. He recognizes that her madness is intertwined with a sharp, cunning intelligence that rivals his own. The narrative sets the stage for a complex relationship between the physician and her patient, now reversed in roles, as they navigate a world where mental illness may be the key to solving ancient mysteries and surviving political assassinations.