Procedurally generated concrete poetry.
I was inspired by Lewis Thomas's wonderful comparison between human speech and the pursuits of social insects:
Language is, like nest building or hive making, the universal and biologically specific activity of human beings. We engage in it communally, compulsively, and automatically. We cannot be human without it; if we were to be separated from it our minds would die, as surely as bees lost from the hive.
[…] New ways of stringing words and sentences together come into fashion and vanish again, but the underlying structure simply grows, enriches itself, and expands.
Ant nests accrete from the tiny bits of earth that each worker carries in its mandibles. Here, sculptural forms are shaped by the dirt clods of language—the letters of our alphabet.
Each time it is run, the program:
- selects random animal species from a static list in Darius Kazemi's Corpora project;
- sorts the letters in each species according to character density (e.g. seal → slea);
- finds a random image of each species using Google's JSON/Atom Custom Search API;
- maps the reordered letters to pixel intensities with code from asciinator.py; and
- parses the resulting poems into HTML that is rendered as a PDF file with wkhtmltopdf.