Yeah, I totally get what you are saying. First, I would see where those two interests cross and maybe you could stand out as a hybrid web dev and AI guy. If you really need to choose one skill, test both of them out on a small scale and see which one grabs your interest more.
Testing out multiple skills isn’t bad. The issue is when you get into large side projects and career decisions before you have validated your interest in the skill.