We were including the context at the end which meant it never got
cached. We'll now include it with the first message that introduced it
so it's cached as long as it doesn't change.
This is an improvement, but we probably still need to think of ways to
optimize caching for cases where files in context change.
Release Notes:
- N/A
This PR removes an unneeded `else if` branch that was the same as the
previous branch in the conditional.
Doesn't seem necessary to run this twice.
Release Notes:
- N/A
This PR makes it so if we receive a tool use from the model without any
corresponding text, we'll insert some placeholder text to keep the
conversation in a well-structured format.
This aims to fix an error that Antonio was seeing:

Release Notes:
- N/A