The good news is that those little critters are totally harmless to your fish. They are a type of planaria and are simply feeding on excess waste in the tank. The bad news is the reason they are thriving in your tank is that you've been overfeeding. Medications and chemicals have little effect on planaria. Planaria freaked me out too the first time I saw them in an overfed guppy tank many years ago. They survived even a bleach treatment on the whole tank (I took the fish out first of course). Planaria have to be "starved out". They don't touch your fish so don't worry about that.
The first thing to do is cut back on feeding the fish. Cut back by 50%. The rule of thumb in feeding fish is that whatever food you put in the tank must be totally consumed from all areas of the tank in 2 to 5 minutes. If you feed twice a day, it's 2 minutes. If you feed once a day it's about 5 minutes. The goal is to allow the fish about 5 minutes of actual eating time per day. If there is any food floating around or on the bottom of the tank or on the decorations after that time, you are overfeeding. Even if the fish eat all the food eventually it is just too much for them to digest properly so they produce more waste and eating too much could also make the fish sick.
The one thing you want to try to avoid is cleaning the whole tank out. Your fish will have to suffer through another episode of new tank syndrome if that happens. It's pretty stressful for them and some or all may die. You should be making water changes and vacuuming the gravel now though. Replace 25% of the water right away and vacuum the gravel lightly. Do a 25% water change every week but only vacuum the gravel every 2 to 4 weeks. That schedule is normal for any tank, no matter what kind of fish you have.
You may see more planaria for a little while as they come out of their hiding places to look for more food. They aren't increasing in numbers, just easier to see. They will die off and the fish may even eat some. It's good for your fish to do that. It's natural live food they would seek out under normal circumstances. Since the fish were so well fed, they just didn't care to do that.
There are a couple of other things you may have may want to know about too. You need more female guppies or take two of the males out to make it a more healthy ratio. Males want to breed all the time and will literally breed the females to death if they don't get a break. There really should be a minimum of 2 or 3 females per male. (The females are more plain looking, males have the pretty tails.) I've even seen tanks with males only and they seem to do just fine as long as they aren't overcrowded. There aren't babies to over populate the tank that way too. Just provide plenty of hiding places so they can get a break from each other ocassionally.
Also, the plecostomus will get too big for that little 10 gallon and will begin eating your other fish eventually. The common variety of plecostomus gets a foot long. (yikes!) There are some that stay under 6 inches or so (Clown and Bristlenose) but that is still a bit big for a 10 gallon. The best algae eater for a tank that size is the Otocinclus. They stay under 2 inches and are just very sweet little guys that don't bother the other fish. They may be hard to find but well worth the effort. I would get 2 Otos for a ten gallon. Here is a link to a page about these cute little fellas;
http://www.aqualandpetsplus.com/Catfish ... inclus.htm At Your Service;
Chris Robbins