Polymorph Blade

From Lost Laboratory of Kwalish, page 56.

Description
Weapon (any sword), very rare (requires attunement).

When you attack a creature with this magic weapon and roll a 20 on the attack roll, the creature must make a DC 15 Wisdom saving throw in addition to suffering the attack's normal effects. On a failed save, the creature also suffers the effects of a Polymorph spell. Roll a d20 and consult the following table to determine the form the target creature is transformed into.

A creature is immune to this effect if it is immune to damage of the weapon's type, is a shapechanger, or has legendary actions.

Curse. This weapon is cursed, and becoming attuned to it extends the curse to you. Until the curse is broken with a Remove Curse spell or similar magic, you are unwilling to part with the weapon. Whenever you attack a creature with this weapon and roll a 1 on the attack roll, you suffer the effect of a Polymorph spell for 1 hour, rolling on the table to determine your new form.