Presumably, the building company would be the owners for all the empty apartments which would make it easy to find and tax. It would be more difficult to detect someone buying a home/apartment as an "investment".
For example, obviously a smoke alarm is something that takes 15 minutes to install, so that wouldn't be when you start the clock.
You might be able to base it on when any single unit is sold in the block. That is "You sell 1 apartment, you've got a year to sell to rest or you are going to start seeing vacancy taxes".
That isn't the reason rent is high in SF.
See ‘homestead exemption’. Other states use this term, but it means different things.
WV, for instance, only allows the exemption for people above a certain age.