Took a deeper look into the PlanetArtDefs, I think you could remove the planets with not traits. But, it will take alot of the randomness out of galaxy generation. Will require you to remove or add a trait to the GenericWorld Art defines. I do not believe the schema will allow you to add more than one trait to a single art define to keep the randomness in there.
Oh, I see what you mean... giving a trait the same name as the generic art defines... I don't know that that will work, because I suspect that the random generator picks a planet, decides if it will have a trait (random chance based supposedly on a percentage), THEN accesses the appropriate PlanetArt. If it were otherwise then the relative abundance percentages would be a field in the PlanetArtDef, not the PlanetTraitDef. I might be wrong, though.
I'm pretty sure if you take the GenericWorld PlanetArtDefs out it will crash, but I haven't tried it. I was just trying to set the % of planets with traits to 100%. If that doesn't do the job, it seems to me that part of the game is dysfunctional (not 'broken' because it does not effect game play). I was hoping that the Red Phantom Planet would lead to the secret of why planets without traits keep sneaking through, but it looks like it won't. Boo!
I don't think it would take randomness out of the galaxy generation routine to remove the generics if you add a lot of planet traits with their own varied PlanetArts. There are only a handful of GenericWorlds: replacing each one with a trait (so, what 5-6 new traits) will effectively maintain the visual diversity of worlds in the game. Frankly, having half the world in the game with a red moon isn't very diverse at all. Further, the planet traits are designed to allow for more visual diversity than is actually there (since most fields can have multiple options), so simply making PlanetArtDefs more varied could also preserve diversity.
And no, you are right, there has to be a one-to-one correspondence between PlanetArts and PlanetTraits. I don't see how that would be a problem. You could have a trait Generic World1-5, a trait GenericWorld6-10, etc. I guess I don't see a problem.
Thanks again! It is really great to get all this information from someone who has been there already. I will be sure to put a thank-you in the mod!