Factory provider

See #102 for more information.

I think that is ready to merge after someone gives it a good look.

I will improve the wiki page after this is merged.