sunbal7 commited on
Commit
75f839c
·
verified ·
1 Parent(s): 08b539a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -220,11 +220,11 @@ CONCEPTS = {
220
  }
221
  }
222
 
223
- # Pre-generated animation examples
224
  ANIMATION_EXAMPLES = {
225
- "loop": "https://i.imgur.com/7zQY1eE.gif",
226
- "conditional": "https://i.imgur.com/5X8jYAy.gif",
227
- "function": "https://i.imgur.com/9zJkQ7P.gif"
228
  }
229
 
230
  # Initialize AI models
@@ -319,9 +319,9 @@ def create_animation_preview(story, concept):
319
  """Create an animation preview for the concept"""
320
  try:
321
  # Return a sample GIF for the concept
322
- return ANIMATION_EXAMPLES.get(concept, "https://i.imgur.com/7zQY1eE.gif")
323
  except:
324
- return "https://i.imgur.com/7zQY1eE.gif"
325
 
326
  def text_to_speech_custom(text, models, filename="story_audio.wav"):
327
  """Convert text to speech using AI model"""
 
220
  }
221
  }
222
 
223
+ # Updated animation examples with reliable URLs
224
  ANIMATION_EXAMPLES = {
225
+ "loop": "https://media.giphy.com/media/3o7abKhOpu0NwenH3O/giphy.gif",
226
+ "conditional": "https://media.giphy.com/media/l0HlG8vJXW0X5yX4s/giphy.gif",
227
+ "function": "https://media.giphy.com/media/3o7TKsQ8UQ4l4LhGz6/giphy.gif"
228
  }
229
 
230
  # Initialize AI models
 
319
  """Create an animation preview for the concept"""
320
  try:
321
  # Return a sample GIF for the concept
322
+ return ANIMATION_EXAMPLES.get(concept, "https://media.giphy.com/media/3o7abKhOpu0NwenH3O/giphy.gif")
323
  except:
324
+ return "https://media.giphy.com/media/3o7abKhOpu0NwenH3O/giphy.gif"
325
 
326
  def text_to_speech_custom(text, models, filename="story_audio.wav"):
327
  """Convert text to speech using AI model"""