الْهَمْزَةُ لِطَلَبِ التَّصَوُّرِ أَوِ التَّصْدِيقِ
Interrogative hamzah may request conception or assent.
أَزَيْدٌ فِي الْمَكْتَبِ أَمْ عَمْرٌو؟
Is Zayd in the office, or is it ʿAmr?
This seeks to identify the person present, presupposing that one of them is in the office.
أَزَيْدٌ فِي الْمَكْتَبِ؟
Is Zayd in the office?
This asks whether his being there is true at all. We therefore cannot classify every occurrence of hamzah identically: the alternative introduced by am and the context matter.