lkm2835 commited on
Commit
3470d92
1 Parent(s): 447b868

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +19 -3
app.py CHANGED
@@ -13,6 +13,8 @@ EXAONE_TOKEN = os.environ.get("EXAONE_TOKEN", None)
13
  EXAONE_2_4B = os.environ.get("EXAONE_2_4B", None)
14
  EXAONE_7_8B = os.environ.get("EXAONE_7_8B", None)
15
  EXAONE_32B = os.environ.get("EXAONE_32B", None)
 
 
16
  MODEL = "LGAI-EXAONE/EXAONE-3.5-2.4B-Instruct"
17
  MAX_NEW_TOKENS = 4096
18
  DEFAULT_MAX_NEW_TOKENS = 512
@@ -120,8 +122,14 @@ def generate(
120
 
121
 
122
  def radio1_change(model_size):
123
- return f"<center><font size=5>EXAONE-3.5-{model_size}-instruct</center>"
124
-
 
 
 
 
 
 
125
 
126
  def choices_model(model_size):
127
  endpoint_url_dict = {
@@ -151,7 +159,15 @@ with gr.Blocks(fill_height=True) as demo:
151
  gr.Markdown("""<p align="center"><img src="https://huggingface.co/spaces/LGAI-EXAONE/EXAONE-3.5-Instruct-Demo/resolve/main/EXAONE_Symbol%2BBI_3d.png" style="margin-right: 20px; height: 50px"/><p>""")
152
  gr.Markdown(DESCRIPTION)
153
 
154
- markdown = gr.Markdown("<center><font size=5>EXAONE-3.5-2.4B-instruct</center>")
 
 
 
 
 
 
 
 
155
  with gr.Row():
156
  model_size = ["2.4B", "7.8B", "32B"]
157
  radio1 = gr.Radio(choices=model_size, label="EXAONE-3.5-Instruct", value=model_size[0])
 
13
  EXAONE_2_4B = os.environ.get("EXAONE_2_4B", None)
14
  EXAONE_7_8B = os.environ.get("EXAONE_7_8B", None)
15
  EXAONE_32B = os.environ.get("EXAONE_32B", None)
16
+ FRIENDLIAI = "https://friendli.ai"
17
+ FRIENDLIAI_LOGO = "https://huggingface.co/spaces/LGAI-EXAONE/EXAONE-3.5-Instruct-Demo/resolve/main/friendliai-logo.png"
18
  MODEL = "LGAI-EXAONE/EXAONE-3.5-2.4B-Instruct"
19
  MAX_NEW_TOKENS = 4096
20
  DEFAULT_MAX_NEW_TOKENS = 512
 
122
 
123
 
124
  def radio1_change(model_size):
125
+ markdown_ = f"""
126
+ <div style="display: flex; width: 450px; margin-left: 525px; font-size: 20px;">
127
+ <span style="margin-top: 6px; margin-right: -2px">EXAONE-3.5-{model_size}-instruct </span>
128
+ <span style="margin-top: 10px; margin-left: 7px; font-size: 16px;">powered by</span>
129
+ <a href={FRIENDLIAI}><img src={FRIENDLIAI_LOGO} style="margin-left: -4px; height: 41px;"/></a>
130
+ </div>
131
+ """
132
+ return markdown_
133
 
134
  def choices_model(model_size):
135
  endpoint_url_dict = {
 
159
  gr.Markdown("""<p align="center"><img src="https://huggingface.co/spaces/LGAI-EXAONE/EXAONE-3.5-Instruct-Demo/resolve/main/EXAONE_Symbol%2BBI_3d.png" style="margin-right: 20px; height: 50px"/><p>""")
160
  gr.Markdown(DESCRIPTION)
161
 
162
+ markdown = gr.Markdown(
163
+ f"""
164
+ <div style="display: flex; width: 450px; margin-left: 525px; font-size: 20px;">
165
+ <span style="margin-top: 6px; margin-right: -2px">EXAONE-3.5-2.4B-instruct </span>
166
+ <span style="margin-top: 10px; margin-left: 7px; font-size: 16px;">powered by</span>
167
+ <a href={FRIENDLIAI}><img src={FRIENDLIAI_LOGO} style="margin-left: -4px; height: 41px;"/></a>
168
+ </div>
169
+ """
170
+ )
171
  with gr.Row():
172
  model_size = ["2.4B", "7.8B", "32B"]
173
  radio1 = gr.Radio(choices=model_size, label="EXAONE-3.5-Instruct", value=model_size[0])