I already made this question Naga evolution based on varanids related with the viability of varanid nagas. Any ways here I let the most relevant part from that question to explain my reasonement.
Varanids currently are very good swimmers using anguilliform or serpentine moves to swim this might cause the reduction of the hind limbs by adapting to aquatic environments. And varanids are closely related with snakes and mosasaurids.
This could have explained the presence of a large snake-like body.
Then, to explain the humanoid part of the body. Many varanids are arboreal too, some species just during their young and others during their entire live, this life style eventually might evolve hands to improve the arboreal locomotion, at the same time getting more complex shoulders and expanding freedom of movement of the arms, improving the object manipulation, maybe with some time would change some aspects of the rib cage.
Varanid species are very intelligent too, they know how to count and have one the highest energy and more active lifestyles in reptiles and with a four chambered heart, this would permit the energetic requisites of turn to a sapient specie.
This all is because I want to make some "realistic" Naga species evolved in a natural way without genetic engineering and the options from the question "anatomically correct naga" didn't convince me.
But the problems appears in the adaptive part, there are varanids more adapted to the arboreal life, others to digging or run, others to swim, but none is simultaneously such good for the mentioned life styles and this might cause that none could get a combination of the mentioned adaptations and abilities.
I meaning, I think the most probable case for the evolution of a varanid is to get just one set of the mentioned features generating different species to due the niche partition.
So the question is which would a propitious enviroment for impulse a species to get the mentioned naga features and avoid to evolve in different species?