Colonel Jack O'Neill, Teal'c and a team of four young SGC recruits approach an abandoned warehouse, where they hope to find Major Carter and Dr. Jackson -- whom Jack says were taken by the Goa'uld. O'Neill and Teal'c go inside, and the young soldiers -- commanded by Lieutenant Elliot -- rush in a few moments later when they hear gunfire.They find O'Neill and Teal'c unconscious on the floor, and Sam and Daniel pointing weapons at each other. They both claim the other is a Goa'uld. They subdue Carter, but Daniel reveals that he is a Goa'uld -- and shoots them all.
The training exercise ends, and Colonel O'Neill chastises Elliot and his team for failing.
In the SGC mess hall, Carter talks to O'Neill about Lieutenant Elliot. Jack recognizes that Lieutenant Hailey ("Prodigy") is brilliant, but thinks that the rest of the team doesn't hold great promise for the future of the SGC. Elliot is a fine Air Force Academy graduate, but being in the SGC takes an extra something. Jack believes that Elliot thinks too much, and that makes him indecisive.
Back at the training facility, Colonel O'Neill leads the recruits in another simulation. They are to infiltrate a building believed to house a valuable piece of Goa'uld technology. They find the device, but it is booby-trapped. After a moment of indecision, Elliot orders his team out, and the device explodes. But one of his men, Grogan, doesn't make it out. O'Neill condemns Elliot for leaving a man behind, and declares the exercise another failure.
The colonel gets a phone call, and the recruits overhear the word "foothold." A group of soldiers arrive and order O'Neill to relinquish his weapon -- and he shoots them. Jack is injured in the process, and Elliot's team learns that there has been an alien incursion at the SGC. Despite O'Neill's reservations, he allows them to accompany him back to the mountain. He has no one else.
Once inside the compound, Elliot and his team discover that everyone on the base has been taken over by Goa'uld nanites -- tiny machines within the bodies of SGC personnel. Dr. Jackson is the leader of the invasion, using alien technology to control the others.
O'Neill remains in a security room, and sends the young team to Carter's lab to find a way to counteract the nanites. On the way, they meet Major Carter -- who claims that her experience as a Goa'uld host has made her immune to the nanites' control. They take her back to O'Neill, and discover him untying an SGC security guard.
Worried that the colonel himself has been compromised, Lieutenant Elliot shoots him with his training weapon (an Intar, first encountered in Season Three's "Rules of Engagement") and takes command.
The team makes their way to General Hammond's office, and after a firefight manage to subdue Dr. Jackson and Teal'c. Lieutenant Satterfield tries to turn off the alien device that is controlling the nanites, but it begins to build toward self-destruct. They clear the room, but the device does not explode.
General Hammond and SG-1 enter the room, revealing that it was all another training exercise -- one that they passed with flying colors, even outwitting O'Neill and Carter's attempts to guide their actions. But they realize that Lieutenant Hailey is absent -- she's in the Gate Room attempting to regain control of the Stargate, believing that the invasion is real. Elliot and the others see her receive a major electrical shock, and fall unconscious.
The Stargate is active, and Carter reports that massive amounts of gamma radiation is pouring through -- a Goa'uld attack. General Hammond orders Level 28 evacuated, telling the team that Hailey is already dead by now. But Elliot steals Carter's access card and rushes into the Gate Room. He manages to close the iris and rescue Hailey.
But as he picks her up and heads for the door, the blast doors to the control room raise -- revealing Hammond, SG-1 and the rest of his team, applauding. It was yet another test, and Elliot demonstrated that he was willing to risk his life rather than leaving one of his people behind. As for Hailey -- she was in on the training exercise the entire time.
O'Neill congratulates Elliot, and Hammond tells him that he will be assigned to SG-17. His teammates will also be assigned to the SGC as positions become available.