JeCabrera commited on
Commit
ffd3b9c
·
verified ·
1 Parent(s): 617ed94

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +72 -4
app.py CHANGED
@@ -34,28 +34,96 @@ def get_mention_instruction(product_mention, product):
34
  def get_formula_instruction(formula, product):
35
  if formula == "If/Then":
36
  return f"""
37
- Write the opening paragraph using the 'If/Then' structure. Start by presenting a problem or goal the reader might have, and then clearly explain how the product '{product}' can solve it. For example, 'If you want to achieve X, then this product is the solution.'
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
38
  """
39
  elif formula == "If / Then + Authority":
40
  return f"""
41
- Write the opening paragraph using the 'If/Then' structure but add an authority figure or testimonial for added credibility. Start by presenting a problem or goal the reader might have, then explain how the product '{product}' can solve it, while mentioning an authority figure or expert opinion. For example, 'If you want to achieve X, then this expert recommends this product for solving it.'
 
 
 
 
42
  """
43
  elif formula == "Honesty":
44
  return f"""
45
- Write the opening paragraph using an honest approach, focusing on transparency. Introduce the product '{product}' and make it clear that you are not pretending to have all the answers, but you can provide a solution. Be authentic and straightforward.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
46
  """
47
  elif formula == "Sensationalist":
48
  return f"""
49
  Write the opening paragraph using a sensationalist approach. Introduce an unexpected or shocking fact, and link it to the product '{product}' as the solution. The goal is to create curiosity and urgency in the reader's mind.
 
 
 
 
 
 
 
 
50
  """
51
  elif formula == "Ask a Question":
52
  return f"""
53
  Write the opening paragraph by asking a provocative question related to the reader's problem or goal. After the question, suggest that the product '{product}' holds the answer.
 
 
 
 
 
 
 
 
54
  """
55
  elif formula == "Micro Openings":
56
  return f"""
57
  Write the opening paragraph using a very short, impactful sentence. Create a strong hook that grabs the reader's attention immediately. For example, 'What if I told you that you could achieve X with just one simple tool?' Then, introduce the product '{product}' as the key to solving the issue.
58
- """
 
 
 
 
 
 
 
 
 
 
 
 
59
  return ""
60
 
61
  # Generar respuesta del modelo
 
34
  def get_formula_instruction(formula, product):
35
  if formula == "If/Then":
36
  return f"""
37
+ Write the opening paragraph using the 'If/Then' structure. Start by presenting a problem or goal the reader might have, and then clearly explain how the product '{product}' can solve it. The 'If/Then' logic is based on a direct connection between the reader's desire (the 'If') and the solution you're offering (the 'Then'). This structure taps into a basic belief system that reinforces the idea that the promised benefit is achievable if the initial condition is met.
38
+
39
+ Here are some variations of the 'If/Then' structure that you can use:
40
+
41
+ 1. Curious: "If you've ever wondered why ice cream tastes better when you eat it with a metal spoon, then this psychological trick will surprise you."
42
+ 2. Emotional: "If you feel like you always give more than you receive in your relationships, then this message can help you change your story."
43
+ 3. Funny: "If you think slow Wi-Fi is a form of modern-day torture, then you need to read this before throwing your router out the window."
44
+ 4. Intriguing: "If everyone seems to be successful while you're still looking for your way, then this guide might be exactly what you need to turn things around."
45
+ 5. Creative: "If you've ever dreamed of writing a letter so powerful it makes your ex cry or convinces a stranger to buy, then here's the formula you've been searching for."
46
+
47
+ The 'If/Then' approach is highly effective because it connects with pre-existing beliefs or desires in the reader’s mind. It either reinforces or challenges these beliefs by offering a direct benefit or new perspective.
48
+ For example:
49
+ - Reinforcing a belief: "If you believe authenticity is the key to connecting with people, then you're closer to writing texts that sell without sounding fake."
50
+ - Challenging a belief: "If you think you need to be extroverted to sell more, then you'll be surprised to know that many introverts are actually the best salespeople."
51
+ - Showing a benefit: "If you believe spending time with your family is more important than any paycheck, then this system will help you earn more while working less."
52
+ - Showing a disadvantage: "If you believe that talent is everything when it comes to success, then you may be underestimating the power of discipline."
53
+ - Intriguing and transformative: "If you think you already know everything about how to write to sell, then this forgotten secret could make you rethink everything you thought you knew."
54
  """
55
  elif formula == "If / Then + Authority":
