From my observations of ants I'm convinced that they groom as "excitement regulation."
Grooming seems to calm them down and if they can complete grooming without anything else scary happening it's a pretty good sign that the danger has passed and it's OK to stop biting everything.
I've seen two dozen ants all grooming simultaneously after opening then closing the lid to their terrarium (which causes them to panic and start biting everything that isn't a sister)