"And if it gores" (Exodus 21:35) - included in striking are goring, shoving, lying down upon, kicking, and biting; the words of Rabbi Josiah. Abba Saul says in the name of Rabbi Eliezer: included in striking are goring, shoving, lying down upon, and kicking. From where do we learn biting? Scripture teaches "and its owner did not guard it" (Exodus 21:36). And the matter follows by inference from minor to major: if when he had guarded it and it got out and caused damage he is liable, then all the more so before he has guarded it. Then what does Scripture teach by "and its owner did not guard it"? Rather, Scripture comes to add yet another act of guarding, and which is it? This is biting. "The ox of a man" (Exodus 21:35) - to exclude the ox of a minor. "The ox of a man" - to include the ox of others. "His neighbor's" - to include the ox of a minor. One might think Scripture speaks of two animals of equal value, or is it speaking both of equal and unequal value? You reason: just as it is the way of those who cause damage to gain or to lose, and so forth, so too those who suffer damage take their damages or more than their damages - you must say: not more than their damages. Rabbi Akiva says: half is stated regarding the living and half regarding the dead, so Scripture speaks of animals of equal value.
What Counts as Goring and the Duty to Guard the Ox
Yalkut Shimoni on Torah 341:18
וְכִי יִגֹּף בִּכְלָל נְגִיפָה נְגִיחָה דְּחִיָּה רְבִיצָה בְּעִיטָה נְשִׁיכָה דִּבְרֵי רַבִּי יֹאשִׁיָּה. אַבָּא שָׁאוּל אוֹמֵר מִשּׁוּם רַבִּי אֱלִיעֶזֶר: בִּכְלָל נְגִיפָה, נְגִיחָה דְּחִיָּה רְבִיצָה בְּעִיטָה. נְשִׁיכָה מִנַּיִן, תַּלְמוּד לוֹמַר: "וְלֹא יִשְׁמְרֶנּוּ בְּעָלָיו". וַהֲרֵי דְּבָרִים קַל וָחֹמֶר: וּמָה אִם בִּשְׁמָרוֹ וְיָצָא וְהִזִּיק חַיָּב, קַל וָחֹמֶר עַד שֶׁלֹּא יִשְׁמְרֶנּוּ, וּמַה תַּלְמוּד לוֹמַר "וְלֹא יִשְׁמְרֶנּוּ בְּעָלָיו", אֶלָּא לְהוֹסִיף הַכָּתוּב עוֹד שְׁמִירָה אַחֶרֶת, וְאֵיזוֹ, זוֹ נְשִׁיכָה. "שׁוֹר אִישׁ" לְהוֹצִיא שׁוֹר שֶׁל קָטָן. "שׁוֹר אִישׁ" לְהָבִיא שׁוֹר שֶׁל אֲחֵרִים. "רֵעֵהוּ" לְהָבִיא שׁוֹר שֶׁל קָטָן. יָכוֹל, אַתָּה אוֹמֵר בְּשָׁוִין הַכָּתוּב מְדַבֵּר, אוֹ אֵינוֹ אֶלָּא בְּשָׁוִין וּבְשֶׁאֵין שָׁוִין, אָמַרַת: מַה דֶּרֶךְ הַמַּזִּיקִין נִשְׂכָּרִין אוֹ מַפְסִידִין, הֱוֵי וְכוּ', אַף הַנִּזָּקִין נוֹטְלִין נִזְקָן אוֹ יוֹתֵר עַל נִזְקָן, הֱוֵי אוֹמֵר: וְלֹא יוֹתֵר עַל נִזְקָן. רַבִּי עֲקִיבָא אוֹמֵר: נֶאֱמַר חֲצִיָּה בַּחַי וְנֶאֱמַר חֲצִיָּה בַּמֵּת, הָא בְּשָׁוִין הַכָּתוּב מְדַבֵּר.