leoxia711 commited on
Commit
dd91b48
·
verified ·
1 Parent(s): 494d656

Update function.py

Browse files
Files changed (1) hide show
  1. function.py +1 -1
function.py CHANGED
@@ -27,7 +27,7 @@ def text2story(text):
27
  model = AutoModelForCausalLM.from_pretrained("openai-community/gpt2")
28
 
29
  prompt = (
30
- f"Please write a short, imaginative story based on the following idea (no more than 100 words):\n\n"
31
  f"{text}\n\nStory:"
32
  )
33
  inputs = tokenizer(prompt, return_tensors="pt")
 
27
  model = AutoModelForCausalLM.from_pretrained("openai-community/gpt2")
28
 
29
  prompt = (
30
+ f"Please write a short, imaginative story based on the following idea (no more than 10 words):\n\n"
31
  f"{text}\n\nStory:"
32
  )
33
  inputs = tokenizer(prompt, return_tensors="pt")