Update app.py
Browse files
app.py
CHANGED
|
@@ -31,7 +31,7 @@ def generate_content(image):
|
|
| 31 |
|
| 32 |
# Create prompt for story
|
| 33 |
prompt = (
|
| 34 |
-
f"Write a funny,
|
| 35 |
f"in third-person narrative, that describes this scene exactly: {caption} "
|
| 36 |
f"mention the exact place, location or venue within {caption}"
|
| 37 |
)
|
|
@@ -40,7 +40,7 @@ def generate_content(image):
|
|
| 40 |
raw = storyer(
|
| 41 |
prompt,
|
| 42 |
max_new_tokens=150,
|
| 43 |
-
temperature=0.
|
| 44 |
top_p=0.9,
|
| 45 |
no_repeat_ngram_size=2,
|
| 46 |
return_full_text=False
|
|
|
|
| 31 |
|
| 32 |
# Create prompt for story
|
| 33 |
prompt = (
|
| 34 |
+
f"Write a funny, interesting children's story that precisely centered on this scene {caption}\nStory:"
|
| 35 |
f"in third-person narrative, that describes this scene exactly: {caption} "
|
| 36 |
f"mention the exact place, location or venue within {caption}"
|
| 37 |
)
|
|
|
|
| 40 |
raw = storyer(
|
| 41 |
prompt,
|
| 42 |
max_new_tokens=150,
|
| 43 |
+
temperature=0.7,
|
| 44 |
top_p=0.9,
|
| 45 |
no_repeat_ngram_size=2,
|
| 46 |
return_full_text=False
|