I suggest the addition of a new module : the ship module. This module would serve as a replacement for faction modules on turrets and AI controlled ships docked on your ship, even leading to drone controlled by drone ships. It would also serve a a naming module for ships, allowing you to rename your ship, turret and whatnot. Any ship equiped with a ship module will consider their docking ship as their home/base and will try to dock to it if possible; they will also be considered the same faction as their controlling ship.
Ships using the same name could use the same AI and be undocked as a group.
Ships using the same name could use the same AI and be undocked as a group.