चतस्र: संहिताश्चक्रे मन्त्रैर्मणिगणा इव ॥ ५० ॥
rāśīr uddhṛtya vargaśaḥ
catasraḥ saṁhitāś cakre
mantrair maṇi-gaṇā iva
Śrīla Vyāsadeva separated the mantras of the Ṛg, Atharva, Yajur and Sāma Vedas into four divisions, just as one sorts out a mixed collection of jewels into piles. Thus he composed four distinct Vedic literatures.
When Lord Brahmā first spoke the four Vedas with his four mouths, the mantras were mixed together like an unsorted collection of various types of jewels. Śrīla Vyāsadeva sorted the Vedic mantras into four divisions (saṁhitās), which thus became the recognizable Ṛg, Atharva, Yajur and Sāma Vedas.