There are several current beliefs in science about how the universe began, but one popular model shows the universe as happening completely spontaneously. The model allows for it happening many times, with most universes being unstable and self-annihilating almost immediately.
There's no thought involved at all, as nothing at all exists before the universe just pops into existence. This is possible, because all the energy in the universe sums to zero. That is, a universe, taken as a whole, is nothing. The nothing has fine detail - including us.