Communities and Specializations are two very different things even if you can group Courses in both.
Specializations allow admins to design learning plans or learning paths so learners can achieve a larger learner objective. Use Specializations to define the Courses that Learners must complete to achieve the objectives of a Specialization. To complete the Specialization, learners must complete the Course requirements in all Sections of a Specialization.
A learning Community is a place where learning can be grouped around a particular topic or area of interest and shared with a distinct set of people known as community members. The purpose of a community can range from collaborative Communities created by employees or managers to a more formal learning Community.
So, use Specializations if you want people to complete a group of Courses as a one-time event, and once they have completed all the Courses, they don't need to return to the Specialization again. The Admin can easily report if Learners have completed a Specialization
Use Communities if you want Learners to collaborate around a topic, and add Courses, Videos, Tutorials, etc. into the Community as needed.
I hope this blog post was helpful for you. If you have any questions or feedback, please leave a comment below.