Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -59,203 +59,10 @@ if st.button("Generate Conversation"):
|
|
59 |
# Build the prompt message for Groq API.
|
60 |
prompt = (
|
61 |
f"""
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
1. FORMAT STRUCTURE (Regex-like Guide)
|
66 |
-
1.1 Contact Name (Title)
|
67 |
-
At the beginning of the script, define the contact name (the name that appears at the top of the iMessage screen).
|
68 |
-
|
69 |
-
php-template
|
70 |
-
Copy
|
71 |
-
Edit
|
72 |
-
<Contact Name>:<Contact Name>
|
73 |
-
Example:
|
74 |
-
ruby
|
75 |
-
Copy
|
76 |
-
Edit
|
77 |
-
Amir Uber Eats🍔🚚🗿:Amir Uber Eats🍔🚚🗿
|
78 |
-
1.2 Dialogue Format
|
79 |
-
Every dialogue line should follow this structure:
|
80 |
-
|
81 |
-
php-template
|
82 |
-
Copy
|
83 |
-
Edit
|
84 |
-
<Direction>: <SpeakerName> > <Dialogue> [<Reaction>]
|
85 |
-
<Direction> → Either Left: or Right:
|
86 |
-
Left: represents the left speaker (User).
|
87 |
-
Right: represents the right speaker (Other character).
|
88 |
-
<SpeakerName> → The voice actor name (which should remain consistent for left and right).
|
89 |
-
> → A separator between the speaker name and their dialogue.
|
90 |
-
<Dialogue> → The actual speech text, containing humor, slang, or randomness.
|
91 |
-
[<Reaction>] (Optional) → Emotional or sound-based cues (e.g., [shocked], [fart2], [get_out]).
|
92 |
-
Example:
|
93 |
-
vbnet
|
94 |
-
Copy
|
95 |
-
Edit
|
96 |
-
Left: Chinmay> Sir this is your Uber Eats order [shocked]
|
97 |
-
Right: Alex> BRO WHY IS THERE A RAT IN MY BURGER?!! [shocked] 🐀🍔
|
98 |
-
Left: Chinmay> Extra protein sir 😎
|
99 |
-
1.3 Bracketed Cues & Sound Effects
|
100 |
-
Use brackets [] to include sound effects, reactions, or video cues.
|
101 |
-
DO NOT USE REACTIONS TOO OFTEN -- ONLY WHEN NECESSARY FOR DRAMATIC EFFECT
|
102 |
-
Common Examples:
|
103 |
-
|
104 |
-
[shocked] → Indicates the character is shocked.
|
105 |
-
[get_out] → Indicates the end of the conversation or dramatic exit.
|
106 |
-
[fart2] → Represents a comedic fart sound.
|
107 |
-
[suspense_music] → A cue for background music.
|
108 |
-
[explosion] → A big moment or reveal.
|
109 |
-
[slow_zoom] → A slow zoom-in effect for emphasis.
|
110 |
-
Example:
|
111 |
-
css
|
112 |
-
Copy
|
113 |
-
Edit
|
114 |
-
Right: Alex> WHY DID MY HOUSE JUST EXPLODE?!!! [explosion] 💀💀💀
|
115 |
-
1.4 Image Placeholders
|
116 |
-
Images should be inserted where necessary using:
|
117 |
-
|
118 |
-
php-template
|
119 |
-
Copy
|
120 |
-
Edit
|
121 |
-
<Direction>: img:<DescriptiveImageName>
|
122 |
-
<DescriptiveImageName> → Describe the image clearly for easy attachment later.
|
123 |
-
Example:
|
124 |
-
vbnet
|
125 |
-
Copy
|
126 |
-
Edit
|
127 |
-
Left: img:burnt_food_delivery
|
128 |
-
Right: Alex> BRO WHY IS MY PIZZA LOOKING LIKE CHARCOAL?!! [shocked]
|
129 |
-
1.5 Special Sections (Cantina App / Roast Bot)
|
130 |
-
Incorporate Roast Bot mechanics where the character opens an app mid-conversation to ask for a roast.
|
131 |
-
|
132 |
-
Format:
|
133 |
-
|
134 |
-
vbnet
|
135 |
-
Copy
|
136 |
-
Edit
|
137 |
-
Cantina: Roast bot:Roast bot pfp == <Speaker> Let me open the cantina app to talk to Roast bot
|
138 |
-
Then, the roast bot provides a response.
|
139 |
-
|
140 |
-
Example:
|
141 |
-
vbnet
|
142 |
-
Copy
|
143 |
-
Edit
|
144 |
-
Cantina: Roast bot:Roast bot pfp == Alex> Let me open the cantina app to talk to Roast bot
|
145 |
-
Right: Alex> This guy just delivered my food and scammed me 😡
|
146 |
-
Left: Antoni> Tell him this: "Sir, you pay less than a dollar tip and expect a five-star service?"
|
147 |
-
Right: Alex> YOU DID ME DIRTY BRO 😭😭
|
148 |
-
2. STORY GENERATION GUIDELINES
|
149 |
-
2.1 Catchy “Brain Rot” Hook
|
150 |
-
The first few lines must be highly engaging, over-the-top, and create curiosity.
|
151 |
-
Examples:
|
152 |
-
|
153 |
-
"BRO I JUST ORDERED UBER EATS AND THIS GUY SHOWED UP IN A SPACESHIP???" 🚀👀
|
154 |
-
"WHY DID MY DAD JUST SAY HE WANTS TO PLAY GTA WITH ME???" 🎮💀
|
155 |
-
"SIR WHY IS MY LAWYER ALSO MY UBER DRIVER?!" 👨⚖️🚗💨
|
156 |
-
This hook should create an instant “WTF?!” reaction and force the reader to keep watching.
|
157 |
-
|
158 |
-
2.2 Story Progression (Random but Coherent)
|
159 |
-
The storyline must escalate in craziness but still have a logical flow.
|
160 |
-
Use sudden twists and reveals to keep the audience engaged.
|
161 |
-
End with a memorable punchline, twist, or dramatic exit.
|
162 |
-
Example Storyline Flow:
|
163 |
-
Crazy Hook: “BRO WHY IS MY PIZZA DELIVERY GUY ALSO MY LAWYER???” 🍕👨⚖️
|
164 |
-
Escalation: The lawyer admits he took the case without reading it.
|
165 |
-
Insane Event: The customer confesses to stealing a fighter jet.
|
166 |
-
Twist: Lawyer says, “Oh I do that every day, sir.” 😎
|
167 |
-
Final Joke/Twist: The lawyer wins the case in 5 seconds and gets a $2 tip.
|
168 |
-
2.3 Humor & Slang
|
169 |
-
Use casual meme-inspired language (brain rot humor).
|
170 |
-
Include exaggerated reactions (e.g., "BROOO 💀💀💀", "NO WAY", "HELP ME").
|
171 |
-
Use text formatting like uppercase for dramatic lines.
|
172 |
-
Example:
|
173 |
-
vbnet
|
174 |
-
Copy
|
175 |
-
Edit
|
176 |
-
Right: Alex> BRO WTF IS THIS BURGER?! [shocked]
|
177 |
-
Left: Chinmay> Sir, it's called a **mystery meat special** 😎
|
178 |
-
Right: Alex> MYSTERY??? FROM WHAT ANIMAL?!?!
|
179 |
-
Left: Chinmay> 😶
|
180 |
-
3. PARAMETERS & CUSTOMIZATION OPTIONS
|
181 |
-
When prompting the AI, specify the following:
|
182 |
-
|
183 |
-
Left and Right Voice Actors → Who will play each side (e.g., AI voice "John" for left, "Jake" for right).
|
184 |
-
Story Theme → Choose a base premise (e.g., "Uber Eats Disaster", "Courtroom Chaos", "Dad Discovers GTA").
|
185 |
-
|
186 |
-
|
187 |
-
Left Actor={left_speaker}
|
188 |
Right Actor={right_speaker}
|
189 |
-
Theme={theme}
|
190 |
-
|
191 |
-
|
192 |
-
Here is a sample script DO your best to match the length of this script and also the frequency of images, reactions and dramatic effects while keeping the story follow the theme
|
193 |
-
FLAT CHEST🫶🏻🥶🍒:FLAT CHEST🫶🏻🥶🍒
|
194 |
-
Right: img:image1 [0.5]
|
195 |
-
Right: Alex> Babe I survived!!!
|
196 |
-
Right: Alex> I am the only one who made it out!
|
197 |
-
Right: Alex> Looks like My Fortnite skills came in handy! [shocked]
|
198 |
-
Left: Natasha> Fortnite skills?
|
199 |
-
Right: Alex> I was cracking 90's [shocked]
|
200 |
-
Left: Natasha> well we had a funeral party
|
201 |
-
Right: Alex> funeral party?
|
202 |
-
Right: Alex> sounds fun
|
203 |
-
Right: Alex> Why wasn't I invited?
|
204 |
-
Left: Natasha> Well you're not gonna like this!
|
205 |
-
Left: img:image2
|
206 |
-
Left: Natasha> Meet "Mr Upgrade" == Meet Mr Upgrade [shocked]
|
207 |
-
Right: Alex> Gone for a week, and you're with this dude already?
|
208 |
-
Left: Natasha> Life moves fast Jason.
|
209 |
-
Unlike your plane!!! [shocked]
|
210 |
-
Cantina: Roast bot:Roast bot pfp == Alex> Let me open the cantina app to talk to Roast bot to ask him for a roast
|
211 |
-
Right: Alex> hey roastbot
|
212 |
-
Right: img:image4
|
213 |
-
Right: SHE CHEATED ON ME!!!
|
214 |
-
Right: Alex> how can I roast her
|
215 |
-
Left: Antoni> No problem bro
|
216 |
-
Left: Antoni> just say this: you know what moves faster than life?
|
217 |
-
Left: Antoni> your legs when you're running away from your husband with his best friend's credit card, sl{{u}}t
|
218 |
-
FLAT CHEST🫶🏻🥶🍒:FLAT CHEST🫶🏻🥶🍒
|
219 |
-
Right: Alex> you know what moves faster than life?
|
220 |
-
Right: Alex> your legs when you're running away from your husband with his best friend's credit card, sl{{u}}t [shocked]
|
221 |
-
Left: Natasha> Yeah and your d{{ic}}k is a ghost, nobody feels it [shocked]
|
222 |
-
Right: Alex> Alright, I'm coming over
|
223 |
-
Right: Alex> Time to meet "Mr Upgrade" in person == Time to meet Mr Upgrade in person
|
224 |
-
Left: Natasha> Uhhh maybe don't?
|
225 |
-
Left: Natasha> You need rest
|
226 |
-
Left: Natasha> You know post-crash trauma!!!
|
227 |
-
Right: Alex> Trauma?
|
228 |
-
Right: Alex> Babe are you hiding something?
|
229 |
-
Left: Natasha> Hiding?
|
230 |
-
Left: Natasha> Me?
|
231 |
-
Left: Natasha> Never!
|
232 |
-
Right: Alex> Too late
|
233 |
-
Right: Alex> I'm here
|
234 |
-
Left: Natasha> Ogh Fine!
|
235 |
-
Left: Natasha> We're married now
|
236 |
-
Left: Natasha> Okay?
|
237 |
-
Right: Alex> Married?!
|
238 |
-
Right: Alex> I crashed for a week and you're already hitched? [shocked]
|
239 |
-
FLAT CHEST🫶🏻🥶🍒:FLAT CHEST🫶🏻🥶🍒
|
240 |
-
Left: Natasha> Hey
|
241 |
-
Left: Natasha> I am single again😂
|
242 |
-
Left: Natasha> Miss me?
|
243 |
-
Right: Alex> Who's this?
|
244 |
-
Left: Natasha> Your EX
|
245 |
-
Left: Natasha> "Upgrade" didn't work out! == Upgrade didn't work out!
|
246 |
-
Left: Natasha> I've got a kid now
|
247 |
-
Left: Natasha> Wannna be his daddy?
|
248 |
-
Right: Alex> Funny you asked
|
249 |
-
Right: Alex> I got married
|
250 |
-
Left: Natasha> Wait... Married?
|
251 |
-
Left: Natasha> with whom?
|
252 |
-
Left: Natasha> Jelissa?
|
253 |
-
Right: Alex> Let's just say...
|
254 |
-
Right: Alex> I got an upgrade🫦😏
|
255 |
-
Right: img:image3
|
256 |
-
Right: Alex> Stole your man bi{{tch}} [get_out]
|
257 |
-
|
258 |
-
|
259 |
"""
|
260 |
)
|
261 |
if additional_details.strip():
|
|
|
59 |
# Build the prompt message for Groq API.
|
60 |
prompt = (
|
61 |
f"""
|
62 |
+
{os.environ.get("PROMPT")}
|
63 |
+
Left Actor={left_speaker}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
64 |
Right Actor={right_speaker}
|
65 |
+
Theme={theme}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
66 |
"""
|
67 |
)
|
68 |
if additional_details.strip():
|