The Holy One, Blessed be He, Gazed into the Torah and Created His World
The Torah preceded the creation of the world, and according to what is said in it, the world was created.
("In the beginning He created - as in the beginning of all creation, He created the heavens and the earth. Another thing, in the beginning - in the Torah, the Blessed One was accomplished and created His world, thus we say in the beginning He created God. And so Rabbi Hoshaya Rabbah teaches, as a king accomplishes his vision and builds the palace" - Psikta Zutrah (Good Take) at the beginning of Chapter A)
Translation
Expression (Hebrew)
הקב"ה הִסְתַּכֵּל בַּתּוֹרָה וּבָרָא אֶת עוֹלָמוֹ
Definition (Hebrew)
הַתּוֹרָה קָדְמָה לִבְרִיאַת הָעוֹלָם וְעַל פִּי הָאָמוּר בָּהּ נִבְרָא הָעוֹלָם.
("בְּרֵאשִׁית בָּרָא- כְּלוֹמַר בְּרֹאשׁ כָּל מַעֲשֶׂה, בָּרָא אֵת הַשָּׁמַיִם וְאֵת הָאָרֶץ. דָּבָר אַחֵר, בְּרֵאשִׁית- בַּתּוֹרָה נִסְתַּכֵּל הקב"ה וּבָרָא אֶת עוֹלָמוֹ,לְכָךְ נֶאֱמַר בְּרֵאשִׁית בָּרָא אֱלֹהִים. וְכֵן דָּרַשׁ ר' הוֹשַׁעְיָה רַבָּה, כְּמֶלֶךְ מִסְתַּכֵּל בַּדֶּפְתְּרָאִיּוֹתוֹפֶנְקְסָאוּת שֶׁלּוֹ וּבוֹנֶה אֶת הַפָּלָטִין"- פְּסִיקְתָּא זוֹטְרָתָא (לֶקַח טוֹב) בְּרֵאשִׁית פֶּרֶק א)