This commit updates the GenerateContentRequest struct in the Google AI module
to include an optional cached_content field. This allows for the use of
previously cached content in subsequent requests, potentially improving
response times and maintaining context across multiple interactions.
The changes are propagated through the assistant and collab crates to ensure
that the cached content can be passed from the user interface down to the
API request level.
Changes:
- Added cached_content field to GenerateContentRequest in google_ai.rs
- Updated LanguageModelRequest struct in assistant.rs to include cached_contents
- Modified relevant functions in assistant_panel.rs, completion_provider/cloud.rs,
inline_assistant.rs, and prompt_library.rs to accommodate the new field
- Updated language_model_request_to_google_ai function in collab/ai.rs to
pass cached content to the Google AI request
- Added cached_contents field to CompleteWithLanguageModel message in zed.proto