fixed unicode issue
Browse files
app.py
CHANGED
|
@@ -45,8 +45,7 @@ def build_structured_prompt(user_prompt, repo_data=None):
|
|
| 45 |
"No [] or () for links",
|
| 46 |
"No ``` for code blocks",
|
| 47 |
"No > for quotes",
|
| 48 |
-
"No _underscore_ formatting"
|
| 49 |
-
"No /u or any other symbols"
|
| 50 |
],
|
| 51 |
"allowed_formatting": [
|
| 52 |
"Use line breaks (empty lines) to separate paragraphs",
|
|
@@ -54,6 +53,7 @@ def build_structured_prompt(user_prompt, repo_data=None):
|
|
| 54 |
"Use • or → or numbers (1, 2, 3) for lists WITHOUT any markdown",
|
| 55 |
"Use CAPS for emphasis sparingly",
|
| 56 |
"Use quotation marks for actual quotes"
|
|
|
|
| 57 |
],
|
| 58 |
"link_format": "Plain text only - write 'GitHub: [INSERT YOUR GITHUB LINK HERE]' or 'Live Demo: [INSERT DEMO LINK HERE]'",
|
| 59 |
"meta_commentary": "Never include section labels like (Opening Hook) or (First 250 words) in the final output"
|
|
@@ -171,7 +171,7 @@ def build_structured_prompt(user_prompt, repo_data=None):
|
|
| 171 |
}
|
| 172 |
|
| 173 |
# Convert to JSON for clarity and structure
|
| 174 |
-
return json.dumps(structured_prompt, indent=2)
|
| 175 |
|
| 176 |
def generate_post(topic, user_prompt):
|
| 177 |
if not topic:
|
|
|
|
| 45 |
"No [] or () for links",
|
| 46 |
"No ``` for code blocks",
|
| 47 |
"No > for quotes",
|
| 48 |
+
"No _underscore_ formatting"
|
|
|
|
| 49 |
],
|
| 50 |
"allowed_formatting": [
|
| 51 |
"Use line breaks (empty lines) to separate paragraphs",
|
|
|
|
| 53 |
"Use • or → or numbers (1, 2, 3) for lists WITHOUT any markdown",
|
| 54 |
"Use CAPS for emphasis sparingly",
|
| 55 |
"Use quotation marks for actual quotes"
|
| 56 |
+
"Use Emojies that relates"
|
| 57 |
],
|
| 58 |
"link_format": "Plain text only - write 'GitHub: [INSERT YOUR GITHUB LINK HERE]' or 'Live Demo: [INSERT DEMO LINK HERE]'",
|
| 59 |
"meta_commentary": "Never include section labels like (Opening Hook) or (First 250 words) in the final output"
|
|
|
|
| 171 |
}
|
| 172 |
|
| 173 |
# Convert to JSON for clarity and structure
|
| 174 |
+
return json.dumps(structured_prompt, indent=2, ensure_ascii=False)
|
| 175 |
|
| 176 |
def generate_post(topic, user_prompt):
|
| 177 |
if not topic:
|