I think George intended the prequels to deal with the theme of Jedi being a flawed organisation, but it’s only occasionally made clear or done well. I think he wanted to show that the Jedi were corrupted by war and betrayed their own principles, which was a factor in Anakin’s turn to evil. The biggest example of this I can think of is when. Mace Windu says of Palpatine, “He’s too dangerous to be left alive!” echoing the line spoken by Palpatine himself earlier in the film: “He was too dangerous to be kept alive…” I think that’s the point where Anakin begins to see truth in Palpatine’s assertion that the Jedi are very similar to the Sith.
This whole theme was mostly just hinted or grasped at in the prequels, but yeah, I think it was much better explored in The Clone Wars and other novels and comics.
Not entirely relevant to the question, but this reminds me of this quote from Rebels.
“Thousands of Jedi once there were. Then came war. In our arrogance, join the conflict, swiftly, we did. Fear, anger, hate… consumed by the dark side the Jedi were.” - Yoda