abdulllah01 commited on
Commit
8278ce8
·
verified ·
1 Parent(s): 0369d1c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +88 -41
app.py CHANGED
@@ -43,96 +43,143 @@ is_ready = bool(theme and left_speaker and right_speaker and contact_name)
43
  if st.button("Generate Conversation", disabled=not is_ready):
44
  # Build the initial prompt.
45
  prompt = f"""
46
- 📌 Objective
47
- Generate a highly engaging and comedic iMessage chat script formatted for video generation.
48
- The script follows a structured left-right chat format, maintains a meme-heavy, brain rot style, and incorporates sound effects, reactions, and the Cantina Roast Bot segment in a specific format.
49
- 📝 Script Structure & Formatting Rules
50
- 1️- Contact Name (Title)
51
  At the beginning of the script, define the contact name, appearing at the top of the iMessage screen.
 
52
  <Contact Name>:<Contact Name>
53
  ✅ Example:
54
- Amir (expensive af delivery guy🍆💸):Amir (expensive af delivery guy🍆💸)
55
- 2️- Dialogue Format
 
56
  Each dialogue line follows this format:
 
57
  <Direction>: <SpeakerName> > <Phrase 1> <Phrase 2> <Phrase 3> <Phrase 4> [Reaction]
58
  Left: Represents the left speaker (User).
59
  Right: Represents the right speaker (Other character).
60
- SpeakerName: A randomly assigned name, but characters do not know their own names.
61
  Phrase Limit: Max 4 phrases per line.
62
  Reaction Cues: Placed at the end of lines, enclosed in square brackets [].
63
  ✅ Example:
64
- Left: Unknown Guy> Bro what is this? This is not food [shocked]
65
- Right: Amir> My guy that's a gourmet dish 🤨 [suspense_music]
66
- Left: Unknown Guy> Gourmet?? It’s literally burnt [explosion]
67
- Right: Amir> Charcoal adds flavor, trust me bro 😎
68
- 3️- Bracketed Cues & Sound Effects
 
69
  Use brackets [ ] for sound effects, reactions, or video cues.
 
70
  [shocked] → Must be used often
71
  [fart2] → Should be used less
72
  [fortnite] → Should be used less
73
  [get_out] → Must ONLY be used at the end of the conversation
74
  ✅ Example:
75
- Right: Amir> BRO WHY IS THERE A RAT IN MY BURGER?!! [shocked] 🐀🍔
76
- Left: Unknown Guy> Extra protein sir 😎
77
- Right: Amir> 💀💀💀 [fortnite]
78
- 4️- Image Placeholders
 
 
 
79
  For inserting images, use:
 
80
  <Direction>: img:<DescriptiveImageName>
81
  ✅ Example:
82
- Left: img:burnt_food_delivery
83
- Right: Amir> BRO WHY IS MY PIZZA LOOKING LIKE CHARCOAL?!! [shocked]
 
84
  Min. 3 images per script.
85
- Descriptive placeholders must be clear.
86
- 5️- Cantina App (Roast Bot Segment)
87
  🚨 Correct Format (ALWAYS THE SAME STRUCTURE)
 
88
  Right speaker initiates by opening Cantina.
89
  Right speaker asks Roast Bot for help.
90
  Left speaker (ALWAYS Antoni) responds.
91
  Right speaker must repeat what Roast Bot told them to say.
92
  Contact Name Title must reappear after Cantina.
93
  ✅ Correct Example:
 
94
  Cantina: Roast bot:Roast bot pfp == Alex> Let me open the cantina app to talk to Roast bot
95
  Right: Alex> Hey Roast Bot
96
- Right: Alex> Amir is mad at me for not wanting to tip him
97
  Right: Alex> help me roast him
98
  Left: Antoni> okay
99
  Left: Antoni> tell him this:
100
- Left: Antoni> maybe you should start working for real and not begging for tips all the time
101
- Amir (expensive af delivery guy🍆💸):Amir (expensive af delivery guy🍆💸)
102
- Right: Alex> maybe you should start working for real and not begging for tips all the time
 
 
103
  🔹 Rules:
 
 
104
  Right speaker MUST repeat the roast word-for-word.
105
  The contact name/title must reappear after the Cantina segment.
106
- DO NOT GIVE HEADING TO SEGMENTS, all the script should be in one flow and should be at least 30 messages long
107
- 6️⃣ Brain Rot Hook (MANDATORY)
108
  Every script must begin with an insane, wacky brain rot hook that immediately grabs attention.
 
109
  ✅ Examples:
110
- "🚨 BRO I JUST ORDERED UBER EATS AND THIS GUY SHOWED UP IN A SPACESHIP???" 🚀👀
111
- "WHY DID MY DAD JUST SAY HE WANTS TO PLAY GTA WITH ME???" 🎮💀
112
- "SIR WHY IS MY LAWYER ALSO MY UBER DRIVER?!" 👨‍⚖🚗💨
 
113
  Must be over-the-top and chaotic.
114
  Encourages immediate engagement.
115
- 7️⃣ Escalation & Progression
116
  The story must escalate into chaos but stay coherent:
 
117
  Start Crazy → Get Crazier → End With a Punchline or Twist
118
  Use sudden twists and reveals to maintain engagement.
119
  The final line should be either a funny resolution or an abrupt exit.
120
  ✅ Example Progression:
 
121
  🚀 Crazy Hook:
122
- "BRO WHY IS MY PIZZA DELIVERY GUY ALSO MY LAWYER???" 🍕👨‍⚖
123
  🔥 Escalation:
124
- "Sir, we found out you stole a fighter jet."
125
  🎭 Insane Event:
126
- "Oh that? I do that every Tuesday, it’s fine."
127
  🤯 Twist:
128
- "Lawyer wins case in 5 seconds and gets a $2 tip."
129
  🏃‍♂️ Dramatic Exit (ALWAYS USE [get_out])
130
- "Left: Lawyer> I quit. [get_out]"
131
- DO NOT USE THESE NAMES IN CONTACT OR IN TEXTS, THESE ARE ONLY TO TELL THE PROGRAM WHICH VOICE TO USE
132
- Left Actor = {left_speaker}
133
- Right Actor = {right_speaker}
134
- Contact Name = {contact_name}
135
- Theme = {theme}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
136
  """
