The AI is talking to itself because it doesn't really have anyone else to talk to. It's sorta like how people have mental conversations with themselves when they're thinking about and solving some problem.
My mental back-and-forths usually end with "Ok, let's do this" or "NOPE, I'm not touching...