Prompt cache key
# support
d
Hello. For my Vapi bots, I use many bots with the same system prompt and then a knowledge base below. I just noticed that prompt cache key is a thing in Vapi. - Do I give all these bots the same prompt cache key to use prompt caching? - Can I just come with a random key and apply this key to all? Or is there a key already? Because the system prompt for all these bots is the same. TIA!
c
Hi douwe26, • Yes — give all assistants that share the exact same system prompt the same prompt cache key to enable caching across them. • You can create any stable, unique string (e.g., a deterministic hash of the prompt or a readable key) and apply it to each assistant; using a random key each time defeats caching. • There is no automatic global key — generate and manage the key yourself (common approach: compute an SHA256 or UUID derived from the prompt text). Relevant guidance: see the Prompting Guide for prompt best practices: https://docs.vapi.ai/prompting-guide