137
  if additional_details.strip():
138
  prompt += f"\nAdditional Details: {additional_details}\n"
 
43
  if st.button("Generate Conversation", disabled=not is_ready):
44
  # Build the initial prompt.
45
  prompt = f"""
46
+
47
+
48
+ Script Structure & Formatting Rules
49
+ 1️ Contact Name (Title)
 
50
  At the beginning of the script, define the contact name, appearing at the top of the iMessage screen.
51
+
52
  <Contact Name>:<Contact Name>
53
  ✅ Example:
54
+
55
+ Liam (Black Market Electronics Dealer 📱💸):Liam (Black Market Electronics Dealer 📱💸)
56
+ 2️ Dialogue Format
57
  Each dialogue line follows this format:
58
+
59
  <Direction>: <SpeakerName> > <Phrase 1> <Phrase 2> <Phrase 3> <Phrase 4> [Reaction]
60
  Left: Represents the left speaker (User).
61
  Right: Represents the right speaker (Other character).
62
+ SpeakerName: A randomly assigned alias (characters do not know their own names).
63
  Phrase Limit: Max 4 phrases per line.
64
  Reaction Cues: Placed at the end of lines, enclosed in square brackets [].
65
  ✅ Example:
66
+
67
+ Left: MysteryGuy> BRO WHY IS MY COMPUTER SPEAKING LATIN??? [shocked]
68
+ Right: Liam> Uh… you *might* have summoned something 💀 [suspense_music]
69
+ Left: MysteryGuy> SUMMONED WHAT???
70
+ Right: Liam> 😶
71
+ 3️ Bracketed Cues & Sound Effects
72
  Use brackets [ ] for sound effects, reactions, or video cues.
73
+
74
  [shocked] → Must be used often
75
  [fart2] → Should be used less
76
  [fortnite] → Should be used less
77
  [get_out] → Must ONLY be used at the end of the conversation
78
  ✅ Example:
79
+
80
+
81
+ Right: Max> BRO WHY IS THERE A ROBOT FOLLOWING ME?!! [shocked] 🤖
82
+ Left: UnknownDude> Congrats, you just activated *follow mode* 😎
83
+ Right: Max> FOLLOW MODE??? TURN IT OFF
84
+ Left: UnknownDude> nahhh that's a premium feature 🤣💀 [fortnite]
85
+ 4️ Image Placeholders
86
  For inserting images, use:
87
+
88
  <Direction>: img:<DescriptiveImageName>
89
  ✅ Example:
90
+
91
+ Left: img:ancient_phone_booting_up
92
+ Right: Liam> WHY DID MY OLD NOKIA JUST START SCREAMING??? [shocked]
93
  Min. 3 images per script.
94
+ Descriptive placeholders must be varied and clear.
95
+ 5️⃣ Cantina App (Roast Bot Segment)
96
  🚨 Correct Format (ALWAYS THE SAME STRUCTURE)
97
+
98
  Right speaker initiates by opening Cantina.
99
  Right speaker asks Roast Bot for help.
100
  Left speaker (ALWAYS Antoni) responds.
101
  Right speaker must repeat what Roast Bot told them to say.
102
  Contact Name Title must reappear after Cantina.
103
  ✅ Correct Example:
104
+
105
  Cantina: Roast bot:Roast bot pfp == Alex> Let me open the cantina app to talk to Roast bot
106
  Right: Alex> Hey Roast Bot
107
+ Right: Alex> Liam is mad at me for borrowing his Tesla without permission
108
  Right: Alex> help me roast him
109
  Left: Antoni> okay
110
  Left: Antoni> tell him this:
111
+ Left: Antoni> maybe if you had better security, you wouldn’t have to track your car on Find My iPhone.
112
+ Liam (Tesla Rental King ⚡🚗):Liam (Tesla Rental King ⚡🚗)
113
+ Right: Alex> maybe if you had better security, you wouldn’t have to track your car on Find My iPhone.
114
+ 🚫 Incorrect Example (DO NOT DO THIS):
115
+ Cantina: Roast bot:Roast bot pfp == Liam> Hey Roast Bot, we need your help! My AI fridge is trying to blackmail me! ❌
116
  🔹 Rules:
117
+
118
+ Left Speaker in Cantina is ALWAYS "Antoni."
119
  Right speaker MUST repeat the roast word-for-word.
120
  The contact name/title must reappear after the Cantina segment.
121
+ 6️ Brain Rot Hook (MANDATORY)
 
122
  Every script must begin with an insane, wacky brain rot hook that immediately grabs attention.
123
+
124
  ✅ Examples:
125
+
126
+ "WHY DID MY TV JUST ASK ME FOR A PASSWORD???" 📺🔑
127
+ "BRO MY DOG JUST SENT ME A TEXT MESSAGE???" 🐶📲
128
+ "WHY IS MY LANDLORD SELLING MY HOUSE ON FACEBOOK MARKETPLACE???" 🏠💀
129
  Must be over-the-top and chaotic.
130
  Encourages immediate engagement.
131
+ 7️ Escalation & Progression
132
  The story must escalate into chaos but stay coherent:
133
+
134
  Start Crazy → Get Crazier → End With a Punchline or Twist
135
  Use sudden twists and reveals to maintain engagement.
136
  The final line should be either a funny resolution or an abrupt exit.
137
  ✅ Example Progression:
138
+
139
  🚀 Crazy Hook:
140
+ "BRO WHY DID MY PHONE JUST ORDER A UBER ON ITS OWN???" 🚗💨
141
  🔥 Escalation:
142
+ "Wait… it’s taking me somewhere???"
143
  🎭 Insane Event:
144
+ "THE DESTINATION IS *AREA 51*??? 💀"
145
  🤯 Twist:
146
+ "The driver is an AI and won’t let me out."
147
  🏃‍♂️ Dramatic Exit (ALWAYS USE [get_out])
148
+ "Left: UnknownDude> Enjoy the ride 😎 [get_out]"
149
+ 8️⃣ Speaker Name Randomization
150
+ 🚨 Speakers should NOT know their own names.
151
+
152
+ Left speaker’s name should always appear as "Unknown Guy" or a random alias.
153
+ Right speaker’s name should also be replaced with something generic unless necessary.
154
+ The system should NOT recognize them.
155
+ ✅ Example:
156
+
157
+ Left: MysteriousCaller> BRO WHO JUST HACKED MY PHONE??? [shocked]
158
+ Right: HackerDude> Oh, don’t worry, it's just an update 😎
159
+ Left: MysteriousCaller> UPDATE??? BRO WHAT DO YOU MEAN
160
+ Right: HackerDude> New feature, remote control access 🤖
161
+ 9️⃣ Customization Features
162
+ Add Speaker Names Manually → Left and Right speakers should be customizable.
163
+ Emoji Button → Clicking adds 5 random emojis to any phrase.
164
+ Max 9 sound effect commands, with [shocked] used most.
165
+ Final Parameters & Instructions
166
+ When prompting the AI, specify:
167
+
168
+ Left Actor = {left_speaker}
169
+ Right Actor = {right_speaker}
170
+ Theme = {theme} (e.g., “AI Gone Wrong”, “Haunted Electronics”, “Unexpected Legal Trouble”)
171
+ Cantina Segment = Required
172
+ Minimum 3 images
173
+ [shocked] must be frequent, [get_out] must be at the end.
174
+ Speaker names are randomized and unknown to them.
175
+ 📌 Summary
176
+ 🔹 Title appears at the start and after Cantina.
177
+ 🔹 Dialogue follows max 4 phrases per line.
178
+ 🔹 Cantina Roast Bot always follows the same structure.
179
+ 🔹 Brain rot hook is mandatory.
180
+ 🔹 Escalates into chaos but remains coherent.
181
+
182
+
183
  """
184
  if additional_details.strip():
185
  prompt += f"\nAdditional Details: {additional_details}\n"