Can I reference a Sprite's number or name?

Just use 2 parentheses around the variable name.

script variables ((a)) @addInput
script variables ((a)) @addInput

You can learn more about snapblocks at https://snap-blocks.github.io/docs/syntax or How to write snapblocks