[verb (volitional)] + と思う [verb (volitional)] + と思っている
ようと思う says what you intend to do: "I think I'll", "I'm going to". The verb goes in the volitional form – たべよう食べよう, いこう行こう, しよう – followed by とおもう思う, or とおもいます思います in polite speech.
With the dictionary form, と思う is a guess about what will happen: "I think it will". Only the volitional makes it your own plan.
ようと思う is a decision you are making as you speak. ようと思っている is a plan you have had for a while.
Someone else's plan always takes と思っている, usually with そうだ or らしい, because you can't speak for their decision in the moment.
In the past, ようと思った is something you meant to do, often followed by what stopped you.