The Lady of the Lake began appearing by this title in the French chivalric romances by the early 13th century as the fairy godmother-type foster mother of the hero Lancelot.
In the Lancelot-Grail (Vulgate) prose cycle, the Lady resides in an enchanted realm, an otherworld the entry to which is disguised as an illusion of a lake (the Post-Vulgate notes it as Merlin's work).
There, she raises Lancelot from his infancy following the death of his father King Ban, teaching Lancelot arts and writing, infusing him with wisdom and courage, and overseeing his training to become an unsurprassed warrior.
She also rears his orphaned cousins Lionel and Bors after having her damsel Seraide (Saraïde, later called Celise) rescue them from King Claudas.
All this takes her only a few years in the human world.
Afterwards, she sends off the young Lancelot to King Arthur's court as the nameless White Knight (a part of her affinity with the color white), but then keeps aiding him in various ways during his early adventures with her magic-item gifts (similar in that to his unnamed fairy protectoress in Chrétien's version, who too gives him a magic ring) and through her maidens serving as her agents and messengers.
She furthermore personally arrives to restore Lancelot to sanity during some of his recurring fits of madness.

The Vulgate Cycle tells of either a different or the same (that was made explicitly clear only in the later revisions) Lady of the Lake in the Prose Merlin-derived section, which takes place before its main Vulgate Lancelot section but was written later, and links her with the disappearance of Merlin.
Here, she is given the name Viviane (or similar) and a human origin.
In the Vulgate Merlin, she refuses to give Merlin (who at this time is already old but appears to her in the guise of a handsome young man) her love until he has taught her all his secrets, after which she uses her power to seal him forever, originally either in the trunk of a hawthorn tree or beneath a stone.
Though Merlin knows beforehand that this will happen due to his power of foresight, he is unable to counteract her because of the 'truth' this ability of foresight holds.
He decides to do nothing for his situation other than to continue to teach her his secrets until she takes the opportunity to entrap and entomb him within a tree, underneath a large stone, or inside a cave or a tomb, depending on the version of this story.
In the Prophéties de Merlin, she is proud of how Merlin had never taken her virginity, unlike what happened with his other students, and is especially cruel in the way she disposes of him; she then takes Tristan's brother Meliadus the Younger as her actual lover.
The Vulgate Lancelot explains this by a spell she put "on her groin which, as long as it lasted, prevented anyone from deflowering her and having relations with her."
The Livre d'Artus has Niniane leave Merlin for another lover (the evil king Brandin of the Isles, whom she teaches some magic that he then applies to his terrible castle Dolorous Gard); she is never actually molested by Merlin and rids herself of him only as a precaution.
In still another telling, in a nonviolent scene taking place under a blooming hawthorn, Merlin is betrayed and placed inside an invisible and indestructible tower, but then she comes to him every day or night (a motif reminiscent of Ganieda's visits of Merlin's house in an earlier version of Merlin's life as described in Vita Merlini).

According to her backstory in the Vulgate Merlin, Viviane was a daughter of the knight Dionas (Dyonas) and a niece of the Duke of Burgundy.
She was born in Dionas' domain of Briosque in the forest Brocéliande, and it was an enchantment of her fairy godmother Diana that caused Viviane to be so alluring to Merlin when she first met him there as a young teenager.
The Vulgate Lancelot informs the reader that, back "in the time of Virgil", Diana had been a Queen of Sicily that was considered a goddess by her subjects.
In the Post-Vulgate Suite de Merlin, the future Lady of the Lake was born and lived in a magnificent
The Lady of the Lake began appearing by this title in the French chivalric romances by the early 13th century as the fairy godmother-type foster mother of the hero Lancelot. In the Lancelot-Grail (Vulgate) prose cycle, the Lady resides in an enchanted realm, an otherworld the entry to which is disguised as an illusion of a lake (the Post-Vulgate notes it as Merlin's work). There, she raises Lancelot from his infancy following the death of his father King Ban, teaching Lancelot arts and writing, infusing him with wisdom and courage, and overseeing his training to become an unsurprassed warrior. She also rears his orphaned cousins Lionel and Bors after having her damsel Seraide (Saraïde, later called Celise) rescue them from King Claudas. All this takes her only a few years in the human world. Afterwards, she sends off the young Lancelot to King Arthur's court as the nameless White Knight (a part of her affinity with the color white), but then keeps aiding him in various ways during his early adventures with her magic-item gifts (similar in that to his unnamed fairy protectoress in Chrétien's version, who too gives him a magic ring) and through her maidens serving as her agents and messengers. She furthermore personally arrives to restore Lancelot to sanity during some of his recurring fits of madness. 
The Vulgate Cycle tells of either a different or the same (that was made explicitly clear only in the later revisions) Lady of the Lake in the Prose Merlin-derived section, which takes place before its main Vulgate Lancelot section but was written later, and links her with the disappearance of Merlin. Here, she is given the name Viviane (or similar) and a human origin. In the Vulgate Merlin, she refuses to give Merlin (who at this time is already old but appears to her in the guise of a handsome young man) her love until he has taught her all his secrets, after which she uses her power to seal him forever, originally either in the trunk of a hawthorn tree or beneath a stone. Though Merlin knows beforehand that this will happen due to his power of foresight, he is unable to counteract her because of the 'truth' this ability of foresight holds. He decides to do nothing for his situation other than to continue to teach her his secrets until she takes the opportunity to entrap and entomb him within a tree, underneath a large stone, or inside a cave or a tomb, depending on the version of this story. In the Prophéties de Merlin, she is proud of how Merlin had never taken her virginity, unlike what happened with his other students, and is especially cruel in the way she disposes of him; she then takes Tristan's brother Meliadus the Younger as her actual lover. The Vulgate Lancelot explains this by a spell she put "on her groin which, as long as it lasted, prevented anyone from deflowering her and having relations with her." The Livre d'Artus has Niniane leave Merlin for another lover (the evil king Brandin of the Isles, whom she teaches some magic that he then applies to his terrible castle Dolorous Gard); she is never actually molested by Merlin and rids herself of him only as a precaution. In still another telling, in a nonviolent scene taking place under a blooming hawthorn, Merlin is betrayed and placed inside an invisible and indestructible tower, but then she comes to him every day or night (a motif reminiscent of Ganieda's visits of Merlin's house in an earlier version of Merlin's life as described in Vita Merlini).
According to her backstory in the Vulgate Merlin, Viviane was a daughter of the knight Dionas (Dyonas) and a niece of the Duke of Burgundy. She was born in Dionas' domain of Briosque in the forest Brocéliande, and it was an enchantment of her fairy godmother Diana that caused Viviane to be so alluring to Merlin when she first met him there as a young teenager. The Vulgate Lancelot informs the reader that, back "in the time of Virgil", Diana had been a Queen of Sicily that was considered a goddess by her subjects. In the Post-Vulgate Suite de Merlin, the future Lady of the Lake was born and lived in a magnificent
Lady of the Lake