Spaces:
Sleeping
Sleeping
fix: textinput styling
Browse files
app.py
CHANGED
@@ -61,7 +61,7 @@ EXAMPLES = [
|
|
61 |
|
62 |
HEADER = """
|
63 |
<div style="width: 100%; display: flex; flex-direction: column; gap: 24px; padding-top: 24px">
|
64 |
-
<img src="https://postimage.me/images/2024/12/19/ICONGLIDER.md.png" width="
|
65 |
<div style="display: flex; justify-content: space-between; z-index: 1;">
|
66 |
<a href="https://www.patronus.ai">
|
67 |
<img src="https://postimage.me/images/2024/12/19/patronuslogo-white.png" width="250">
|
@@ -97,6 +97,10 @@ EXAMPLES_HEADER = """
|
|
97 |
"""
|
98 |
|
99 |
css = """
|
|
|
|
|
|
|
|
|
100 |
.example-button {
|
101 |
width: fit-content;
|
102 |
font-size: 1rem;
|
@@ -173,20 +177,20 @@ with gr.Blocks(css=css, theme=theme) as demo:
|
|
173 |
with gr.Row(equal_height=True):
|
174 |
with gr.Column(scale=1):
|
175 |
gr.Markdown("<div style='color: #fff !important; font-weight: 600'>Your Inputs</div>")
|
176 |
-
model_output = gr.Textbox(label="MODEL OUTPUT (required)")
|
177 |
-
user_input = gr.Textbox(label="USER INPUT (required)")
|
178 |
-
gold_answer = gr.Textbox(label="GOLD ANSWER")
|
179 |
-
retrieved_context = gr.Textbox(label="RETRIEVED CONTEXT")
|
180 |
-
pass_criteria = gr.Textbox(label="Pass Criteria (required)")
|
181 |
-
rubric = gr.Textbox(label="Rubric")
|
182 |
with gr.Row():
|
183 |
clear_btn = gr.ClearButton([model_output, user_input, gold_answer, retrieved_context, pass_criteria, rubric])
|
184 |
submit_button = gr.Button("Submit", variant="primary")
|
185 |
with gr.Column(scale=1):
|
186 |
gr.Markdown("<div style='color: #fff !important; font-weight: 600'>GLIDER Output</div>")
|
187 |
-
score = gr.Textbox(label="Score")
|
188 |
-
reasoning = gr.Textbox(label="Reasoning")
|
189 |
-
highlights = gr.Textbox(label="Highlights")
|
190 |
gr.Markdown(" ")
|
191 |
gr.Markdown(EXAMPLES_HEADER)
|
192 |
with gr.Row():
|
|
|
61 |
|
62 |
HEADER = """
|
63 |
<div style="width: 100%; display: flex; flex-direction: column; gap: 24px; padding-top: 24px">
|
64 |
+
<img src="https://postimage.me/images/2024/12/19/ICONGLIDER.md.png" width="325" style="position: absolute; top: 0; right: -24px">
|
65 |
<div style="display: flex; justify-content: space-between; z-index: 1;">
|
66 |
<a href="https://www.patronus.ai">
|
67 |
<img src="https://postimage.me/images/2024/12/19/patronuslogo-white.png" width="250">
|
|
|
97 |
"""
|
98 |
|
99 |
css = """
|
100 |
+
.custom_textbox textarea {
|
101 |
+
background-color: #fff !important;
|
102 |
+
color: #000 !important;
|
103 |
+
}
|
104 |
.example-button {
|
105 |
width: fit-content;
|
106 |
font-size: 1rem;
|
|
|
177 |
with gr.Row(equal_height=True):
|
178 |
with gr.Column(scale=1):
|
179 |
gr.Markdown("<div style='color: #fff !important; font-weight: 600'>Your Inputs</div>")
|
180 |
+
model_output = gr.Textbox(label="MODEL OUTPUT (required)", elem_classes="custom_textbox")
|
181 |
+
user_input = gr.Textbox(label="USER INPUT (required)", elem_classes="custom_textbox")
|
182 |
+
gold_answer = gr.Textbox(label="GOLD ANSWER", elem_classes="custom_textbox")
|
183 |
+
retrieved_context = gr.Textbox(label="RETRIEVED CONTEXT", elem_classes="custom_textbox")
|
184 |
+
pass_criteria = gr.Textbox(label="Pass Criteria (required)", elem_classes="custom_textbox")
|
185 |
+
rubric = gr.Textbox(label="Rubric", elem_classes="custom_textbox")
|
186 |
with gr.Row():
|
187 |
clear_btn = gr.ClearButton([model_output, user_input, gold_answer, retrieved_context, pass_criteria, rubric])
|
188 |
submit_button = gr.Button("Submit", variant="primary")
|
189 |
with gr.Column(scale=1):
|
190 |
gr.Markdown("<div style='color: #fff !important; font-weight: 600'>GLIDER Output</div>")
|
191 |
+
score = gr.Textbox(label="Score", elem_classes="custom_textbox")
|
192 |
+
reasoning = gr.Textbox(label="Reasoning", elem_classes="custom_textbox")
|
193 |
+
highlights = gr.Textbox(label="Highlights", elem_classes="custom_textbox")
|
194 |
gr.Markdown(" ")
|
195 |
gr.Markdown(EXAMPLES_HEADER)
|
196 |
with gr.Row():
|