Why you don't change the flee when from "Enemy Military sighted" into "attacked" ? This reduce the loops.
Most people improve their Constution Ship with some extra Shield/armor and some Shield piercing weapons, not enough to kill the attackers but enough so they flee because they want to repair.
Now I feel kinda bad for not mentioning these as well. =P Yes, as long as you have decent shielding on your Constructors, which comes by default, you can comfortably set it to "when attacked," when can help when the pirates are doing something else in system and aren't interested in you.
Also, turning the Constructor into a mini-warship is completely feasible, and in fact some players prefer to play that way so Constructors can take care of threats wherever they are. It's especially easy if you use blasters, as they have high damage, small size, and you'll already need several reactors due to the static draw of the construction yard and energy/high tech/weapon plants.