kabbi commited on
Commit
5511411
1 Parent(s): 8da4de5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -5
app.py CHANGED
@@ -6,15 +6,15 @@ from transformers import AutoModelForCausalLM, AutoTokenizer, TextIteratorStream
6
  import gradio as gr
7
  from threading import Thread
8
 
9
- MODEL_LIST = ["mistralai/Mistral-Nemo-Instruct-2407"]
10
  HF_TOKEN = os.environ.get("HF_TOKEN", None)
11
  MODEL = os.environ.get("MODEL_ID")
12
 
13
- TITLE = "<h1><center>Mistral-Nemo</center></h1>"
14
 
15
  PLACEHOLDER = """
16
  <center>
17
- <p>The Mistral-Nemo is a pretrained generative text model of 12B parameters trained jointly by Mistral AI and NVIDIA.</p>
18
  </center>
19
  """
20
 
@@ -75,7 +75,8 @@ def stream_chat(
75
  top_k = top_k,
76
  temperature = temperature,
77
  streamer=streamer,
78
- pad_token_id = 10,
 
79
  )
80
 
81
  with torch.no_grad():
@@ -109,7 +110,7 @@ with gr.Blocks(css=CSS, theme="soft") as demo:
109
  ),
110
  gr.Slider(
111
  minimum=128,
112
- maximum=8192,
113
  step=1,
114
  value=1024,
115
  label="Max new tokens",
 
6
  import gradio as gr
7
  from threading import Thread
8
 
9
+ MODEL_LIST = ["LGAI-EXAONE/EXAONE-3.0-7.8B-Instruct"]
10
  HF_TOKEN = os.environ.get("HF_TOKEN", None)
11
  MODEL = os.environ.get("MODEL_ID")
12
 
13
+ TITLE = "<h1><center>EXAONE-3.0-7.8B-Instruct</center></h1>"
14
 
15
  PLACEHOLDER = """
16
  <center>
17
+ <p>EXAONE-3.0-7.8B-Instruct is a pre-trained and instruction-tuned bilingual (English and Korean) generative model with 7.8 billion parameters</p>
18
  </center>
19
  """
20
 
 
75
  top_k = top_k,
76
  temperature = temperature,
77
  streamer=streamer,
78
+ pad_token_id = 0,
79
+ eos_token_id = tokenizer.eos_token_id # 361
80
  )
81
 
82
  with torch.no_grad():
 
110
  ),
111
  gr.Slider(
112
  minimum=128,
113
+ maximum=4096,
114
  step=1,
115
  value=1024,
116
  label="Max new tokens",