Generalization is a process in psychology that falls within operant and classical conditioning. It’s when a conditioned response occurs after a similar conditioned stimulus (but not the exact one) occurs.
Think of a dog trained to bark on command. The owner would usually say “speak” (the conditioned stimulus) and the dog would bark as a conditioned response. But if the owner randomly said “peak” or “week” or “leak” in a conversation, and the dog barked, this would be an example of generalization in psychology. A response to commands that are similar but not the same.