Skip to content

Commit

Permalink
space nits
Browse files Browse the repository at this point in the history
  • Loading branch information
ochafik committed Oct 28, 2024
1 parent 9a86ea7 commit c88095e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions common/tool-call.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ llama_tool_calls parse_tool_calls(llama_tool_call_style style, const json & tool
case llama_tool_call_style::Hermes2Pro:
return parse_hermes_tool_calls(input);
case llama_tool_call_style::MistralNemo:
return parse_mistral_nemo_tool_calls(input);
return parse_mistral_nemo_tool_calls(input);
default:
throw std::runtime_error("Unsupported tool call style");
}
Expand Down Expand Up @@ -390,7 +390,7 @@ llama_tool_call_handler llama_tool_call_handler_init(
}},
{"required", json::array({"tool_call"})},
};
const auto schema =
const auto schema =
allow_content
? json {
{"anyOf", json::array({
Expand All @@ -412,7 +412,7 @@ llama_tool_call_handler llama_tool_call_handler_init(
});
// TODO: add schema to system prompt.
auto tweaked_messages = add_system(
messages,
messages,
"Respond in JSON format, either with a request to call tools or with a response to the user's request. Here is the schema for all responses:\n\n```json\n" + schema.dump(2) + "\n```");
handler.prompt = tmpl.apply(tweaked_messages, tools, /* add_generation_prompt= */ true);
break;
Expand Down
2 changes: 1 addition & 1 deletion examples/agent/Dockerfile.tools
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@ COPY ./squid/ssl_cert/squidCA.crt /usr/local/share/ca-certificates/squidCA.crt
RUN chmod 644 /usr/local/share/ca-certificates/squidCA.crt && update-ca-certificates

ENTRYPOINT [ "uvicorn" ]
CMD ["tools:app", "--host", "0.0.0.0", "--port", "8088"]
CMD ["tools:app", "--host", "0.0.0.0", "--port", "8088"]

0 comments on commit c88095e

Please sign in to comment.