Spaces:
Sleeping
Sleeping
Commit
·
cb081db
1
Parent(s):
c63e515
improved readability
Browse files
app.py
CHANGED
@@ -386,7 +386,7 @@ def random_prompt():
|
|
386 |
])
|
387 |
|
388 |
def load_css():
|
389 |
-
with open('style.css', 'r') as file:
|
390 |
return file.read()
|
391 |
|
392 |
def run_gradio():
|
@@ -397,9 +397,8 @@ def run_gradio():
|
|
397 |
'./logo.png',
|
398 |
interactive=False,
|
399 |
show_label=False,
|
400 |
-
|
401 |
-
|
402 |
-
height="50%"
|
403 |
)
|
404 |
with gr.Column():
|
405 |
dora_chatbot_button = gr.Checkbox(label="Dora", value=True, elem_classes=["navbar-button"])
|
@@ -482,7 +481,7 @@ if __name__ == "__main__":
|
|
482 |
|
483 |
dora_question_rewriter = IMPROVE_PROMPT | tool_llm | StrOutputParser()
|
484 |
retrieval_grader = RELEVANCE_PROMPT | fast_llm.with_structured_output(GradeDocuments)
|
485 |
-
answer_chain = ANSWER_PROMPT | tool_llm | StrOutputParser()
|
486 |
hallucination_grader = HALLUCINATION_PROMPT | fast_llm.with_structured_output(GradeHallucinations)
|
487 |
answer_grader = RESOLVER_PROMPT | fast_llm.with_structured_output(GradeAnswer)
|
488 |
question_rewriter = REWRITER_PROMPT | rewrite_llm | StrOutputParser()
|
|
|
386 |
])
|
387 |
|
388 |
def load_css():
|
389 |
+
with open('./style.css', 'r') as file:
|
390 |
return file.read()
|
391 |
|
392 |
def run_gradio():
|
|
|
397 |
'./logo.png',
|
398 |
interactive=False,
|
399 |
show_label=False,
|
400 |
+
width=200,
|
401 |
+
height=200
|
|
|
402 |
)
|
403 |
with gr.Column():
|
404 |
dora_chatbot_button = gr.Checkbox(label="Dora", value=True, elem_classes=["navbar-button"])
|
|
|
481 |
|
482 |
dora_question_rewriter = IMPROVE_PROMPT | tool_llm | StrOutputParser()
|
483 |
retrieval_grader = RELEVANCE_PROMPT | fast_llm.with_structured_output(GradeDocuments)
|
484 |
+
answer_chain = ANSWER_PROMPT | tool_llm | StrOutputParser()
|
485 |
hallucination_grader = HALLUCINATION_PROMPT | fast_llm.with_structured_output(GradeHallucinations)
|
486 |
answer_grader = RESOLVER_PROMPT | fast_llm.with_structured_output(GradeAnswer)
|
487 |
question_rewriter = REWRITER_PROMPT | rewrite_llm | StrOutputParser()
|
style.css
CHANGED
@@ -43,6 +43,7 @@
|
|
43 |
max-width: calc(100% - 300px);
|
44 |
box-sizing: border-box;
|
45 |
overflow-x: hidden;
|
|
|
46 |
word-wrap: break-word;
|
47 |
}
|
48 |
#llm_output {
|
@@ -52,6 +53,7 @@
|
|
52 |
}
|
53 |
#clickable_markdown {
|
54 |
position: relative;
|
|
|
55 |
cursor: pointer;
|
56 |
}
|
57 |
#invisible_button {
|
|
|
43 |
max-width: calc(100% - 300px);
|
44 |
box-sizing: border-box;
|
45 |
overflow-x: hidden;
|
46 |
+
color: red;
|
47 |
word-wrap: break-word;
|
48 |
}
|
49 |
#llm_output {
|
|
|
53 |
}
|
54 |
#clickable_markdown {
|
55 |
position: relative;
|
56 |
+
color: black;
|
57 |
cursor: pointer;
|
58 |
}
|
59 |
#invisible_button {
|