Magic fill turns a sentence into an entry. Say "3h design for Acme yesterday" and it should fill in the duration, the day, the project and the task.
It was only ever shown your project names, never your client names. So when you named the company — which is how most people describe their work — it had nothing to match against. The hours, the task and the notes filled in correctly and the project was left on whatever was already there.
Where the same project name appears under more than one client, which is normal for a "Retainer" or a "Monthly", it was worse than not matching: there was no way to tell those projects apart, so one was chosen and the entry landed on the wrong company while everything else about it looked right.
It now matches on the client name as well as the project name. Naming the project still wins where both would fit, since that is the more specific thing to have said.
Worth a glance at recent entries if you use Magic fill on projects that share a name across clients.