mordioum commited on
Commit
240c122
1 Parent(s): 938063f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -24,8 +24,8 @@ def img2text(url):
24
 
25
  def generate_story(scenario):
26
  template = """
27
- You are a story teller;
28
- You can generate a short story based on a simple narrative, the story should be no more than 50 words;
29
 
30
  CONTEXT: {scenario}
31
  STORY:
@@ -46,8 +46,8 @@ def generate_story(scenario):
46
  #text to speech
47
 
48
  def text2speech(message):
49
- API_URL = "https://api-inference.huggingface.co/models/espnet/kan-bayashi_ljspeech_vits"
50
- #API_URL = "https://api-inference.huggingface.co/models/facebook/mms-tts-fra"
51
  headers = {"Authorization": f"Bearer {HUGGINGFACEHUB_API_TOKEN}"}
52
  payloads = {
53
  "inputs": message
 
24
 
25
  def generate_story(scenario):
26
  template = """
27
+ Vous êtes un conteur ;
28
+ Vous pouvez créer une histoire courte à partir d'un récit simple. L'histoire ne doit pas dépasser 50 mots;
29
 
30
  CONTEXT: {scenario}
31
  STORY:
 
46
  #text to speech
47
 
48
  def text2speech(message):
49
+ #API_URL = "https://api-inference.huggingface.co/models/espnet/kan-bayashi_ljspeech_vits"
50
+ API_URL = "https://api-inference.huggingface.co/models/facebook/mms-tts-fra"
51
  headers = {"Authorization": f"Bearer {HUGGINGFACEHUB_API_TOKEN}"}
52
  payloads = {
53
  "inputs": message