Wajahat698 commited on
Commit
d8abc79
·
verified ·
1 Parent(s): 4af38c2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +54 -52
app.py CHANGED
@@ -2236,60 +2236,62 @@ def handle_prompt(prompt):
2236
  # Check if user request includes blog, article, or newsletter
2237
  if any(keyword in prompt.lower() for keyword in ["blog", "write", "article", "annual report", "report", "newsletter", "news letter ", "website introduction"]):
2238
  appended_instructions = (
2239
- """
2240
- Create compelling copy that flows naturally, using these essential guidelines:
2241
-
2242
- ---
2243
- **Format-Specific Voice (CRITICAL)**
2244
- - **Newsletters**: Always use "you" or "your" throughout—never "they," "them," or "residents."
2245
- - **Blogs/Reports**: Use "we" to reflect an organizational voice.
2246
- - **Website Copy**: Balance "we" and "you" to create a two-way dialogue.
2247
-
2248
- ---
2249
- **Flow & Structure**
2250
- - Begin each section by referencing or linking it to the previous point.
2251
- - End each section by bridging to the next topic, ensuring a seamless transition.
2252
- - Example flow:
2253
- - Previous point New insight Connection to next topic
2254
-
2255
- ---
2256
- **Headlines & Subheads**
2257
- - Format:
2258
- - Main Headline: Highlight the problem or promise (e.g., "Transform Your Living Space")
2259
- - Subhead: Provide supporting detail (e.g., "Simple tips to make your apartment more comfortable")
2260
- - **Never use -ing words** in headlines. (Use "Transform" or "Expand" instead of "Transforming" or "Expanding.")
2261
-
2262
- ---
2263
- **TrustBuilder Integration**
2264
- - Weave TrustBuilders naturally into the narrative.
2265
- - Example: Instead of saying "We have 5-star ratings," write "You’ll enjoy the same five-star experience that [specific number] of our users treasure."
2266
-
2267
- ---
2268
- **Crucial Rules**
2269
- 1. Keep the **audience perspective** consistent (newsletters "you," blogs "we," etc.).
2270
- 2. Every paragraph must logically connect to the ones before and after it, ensuring a **unified narrative** without disjointed sections.
2271
- 3. Use **active, engaging language** without AI or corporate clichés.
2272
- 4. Write naturally, maintaining clarity and authenticity.
2273
-
2274
- ---
2275
- **Ending with TrustBuilders & Techniques**
2276
- - After the main content, provide:
2277
- - **List of TrustBuilders Used** (no source links in the main body, only here).
2278
- - **Heuristics and Creative Techniques** in a footnote-style heading:
2279
- - Heuristics: Mention names only (e.g., social proof, authority, commitment).
2280
- - Creative Techniques: List only relevant marketing techniques (e.g., storytelling, vivid imagery).
2281
-
2282
- ---
2283
- **MOST IMPORTANT RULE**
2284
- - In every paragraph, strengthen connections between sections to ensure smoother flow.
2285
- - The entire piece **must read like a single, cohesive story**, without disjointed paragraphs or independent blocks.
2286
- - Each section must logically flow into the next, preserving consistency and relevance throughout.
2287
- - This cohesive structure engages readers effectively, captures their attention, and conveys the intended message with clarity and impact.
2288
- - *Use creative headlines* for each paragraph, summarizing the content in an active tone (no “-ing” endings like “Driving,” “Empowering,” etc.).
2289
-
2290
- """
2291
  )
2292
 
 
 
2293
 
2294
  appended_instructions = ""
2295
  final_prompt = f"{prompt} {base_instructions} {appended_instructions}"
 
2236
  # Check if user request includes blog, article, or newsletter
2237
  if any(keyword in prompt.lower() for keyword in ["blog", "write", "article", "annual report", "report", "newsletter", "news letter ", "website introduction"]):
