Diversification and specialization are central to complex adaptive systems, yet overarching principles across domains remain elusive. Vicky Chuqiao Yang, assistant professor at the MIT Sloan School of Management, and James Holehouse, a mathematical biologist with the Santa Fe Institute led a research project that has introduced a general theory that unifies diversity and specialization across disparate systems, including microbes, federal agencies, companies, universities, and cities, characterized by two key parameters. The research team show from extensive data that function diversity scales with system size as a sublinear power law-resembling Heaps’ law-in all but cities, where it is logarithmic. Their theory explains both behaviors and suggests that function creation depends on system goals and structure: federal agencies tend to ensure functional coverage; cities slow new function growth as old ones expand; and cells occupy an intermediate position. Once functions are introduced, their growth follows a remarkably universal pattern across all systems.