Welcome to Portkey Forum

Updated 4 weeks ago

Ability to choose models for prompt templates based on api key

Could be an edge case, but the ability to choose models for prompt templates based on which API key is used. ie. I have 3 keys (dev, staging and prod). In staging I want to use llama 8b to save money while in prod I want 70b. Right now I need to implement this logic in my backend, but I could see value for something like dynamic model choice based on X (not necessarily API key but could be anything like user ID or something like that?)
S
M
4 comments
Yes, this would be cool, currently you can also route your requests conditionally by using the metadata.

You might find this useful:
https://portkey.ai/docs/product/ai-gateway/conditional-routing
Yeah this is my current workflow but thinking it could be nice as a UI feature too
I mostly use templates, and this feature doesnt seem to be there for templates so I end up having to make the same templates with different models which is a bit of a pain
Thankyou @MolBioBoy , we'll keep this in mind when we plan for this feature!!
Add a reply
Sign up and join the conversation on Discord