-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: Vertex AI Gemini Structured JSON caching not working #9692
Labels
bug
Something isn't working
Comments
4 tasks
adrianlyjak
added a commit
to adrianlyjak/litellm
that referenced
this issue
Apr 2, 2025
A) Return a copy from strict key removal to not break cache keys B) Fix issue in existing cache key stabilizer that was not storing a stable key across request/response if no litellm_params existed in the request
adrianlyjak
added a commit
to adrianlyjak/litellm
that referenced
this issue
Apr 2, 2025
A) Return a copy from strict key removal to not break cache keys B) Fix issue in existing cache key stabilizer that was not storing a stable key across request/response if no litellm_params existed in the request
adrianlyjak
added a commit
to adrianlyjak/litellm
that referenced
this issue
Apr 2, 2025
A) Return a copy from strict key removal to not break cache keys B) Fix issue in existing cache key stabilizer that was not storing a stable key across request/response if no litellm_params existed in the request
adrianlyjak
added a commit
to adrianlyjak/litellm
that referenced
this issue
Apr 2, 2025
A) Return a copy from strict key removal to not break cache keys B) Fix issue in existing cache key stabilizer that was not storing a stable key across request/response if no litellm_params existed in the request
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What happened?
I noticed that vertex gemini calls are no longer being cached after upgrading.
I believe I tracked down the issue to the removal of a
strict: True
in response schema, breaking the cachehttps://github.com/BerriAI/litellm/blob/655ce2e7451fa81f1da53279bf29a20248fb3d5c/litellm/llms/vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py#L246C1-L246C50
Logging out the cache key calculation, this is what I see:
That's from adding this here
litellm/litellm/caching/caching.py
Line 264 in 655ce2e
and this here
litellm/litellm/caching/caching.py
Line 501 in 655ce2e
and this here:
litellm/litellm/caching/caching.py
Line 579 in 655ce2e
Relevant log output
Are you a ML Ops Team?
No
What LiteLLM version are you on ?
1.65.0
Twitter / LinkedIn details
https://x.com/rnges_us
The text was updated successfully, but these errors were encountered: