My Sand Soldier has Shady Spectacles equipped and is a copy of Azir, Ascendent. What happens if I activate the copied Azir’s activated ability before detaching the Shady Spectacles and then attach them to the same Sand Soldier as a copy of the same Azir, Ascendent? Can I use the activated ability again?
You can.
Each instance of the copied ability is a different ability. The game object remains the same throughout this whole process, so any temporary modifications will remain on the Sand Soldier as it transforms, but the copied rules text is an entirely new instance of the ability. It is the same idea as Svellsongur’s copy of an ability being “refreshed” if Svellsongur is detached and then reattached to the same unit.