From Starfleet Commander
The Factory is where droids are produced. When you cannot get enough people to join your Crew, droids do some of the work that humans would otherwise do. While you would still prefer human crew members because they are free and more effective, droids can, at least, fill in while you try to earn more of them.
The time it takes to build any droid is based on the following formula:
|Ore Cost + Crystal Cost
|2500*(1+Factory Level)*2Foundry Level
Cost and Effect
||Build Time %