Part of what leads me to the conclusion that Joseph Smith was onto something legitimate is that you can synthesize Mormonism with a sections from a lot of those Gnostic texts much easier than you can synthesize it with Nicene Christianity. “Your star has led you astray Judas,” and so on. It’s just too specific; he didn’t just make that stuff up, and he didn’t have access to the Nag Hammadi texts.
I’ve considered the possibility that he was speaking with demons or some other similarly evil entity, but when people go down that road the word “heretical” comes up real fast, and as we both know, being “heretical” literally just means not agreeing with Orthodoxy. So it’s kind of begging the question; imagine if I were to just copy-paste chunks of the LDS website to you and call you an “apostate” every time you went off the LDS reservation. It would be stupid, and it’s special pleading to say that it being stupid doesn’t go both ways.