2238
  appended_instructions = (
2239
+ "Craft a flawless, engaging, and fluid marketing copy using *non-flowery language* that reads as though written by a seasoned marketing copywriter with 25 years of experience. "
2240
+ "Avoid AI jargon, vague phrases, or overly formal language. Exclude any mention of trustbucket names in headings or content. Follow these enhanced guidelines to ensure a cohesive, publication-ready piece that attains a 10/10 quality rating:\n\n"
2241
+
2242
+ "**Format-Specific Voice**:\n"
2243
+ "- **Newsletters**: Use 'you' or 'your' throughout to establish a personal, direct connection. Avoid references like 'they' or 'them.'\n"
2244
+ "- **Blogs/Articles/Reports**: Use 'we' for an organizational perspective, emphasizing collective efforts.\n"
2245
+ "- **Website Copy**: Balance 'we' and 'you' to create a two-way dialogue.\n\n"
2246
+
2247
+ "**Flow and Interconnected Structure**:\n"
2248
+ "- Begin each section by referencing the previous point and end with a transitional bridge to the next.\n"
2249
+ "- Maintain a single, unified theme without disjointed or standalone paragraphs.\n"
2250
+ "- Example Flow: Previous point New insight Connection to next topic.\n\n"
2251
+
2252
+ "**Creative Headlines (No '-ing' Endings)**:\n"
2253
+ "- Start each paragraph with an action-oriented, active headline that grabs attention.\n"
2254
+ "- Avoid '-ing' endings (e.g., 'Transform Lives Today' instead of 'Transforming Lives Today').\n"
2255
+ "- Summarize the paragraph’s core idea and the benefit or promise to the reader.\n\n"
2256
+
2257
+ "**TrustBuilder® Integration**:\n"
2258
+ "- Weave TrustBuilders® into the story contextually. For example, instead of listing them, embed them into the narrative.\n"
2259
+ "- Demonstrate impact and credibility by referencing specific achievements or numbers within fluid, emotionally resonant sentences.\n\n"
2260
+
2261
+ "**Engaging, Human Tone**:\n"
2262
+ "- Write in a relatable, conversational style. Use active voice consistently.\n"
2263
+ "- Keep corporate jargon and AI-specific phrasing to a minimum. Focus on clarity and authenticity.\n"
2264
+ "- Tailor the content to the reader’s experience, needs, and aspirations.\n\n"
2265
+
2266
+ "**Storytelling and Audience Appeal**:\n"
2267
+ "- Hook the reader at the outset with a compelling scenario or statistic.\n"
2268
+ "- Use real-life examples or scenarios to maintain momentum.\n"
2269
+ "- Conclude with a strong call-to-action (CTA) that encourages reflection or action.\n\n"
2270
+
2271
+ "**Purpose and Consistency**:\n"
2272
+ "- Clearly define the piece’s aim: to inform, persuade, or inspire. Every paragraph must reinforce this goal.\n"
2273
+ "- Keep language purposeful, ensuring each section advances the overall message.\n\n"
2274
+
2275
+ "**Polished and Professional**:\n"
2276
+ "- Ensure an error-free, visually inviting final output.\n"
2277
+ "- Use thoughtful headings, subheadings, and smooth transitions for easy reading.\n"
2278
+ "- Maintain advanced language proficiency, yet remain accessible and straightforward.\n\n"
2279
+
2280
+ "**Ending with TrustBuilders and Techniques**:\n"
2281
+ "- After the main content, provide a separate 'List of TrustBuilders Used' with source links (no links in the body).\n"
2282
+ "- Include a 'Heuristics and Creative Techniques' section in footnote style:\n"
2283
+ " - **Heuristics**: List names only (e.g., 'social proof,' 'authority,' 'commitment').\n"
2284
+ " - **Creative Techniques**: Mention only relevant marketing approaches (e.g., 'storytelling,' 'vivid imagery').\n\n"
2285
+
2286
+ "**Most Important Rule**:\n"
2287
+ "- In every paragraph, reinforce connections between sections for a smooth, cohesive narrative.\n"
2288
+ "- Avoid disjointed blocks of text or sudden shifts in topic. Each paragraph should seamlessly transition into the next.\n"
2289
+ "- Headlines must reflect an active, creative essence without '-ing' endings, summarizing the paragraph’s content effectively.\n\n"
2290
+ "By adhering to these guidelines, the final output must read like a single, unified piece, fully engaging the reader and ensuring maximum clarity, impact, and trust."
2291
  )
2292
 
2293
+
2294
+
2295
 
2296
  appended_instructions = ""
2297
  final_prompt = f"{prompt} {base_instructions} {appended_instructions}"