a1wonder
Fishaholic
What you see though little betta in cups at stores is temporly housing the fish usually fly off the shelves and at the very very most spend a week in them. I'd get at last a 2 gal tank for your little betta so that he can be comfortable I have mine in an overside glass cookie jar (the kind you buy at walmart) he seems very comfortable and has enough room to swim and move around. Once you get rid of thoughs loches though you'll have room enough to fix up your school. You listed a few species of schooling type fish I'd always put them in a group of at least 6. Once you've fixed that up you've got yourself a really nice tank! 
I couple of response female betta need to be keep like tiger barbs IMO in larger groups of at least four that way aggression is evenly distubted throughout the tank.
Khuli loaches do not clean sand. Trust me I have three and they just play in and hid all day. Corries are the only ones that might do a bit of cleaning but like all scavengers in a tank enviroment they also need to get feed extra on the side.
Algae is cause typicall by two much light (green algae) or not enough light (brown algae) as long as you don't leave your light on for more than 8 hours a day and no less than 6 hours a day you'll be fine
I couple of response female betta need to be keep like tiger barbs IMO in larger groups of at least four that way aggression is evenly distubted throughout the tank.
Khuli loaches do not clean sand. Trust me I have three and they just play in and hid all day. Corries are the only ones that might do a bit of cleaning but like all scavengers in a tank enviroment they also need to get feed extra on the side.
Algae is cause typicall by two much light (green algae) or not enough light (brown algae) as long as you don't leave your light on for more than 8 hours a day and no less than 6 hours a day you'll be fine