After spending years perfecting a score, in a matter of weeks, the score was torn apart and rebuilt from the ground up by Lucas and company for the battle for Naboo.
What once was a magnificent battle sequence, perhaps THE best battle sequence score he's composed, became nothing more than a hodge podge of snippets.
Why? Because he composed the music for the scene, then they edited it. He went back and rescored it. They re-edited it... he finally was unable to contribue any further, and they edited it however the frak they wanted, and simply pillaged his score.
Williams is said to have felt betrayed and artistically ignored by this.
Then you get Episode II. From composing Nearly 4 CD's worth of music for Episode I, he composed about one CD worth of music.
There was so much not finished with the film when he saw it that he and Lucas actually decided against scoring anymore, and he simply let them take from Episode I what they wanted and put it in the film.
After this, Williams seemingly had a talk with Lucas and said "Look, if you want me to score the films, we have to make a change here."
So, for episode III, they did things a lot different.
Williams composed nearly 3 cd's worth of music (as normal) and the music tracked into Episode III for the most part was pre-decided upon.
Everything except for a couple scenes like "Prophesy Misread" and "Plot to Destroy the Jedi" had pre-planned tracked music.
The rest were just small edits to the score.