ah of course A factory is a upgrade componite for starbases.
It allows an inventory of iteams while players are docked on you.
It also regenerates your armour when damaged. it has quite a bit of volume to it so it may interfear with other upgrades.
thats just about the jist of it
Pretty much what Harpor said, it also allows NPCs to spawn on you when npcs die, which is good if you are lacking NPCs due to having a destroyed starbase at the time. You can regenerate your ship faster, including your armor, and others that dock onto you can repair/regenerate as well, including swapping there weapons.
It's more or less a good thing to have when attacking with a group and having a starbase as a support ship. I'll probably be making it more fancy though in the future.