We could flag team A the first time when it happens but team B would get a stern warning to modify their calls since the rules give team A a 100% right to offensive starting signals that are not interfered with by B, otherwise the 2nd time the same thing happens, the flag goes to B.
I think this gets into a grey area - we're being asked to interpret intent of signals. If the defence is pondering a blitz, and the middle linebacker, up on the d-line, turns around calls it off with "cancel," at the last minute, before backing away do we flag them if the offence flinches for an obvious change of defensive set?
What if there's a safety blitz planned in addition to a blitz package, and the middle linebacker opts to call that off with a code-word, "blue! blue!" but doesn't turn in the safety's direction, and the offence flinches? Is the defence not allowed some measure of communication as well? Why would we penalize the defence for the same rights we grant the offence?
What if the offence sends out a bunch formation right, and the linebacker calls out "roger, roger!" to call for a defence against a strong-right formation? If the offence flinches, is that a penalty?
Now, if the defence is yelling "hut! Hut" or some other sound that simulates the offensive cadence here, sure. But the above three examples are pretty darn common, I'd think.
Your "shift" situation seems greyer. I would like to know if this was done the week before. In the same vein, it has the potential to be more legal than not, but if concocted to screw up the offence, clearly otherwise.
<devil's advocate>
Defensive communication ought not to be silenced just because the offence is doing something odd, like a first-sound snap. Heck, the solution here is simple, really: the offence shifts to a "standard" cadence to avoid the procedure infractions.
</devil's advocate>
And just for giggles:
What if the offence calls out an option play at the LOS, with the quarterback calling out "hamburger! hamburger!" and the tight end confirming with the counter-phrase "cheeseburger!" On the fifth or sixth time they do this, the defensive end pipes up with "Large fries!" (This actually happened in a game last week, fwiw. Everybody cackled, no coaches went ballistic, and the game continued as normal.)