56
  return f"""
57
+ Write the opening paragraph using the 'If/Then' structure but add an authority figure or testimonial for added credibility. Start by presenting a problem or goal the reader might have, then explain how the product '{product}' can solve it, while mentioning an authority figure or expert opinion. The inclusion of authority figures or recognized references increases the impact of your message, making it more persuasive. For example:
58
+
59
+ "If you want to learn how to write paragraphs that sell, then here are the techniques used by legendary copywriters like Gary Halbert and Eugene Schwartz to captivate millions."
60
+
61
+ This use of authority validates your claim and makes the reader more likely to trust the solution you're offering.
62
  """
63
  elif formula == "Honesty":
64
  return f"""
65
+ Write the opening paragraph using an honest approach, focusing on transparency and vulnerability. With the product '{product}', be clear that you're not pretending to have all the answers, but you do have a solution based on your genuine experience. The goal here is to create a real connection through authenticity. Honesty disarms skepticism and makes the reader feel heard, which is more impactful than over-promising or presenting yourself as an expert in every area.
66
+
67
+ Why does this approach work?
68
+ - It breaks barriers: Admitting what you aren't or don't have makes you more relatable and trustable.
69
+ - It creates empathy: Readers resonate with your honesty and appreciate transparency.
70
+ - It focuses attention: By being upfront about what you aren't, you spotlight what you can offer.
71
+
72
+ Example (without honesty):
73
+ "I'm a fitness expert, and I have the perfect plan to help you lose 10 kilos in 30 days."
74
+
75
+ Example (with honesty):
76
+ "I'm not a personal trainer, nor do I have a degree in nutrition. In fact, the only thing I know about fitness is what I learned from struggling with my own weight. But that's why I want to show you how I lost 10 kilos without complicated diets or hours at the gym."
77
+
78
+ Which one feels more real? Probably the second one, because it sounds authentic, not like an empty promise.
79
+
80
+ Teaching how to write with honesty:
81
+ 1. Admit something you're not or don't have.
82
+ Example: "I don't have a psychology PhD, but..."
83
+ 2. Follow up with what you are or what you bring to the table.
84
+ Example: "...I've spent 10 years studying how to improve my relationships, and I want to share what really works."
85
+ 3. Balance honesty with value: Be genuine, but ensure your message still highlights what you can offer.
86
  """
87
  elif formula == "Sensationalist":
88
  return f"""
89
  Write the opening paragraph using a sensationalist approach. Introduce an unexpected or shocking fact, and link it to the product '{product}' as the solution. The goal is to create curiosity and urgency in the reader's mind.
90
+
91
+ Context:
92
+ Sensationalism works by surprising the reader with an outlandish or shocking statement. It grabs attention instantly and makes the reader want to know more. Use bold, extreme statements that provoke curiosity or astonishment.
93
+
94
+ Example:
95
+ "¿Sabías que la mayoría de las personas pierden $5,000 al año por no conocer este simple truco financiero? Aquí te cuento cómo evitarlo."
96
+
97
+ By shocking the reader with an unusual claim or fact, you spark curiosity and compel them to keep reading.
98
  """
99
  elif formula == "Ask a Question":
100
  return f"""
101
  Write the opening paragraph by asking a provocative question related to the reader's problem or goal. After the question, suggest that the product '{product}' holds the answer.
102
+
103
+ Context:
104
+ Asking a question is a powerful way to engage the reader. It immediately invites them to think about their own situation and wonder how your product can provide a solution.
105
+
106
+ Example:
107
+ "¿Sabías que el valor a largo plazo de las tarjetas de béisbol es mayor que el de las acciones y monedas raras?"
108
+
109
+ The question makes the reader pause and consider the information they are being offered, creating an interactive and engaging experience.
110
  """
111
  elif formula == "Micro Openings":
112
  return f"""
113
  Write the opening paragraph using a very short, impactful sentence. Create a strong hook that grabs the reader's attention immediately. For example, 'What if I told you that you could achieve X with just one simple tool?' Then, introduce the product '{product}' as the key to solving the issue.
114
+
115
+ Context:
116
+ Micro openings work by delivering a quick, powerful message that hooks the reader. These openings often feel personal and conversational, sparking curiosity with just a few words.
117
+
118
+ Example:
119
+ "Yo no creía que fuera posible.
120
+ Ganar dinero desde casa.
121
+ Sin salir.
122
+ Sin jefes.
123
+ Pero me equivoqué."
124
+
125
+ The brevity and simplicity of micro openings make them easy to absorb, yet powerful enough to captivate the reader's attention.
126
+ """
127
  return ""
128
 
129
  # Generar respuesta del modelo