Welcome to Portkey Forum

Updated 12 months ago

Default cache duration

Default is 7 days.
Where are you trying the cache_status parameter?
d
a
7 comments
using with llama index, but its not working @ayush-portkey
Possible to share your code snippet?
Plain Text
portkey_client = Portkey(
    mode="single",
    api_key=PORTKEY_API_KEY
)
portkey_client.add_llms(pk.LLMOptions(provider="openai", model="gpt-4-1106-preview", virtual_key="xyz", cache_status="simple", cache_age=6000))
service_context = ServiceContext.from_defaults(llm=portkey_client, embed_model=OpenAIEmbedding(model="text-embedding-ada-002"))
set_global_service_context(service_context)
We have figured the issue @deepanshu_11, cache config is getting dropped in this case. Fixing it asap.
Thanks for reporting.
Hello @ayush-portkey thanks for taking this up! Any updates on this?
Add a reply
Sign up and join the conversation on Discord