Rifqidits commited on
Commit
e2b7d51
·
1 Parent(s): 237037e

Change to Bahasa Indonesia and change font type

Browse files
Files changed (1) hide show
  1. app.py +24 -11
app.py CHANGED
@@ -112,11 +112,24 @@ def chat_interface(json_data, question, history):
112
 
113
  # === Gradio UI ===
114
  with gr.Blocks(title="TAT-LLM: Semi-Tabular Data QA", theme=gr.themes.Soft()) as demo:
 
 
 
 
 
 
 
 
 
 
 
 
 
115
  gr.Markdown("""
116
- # TAT-LLM: Semi-Tabular Data Question Answering
117
 
118
- Upload an XLSX file containing tables and paragraphs, then ask questions about the data.
119
- The system will convert your file to JSON format and use the fine-tuned TAT-LLM model to answer questions.
120
  """)
121
 
122
  # State to store JSON data
@@ -154,11 +167,11 @@ with gr.Blocks(title="TAT-LLM: Semi-Tabular Data QA", theme=gr.themes.Soft()) as
154
 
155
  with gr.Column(scale=1):
156
  # Chat interface
157
- gr.Markdown("### Ask Questions About Your Data")
158
  chatbot = gr.Chatbot(height=400)
159
  msg = gr.Textbox(
160
- label="Question",
161
- placeholder="Ask a question about the table data...",
162
  lines=2
163
  )
164
 
@@ -169,11 +182,11 @@ with gr.Blocks(title="TAT-LLM: Semi-Tabular Data QA", theme=gr.themes.Soft()) as
169
  # Example questions
170
  gr.Examples(
171
  examples=[
172
- "What insights can we get from this data?",
173
- "What is the year-over-year change?",
174
- "What are the key trends in the data?",
175
- "Calculate the percentage change between years",
176
- "What recommendations would you make based on this data?"
177
  ],
178
  inputs=msg
179
  )
 
112
 
113
  # === Gradio UI ===
114
  with gr.Blocks(title="TAT-LLM: Semi-Tabular Data QA", theme=gr.themes.Soft()) as demo:
115
+ gr.HTML("""
116
+ <style>
117
+ body, .gradio-container {
118
+ font-family: 'Poppins', sans-serif;
119
+ }
120
+
121
+ h1, h2, h3, h4, h5 {
122
+ font-family: 'Poppins', sans-serif;
123
+ }
124
+ </style>
125
+ <link href="https://fonts.googleapis.com/css2?family=Poppins&display=swap" rel="stylesheet">
126
+ """)
127
+
128
  gr.Markdown("""
129
+ # terTATa: Dari Tabel dan Teks Menjadi Langkah Bisnis Strategis
130
 
131
+ Unggah berkas XLSX berisi tabel dan paragraf, lalu ajukan pertanyaan tentang data tersebut.
132
+ Sistem akan mengonversi berkas Anda ke format JSON dan menggunakan model TAT-LLM yang telah disempurnakan untuk menjawab pertanyaan.
133
  """)
134
 
135
  # State to store JSON data
 
167
 
168
  with gr.Column(scale=1):
169
  # Chat interface
170
+ gr.Markdown("### Ajukan Pertanyaan Mengenai Data Anda")
171
  chatbot = gr.Chatbot(height=400)
172
  msg = gr.Textbox(
173
+ label="Prompt",
174
+ placeholder="Ajukan pertanyaan tentang data tabel...",
175
  lines=2
176
  )
177
 
 
182
  # Example questions
183
  gr.Examples(
184
  examples=[
185
+ "Apa saja wawasan yang bisa kita ambil dari data ini?",
186
+ "Bagaimana perubahan dari tahun ke tahun?",
187
+ "Apa saja tren utama yang terlihat dalam data?",
188
+ "Hitung persentase perubahan antar tahun.",
189
+ "Rekomendasi apa yang dapat diberikan berdasarkan data ini?"
190
  ],
191
  inputs=msg
192
  )