manthilaffs commited on
Commit
8a9554d
·
verified ·
1 Parent(s): f600a11

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -6
app.py CHANGED
@@ -57,16 +57,12 @@ def infer(message, history, enable_history=False, max_new_tokens=512):
57
 
58
  # ---------------- UI ----------------
59
  with gr.Blocks() as demo:
60
- gr.Markdown("## 🧠 Gamunu 4B Instruct Alpha — Sinhala Instruct LLM")
61
-
62
- with gr.Accordion("⚙️ Advanced Settings", open=False):
63
- enable_history = gr.Checkbox(label="Enable chat history", value=False)
64
- max_new_tokens = gr.Slider(64, 1024, value=512, step=32, label="🔢 Max New Tokens")
65
 
66
  # Use only stable arguments (compatible everywhere)
67
  chat = gr.ChatInterface(
68
  fn=lambda message, history: infer(message, history, enable_history.value, max_new_tokens.value),
69
- title="Gamunu 4B Instruct Alpha",
70
  examples=[
71
  ["ෆොටෝසින්තසිස් ක්‍රියාවලිය පැහැදිලි කරන්න."],
72
  ["මෙම වාක්‍යය සිංහලයට පරිවර්තනය කරන්න: 'The sun rises in the east.'"],
@@ -75,6 +71,9 @@ with gr.Blocks() as demo:
75
  ["ඔබ කවියෙකු ලෙස 'ගඟක්' ගැන කෙටි කවියක් ලියන්න."],
76
  ]
77
  )
 
 
 
78
 
79
  gr.Markdown("""
80
  ---
 
57
 
58
  # ---------------- UI ----------------
59
  with gr.Blocks() as demo:
60
+ # gr.Markdown("## 🧠 Gamunu 4B Instruct Alpha — Sinhala Instruct LLM")
 
 
 
 
61
 
62
  # Use only stable arguments (compatible everywhere)
63
  chat = gr.ChatInterface(
64
  fn=lambda message, history: infer(message, history, enable_history.value, max_new_tokens.value),
65
+ title="🧠 Gamunu 4B Instruct — සිංහල LLM",
66
  examples=[
67
  ["ෆොටෝසින්තසිස් ක්‍රියාවලිය පැහැදිලි කරන්න."],
68
  ["මෙම වාක්‍යය සිංහලයට පරිවර්තනය කරන්න: 'The sun rises in the east.'"],
 
71
  ["ඔබ කවියෙකු ලෙස 'ගඟක්' ගැන කෙටි කවියක් ලියන්න."],
72
  ]
73
  )
74
+ with gr.Accordion("⚙️ Advanced Settings", open=False):
75
+ enable_history = gr.Checkbox(label="Enable chat history", value=False)
76
+ max_new_tokens = gr.Slider(64, 1024, value=512, step=32, label="🔢 Max New Tokens")
77
 
78
  gr.Markdown("""
79
  ---