Limiting exports of AI services to all foreigners is probably allowed under GATS, since there's no favoring one county over another. But even then there's a national security exemption, which fits reasonably well with US arguments here.
If a country thought the AI export restrictions were inconsistent with treaty the remedy is challenging them, not unilaterally imposing their own tariffs. But even if they got a favorable panel decision the US would speak, and the Appellate Body is non-functional because the US stopped consenting to the addition of new members and all the terms expired. Which means anything that gets appealed is frozen indefinitely waiting for the AB to reach a quorum that won't come until the US changes is mind (and Biden didn't reverse Trump's decision here).