how does the netmask let us distinguish two IP addresses?
It doesn't. I lets us or a device distinguish the scope of the network to which it is attached.
I don't see how these are two different addresses just because you added a more specific "sub group" to one. They are (or seem to be) the same IP address!
They are the same address. It is the scope of what you are referring to that has changed. Generally speaking, when you see a /32 referenced, you are referring to a single host. When you use a smaller netmask, such as the /8 in your example, you are defining the size of the (sub)network to which that host is attached.
While you are reading the IP address in a dotted decimal format, the address used by computers/network devices is in binary. It is a string of 32 binary 1's and 0's. The mask just differentiates what part of that 32 character binary string is used to designate the network and which part can be used to designate hosts.
Adding to my general statement above, when you are referring to a network and not a specific host, the host bits of the address are all set to 0. If one or more of the host bits are set to 1, then this typically indicates a specific host within the network of the designated size. So when you included 25.47.130.1/8 above, this would tend to indicate a specific host in the /8 network of 25.0.0.0/8.
Both addresses are exactly the same. They both refer to the same house. It's irrelevant that in one of the "masks" you narrowed it down to the smaller sub-location.
Extending your example, which takes this out of networking. Yes, they are both the same house, but that doesn't make the mask "irrelevant." This is actually a very important piece of information for Bob.
Bob is identified by a numerical value (25.47.130.1/32) lives in a town (represented as 25.47.130.0/24). Bob has an old fashioned post office with separate mail boxes, one box for local mail (i.e. someone else in town) and one for all other mail.
This way local mail can be delivered more directly to the destination (making delivery faster and better for the environment). Mail that goes in the all other mail box gets sent to a regional sorting/handling post office before it is sent along it's way to the destination.
Bob has two letters to send, one to 25.47.130.2 and one to 35.57.140.2. Bob, who knows his town is 25.47.130.0/24, determines that the letter to 25.47.130.2 is local and puts it in the local box. However 35.57.140.2 is not in his town, so puts it in the all other mail box.
You could even extend this further and say that Bob knows his town is located in a state (25.47.0.0/16) and that state is part of a larger country (25.0.0.0/8). Bob now knows that his letter to 35.57.140.2 is out of state and out of country (which may have additional requirements, like additional postage).
However, typically most network end points (Bobs) simply wouldn't need to know or care about anything more than if the traffic (mail) is local or not. In other words, is the traffic sent directly to a local destination or is it handed off to another device to route it to the proper destination.