Jaward commited on
Commit
3133efe
·
verified ·
1 Parent(s): 4e2868d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -26,7 +26,7 @@ def transcribe(audio):
26
  HF_TOKEN = os.environ.get("HF_TOKEN", None)
27
 
28
  def client_fn(model):
29
- if "Llama 3B Service" in model:
30
  return OpenAI(
31
  base_url="http://52.76.81.56:60002/v1",
32
  api_key="token-abc123"
@@ -65,7 +65,7 @@ def models(text, model="Llama 3B Service", seed=42):
65
 
66
  client = client_fn(model)
67
 
68
- if "Llama 3B Service" in model:
69
  messages = [
70
  {"role": "system", "content": system_instructions1},
71
  ] + conversation_history + [
@@ -181,13 +181,13 @@ with gr.Blocks(css="style.css") as demo:
181
  with gr.Tabs() as tabs:
182
  with gr.TabItem("Voice Assistant") as voice_assistant:
183
  select = gr.Dropdown([
184
- 'Llama 3B Service',
185
  'Mixtral 8x7B',
186
  'Llama 3 8B',
187
  'Mistral 7B v0.3',
188
  'Phi 3 mini',
189
  ],
190
- value="Llama 3B Service",
191
  label="Model"
192
  )
193
  seed = gr.Slider(
 
26
  HF_TOKEN = os.environ.get("HF_TOKEN", None)
27
 
28
  def client_fn(model):
29
+ if "Llama 3 8B Service" in model:
30
  return OpenAI(
31
  base_url="http://52.76.81.56:60002/v1",
32
  api_key="token-abc123"
 
65
 
66
  client = client_fn(model)
67
 
68
+ if "Llama 3 8B Service" in model:
69
  messages = [
70
  {"role": "system", "content": system_instructions1},
71
  ] + conversation_history + [
 
181
  with gr.Tabs() as tabs:
182
  with gr.TabItem("Voice Assistant") as voice_assistant:
183
  select = gr.Dropdown([
184
+ 'Llama 3 8B Service',
185
  'Mixtral 8x7B',
186
  'Llama 3 8B',
187
  'Mistral 7B v0.3',
188
  'Phi 3 mini',
189
  ],
190
+ value="Llama 3 8B Service",
191
  label="Model"
192
  )
193
  seed = gr.Slider(