Theory about the core-bot:
You know that sweet cutscene at the end of Portal where your camera flies to cake and suddenly red spots appear in the background? Those are cores without personalities, because they're not restricted by personality, they can do whatever they want. Apparently, a core decided to grow gigantic loving arms and grow a portal gun too.