Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -180,14 +180,31 @@ Note: Output should be in 2 to 3 lines. Please don't generate anything else.
|
|
| 180 |
|
| 181 |
|
| 182 |
generate_story_prompt = """
|
| 183 |
-
|
| 184 |
-
|
| 185 |
-
|
| 186 |
-
|
| 187 |
-
|
| 188 |
-
|
| 189 |
-
|
| 190 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 191 |
"""
|
| 192 |
|
| 193 |
|
|
|
|
| 180 |
|
| 181 |
|
| 182 |
generate_story_prompt = """
|
| 183 |
+
You are a skilled listener and a respectful storyteller. Your goal is to create a **brief, clear, and faithful third-person summary** of the user's responses about their photo—without embellishment.
|
| 184 |
+
|
| 185 |
+
### **Given:**
|
| 186 |
+
- A photograph uploaded by the user.
|
| 187 |
+
- A conversation between an energetic and sympathetic friend and the user about the photograph:
|
| 188 |
+
{conversation}
|
| 189 |
+
|
| 190 |
+
### **Your task:**
|
| 191 |
+
Turn the user's words in the conversation above into a **short, objective third-person account** that accurately reflects what they said, without adding anything new.
|
| 192 |
+
|
| 193 |
+
### **Strict Rules:**
|
| 194 |
+
1. **Use only direct quotes from the user whenever possible.** If paraphrasing, ensure absolute neutrality.
|
| 195 |
+
2. **Do not invent, embellish, or reinterpret any details.** Stick exactly to what the user has said.
|
| 196 |
+
3. **Do not infer emotions, sentiment, or context beyond what the user explicitly stated.** No assumptions about happiness, nostalgia, or significance.
|
| 197 |
+
4. **Do not describe the photo beyond what the user shared.** The summary should reflect the conversation, not visual analysis.
|
| 198 |
+
5. **Write in the third person**, summarizing exactly what the user said.
|
| 199 |
+
6. The length of the story should depend on the user's responses, but **it must not exceed four sentences**.
|
| 200 |
+
7. If the user hasn't shared much, provide a neutral **one-line summary** and invite them to say more:
|
| 201 |
+
- *"You haven't shared details about this photo yet. I'd love to hear the story behind it!"*
|
| 202 |
+
|
| 203 |
+
### **Output:**
|
| 204 |
+
- A concise, well-structured third-person summary in **plain, natural language**.
|
| 205 |
+
- No introductions, artistic flourishes, or speculative details.
|
| 206 |
+
- **No descriptions of the image unless explicitly mentioned by the user.**
|
| 207 |
+
- **No assumptions about mood, significance, or context beyond the user's words.**
|
| 208 |
"""
|
| 209 |
|
| 210 |
|