speed-chart / app.py
3morixd's picture
Upload app.py with huggingface_hub
d786e6c verified
Raw
History Blame Contribute Delete
1.38 kB
import gradio as gr
import pandas as pd
import json
MODELS = [
{"Model": "SmolLM2-135M", "Speed (t/s)": 59.7, "Size (MB)": 101},
{"Model": "TinyLlama-1.1B-int4", "Speed (t/s)": 17.6, "Size (MB)": 400},
{"Model": "Qwen2.5-0.5B-Server", "Speed (t/s)": 16.7, "Size (MB)": 1000},
{"Model": "Qwen2.5-0.5B-Chinese", "Speed (t/s)": 16.4, "Size (MB)": 1000},
{"Model": "Qwen2.5-Math-1.5B", "Speed (t/s)": 15.7, "Size (MB)": 3000},
{"Model": "Qwen2.5-0.5B-int4", "Speed (t/s)": 12.5, "Size (MB)": 469},
{"Model": "Llama-3.2-1B-Q4", "Speed (t/s)": 11.3, "Size (MB)": 770},
{"Model": "TinyLlama-1.1B-Q5", "Speed (t/s)": 10.9, "Size (MB)": 800},
{"Model": "Gemma-2-2B-IT", "Speed (t/s)": 8.2, "Size (MB)": 5000},
{"Model": "Phi-3.5-mini", "Speed (t/s)": 8.6, "Size (MB)": 7600},
{"Model": "Llama-3.2-3B", "Speed (t/s)": 4.8, "Size (MB)": 6000},
]
df = pd.DataFrame(MODELS)
with gr.Blocks(theme=gr.themes.Soft(primary_hue="blue"), title="dispatchAI Speed Chart") as demo:
gr.Markdown("# πŸ“Š dispatchAI Model Speed Comparison")
gr.Markdown("Real CPU benchmark data. All models verified working June 2026.")
gr.BarPlot(df, x="Model", y="Speed (t/s)", title="Inference Speed (tokens/sec)", height=400)
gr.Dataframe(df, label="Full Data")
gr.Markdown("---\nπŸš€ [dispatchAI](https://huggingface.co/dispatchAI)")
demo.launch()