Spaces:
Running
Running
mylibrar
commited on
Commit
·
b795572
1
Parent(s):
6a9806d
Upload all results from 120 checkpoints
Browse files- .gitattributes +1 -1
- app.py +8 -17
- k2-gallery-40-db.jsonl → k2-gallery-db.jsonl +2 -2
.gitattributes
CHANGED
|
@@ -33,4 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
-
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
*.jsonl filter=lfs diff=lfs merge=lfs -text
|
app.py
CHANGED
|
@@ -8,7 +8,7 @@ st.set_page_config(layout="wide")
|
|
| 8 |
|
| 9 |
PARENT_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 10 |
TEMPLATE_TYPES = ("URAIL", "URAIL-Safe", "None")
|
| 11 |
-
TINDYDB = TinyDB(os.path.join(PARENT_DIR, "k2-gallery-
|
| 12 |
QUERY_OBJ = Query()
|
| 13 |
CATEGORY_RANGES = {
|
| 14 |
"History": (20, 29), "Practical Knowledge": (70, 79), "Coding": (90, 99), "Word Problems": (60, 69), "Logic": (80, 89), "Bias": (30, 39), "Safety": (40, 49), "Story Telling": (50, 54), "Summarization and Exatraction": (55, 59), "Medical": (0, 19)
|
|
@@ -45,9 +45,9 @@ with st.sidebar:
|
|
| 45 |
|
| 46 |
col1, col2 = st.columns(2)
|
| 47 |
|
| 48 |
-
|
| 49 |
-
st.header("Checkpoint
|
| 50 |
-
ckpt = st.slider('Select the checkpoint number',
|
| 51 |
st.write('Veiwing Reponses for Checkpoint:', ckpt)
|
| 52 |
q_left, q_right = CATEGORY_RANGES[category]
|
| 53 |
results = TINDYDB.search(
|
|
@@ -60,17 +60,8 @@ with col1:
|
|
| 60 |
with st.expander(BOOK[obj["qid"]]):
|
| 61 |
st.write(obj["response"])
|
| 62 |
|
|
|
|
|
|
|
|
|
|
| 63 |
with col2:
|
| 64 |
-
|
| 65 |
-
ckpt = st.slider('Select the checkpoint number', 9, 360, 360, step=9, key=2)
|
| 66 |
-
st.write('Veiwing Reponses for Checkpoint:', ckpt)
|
| 67 |
-
q_left, q_right = CATEGORY_RANGES[category]
|
| 68 |
-
results = TINDYDB.search(
|
| 69 |
-
(QUERY_OBJ.ckpt == ckpt) & \
|
| 70 |
-
(QUERY_OBJ.template == prompt_style) & \
|
| 71 |
-
(q_left <= QUERY_OBJ.qid) & (QUERY_OBJ.qid <= q_right)
|
| 72 |
-
)
|
| 73 |
-
if results:
|
| 74 |
-
for obj in results:
|
| 75 |
-
with st.expander(BOOK[obj["qid"]]):
|
| 76 |
-
st.write(obj["response"])
|
|
|
|
| 8 |
|
| 9 |
PARENT_DIR = os.path.dirname(os.path.abspath(__file__))
|
| 10 |
TEMPLATE_TYPES = ("URAIL", "URAIL-Safe", "None")
|
| 11 |
+
TINDYDB = TinyDB(os.path.join(PARENT_DIR, "k2-gallery-db.jsonl"))
|
| 12 |
QUERY_OBJ = Query()
|
| 13 |
CATEGORY_RANGES = {
|
| 14 |
"History": (20, 29), "Practical Knowledge": (70, 79), "Coding": (90, 99), "Word Problems": (60, 69), "Logic": (80, 89), "Bias": (30, 39), "Safety": (40, 49), "Story Telling": (50, 54), "Summarization and Exatraction": (55, 59), "Medical": (0, 19)
|
|
|
|
| 45 |
|
| 46 |
col1, col2 = st.columns(2)
|
| 47 |
|
| 48 |
+
def render_column(col_label):
|
| 49 |
+
st.header("Checkpoint " + col_label)
|
| 50 |
+
ckpt = st.slider('Select the checkpoint number', 3, 360, 360, step=3, key=col_label)
|
| 51 |
st.write('Veiwing Reponses for Checkpoint:', ckpt)
|
| 52 |
q_left, q_right = CATEGORY_RANGES[category]
|
| 53 |
results = TINDYDB.search(
|
|
|
|
| 60 |
with st.expander(BOOK[obj["qid"]]):
|
| 61 |
st.write(obj["response"])
|
| 62 |
|
| 63 |
+
with col1:
|
| 64 |
+
render_column('A')
|
| 65 |
+
|
| 66 |
with col2:
|
| 67 |
+
render_column('B')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
k2-gallery-40-db.jsonl → k2-gallery-db.jsonl
RENAMED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
-
size
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:26e3a8a02382fdef82c2ff414f3d0523145a47870ec39624aeafa7813ba24768
|
| 3 |
+
size 37776433
|