Microsoft added a PluralizationService
base abstract class to the .NET framework - which can be used for other purposes as well!
public abstract class PluralizationService
{
public static PluralizationService CreateService(CultureInfo culture);
public abstract string Pluralize(string word);
public abstract string Singularize(string word);
}
See a great blog post on EF Pluralization which explains it in great detail. Microsoft provides a few concrete implementations of that service in various languages / cultures, but you're totally free to roll your own.
I don't know for a fact how the EF4 provided pluralization services work - but most likely it's a combination of certain linguistic rules, and a plethora of exceptions to handle differently. Those are most likely stored as resources or in some other way inside the relevant assemblies.