From 7a070a371173e1c42209bd41500616c5837b7418 Mon Sep 17 00:00:00 2001 From: hananel <hananel.hadad@accenture.com> Date: Thu, 11 Jan 2024 18:47:04 +0200 Subject: [PATCH] unindent the second prompt as well --- semantic_router/route.py | 46 ++++++++++++++++++++-------------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/semantic_router/route.py b/semantic_router/route.py index 6cca7eaf..22898250 100644 --- a/semantic_router/route.py +++ b/semantic_router/route.py @@ -96,29 +96,29 @@ class Route(BaseModel): logger.info("Generating dynamic route...") prompt = f""" - You are tasked to generate a JSON configuration based on the provided - function schema. Please follow the template below, no other tokens allowed: - - <config> - {{ - "name": "<function_name>", - "utterances": [ - "<example_utterance_1>", - "<example_utterance_2>", - "<example_utterance_3>", - "<example_utterance_4>", - "<example_utterance_5>"] - }} - </config> - - Only include the "name" and "utterances" keys in your answer. - The "name" should match the function name and the "utterances" - should comprise a list of 5 example phrases that could be used to invoke - the function. Use real values instead of placeholders. - - Input schema: - {function_schema} - """ +You are tasked to generate a JSON configuration based on the provided +function schema. Please follow the template below, no other tokens allowed: + +<config> +{{ + "name": "<function_name>", + "utterances": [ + "<example_utterance_1>", + "<example_utterance_2>", + "<example_utterance_3>", + "<example_utterance_4>", + "<example_utterance_5>"] +}} +</config> + +Only include the "name" and "utterances" keys in your answer. +The "name" should match the function name and the "utterances" +should comprise a list of 5 example phrases that could be used to invoke +the function. Use real values instead of placeholders. + +Input schema: +{function_schema} +""" llm_input = [Message(role="user", content=prompt)] output = llm(llm_input) -- GitLab