There are many flowers elsewhere and, about every other year, I've got radish, bok choy, mustard, or something flowering to replenish seed stocks.
For a vegetable garden "companion" - it has to be sunflowers. I have never had a tomato hornworm in the garden since I started growing sunflowers nearby and this is going on 7 or 8 years now.
The last time I saw hornworm damage was the 1st year with sunflowers. I decided that I'd need to bring the Bt spray out to kill it. Of course, I forgot. So, I got in there and searched carefully for it and couldn't find the worm. Over the course of the next few days, the plant healed completely!
Above the plant were my first sunflowers in many years. These plants are visited often by the birds, mostly finches. Even before they bloom, the birds make frequent stops. It may be that they are "staking out their territories" for the time when there will be seed.
You gotta watch the plants, tho' - they are magnates to aphids. (That could be why the finches show up, also.) Washing the plants with dishsoap once a season seems to do it for pest control. The birds that the sunflowers bring in, aren't pests -- to my way of thinking
Make everything as simple as possible but not simpler. ~ Albert Einstein