Don't make the same mistake I did of killing these hornworms with cocoons on their backs. The cocoons are of the beneficial braconid wasp.
I've seen these little wasps, less than half an inch long, flitting about in the garden but never knew they were so beneficial. They feed on flowers with small bracts like herb flowers. No wonder I have so many of them around. I have lots of herbs. The wasp is not harmful to humans and does not sting. the female braconid wasp lays it's eggs inside the tomato hornworm and the larvae eat their way out and form cocoons and eventually turn into more braconid wasps.