Facilitated variation via ecology is one way modification leads to speciation. A change in environment provokes envirotypic adaptation.
Many insects form conspicuous galls on their host plants. The galls provide the inducer insects with an isolated and exclusive habitat, constant and high-quality food supply, physical barrier against predators and parasites, and mitigated environmental stresses such as desiccation and temperature fluctuation. The gall-forming insects manipulate the plant growth and morphogenesis for their own sake in a sophisticated manner, thereby inducing elaborate plant structures as “extended phenotypes” of the insects. ~ Japanese biologist Mayako Kutsukake et al
Rather than build their own nests, social aphids induce galls on a plant to secure a comfortable home. Some gall nests have an open structure, with waxy walls. Other aphids prefer sealed structures, where they live for months without emerging.
Aphids feed exclusively on plant sap. As gall tissue provides a constant sap supply, no foraging outside is needed. But there is a plumbing problem: wastes must be flushed. Some galls have small openings through which soldier nymphs dispose colony refuse.
This is a compromise. Completely closed colonies offer the coziest abode: safe from all but gall-boring predators.
Aphids in closed galls engineered a clever solution: inducing galls with an inner surface specialized for absorbing water. Honeydew waste is promptly removed via the plant vascular system. This innovation evolved independently in different aphid species. The engineering skill is hereditary.