I received seeds from various produces as a gift. They are in sealed paper bags, but they occupy a lot of space and I was thinking about opening the bags and putting the seeds into small transparent plastic containers. Is this a good way to store and not compromise them? If not, what is the preferred alternative?
Things that are bad for seeds in storage are:
If the plastic containers are airtight and you are going to store them in a cool, dark, dry place, then it should be ok.
The best thing to do would be to ensure that they are thoroughly dry first -- you can use a desiccant like silica gel in the container. But if you plan to use the seeds soon, and they were properly dried before they were given to you, and the bags they are in haven't gotten damp/humid, then you may be ok.
Keeping them in the paper bags lets you be able to write the name/variety of them on the bag.
Long term storage of most vegetable and grains seeds would be to put them into a cool and dry environment. And longer storage happens when oxygen is removed from the container. This is why grains for long term storage will have air replaced with pure nitrogen.
In addition to what bstpierre said, I would add that seeds are sometimes also vulnerable to insects and mice.
We had a mouse last winter, which feasted day by day on piles of muskmelon seeds that had fallen from my seed-drying station. Mice can climb, but this one wasn't desperate enough to do so (I guess I fed it pretty well). We caught the mouse, eventually, but that made me realize more that seeds can be vulnerable to mice.
Also, weevils and other critters can sometimes have eggs on seeds that may hatch. They may or may not damage the seeds. I got some squash seeds from someone, one time, and after a while, little critters started hatching all over them. I added some food grade diatomaceous earth, and I didn't see any new ones after that. Weevils are known to infest grains.
Milk thistle plants (Silybum marianum) attract weevils, as I've seen in my garden (I don't know if they lay eggs in the seeds, but I see weevils on the plants when they get to a certain age); so, if you grow milk thistle, you may want to protect the seeds with food grade diatomaceous earth.
Food grade diatomaceous earth can look a little messy on vegetable seeds (and I've only rarely used it on vegetable seeds), but you don't need to add a noticeable amount for grain storage (so maybe I added too much to my squash seeds). Don't use it on hot pepper seeds, though: That's a great way to make coughing powder (mix DE with dry hot chile seeds)—i.e. powder that makes anyone near it cough (without exactly knowing why they're coughing, necessarily), and you don't want to inhale it anyway (but it doesn't have to noticeably get in the air to make people cough).
Food grade diatomaceous earth helps to keep seeds dry, too. It's mostly silica—bstpierre already mentioned silica gel packets.
I personally store my seeds in those little plastic zipper bags (bead bags), or in empty herbal tea bags (I dry them in those on top of brown paper bags in a room, ideally warm, with a fan going; the fan is more important than the temperature). The empty herbal tea bags (you can buy them empty), dry easily, and seem to wick moisture away. Brown paper bags themselves are great for drying seeds, but I use the herbal tea bags so I don't have to bag them after they're dry (I just have to put them away—and only rebag them once I open them).
I keep my bagged seeds inside cheap foam coolers to prevent fluctuations in temperature and humidity. Temperature fluctuations are supposed to be bad for seed storage. Ideally, I'd put a pouch of food grade diatomaceous earth, or some silica gel packets in the coolers to absorb moisture (but I still haven't tried it).
Really, though, I think the most important things you can do are to save/dry them well in the first place, and grow healthy seeds from healthy fruits (although healthy seeds can come from unhealthy fruits, many times, provided they're not infected with a disease or something). I honestly haven't noticed a big problem with storage conditions impacting germination rates when using less-than-ideal conditions. People say they do, and it probably influences things—but, yeah: bad storage conditions aren't necessarily the end of the world, every time.
Some of the best storage conditions seem to be in clay vessels in some caves. I can't exactly say why, but here are some guesses: The clay probably helps the seeds to stay dry. The caves must help to keep them cool. I've heard of squash seeds lasting hundreds of years, that way.
I highly recommend saving seeds regularly, though (just so you don't have to save your seeds for a long time, as often). It's great insurance.
There's debate as to which storage containers are the best when it comes to the convenient ones people usually use. There doesn't seem to be a definite consensus as to whether paper or plastic bags are better. Both are pretty good (though, if you're not sure if they're dry enough, use paper). Of course, something sealed with no oxygen and all like Tangurena mentioned is probably a lot better.