I'd like to deprecate the create_chat_func in favor of a client argument which could be a function, as in create_chat_func, but could also be an ellmer::Chat object.
This is feasible because we only need to set the system prompt
|
chat <- create_chat_func(system_prompt = system_prompt) |
which is possible using the $set_system_prompt() method.
This does introduce a few new issues:
- If
client is a Chat object, we'll call $clone() to create a new chat.
- Should we remove turns from the
client?
- I think yes: it maintains current behavior.)
- Should we remove additional tools from the
client?
- I think maybe not, that could be an interesting way to extend querychat.
I'd like to deprecate the
create_chat_funcin favor of aclientargument which could be a function, as increate_chat_func, but could also be anellmer::Chatobject.This is feasible because we only need to set the system prompt
querychat/pkg-r/R/querychat.R
Line 226 in e2ced68
which is possible using the
$set_system_prompt()method.This does introduce a few new issues:
clientis aChatobject, we'll call$clone()to create a new chat.client?client?