xieqilenb commited on
Commit
c0e3d61
·
verified ·
1 Parent(s): e61b3fb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -27,13 +27,13 @@ def generate_story(caption):
27
  "Using the image details provided below, please craft an enchanting tale tailored for children aged 3 to 10. "
28
  "Rather than simply reiterating the image details, enhance your story with imaginative characters, quirky adventures, "
29
  "and delightful surprises that ignite wonder in every young heart. Let your narrative flow naturally and kindle the magic of storytelling. "
30
- "Please ensure that your story is engaging, coherent, and falls between 100 and 300 words in length.\n\n"
31
  f"Image Details: {caption}\n\nStory:"
32
  )
33
 
34
  result = story_generator(
35
  prompt,
36
- max_length=300,
37
  num_return_sequences=1,
38
  do_sample=True,
39
  temperature=1.0
 
27
  "Using the image details provided below, please craft an enchanting tale tailored for children aged 3 to 10. "
28
  "Rather than simply reiterating the image details, enhance your story with imaginative characters, quirky adventures, "
29
  "and delightful surprises that ignite wonder in every young heart. Let your narrative flow naturally and kindle the magic of storytelling. "
30
+ "Please ensure that your story is engaging, coherent, and the words count should lower than 100 in length.\n\n"
31
  f"Image Details: {caption}\n\nStory:"
32
  )
33
 
34
  result = story_generator(
35
  prompt,
36
+ max_length=100,
37
  num_return_sequences=1,
38
  do_sample=True,
39
  temperature=1.0