bitliu commited on
Commit
ebe7362
·
1 Parent(s): ca9429f

Signed-off-by: bitliu <[email protected]>

Files changed (2) hide show
  1. app.py +13 -34
  2. requirements.txt +2 -2
app.py CHANGED
@@ -175,31 +175,15 @@ EXAMPLES_PII = [
175
  ]
176
 
177
  # ============== Gradio Interface ==============
178
- custom_css = """
179
- .gradio-container {
180
- max-width: 1200px !important;
181
- }
182
- .header-logo {
183
- display: flex;
184
- align-items: center;
185
- gap: 20px;
186
- margin-bottom: 10px;
187
- }
188
- .header-logo img {
189
- height: 50px;
190
- }
191
- """
192
 
193
- with gr.Blocks(title="LLM Semantic Router - Model Playground", css=custom_css) as demo:
194
- with gr.Row():
195
- gr.Image("vllm-logo.png", show_label=False, height=60, width=120,
196
- container=False, show_download_button=False)
197
- gr.Markdown(
198
- """
199
- # 🚀 LLM Semantic Router
200
- **Model Playground** - ModernBERT Classifiers for LLM Safety & Routing
201
- """
202
- )
203
 
204
  with gr.Tabs():
205
  # Tab 1: Fact Check
@@ -272,17 +256,12 @@ with gr.Blocks(title="LLM Semantic Router - Model Playground", css=custom_css) a
272
  ner_btn.click(classify_tokens, ner_input, [ner_output, ner_highlight])
273
  ner_input.submit(classify_tokens, ner_input, [ner_output, ner_highlight])
274
 
275
- gr.HTML(
276
  """
277
- <hr style="margin-top: 30px;">
278
- <div style="text-align: center; color: #666; font-size: 14px;">
279
- <p>
280
- <strong>Models</strong>: <a href="https://huggingface.co/LLM-Semantic-Router" target="_blank">LLM-Semantic-Router</a> |
281
- <strong>Architecture</strong>: ModernBERT |
282
- <strong>GitHub</strong>: <a href="https://github.com/vllm-project/semantic-router" target="_blank">vllm-project/semantic-router</a>
283
- </p>
284
- <p>Part of the <a href="https://github.com/vllm-project/vllm" target="_blank">vLLM</a> ecosystem</p>
285
- </div>
286
  """
287
  )
288
 
 
175
  ]
176
 
177
  # ============== Gradio Interface ==============
178
+ with gr.Blocks() as demo:
179
+ gr.Markdown(
180
+ """
181
+ # 🚀 LLM Semantic Router - Model Playground
182
+ **ModernBERT Classifiers for LLM Safety & Routing**
 
 
 
 
 
 
 
 
 
183
 
184
+ Part of the [vLLM](https://github.com/vllm-project/vllm) ecosystem
185
+ """
186
+ )
 
 
 
 
 
 
 
187
 
188
  with gr.Tabs():
189
  # Tab 1: Fact Check
 
256
  ner_btn.click(classify_tokens, ner_input, [ner_output, ner_highlight])
257
  ner_input.submit(classify_tokens, ner_input, [ner_output, ner_highlight])
258
 
259
+ gr.Markdown(
260
  """
261
+ ---
262
+ **Models**: [LLM-Semantic-Router](https://huggingface.co/LLM-Semantic-Router) |
263
+ **Architecture**: ModernBERT |
264
+ **GitHub**: [vllm-project/semantic-router](https://github.com/vllm-project/semantic-router)
 
 
 
 
 
265
  """
266
  )
267
 
requirements.txt CHANGED
@@ -1,4 +1,4 @@
1
  torch
2
- transformers>=4.56.0
3
- gradio>=5.0.0
4
 
 
1
  torch
2
+ transformers>=4.36.0
3
+ gradio
4