The history of Buddhist scriptures has, to simplify a little, two main phases. There were the initial teachings, recorded in a number of languages and passed on first orally and then in written form. The sole complete version of these that we have is called the Pali canon.
Then there are the Mahayana (“Greater Vehicle”) scriptures, which often claim to be the word of the Buddha, but which were clearly composed much later. The style of these indicates that they were composed as written works, and didn’t go through a phase of oral transmission.
The fact that the Mahayana scriptures don’t literally come from the Buddha doesn’t invalidate them as sources of wisdom, of course. I love a lot of the Mahayana Sutras and take inspiration from them. The Perfection of Wisdom sutras (including the Heart Sutra and Diamond Sutra) and the Vimalakirti Nirdesha are works that I consider to be the profoundest spiritual documents in the world. In fact the claim that the Mahayana sutras came from the Buddha himself points to something very interesting about the nature of insight.
These scriptures were composed by people with genuine spiritual insight at a time when other early schools had largely slipped into scholasticism. Just to take one example, some of the key terms of the Mahayana, like “shunyata” (emptiness) are found in the early scriptures, but they’re largely ignored by the Theravadin tradition, or at least they’re very far from being central to its teachings. The Mahayana, on the other hand, kept alive a spiritually vital understanding of what the Buddha meant by that term.
The Mahayana authors chose to present their explication of those teachings as scriptures (writings purporting to be the word of the Buddha) rather than commentaries (the writings of later teachers). There’s a sort of dishonesty implicit in that, unless you consider the possibility of the teachings having emerged in visionary states, in which case the “composers” of the Mahayana sutras might well have believed that they were passing on teachings that mystically came from the Buddha. It’s quite literally possible in a meditative state to “hear” teachings from the Buddha.
There’s plenty of this is the Pali canon, by the way. There are many discourses where a disciple was pondering a question, and the Buddha appeared to them in a vision and gave them a teaching. For example, one time a disciple of the Buddha was trying to meditate, but falling asleep. We’re told that the Buddha then appeared to him (although he was physically elsewhere) and gave him instructions on how to stay awake.
I take this to mean that a deeper level of intuitive insight arose in the disciples, but was presented in the Buddha’s voice.
We all have the experience of having conversations in our head with other people we know well. We’ve internalized their thought patterns and mannerisms to the extent where we can run a mental simulation of them. Sometimes, though, when we’re very familiar with a teacher’s mode of presentation, we can “hear” them answering a question that’s in our mind. It’s not a psychic transmission, but our own wisdom appearing in the teacher’s appearance and voice. Although this is “our” wisdom, we hear insights that are new to us, and that surprise us.
So I think that this may have been what happened with the Mahayana scriptures — that they did come from the Buddha, in a sense, but not the historical Buddha. Instead they came from insights that arose in the minds of deep practitioners of the Dharma, manifesting in the guise of the Buddha.
For us, the important voices to listen to are our conscience and our intuition. This is one reason it’s crucial that we learn to calm the mind in meditation, so that there’s less inner chatter going on. Through meditation we can create a quiet inner space in which the quiet murmurs of our unconscious wisdom can make themselves heard. Eventually, these voices may appear in the guise of the Buddha, or some other figure who represents wisdom. But that’s not what matters. It’s simply important that we learn to still the mind, and to listen.