In a Layman’s language they're the same but they have so many difference.It depends on the extent of use. Both are used for doing automation via ssh. Ansible has prebuilt modules for doing things reliably and has many ideas about the structure which can be utilized.
If you want to do simple things for a small number of hosts, and you don't know Ansible, you might be happier with SSH publishers. If you want to configure lots of hosts, lots of deployments, etc., you should probably use Ansible.