My dogs always knew who is family. Kingo for example was very serious towards people outside the family, even those comming back often. Family was always family. No matter how many months passed. He knew my grandparents good and even when seeing them once a year they could easily come to us and he would let them in. Same with my aunt and uncle or my sister or mom.
I recall also one of memories of Pari. She was 4 maybe 5 months old. A friends of my dad was teasing her through the fence and made her upset. Asked to stop laughed as this was just puppy. Months passed, Pari grow up and wasn’t a cute puppy anymore. It happened there was some small party at our house, many guests, people with children, out dogs. All was chill until this one friend teasing Pari years ago showed up, she came to greet him like everybody and half the wag of her tail she froze looked him in the eyes… and well gladly I was faster. All the time she was watching him and keeping an eye on him. If he tried to move from his sit she would slowly start going towards him looking straight into his eyes. All the time lots of other people and kids around. But she remembered and showed him precisely she’s bit a pupp anymore and who is in charge
Saying this. Do not abuse your dogs or dogs in your family. Growling puppy, shaking nervously from teasing might look adorable (questionable if it really is adorable). But doing it in wrong way or by those that going to be weaker than the dog when it grows up (children or people with to soft character) can bring up some quite serious problems later. I’d hate to buy puppy from breeder that do some stupid things to pupps thinking it shows character. It doesn’t