The Braconid Wasp group are tiny, tiny wasps that parasitize a wide range of pest insects - the Hornworm caterpillars are generally infected by species in the genus Cotesia. The very small female Cotesia wasp (we're talking 2 - 13 mm depending on the species) lays her eggs on young caterpillars. The young wasps then (and this is gross) hatch out and eat the host from the inside out. These particular wasps pupate on the outside of the dead host until they mature into adults and fly off to attack other pests.
The Cotesia wasps have symbiotic viruses that they inject into the host with the eggs. The virus is believed to be involved in suppression of the host immune system and interfering with development. Instead of the caterpillar pupating and turning into a Sphinx Moth it keeps growing past it's normal size, providing extra food (and extra time) to the young wasps.
So despite the damage to the tomato plant (and it's already bouncing back) by leaving the caterpillar I got to watch nature at work and doesn't she do some cool stuff!