echolabsdev / prism

A unified interface for working with LLMs in Laravel
https://prism.echolabs.dev
MIT License
405 stars 20 forks source link

Would setting a default model be helpful from the config? #18

Closed peterramsing closed 3 hours ago

peterramsing commented 11 hours ago

Would it be helpful to have default model in the config:

'openai' => [
    'driver' => 'openai',
    'url' => env('OPENAI_URL', 'https://api.openai.com/v1'),
    'api_key' => env('OPENAI_API_KEY'),
    'default_model' => 'gpt-4o-mini-2024-07-18' #default
],

In addition, one thing that I do when working on packages for clients is that I will enforce a pinned version (so no usage of latest or 4o-mini without the pin so that they don't see changes in their app over time as the models move. I could see there being a strict mode that could be configured.

'openai' => [
    'driver' => 'openai',
    'url' => env('OPENAI_URL', 'https://api.openai.com/v1'),
    'api_key' => env('OPENAI_API_KEY'),
    'strict' => true #whether to allow non-pinned models
],
sixlive commented 3 hours ago

Interesting idea, going to pass on it for now though.