You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
then my application code could simply become Instructor.chat_completion(messages: [...] and I can switch to a different provider by only changing :adapter.
If @thmsmlr you are aligned with this approach, I can send a pull request.
The text was updated successfully, but these errors were encountered:
On the one hand, I totally see your point. It would be nice to set a default params as part of the config, where you could default the mode, the model, really any set of parameters.
However, in practice, when you're switching between different models, you often have to tweak your prompts as well. And so while I think superficially it's useful, in practice it won't yield the results you actually want.
My recommendation is to just create a wrapper function for the time being. When more concrete use cases arise, maybe we can revisit.
Right now, there is an asymmetry between params and config in
Instructor.chat_completion
, which makes it harder to switch between different providers.For example, if I need to send a message to Claude, ChatGPT, and Gemini, respectively, I would need to use slightly different code:
Ideally, I would just set these parameters (including even the default model) in my
config.exs
:then my application code could simply become
Instructor.chat_completion(messages: [...]
and I can switch to a different provider by only changing:adapter
.If @thmsmlr you are aligned with this approach, I can send a pull request.
The text was updated successfully, but these errors were encountered: