When doing AI races with the Formula Raceroom US a lot of AI opponents (if not all) pit on the last few laps. If the race is short (12 laps or less at Road America), they start on Alternate tyres. However if the race is longer (13 laps or more at Road America), the AI starts on Primes and pit on the last few laps (including the last lap!) for Alternates. The pit stop lasts about 6 seconds, that's why I'm guessing they pit for tyres. This doesn't seem to be dependant on AI difficulty (I used 102 at Indianapolis and 104 at Road America)
Yeah, I find it challenging to put together an FR-US race where a significant number of AI don't have really dumb pit strategies. I did one at Hungaroring recently where 3 of the top 5 cars pitted going into the final lap. FWIW, 30-35 minutes seems to be working out to be a good race distance to avoid this type of thing.