Bastila lead Revan into a trapped but instead of killing him या her, whatever gender आप desided to be, they took Revan erased his/her memory so the Republic used him/her.
When आप play the game आप won't confused द्वारा the visions cause the visions is from your past of how आप were captured and how.