Just finished. I'll try to gather my thoughts as to what I think went down here before I read anyone else's interpretation and get swayed one way or the other.
So clearly at some point you either transformed or became host to a Great One, or a lesser Great One, or one of their children or what have you. This likely happened when you received blood ministration in Ioefska's Clinic at the start of the game.
The ragged beast reaching for you is clearly your "bestial" half attempting to overtake you and drive you mad, but it burns to death on contact. There are a couple reasons why this might have happened. Either you repelled it with your own willpower (unlikely, if people like Gascoigne and Amelia succumbed so easily), or the Messengers repelled it for you. I hypothesize that the Messengers are representatives of the Great One, be it the Moon Presence or the Great One possibly gestating inside you.
I think it's pretty obvious what happened to Yarnham in general. Byrgenwerth discovered a "holy medium" in the labyrinth below Yarnham (presumably the chalice dungeons?). Whatever this medium was (I don't think it's ever revealed?), it allowed Laurence to make contact with the Moon Presence. So whatever art was passed on to humanity via the medium, it evolved to miraculous blood healing, being an obvious benefit to everyone. I don't think anyone really knows what's going on at first, but as blood ministration becomes more ubiquitous I believe the Great Ones begin communicating with Byrgenwerth scholars and high-ranking members of the Healing Church telepathically through their dreams.
The ultimate goal of the Great Ones is to terraform the minds of Yarnham's people into something suitable for their habitation. They do this by wooing the Church and creating the Choir, which works in conjunction with Byrgenwerth to further blood healing and spread it to the masses. Some people take (the countless madman's skulls littering Yarnham that seemingly cracked like eggs - possibly birthing the abominations seen in the city), some are in the process of turning (like Micolash, or the pale-faced clerics in the Cathedral Ward), but most lack true insight and became beasts when their Id and Ego were set aside for habitation - the werewolf got them, so to speak.
I'm confused as to why this might be. It's said that clerics became the most hideous beasts, but why would this be if they were closest to the eldritch truth I do not know. I'm convinced that most of the church had no idea what was going on and thus lacked "true" insight. Amelia, for example, clearly believes the Great One Oedon is a god deserving of worship, and transforms into a beast due to her lack of understanding. Perhaps the clerics' more hideous forms were due to the scope of their belief? As in, they believed but did not understand, thus they become higher beasts but beasts nonetheless.
But anyway, Yarnham is a dream, and the dreamer is either yourself or the Moon Presence. I'm trying to piece together exactly what happens when you defeat it. It dies, the scene shifts, and you are a mewling squidthing on the ground. By killing the MP, you shatter the nightmare, but in doing so shatter your human form, which was part of the dream. This is what confuses me. Who woke up, you or the MP?
I don't know. Clearly there's much more discussion to be had. Who was the old man who performed the blood transfusion on you at the start? It doesn't look like Gehrman, but who else would it be? What's up with the mensis ritual? How did the baby Great Ones come into being? Did consuming the umbilicals transform you into one of them, or were you one the whole time?