Best case for survival would be to become multiplanetary. In particular the conditions that would be created would be survivable by the exact same technology that will be the baseline for human colonization on Mars.
How far away do you have to be to avoid getting gamma'd?
So, if GRB are 2 degrees wide at the source, and it occurs 8000LY away, and is pointed directly at us, we'd need to travel 136LY away.
The solar system is moving at 1/1300 the speed of light. I'm not sure how Apep is moving relative to us, but assuming it's stationary, we'd need ~175k years to move out of the crosshairs by sitting here on the planet.
> even with a supernova strength source
In my defence, my reference power source was "supermassive black hole falling into another supermassive black hole" (probably due to having heard either GRBs in general or one specific one attributed to the collapse of a quasar).
Also, how wide, in terms of arcseconds, is the jet? Is it a narrow laser beam that has no chance of actually hitting a planet, or is it wide enough that anything within 30 degrees of north is going to be sterilized?
[1] https://en.wikipedia.org/wiki/Gamma-ray_burst#Rate_of_occurr... [2] https://en.wikipedia.org/wiki/Ordovician%E2%80%93Silurian_ex...
If it's as narrow as the arc of a season, one quarter of the Earth's orbit, it could hit us during Autumn or miss us during Winter, or not at all if it's not pointed into the path of our orbit.