This is a common question and afraid there is no generally good answer: Food sensitivities in AS are an individual thing beyond the fact that especially refined starches are universally provocative.
And any starch can cause severe symptoms, depending upon time, circumstances, and many undetermined factors.
Let me give a few examples: I received a call from a fellow Spondy in Canada who told me he could eat yams without a [known] problem, but cannot eat "yam soup" without flaring. I replied by explaining that it is not only the FACT of the starch, but also the FORM. I would say that a "natural" starch is really only a little safer than a refined starch, but that is enough to make the difference--SOMETIMES. Turning a big-particle yam into small-particle soup allows more substrate to be "seeded" by our nemesis bacterium, creating greater surface area for geometric multiplication of this germ. More germ can subsequently cross our epithelium and trigger the secondary immune response that causes AS.
Also, some people doing the Low Starch Diet are able to tolerate rice, when it is rather well rinsed in cold water and maybe reheated; it is not as virulent a starch as more water-soluble starches from potatoes, for example (yams have less of this and much more fiber than most other tubers).
And I would suggest that, if a food does not cause symptoms within a day (usually 4-6 hours), it is not a problem, albeit some people believe it "builds up" to eventually cause a flare. What I think really happens is a "food combination" issue wherein we eat something along with this type of starch that slows digestion enough to cause greater multiplication of the germ than normal. Look after Jackie LeTissier's results using Dr. Wm Hay's food combining method; she has remained vegetarian despite her AS by attention to other foods taken at same time as starches (avoid fats and proteins then).
AS can be totally overcome with strict diet alone, but it is not very practical to remain vegetarian (I tried for about 1 year after being vegetarian 22 years that really helped accelerate my disease--along with bad drug choices).
Klebsiella also feeds upon caramel and some other complex chemicals but the "four major poisons" of Professor Ebringer are "bread, cake, pasta, and potatoes."