It is not expected of cars that they carefully follow laws and avoid harm when left unsupervised, yet that is expected of AI agents, because the whole idea of the latter is to have, well, agency.
And even when a functional agent is a human being who is also a moral agent in their own right, the law has always held the principal liable for acts taken on their behalf by an agent who has been equipped by the principal to take that action. This goes even more for "agents" that are still just software running on a computer, and not moral agents in their own right.