Wajahat698 commited on
Commit
538535f
·
verified ·
1 Parent(s): 760a8a6

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +65 -46
app.py CHANGED
@@ -2246,53 +2246,72 @@ def handle_prompt(prompt):
2246
  # Check if user request includes blog, article, or newsletter
2247
  if any(keyword in prompt.lower() for keyword in ["blog","write", "article","report","annual report" "newsletter","news letter","website introduction"]):
2248
  appended_instructions = (
2249
- "Craft a flawless, engaging, and fluid compelling copy using *non-flowery language* that reads as though written by a professional copywriter with 25 years of experience. "
2250
- "Avoid AI jargon, vague phrases, or overly formal language. Do not explicitly mention trust bucket names in headings or content. Instead, use the following enhanced guidelines for a polished, publication-ready copy that scores 10/10 in quality:\n\n"
2251
- "Smooth transition between sections should be there strictly ensure that.it should follow previous paragraph."
2252
- "1. **Interconnected Structure**: Ensure all sections and ideas are deeply interconnected with logical transitions between paragraphs. Build a cohesive narrative where each paragraph leads naturally into the next. Use linking phrases to reinforce connections (e.g., 'Building on this success...' or 'This aligns with our broader mission...'). Avoid isolated or disjointed sections.\n\n"
2253
 
2254
- "2. **Tailored Formatting for Blogs and Newsletters**:\n"
2255
- "- **For Blogs**: Use detailed, narrative-style paragraphs to explore topics in depth. Each section must have a creative subheading summarizing the content.\n"
2256
- "- **For Newsletters**: Focus on concise summaries with bullet points and clear headings. Ensure the content is visually digestible and quick to read.\n\n"
2257
-
2258
- "3. **Seamless Integration of TrustBuilders®**: Naturally weave TrustBuilders® into the narrative without isolating them. Highlight their relevance subtly to build credibility and trust while maintaining readability and engagement.\n\n"
2259
-
2260
- "4. **Relatable and Conversational Tone**: Engage the audience with a human, approachable tone. Avoid repetitive phrasing, overly technical explanations, or mechanical structures. Use active voice consistently for a professional yet friendly style.\n\n"
2261
-
2262
- "5. **Audience-Centric Engagement**: Tailor the content to resonate with the audience’s needs, challenges, and aspirations. Use relatable examples, vivid imagery, and direct appeals to create emotional connections. Highlight actionable insights and practical relevance.\n\n"
2263
-
2264
- "6. **Purpose-Driven Impact**: Clearly define and achieve the content's purpose—whether to inform, persuade, or inspire action. Ensure each paragraph contributes to the overall objective and reinforces the key message.\n\n"
2265
-
2266
- "7. **Content Elements for Newsletters**:\n"
2267
- "- Use bullet points for key highlights or statistics to improve readability.\n"
2268
- "- Summarize sections into digestible pieces that are easy to scan.\n"
2269
- "- Add clear calls-to-action (e.g., 'Join us,' 'Learn more,' 'Donate now') at the end of relevant sections.\n\n"
2270
-
2271
- "8. **Polished Presentation**: Refine the output to ensure it is professional, cohesive, and suitable for publication. Avoid ambiguity or errors. Structure the content to highlight key points effectively and keep the reader engaged.\n\n"
2272
-
2273
- "9. **Mandatory Sections for Blogs and Newsletters**:\n"
2274
- "1. ##List of TrustBuilders Used: Provide TrustBuilders used followed by *Source links always.*\n"
2275
- "2. ##Heuristics and Creative Techniques:\n"
2276
- " - List them in a footnote-style small heading.\n"
2277
- " - Use the following structure:\n"
2278
- " - Heuristics: Mention names only (e.g., social proof, authority, commitment).\n"
2279
- " - Creative Techniques: Mention names only (list only relevant marketing techniques without additional details).\n\n"
2280
-
2281
- "10. **Flow and Consistency**:\n"
2282
- "- Strengthen connections between paragraphs to create a seamless flow.\n"
2283
- "- Ensure newsletters are concise, with key points prominently displayed, and blogs maintain a deeper narrative structure with smooth transitions.\n\n"
2284
-
2285
- "11. **Creative Subheadings**:\n"
2286
- "- Each section must have a subheading that captures the essence of the content below.\n"
2287
- "- For example, instead of 'Empowering Communities,' use action-driven headlines like 'Driving Sustainable Change Globally.'\n"
2288
- "- Avoid generic titles or -ing endings.\n\n"
2289
-
2290
- "12. **Key Reminder**:\n"
2291
- "Ensure the final output:\n"
2292
- "- Is deeply interconnected, with transitions between sections creating a cohesive narrative.\n"
2293
- "- Maintains a balance between detail and brevity to suit both blogs and newsletters.\n"
2294
- "- Includes action-oriented subheadings and avoids disjointed or isolated content blocks.\n"
2295
- )
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2296
 
