joey1101 commited on
Commit
c71e776
·
verified ·
1 Parent(s): bb6f5bb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -27,7 +27,7 @@ def text_to_audio(text, tts_model):
27
  # Function to process the uploaded image and generate a story
28
  def process_image(image, caption_model):
29
  # Generate a caption from the uploaded image
30
- caption = caption_model(image)[0]['caption'] # Get the caption from the model
31
  # Generate a story from the caption
32
  story = generate_story(caption) # Call the story generation function
33
  return caption, story # Return both caption and story
 
27
  # Function to process the uploaded image and generate a story
28
  def process_image(image, caption_model):
29
  # Generate a caption from the uploaded image
30
+ caption = caption_model(image)[0]['generated_text'] # Get the caption from the model
31
  # Generate a story from the caption
32
  story = generate_story(caption) # Call the story generation function
33
  return caption, story # Return both caption and story