It's fine if you're under 4 or above 74. Any other time, you should talk to your doctor. Unless you're an american, because freedom is when no healthcare.
Talk to your doctor. I've largely managed the symptoms of my IBD under the direction of my gastroenterologist by megadosing on fiber and avoiding FODMAP-containing foods.