Shrimp are a good indicator of water quality. They are very sensitive to the copper found in most micro-nutrient fertilizers. Also very sensitive to nitrates and ammonia.
I had bad experiences with A LOT of the shrimp i had when i first got into keeping them.
Make sure you are doing you are changing at least 30-40% of your water weekly. The amount of water that you need to change goes up as the size of the tank goes down. Ask the guys at your local fish store about your tap water, and see if you need to be treating it before adding it to your tank. In my town, I don't really have to. If you have the money, RO (reverse osmosis) water is the best to use.
What kind of shrimp did you have, what kind of filter do you have, what substrate do you have, and is there a heater, and if so, at what temperature do you have your tank at?
I'm going to take a stab and say you probably had ghost shrimp, and they need 68-85° F, KH 3-10, pH 6.5-8.0. KH is carbonate hardness.
Betta splendens need 75-86° F, KH 0-25, pH 6.0-8.0.
Another note: Some male bettas can live peacefully with shrimp, especially if there is enough cover. Others are total jerks. Shrimp can be stressed to death, and really do the best in a shrimp only tank.
Also, bettas are native to stagnant water, while Shrimp enjoy a slight current, so maybe the divider would b a good way to set a region with water movement, and a still area.
If you want your shrimp to do well, provide several densely planted areas, which is, I guess, why we're here.
Also, float the shrimp for twice as long, and add some of the aquariums water to the bag after the first 20 minutes, and incrementally until you release them.