Spaces:
Running
Running
Update main.py
Browse files
main.py
CHANGED
@@ -48,7 +48,9 @@ def json_from_text(text):
|
|
48 |
|
49 |
def generate_topics(user_input, num_topics, previous_queries):
|
50 |
previous_context = " -> ".join(previous_queries)
|
51 |
-
prompt = f"""create a list of {num_topics} subtopics to follow for conducting {user_input} in the context of {previous_context}, RETURN VALID PYTHON LIST"""
|
|
|
|
|
52 |
response_topics = together_response(prompt, model="meta-llama/Llama-3-8b-chat-hf", SysPrompt=SysPromptList)
|
53 |
subtopics = json_from_text(response_topics)
|
54 |
return subtopics
|
|
|
48 |
|
49 |
def generate_topics(user_input, num_topics, previous_queries):
|
50 |
previous_context = " -> ".join(previous_queries)
|
51 |
+
prompt = f"""create a list of {num_topics} subtopics along with descriptions to follow for conducting {user_input} in the context of {previous_context}, RETURN A VALID PYTHON LIST"""\
|
52 |
+
+""" Respond in the following format:
|
53 |
+
[["Subtopic","Description"],["Subtopic","Description"]]"""
|
54 |
response_topics = together_response(prompt, model="meta-llama/Llama-3-8b-chat-hf", SysPrompt=SysPromptList)
|
55 |
subtopics = json_from_text(response_topics)
|
56 |
return subtopics
|