Change tool's prompt format

#23
by BDuart - opened

Hi, Thanks for providing this model!

I am exploring this model within some Langchain agents.
The Langchain implementation requires me to use a json blob like this to execute a tool:

Action:

{{{{
  "action": $TOOL_NAME,
  "action_input": $INPUT
}}}}

However, Command R+ always uses something like this:

Action: ```json
[
{
"tool_name": "internet_search",
"parameters": {
"query": "biggest penguin in the world"
}
}
]


Although I am trying to force the nem prompt format, the Command R+ does not respect it. For example, Llama2 70B or Mistral 8x7B respected it and adapted to the json blob I wanted. 
I can change the Langchain code, but I wanted to avoid that, in order to maintain the same code for all the models I test. 
How can I force Command R+ model to use the tool's prompt format that I want?

Sign up or log in to comment