An away mission on an uninhabited planet find a small spaceship, crashed and damaged. Upon finding that its programming is fully sentient and in distress, the Doctor asks that the crew rescue it and return it to its people.
The artificial intelligence's memory is damaged, and it cannot tell them even what its function is; however it is soon found to be a weapon of mass destruction. At the Doctor's behest, Captain Janeway keeps the missile aboard, but orders B'Elanna Torres and Harry Kim to disarm the warhead before it remembers what it is.
However, during the procedure, the warhead's intelligence takes over the Doctor's holomatrix, and traps Kim and Torres in sickbay. Threatening to detonate, the warhead orders the Captain to take it to its target. While the rest of the crew look for ways to disable the intelligence, Kim tries to reason with it. The bomb refuses to listen, insisting that it must be allowed to reach its target; it threatens to detonate and destroy the ship if the crew does not comply.
Voyager crew members attempt to reconstruct the warhead's damaged memory circuits. They determine that its creators, a race called the Druoda, halted all hostilities with their enemy and issued recall orders to its fleet of sentient warheads. Most complied, but a few warheads malfunctioned and could not receive the order. This warhead is one of those, and was forcibly crash landed by the Druoda (by remote) to prevent it from detonating. The warhead does not believe this, and thinks that the order to stand down was faked by the enemy.
However, Kim reasons that the recall orders are protected by a code that is nearly impossible to break. The warhead is eventually convinced that hostilities are over; however, over 30 of its fellow warheads are still out there, and have already found Voyager. They ignore the Druoda order to stand down, and the warhead realizes what it must do next. The warhead is downloaded back into its 'body' (freeing the Doctor) and returned to its companions - whereupon it detonates, destroying itself and the other smart bombs.