What signs did the fish exhibit before they passed? And is there anything odd you notice about your fish currently, other than shyness? Since you mentioned two of your fish rapidly declined in health before dying, I think it would be best to investigate potential illnesses too. It's possible that the stress caused by soft water made them more susceptible to illness, but there also could've been underlying issues caused by other factors (temperature, pH, tankmates, etc.) For example, it's possible your fish were already sick even before you bought them, or that it was the stress of the fish-in cycle rather than water hardness.
I agree with your decision to swap them out for soft-water fish—it's always easier to keep fish that match up with your native water parameters—but when you go to the store, spend a good long while looking at the fish before you buy them. Don't be embarrassed to stand in front of the tank for 5-10 minutes. And don't be embarrassed to ask for a specific individual fish (as long as there aren't many individuals in the tank). Once the worker nets out some fish into a bag, you can inspect them closer and potentially ask them to swap out a fish or two.
Things to look out for include:
-Unusual behavior (swimming erratically, gasping, sitting at the surface, etc.)
-Flashing (when a fish quickly darts through the water and/or flicks itself against the glass or decor to scratch itself)
-Pale coloration
-Body condition (is the fish very thin?)
-Deformities (curved spines, mainly)
-Signs of external illness (cloudy and/or protruding eyes, white patches, fluffy patches, small white spots, red lesions, ragged fins, etc)
-Dead fish in the tank
If I see any unusual behavior, signs of illness in any fish in a store tank, or any dead fish, I do not buy fish from that tank even if the other fish appear healthy. Ask the store whether their tanks are connected via their water system. If the tanks all share a water system, then illness in one tank means illness in the other tanks and I won't buy any livestock in the store. A good LFS will have a quarantine period of at least a few days, ideally a week or more, and will conduct said quarantine in tanks behind the scenes (or will at least mark display tanks that are under quarantine), treating the fish if necessary before putting them up for sale.