It can be both, based on how the weapon is being used. See for example the Improvised Weapon definition.
But really, the issue is whether Sneak Attack is asking for a weapon Classification, or a weapon Property. It's unclear. The text just says "the attack uses a
Finesse or a
Ranged weapon". It doesn't say weapon Classification ("A weapon is classified as either Melee or Ranged"), nor does it say weapon Property ("A Range weapon has a range in parentheses after the
Ammunition or
Thrown property").
There is a reasonable argument for either interpretation. The only thing I question at this point is why people are so confident of their answer.