app.py
CHANGED
@@ -20,7 +20,7 @@ def get_completion_from_messages(messages,
|
|
20 |
)
|
21 |
return response.choices[0].message["content"]
|
22 |
|
23 |
-
def greet(company, solution, target_customer, problem, features,
|
24 |
pitch = f"""My company, {company} is developing {solution} to help {target_customer} {problem} with {features}"""
|
25 |
sys_setup = f"""
|
26 |
Determine the product or solution, the problem being solved, features, target customer that are being discussed in the \
|
@@ -35,5 +35,5 @@ Format your response as a JSON object with \
|
|
35 |
response = get_completion_from_messages(messages, temperature=0)
|
36 |
return json.dumps(response)
|
37 |
|
38 |
-
iface = gr.Interface(fn=greet, inputs=[gr.Textbox(label="Company"), gr.Textbox(label="Solution"), gr.Textbox(label="Customer"), gr.Textbox(label="Problem"), gr.Textbox(label="Feature"), gr.Textbox(label="
|
39 |
iface.launch()
|
|
|
20 |
)
|
21 |
return response.choices[0].message["content"]
|
22 |
|
23 |
+
def greet(company, solution, target_customer, problem, features, audience_persona="the target customer"):
|
24 |
pitch = f"""My company, {company} is developing {solution} to help {target_customer} {problem} with {features}"""
|
25 |
sys_setup = f"""
|
26 |
Determine the product or solution, the problem being solved, features, target customer that are being discussed in the \
|
|
|
35 |
response = get_completion_from_messages(messages, temperature=0)
|
36 |
return json.dumps(response)
|
37 |
|
38 |
+
iface = gr.Interface(fn=greet, inputs=[gr.Textbox(label="Company"), gr.Textbox(label="Solution"), gr.Textbox(label="Customer"), gr.Textbox(label="Problem"), gr.Textbox(label="Feature"), gr.Textbox(label="Target Audience persona", lines=3)], outputs="json")
|
39 |
iface.launch()
|