Steve,
As for what happened, if that wire was partially stripped, it could have been grounding out and draining your battery. The Viper acts just like you mentioned when the battery starts to go - and it seems the alternator can't really recharge it.
Obviously Chuck knows WAY more than I do about this, but if you're looking for why this happened in the first place, that would be my guess.
When the computer is 'reset' it does take a while to idle smoothly. Also, if your battery isn't at 100%, it will idle a bit on the jumpy side. Monitor this over the next few weeks... if it starts to do it again, put it on the charger over night. if it fixes it, it was your battery.
I noticed I got less and less time out of my battery. At first it was like 2-3 months before it would do this... then it was a few weeks, then a few days. Finally it would happen every time I started the car - it was the battery slowly dying and holding less and less of a charge. When they took off the battery box, there was white crusty battery goo everywhere.