Hey, I've been looking around but was wondering if there was an integration with BAML such that it handles the explicit context caching that gemini supports, per
https://ai.google.dev/gemini-api/docs/caching#explicit-caching
I know anthropic is supported with the
cache_control
blocks, but I didn't see anything in the docs for gemini.
yea sadly gemini caching is very funky!
the more turing complete version of BAML allows for such things, but we're rolling that out very slowly to a small batch at at time!
Vaibhav (BAML 🐑)
05/22/2026, 6:12 PM
the best way if you want to do do this today is to use the modular api