Traditional Sources on Multiple Authorship of תנ"ך ("Documentary Hypothesis")
אמר מר יהושע כתב ספרו ושמונה פסוקים שבתורה תניא כמאן דאמר שמונה פסוקים שבתורה יהושע כתבן דתניא (דברים לד, ה) וימת שם משה עבד ה' אפשר משה (מת) וכתב וימת שם משה אלא עד כאן כתב משה מכאן ואילך כתב יהושע דברי ר"י ואמרי לה ר' נחמיה אמר לו ר"ש אפשר ס"ת חסר אות אחת וכתיב (דברים לא, כו) לקוח את ספר התורה הזה אלא עד כאן הקב"ה אומר ומשה אומר וכותב מכאן ואילך הקב"ה אומר ומשה כותב בדמע כמו שנאמר להלן (ירמיהו לו, יח) ויאמר להם ברוך מפיו יקרא אלי את כל הדברים האלה ואני כותב על הספר בדיו
The Gemara elaborates on the particulars of this baraita: The Master said above that Joshua wrote his own book and eight verses of the Torah. The Gemara comments: This baraita is taught in accordance with the one who says that it was Joshua who wrote the last eight verses in the Torah. This point is subject to a tannaitic dispute, as it is taught in another baraita: “And Moses the servant of the Lord died there” (Deuteronomy 34:5); is it possible that after Moses died, he himself wrote “And Moses died there”? Rather, Moses wrote the entire Torah until this point, and Joshua wrote from this point forward; this is the statement of Rabbi Yehuda. And some say that Rabbi Neḥemya stated this opinion. Rabbi Shimon said to him: Is it possible that the Torah scroll was missing a single letter? But it is written: “Take this Torah scroll” (Deuteronomy 31:26), indicating that the Torah was complete as is and that nothing further would be added to it. Rather, until this point the Holy One, Blessed be He, dictated and Moses repeated after Him and wrote the text. From this point forward, with respect to Moses’ death, the Holy One, Blessed be He, dictated and Moses wrote with tears. The fact that the Torah was written by way of dictation can be seen later, as it is stated concerning the writing of the Prophets: “And Baruch said to them: He dictated all these words to me, and I wrote them with ink in the scroll” (Jeremiah 36:18).
אמר רבי יהושע בר אבא אמר רב גידל אמר רב שמנה פסוקים שבתורה יחיד קורא אותן בבהכ"נ כמאן דלא כר"ש דתניא (דברים לד, ה) וימת שם משה עבד יי' אפשר משה חי וכתב וימת שם משה אלא עד כאן כתב משה מכאן ואילך כתב יהושע בן נון דברי רבי יהודה ואמרי לה רבי נחמיה
§ Rabbi Yehoshua bar Abba says that Rav Giddel says that Rav says: With regard to the last eight verses of the Torah (Deuteronomy 32:5–12), a single individual reads them in the synagogue, as that section may not be divided between two readers. The Gemara asks: In accordance with whose opinion is this said? It is not in accordance with the opinion of Rabbi Shimon. As it is taught in a baraita: The verse states: “And Moses the servant of the Lord died there” (Deuteronomy 34:5). Is it possible that after Moses died, he himself wrote: “And Moses died there”? Rather, Moses wrote the entire Torah until this point, and Joshua bin Nun wrote from this point forward; this is the statement of Rabbi Yehuda. And some say that Rabbi Neḥemya stated this opinion.

עשר נקודות בתורה אלו הן:

ישפוט ה' ביני וביניך (בראשית ט״ז:ה׳) על י' שביני״ך נקוד מלמד שלא אמרה לו אלא על הגר וי״א על המטילין מריבה ביני וביניך.

ויאמרו אלי״ו איה שרה (שם יח) נקוד על אי״ו שיודעין בה ומבקרין אחריה.

(נקוד על) בשכבה ובקומה (שם יט) נקוד על וי״ו שבקומה הראשון מלמד שלא הרגיש אלא בעמידתה (של צעירה)

כיוצא בו וירץ עשו לקראתו ויחבקהו ויפול על צואריו וישקה״ו (שם לג) כולו נקוד מלמד שלא נשקו באמת. ר״ש בן אלעזר אומר נשיקה זו של אמת וכולן אינן של אמת.

כיוצא בו וילכו אחיו לרעות את צאן אביהם בשכם (שם לז) נקוד על א״ת מלמד שלא לרעות הצאן הלכו אלא לאכול ולשתות (ולהתפתות).

כיוצא בו כל פקודי הלוים אשר פקד משה ואהרן (במדבר ג׳:ל״ט) נקוד על אהרן למה מלמד שלא היה אהרן מן המנין.

כיוצא בו או בדרך רחוק״ה (שם ט) נקוד על ה' שברחוקה מלמד שלא היתה דרך רחוקה אלא מן אסקופת עזרה ולחוץ.

כיוצא בו ונשים עד נופח אשר עד מידבא (שם כא) נקוד על רי״ש שבאש״ר למה מלמד שהחריבו העובדי כוכבים ולא החריבו המדינות שלא החריבו עובדי כוכבים אלא המדינות.

ועשרון עשרון (במדבר כ״ט:ט״ו) של יו"ט הראשון של חג הסכות נקוד על עשרו״ן בוי״ו למה מלמד שלא יהא שם אלא עשרון אחד

כיוצא בו (דברים כ״ט:כ״ח) הנסתרות לה׳ אלהינו והנגלות לנ״ו ולבנינ״ו נקוד על לנו ולבנינו ועל ע' שבעד

למה?

אלא כך אמר עזרא אם יבא אליהו ויאמר לי מפני מה כתבת כך אומר אני לו כבר נקדתי עליהן ואם אומר לי יפה כתבת אעביר נקודה מעליהן.

אחת עשרה היא [והיא כתיב ביו״ד] בתורה. הראשון הוא מלך בלע היא צוער. הלא הוא אמר לי אחותי הוא והיא גם הוא אמרה אחי הוא. הוא מוצאת והיא שלחה אל חמיה לאמר. וכי ימות מן הבהמה אשר היא לכם לאכלה. והיא הפכה שער לבן. ואם יראנה הכהן [וגו׳] והיא כהה. והיא תראה את ערותו. את אביה היא מחללת. (בקנאות) ונסתרה והיא נטמאה (והיא לא נתפשה). או עבר עליו רוח קנאה וקנא את אשתו והיא לא נטמאה:

וְיֵשׁ אוֹמְרִים לָמָּה נָקוּד?

אֶלָּא כָּךְ אָמַר עֶזְרָא: אִם יָבוֹא אֵלִיָּהוּ וְיֹאמַר לָמָּה כָּתַבְתָּ אוֹתָן?

אוֹמַר לוֹ: כְּבָר נִקַּדְתִּי עֲלֵיהֶם.

וְאִם יֹאמַר לִי: יָפֶה כָּתַבְתָּ, כְּבָר אֶמְחֹק נְקֻדּוֹתֵיהֶן מֵעֲלֵיהֶן.

...And there are those who say: why is it marked [with dots above the letters]?

Because Ezra reasoned as follows: If Eliyahu comes and said 'Why did you write them [like this]?

Ezra would reply: I already marked them.

And if he comes and said: You have written well.

I have already erased the markings from above them.

והכנעני אז בארץ. יתכן שארץ כנען תפשה כנען מיד אחר ואם איננו כן יש לו סוד והמשכיל ידום

The Canaanites were then in the land: It would seem that the Canaanites took the land of Canaan from a different group. But if this is not correct, then there is a secret here, and the wise will remain silent.

וטעם בהר ה' יראה. באלה הדברים

And the meaning of "...when the present saying, "On the Mount of God there is vision"" - in Dvarim.

(א) ויעל משה. לפי דעתי כי מזה הפסוק כתב יהושע כי אחר שעלה משה לא כתב ובדרך נבואה כתבו והעד ויראהו ה' גם ויאמר ה' אליו גם ויקבור:
(1) It is my belief that Joshua wrote from this verse onward, because once Moshe ascended, he wrote nothing further. Joshua must have written prophetically, as evidenced by God showed…, as well as God said to him…, and “He buried…” [: 6].

עד היום הזה. דברי יהושע. ויתכן שכתב זה באחרית ימיו:

To this day These are Joshua’s words [Bava Batra 15a], who wrote them, most likely, toward the end of his life.

והכנעני אז בארץ על שם העתיד נכתב כשהיו ישראל מוחזקים בקרקע לכך נופל בו לשון אז כלומר אז בימי אברהם היה הכנעני בארץ, וכן לפנינו והכנעני והפרזי אז יושב בארץ.

והכנעני אז בארץ, the word: אז, “then,” (in the past) indicates that the Torah did not speak about the political situation at the time when the Jewish people were in possession, but about the political situation at the time when Avraham first wandered through that land.