Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -8,22 +8,24 @@ import gradio as gr
|
|
| 8 |
|
| 9 |
|
| 10 |
# Function to generate customized keywords
|
| 11 |
-
def generate_keywords(customer_profile, pain_points, customer_wishes, brand_name, solution_benefits, differentiators):
|
| 12 |
# Craft the prompt for the OpenAI model
|
| 13 |
prompt = f"""You are an experienced digital marketing specialist AI.
|
| 14 |
-
Provide customized
|
| 15 |
-
who wishes to market their product online using Google Search Ads, using the following details:
|
| 16 |
- Customer profile and what task or job they are trying to do: {customer_profile}
|
| 17 |
- Problems and pain points that customers are currently facing while doing this task: {pain_points}
|
| 18 |
- Customer needs and what they wish the solution (product or service) would have to make their lives easier: {customer_wishes}
|
| 19 |
- Brand name (suggest a brand name and a slogan if the user doesn't yet have them): {brand_name}
|
| 20 |
-
- What
|
| 21 |
-
- What differentiates
|
|
|
|
| 22 |
|
| 23 |
Include:
|
| 24 |
-
-
|
| 25 |
-
- 3 options for Google Search Ad
|
| 26 |
-
-
|
|
|
|
| 27 |
|
| 28 |
Be concise and limit your response to 512 tokens or less."""
|
| 29 |
|
|
@@ -80,10 +82,15 @@ keyworder_app = gr.Interface(
|
|
| 80 |
placeholder="List what differentiates you from the competition.(e.g., Our pet-care-providers love pets and will help you say hi to your pet via our secure network.).",
|
| 81 |
lines=2,
|
| 82 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 83 |
],
|
| 84 |
outputs=gr.Textbox(label="Customized Digital Marketing Advice"),
|
| 85 |
title="Keyworder",
|
| 86 |
-
description="This app provides customized digital marketing advice based on your input. Powered by OpenAI GPT 4, Design Thinking and domain expertise. Developed by wn. Note and Disclaimer: Even AI can make mistakes. Use with caution and at your own risk!",
|
| 87 |
)
|
| 88 |
|
| 89 |
# Launch the application
|
|
|
|
| 8 |
|
| 9 |
|
| 10 |
# Function to generate customized keywords
|
| 11 |
+
def generate_keywords(customer_profile, pain_points, customer_wishes, brand_name, solution_benefits, differentiators, goal):
|
| 12 |
# Craft the prompt for the OpenAI model
|
| 13 |
prompt = f"""You are an experienced digital marketing specialist AI.
|
| 14 |
+
Provide customized digital marketing strategy recommendations for a producer or service provider (user of the chatbot)
|
| 15 |
+
who wishes to market their product online using recommended media mix (Google Search Ads, Facebook Ads, SEO, SEM, etc.) using the following details:
|
| 16 |
- Customer profile and what task or job they are trying to do: {customer_profile}
|
| 17 |
- Problems and pain points that customers are currently facing while doing this task: {pain_points}
|
| 18 |
- Customer needs and what they wish the solution (product or service) would have to make their lives easier: {customer_wishes}
|
| 19 |
- Brand name (suggest a brand name and a slogan if the user doesn't yet have them): {brand_name}
|
| 20 |
+
- What the solution (product or service) offers to solve customer problems, relieve their pain points, and meet or exceed their wishes: {solution_benefits}
|
| 21 |
+
- What differentiates the solution from existing competitor offerings: {differentiators}
|
| 22 |
+
- They main marketing goal the service provider (user of the chatbot) wishes to pursue: {goal}
|
| 23 |
|
| 24 |
Include:
|
| 25 |
+
- Digital marketing strategy and media mix.
|
| 26 |
+
- 3 options for a catchy headline for a Google Search Ad and or a social media Ad (recommend).
|
| 27 |
+
- 3 options for online ad descriptions to match the above headlines in the recommended media.
|
| 28 |
+
- 10 recommended keywords to use in the recommended media.
|
| 29 |
|
| 30 |
Be concise and limit your response to 512 tokens or less."""
|
| 31 |
|
|
|
|
| 82 |
placeholder="List what differentiates you from the competition.(e.g., Our pet-care-providers love pets and will help you say hi to your pet via our secure network.).",
|
| 83 |
lines=2,
|
| 84 |
),
|
| 85 |
+
gr.Textbox(
|
| 86 |
+
label="Marketing Goal",
|
| 87 |
+
placeholder="What is your main marketing goal (e.g., Boost awareness, website visits, conversion, etc.).",
|
| 88 |
+
lines=2,
|
| 89 |
+
),
|
| 90 |
],
|
| 91 |
outputs=gr.Textbox(label="Customized Digital Marketing Advice"),
|
| 92 |
title="Keyworder",
|
| 93 |
+
description="This app provides customized digital marketing strategy advice based on your input. Powered by OpenAI GPT 4, Design Thinking and domain expertise. Developed by wn. Note and Disclaimer: Even AI can make mistakes. Use with caution and at your own risk!",
|
| 94 |
)
|
| 95 |
|
| 96 |
# Launch the application
|