cstr commited on
Commit
2ecb90c
Β·
verified Β·
1 Parent(s): ce55771

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +23 -12
app.py CHANGED
@@ -72,7 +72,13 @@ MODEL_CONTEXT_SIZES = {
72
  "google/gemma-2-2b-it": 2048,
73
  "openai-community/gpt2": 1024,
74
  "microsoft/phi-2": 2048,
75
- "TinyLlama/TinyLlama-1.1B-Chat-v1.0": 2048
 
 
 
 
 
 
76
  },
77
  "Groq API": {
78
  "gemma2-9b-it": 8192,
@@ -107,8 +113,7 @@ MODEL_CONTEXT_SIZES = {
107
  },
108
  "GLHF API": {
109
  "mistralai/Mixtral-8x7B-Instruct-v0.1": 32768,
110
- "mistralai/Mixtral-8x7B-Instruct-v0.2": 32768,
111
- "NousResearch/Nous-Hermes-2-Solar-10.7B": 32768,
112
  "01-ai/Yi-34B-Chat": 32768,
113
  "mistralai/Mistral-7B-Instruct-v0.3": 32768,
114
  "microsoft/phi-3-mini-4k-instruct": 4096,
@@ -1000,7 +1005,21 @@ with gr.Blocks(css="""
1000
  )
1001
 
1002
  send_to_model_btn = gr.Button("πŸš€ Send to Model", variant="primary")
1003
- open_chatgpt_button = gr.Button("🌐 Open ChatGPT")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1004
 
1005
  with gr.Column(scale=1):
1006
  summary_output = gr.Textbox(
@@ -1297,14 +1316,6 @@ with gr.Blocks(css="""
1297
  logging.error(f"Error creating download file: {e}")
1298
  return []
1299
 
1300
- # ChatGPT handler
1301
- open_chatgpt_button.click(
1302
- fn=lambda: "window.open('https://chat.openai.com/', '_blank'); return 'Opened ChatGPT in new tab';",
1303
- inputs=None,
1304
- outputs=progress_status,
1305
- js=True
1306
- )
1307
-
1308
  # Model processing
1309
  # Model processing button
1310
  send_to_model_btn.click(
 
72
  "google/gemma-2-2b-it": 2048,
73
  "openai-community/gpt2": 1024,
74
  "microsoft/phi-2": 2048,
75
+ "TinyLlama/TinyLlama-1.1B-Chat-v1.0": 2048,
76
+ "VAGOsolutions/Llama-3-SauerkrautLM-8b-Instruct": 2048,
77
+ "VAGOsolutions/Llama-3.1-SauerkrautLM-8b-Instruct": 4096,
78
+ "VAGOsolutions/SauerkrautLM-Nemo-12b-Instruct": 4096,
79
+ "openGPT-X/Teuken-7B-instruct-research-v0.4": 4096,
80
+ "Qwen/Qwen2.5-7B-Instruct": 131072,
81
+ "tiiuae/falcon-7b-instruct": 8192,
82
  },
83
  "Groq API": {
84
  "gemma2-9b-it": 8192,
 
113
  },
114
  "GLHF API": {
115
  "mistralai/Mixtral-8x7B-Instruct-v0.1": 32768,
116
+ # "NousResearch/Nous-Hermes-2-Solar-10.7B": 32768,
 
117
  "01-ai/Yi-34B-Chat": 32768,
118
  "mistralai/Mistral-7B-Instruct-v0.3": 32768,
119
  "microsoft/phi-3-mini-4k-instruct": 4096,
 
1005
  )
1006
 
1007
  send_to_model_btn = gr.Button("πŸš€ Send to Model", variant="primary")
1008
+
1009
+ with gr.Row():
1010
+ chatgpt_link = gr.HTML(
1011
+ """
1012
+ <div style="text-align: center; margin: 10px;">
1013
+ <a href="https://chat.openai.com/" target="_blank"
1014
+ style="display: inline-block; padding: 10px 20px;
1015
+ background-color: #2C3E50; color: white;
1016
+ text-decoration: none; border-radius: 5px;
1017
+ font-weight: bold;">
1018
+ 🌐 Open ChatGPT in New Tab
1019
+ </a>
1020
+ </div>
1021
+ """
1022
+ )
1023
 
1024
  with gr.Column(scale=1):
1025
  summary_output = gr.Textbox(
 
1316
  logging.error(f"Error creating download file: {e}")
1317
  return []
1318
 
 
 
 
 
 
 
 
 
1319
  # Model processing
1320
  # Model processing button
1321
  send_to_model_btn.click(