For AI -- you want an Nvidia GPU, and an RTX GPU specifically. VRAM is more important than clock speed for AI, which makes the Nividia 3060 with 12 GB VRAM which you'll get for about $280. You'll want a PC with a good power supply and cooling system. Stable Diffusion workloads are quite different to gaming -- they spin up and stay hot so long as the job is running.
Your other choice would be a rent time on a cloud server -- eg renting a GPU instance from a cloud service provide for something like $2 an hour. Services like RunDiffusion and ThinkDiffusion which permit NSFW use . . . may be a good alternative to buying a machine.
Also note with Nvidia's Blackwell becoming available, it does look like there may be some attractive new GPU choices from NVidia.
(Yes, if you _really_ know what you're doing, it is possible to work with some AMD GPUs, but I don't recommend it. You don't save much money, you get much less support . . . so not really a bargain. If you're going to buy, buy the best supported GPU, which is Nvidia RTX