The boss has multiple targets that you can attack, the intention being that a single intelligent rat is controlling the rat horde. At that point in the game you shouldn't have access to AoE attacks, so you have to hit eat target individually until you eventually kill the smart rat.
The puzzle part comes that you initially have no way of knowing if you hit the smart rat, and its position can change every few turns. You're intended to run away from the boss fight and return with a special item that gives you a visual indication when you hit the correct target.