Yeah, this was a stinker, but notable for being the first script written by Ron Moore who would go on to doing great things on TNG, DS9 and later the Battlestar reboot.

The aliens weren't in the original script, which revolved around Jeremy struggling to deal with his Mom's death by creating a replacement of her in the holodeck. Gene supposedly changed it to aliens because he thought kids in the 24th century would just be able to handle their parent's death better.