Swarms of ants in their reproductive stage often make an appearance in July.
Some ants, both males and females, or queens, have wings at mating time, and July is a time when several species would be flying.
Termites would be more likely to swarm in spring or fall.
As for what they wanted, inspect the air-conditioner for excess moisture, which might attract them.
If they were termites, they would probably not attack the piano, but might seek out structural wood, roofing materials, or anything else with cellulose in it, including books and paper.
Termites have been found even in the top floors of tall steel and concrete buildings where there was a moisture problem and spaces and cracks in the structure that allowed them to penetrate.