As is well known, the entire world was made from the parts of the "seven kings that ruled in the land of Edom" (Gen. 36:31) who died and [the fallen sparks] were separated out. (Eitz Chayim, Sha'ar Shevirat Hakeilim)

Prior to day one of creation and the existence of the sefirot as we know them, there existed preliminary sefirot, the vessels which G‑d was forced to break. This resulted in the world of Tohu [chaos]. Since these were preliminary sefirot, they were not given their final names of keter, chochma, etc. They are referred to by the names of the kings of Edom mentioned in the Book of Genesis (Chap. 36), and the pre-creation existence is called "the Land of Edom." Once G‑d willed the world to be, He sent down a repairing light that 'resurrected' as many of the broken pieces necessary for existence, separating them out from amongst the kelipot.

Those which were the most refined were used for the level of Atzilut, and the next level went to Beriya, after that to Yetzira, and finally to Asiya.

From those used to create Asiya, the most refined were used for man and they were separated out first. After that came the animals who cannot speak, then the vegetable kingdom, and after that inanimate creation. However, a righteous person through his actions such as eating for the sake of a mitzvah, can separate out aspects of the inanimate world and elevate them to the level of the vegetable kingdom, or the animal kingdom, or even to the level of man, as we have explained in Sha’ar HaMitzvot, in the portion Eikev on the mitzvah of Birkat Hamazon.

It all depends upon how intensely one is connected to the spiritual energy inside the food, and not drawn after the physical desire. (Likutei Moharan)

A wicked person, however, through his actions can cause just the opposite to happen and will lower [the sparks down] rungs. Some sins can cause portions of man[soul sparks] to descend until the level of domaim, some until tsoma'och, and some until chai. Thus, after a wicked person dies he can reincarnate into an inanimate rock as a result of the sins he performed in his lifetime, or into vegetation, or into an animal - if his sins were animal-like.

The person who reincarnates in this way will remain there for a set amount of time until he has become purged of the sin that caused him to reincarnate into vegetation. After, he will be elevated to the level of the animal kingdom, and when the time is complete, he will be elevated to that of man.

Reincarnating into a man can happen in one of two ways. Regarding the first way, and the souls of wicked people which after death do not merit to enter Purgatory, or bodies of living people in this world, we will speak about later. According to the second way, they may enter a person in the secret of 'ibur' ['pregnancy' (an added soul part)] as we spoke about earlier, clinging to the person without him even knowing anything at all.

Just as an accessory can be added to a stereo system to enhance and increase the sound it produces, so can soul parts be added to amplify its tendencies and performance - for good or otherwise.

Thus, if a person sins, the nefesh that has come into him will overcome him, and the person will sin and be pulled to the side of evil. For, just as the soul of a righteous person enters a person to help him do good, so the soul of a wicked person causes another to do evil.

Sometimes the ibur is to help the soul rectify itself, and sometimes it is for the sake of the person to bring him to do good. These two levels also exist with respect to the ibur of an evil soul, either for the sake if it having entered the body of a righteous person, or to cause an wicked man to 'complete' his evil and warrant destruction from the world, G‑d forbid.

An evil soul can come into the body of a righteous person to achieve tikun through his actions. It can also come into the body of a wicked person to accelerate his spiritual demise.

Once the set time to atone has finished for the soul that has reincarnated into a person in one of these two ways just mentioned, then he is forgiven. He can then come into this world as a true gilgul, born into a body like most people.

[Translation and commentary by Perets Auerbach.]