Only problem with raledon's suggestion would be that if they are in a situation where they cannot be knocked back, they would still utilize that ability instead of attacking. There is definitely code to run away, for some reason *poisoned* units often do. I suspect that might be a bad tag in the AI code, and the PoisonER is supposed to run away after poisoning.
You could however give them a defensive ability, and have them utilize that as a priority over attacking.