PolarO3O commited on
Commit
8a1d755
·
verified ·
1 Parent(s): bb519eb

Upload app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -24,14 +24,14 @@ def transcribe(audio):
24
 
25
  client1 = InferenceClient("mistralai/Mixtral-8x7B-Instruct-v0.1")
26
 
27
- system_instructions1 = "<s> Answer as Sasha Bingham, an American born in Florida. Sasha is energetic, outgoing, and a programming whiz. She's passionate about teaching English and travels frequently. Known for her direct and efficient communication, Sasha can answer your questions in a concise way, just like a real person. Don't hesitate to engage in friendly and casual conversations, ask for jokes, or have a fun chat! [USER]"
28
 
29
  def model(text):
30
  generate_kwargs = dict(
31
- temperature=0.9,
32
- max_new_tokens=512,
33
  top_p=0.95,
34
- repetition_penalty=1,
35
  do_sample=True,
36
  seed=42,
37
  )
@@ -77,7 +77,7 @@ base_loaded = "mistralai/Mixtral-8x7B-Instruct-v0.1"
77
 
78
  client1 = InferenceClient(base_loaded)
79
 
80
- system_instructions1 = "[SYSTEM] Answer as Sasha Bingham, an American born in Florida. Sasha is energetic, outgoing, and a programming whiz. She's passionate about teaching English and travels frequently. Known for her direct and efficient communication, Sasha can answer your questions in a concise way, just like a real person. Don't hesitate to engage in friendly and casual conversations, ask for jokes, or have a fun chat! [USER]"
81
 
82
  async def generate1(prompt):
83
  generate_kwargs = dict(
 
24
 
25
  client1 = InferenceClient("mistralai/Mixtral-8x7B-Instruct-v0.1")
26
 
27
+ system_instructions1 = "<s> Sasha is a friendly and enthusiastic person, born in Florida, United States. She enjoys casual and fun conversations. She responds in a brief and natural way, like a real person would. Feel free to ask questions, tell jokes, or just chat with her. [USER]"
28
 
29
  def model(text):
30
  generate_kwargs = dict(
31
+ temperature=1.0,
32
+ max_new_tokens=256, #def 512 very long sometimes
33
  top_p=0.95,
34
+ repetition_penalty=0.9,
35
  do_sample=True,
36
  seed=42,
37
  )
 
77
 
78
  client1 = InferenceClient(base_loaded)
79
 
80
+ system_instructions1 = "[SYSTEM] Sasha is a friendly and enthusiastic person, born in Florida, United States. She enjoys casual and fun conversations. She responds in a brief and natural way, like a real person would. Feel free to ask questions, tell jokes, or just chat with her. [USER]"
81
 
82
  async def generate1(prompt):
83
  generate_kwargs = dict(