Spaces:
Sleeping
Sleeping
Wen-Ding Li
commited on
Commit
•
72db41e
1
Parent(s):
50b49a8
fix
Browse files
app.py
CHANGED
@@ -23,11 +23,11 @@ st.sidebar.header('Sample Selection')
|
|
23 |
index_example = st.sidebar.number_input(f"Choose a sample from the existing {len(samples)} notebooks:", min_value=0, max_value=max(0, len(samples)-1), value=0, step=1)
|
24 |
|
25 |
db_id = samples[index_example]["db_id"]
|
26 |
-
st.markdown(f'<h2 style="color:blue;">Database {db_id} schema:</h2>', unsafe_allow_html=True)
|
27 |
-
st.code(samples[index_example]["schema"])
|
28 |
st.markdown(f'<h2 style="color:blue;">{index_example} Question:</h2>', unsafe_allow_html=True)
|
29 |
st.code(samples[index_example]["question"])
|
30 |
sql_str = samples[index_example]["SQL"]
|
31 |
sql_str_pretty = sqlparse.format(sql_str, reindent=True, keyword_case='upper')
|
32 |
-
st.markdown(f'<h2 style="color:blue;">
|
33 |
st.code(sql_str_pretty)
|
|
|
|
|
|
23 |
index_example = st.sidebar.number_input(f"Choose a sample from the existing {len(samples)} notebooks:", min_value=0, max_value=max(0, len(samples)-1), value=0, step=1)
|
24 |
|
25 |
db_id = samples[index_example]["db_id"]
|
|
|
|
|
26 |
st.markdown(f'<h2 style="color:blue;">{index_example} Question:</h2>', unsafe_allow_html=True)
|
27 |
st.code(samples[index_example]["question"])
|
28 |
sql_str = samples[index_example]["SQL"]
|
29 |
sql_str_pretty = sqlparse.format(sql_str, reindent=True, keyword_case='upper')
|
30 |
+
st.markdown(f'<h2 style="color:blue;">SQL:</h2>', unsafe_allow_html=True)
|
31 |
st.code(sql_str_pretty)
|
32 |
+
st.markdown(f'<h2 style="color:blue;">Database schema:</h2>', unsafe_allow_html=True)
|
33 |
+
st.code(samples[index_example]["schema"])
|