As it happens I’ve read an alternative explanation of guilty behavior in dogs, which is that the dog is reacting not to a memory of having committed a misdeed, but to the presence of some situation (i.e. the aftermath of the misdeed) that the dog knows makes you upset, and that the dog would be acting equally guilty regardless of whether this aftermath was the product of the dog’s own behavior or not.
As Yvain pointed out in the main post, the same thing also applies to humans.
As Yvain pointed out in the main post, the same thing also applies to humans.