https://www.boundaryml.com logo
🟡 Does Baml support prompt caching for Bedrock cl...
# questions
m
I probably missed it but does Baml currently support prompt caching for Bedrock clients? If so where can I find an example? thanks!
v
let me check! bedrock is sadly one where passthrough requests are hard to do
given how they expose this, its currently not possible directly in BAML: Bedrock requires a new message type
cachePoint
and we're still designing how we want arbitrary message types to work here! That said you can leverage the modular API to make this possible which will give you the raw web request you can make https://cdn.discordapp.com/attachments/1420442634991964230/1420445479216615587/Screenshot_2025-09-24_at_9.22.17_AM.png?ex=68d56c70&is=68d41af0&hm=d20454abe2da721a6c6b45efcfb058e07819d37185ba2e3b8861a76d380b29c0&
m
Thanks, that's super helpful - do you have a rough timeline in mind for custom message types?
Hi again, could it be the modular API is not supported for bedrock clients? Seeing this atm ERROR/MainProcess] Error in execute_task: Prompt exposure for AWS client is not supported
b
Sorry for the slow response - unfortunately yes, we haven't implemented this yet. No current timeline on exposing this, but we definitely want to. The official AWS SDK unfortunately doesn't give us access to the actual HTTP requests, which is what we usually expose in the modular API 🙁
r
@milomoerkerke_36397 I upgraded to 0.210.0 and this function now works.
v
Yep! Thanks to @greg (BAML) !! 🙂
m
Already in prod :)) thanks both!!!