2297
  else:
2298
 
 
2246
  # Check if user request includes blog, article, or newsletter
2247
  if any(keyword in prompt.lower() for keyword in ["blog","write", "article","report","annual report" "newsletter","news letter","website introduction"]):
2248
  appended_instructions = (
 
 
 
 
2249
 
2250
+ """
2251
+ Craft a flawless, engaging, and fluid compelling copy using *non-flowery language* that reads as though written by a professional copywriter with 25 years of experience.
2252
+ Avoid AI jargon, vague phrases, or overly formal language. Do not explicitly mention TrustBucket® names in headings or content. Instead, adhere to the following enhanced guidelines to ensure a polished, publication-ready copy that scores 10/10 in quality:
2253
+
2254
+ ### **Key Guidelines**
2255
+
2256
+ 1. **Deeply Interconnected Structure:**
2257
+ - Ensure all sections and ideas are seamlessly interconnected with logical transitions between paragraphs.
2258
+ - Use linking phrases to connect ideas (e.g., "Building on this success..." or "This aligns with our mission to...").
2259
+ - Avoid isolated or disjointed sections; every paragraph must flow naturally into the next.
2260
+
2261
+ 2. **Content Formatting for Blogs and Newsletters:**
2262
+ - **For Blogs**:
2263
+ - Use detailed, narrative-style paragraphs to explore topics in depth.
2264
+ - Include creative subheadings for each section that summarize the content effectively.
2265
+ - **For Newsletters**:
2266
+ - Focus on concise summaries, bullet points for key highlights, and clear, visually digestible sections.
2267
+ - Ensure the content is easy to scan and quick to read.
2268
+
2269
+ 3. **Seamless Integration of TrustBuilders®:**
2270
+ - Weave TrustBuilders® into the narrative naturally without isolating them as standalone points.
2271
+ - Highlight their relevance subtly to enhance credibility and trust while maintaining a smooth narrative flow.
2272
+
2273
+ 4. **Relatable and Conversational Tone:**
2274
+ - Engage the reader with a human, approachable tone.
2275
+ - Use active voice and avoid repetitive phrasing, overly technical explanations, or mechanical structures.
2276
+ - Address newsletters directly to the reader using "you" and "your" for a personal connection.
2277
+
2278
+ 5. **Audience-Centric Engagement:**
2279
+ - Tailor the content to resonate with the audience’s needs, challenges, and aspirations.
2280
+ - Use vivid imagery, relatable examples, and direct appeals to create emotional connections.
2281
+ - Highlight actionable insights and practical relevance to maintain engagement.
2282
+
2283
+ 6. **Purpose-Driven Impact:**
2284
+ - Clearly define and achieve the content’s purpose—whether to inform, persuade, or inspire action.
2285
+ - Ensure every paragraph contributes to the overall objective and reinforces the key message.
2286
+
2287
+ 7. **Content Elements for Newsletters:**
2288
+ - Use bullet points to emphasize key statistics, highlights, or impactful statements.
2289
+ - Summarize sections into digestible pieces for easy scanning.
2290
+ - Include clear calls-to-action (e.g., "Join us," "Learn more," "Donate now") at relevant points.
2291
+
2292
+ 8. **Polished Presentation:**
2293
+ - Deliver a professional, cohesive, and error-free final output.
2294
+ - Highlight key points effectively and ensure the structure keeps readers engaged.
2295
+
2296
+ 9. **Mandatory Sections:**
2297
+ - **List of TrustBuilders Used**: Provide TrustBuilders followed by *source links* in a separate section.
2298
+ - **Heuristics and Creative Techniques**:
2299
+ - Heuristics: List only (e.g., Social Proof, Authority, Commitment).
2300
+ - Creative Techniques: List relevant techniques (e.g., Storytelling, Emotional Appeal, Vivid Imagery).
2301
+
2302
+ 10. **Flow and Consistency:**
2303
+ - Strengthen transitions between paragraphs to ensure a seamless narrative.
2304
+ - Newsletters must remain concise, with key points prominently displayed, while blogs should have a deeper narrative structure.
2305
+
2306
+ 11. **Creative Subheadings:**
2307
+ - Each section must include an action-oriented subheading that captures the essence of the content.
2308
+ - Avoid generic or vague titles, and do not use -ing endings (e.g., "Driving Global Change" should be "Drive Global Change").
2309
+
2310
+ 12. **Final Output Checklist:**
2311
+ - Ensure content is deeply interconnected, flowing seamlessly from one idea to the next.
2312
+ - Balance detail and brevity, tailoring the format to blogs or newsletters as required.
2313
+ - Use action-driven subheadings and avoid isolated or fragmented content blocks.
2314
+ """ )
2315
 
2316
  else:
2317