Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -46,9 +46,14 @@ def rag_retriever(message, history, system_prompt, num_sources=4, temperature=0)
|
|
46 |
|
47 |
|
48 |
rag = gr.ChatInterface(rag_retriever,
|
49 |
-
|
50 |
-
|
51 |
-
|
|
|
|
|
|
|
|
|
|
|
52 |
title="Чатене с документа AI Act",
|
53 |
description="Питайте каквото пожелаете, но пишете на български.",
|
54 |
chatbot=gr.Chatbot(placeholder="<strong>Вашият личен AI Act помощник</strong><br>Питайте каквото пожелаете, но пишете на български."),
|
@@ -57,9 +62,11 @@ rag = gr.ChatInterface(rag_retriever,
|
|
57 |
undo_btn="Назад",
|
58 |
clear_btn="Изчистете",
|
59 |
submit_btn="Изпрати",
|
60 |
-
additional_inputs=[
|
61 |
-
|
62 |
-
|
|
|
|
|
63 |
additional_inputs_accordion=gr.Accordion("Допълнителни настройки", open=False),
|
64 |
)
|
65 |
|
|
|
46 |
|
47 |
|
48 |
rag = gr.ChatInterface(rag_retriever,
|
49 |
+
examples=[
|
50 |
+
["Каква е целта на настоящия регламент",
|
51 |
+
"You are an expert assistant in Bulgarian regulations. Provide precise and clear answers. Provide a detailed and comprehensive answer, incorporating as much relevant information as possible. Always respond in Bulgarian, regardless of the language used in the question."],
|
52 |
+
["Какво са Системите с ИИ",
|
53 |
+
"You are an expert assistant in Bulgarian regulations. Provide precise and clear answers. Always respond in Bulgarian, regardless of the language used in the question."],
|
54 |
+
["Какво е равнище на технологично развитие",
|
55 |
+
"You are an expert assistant in Bulgarian regulations. Provide precise and clear answers. Always respond in Bulgarian, regardless of the language used in the question."]
|
56 |
+
],
|
57 |
title="Чатене с документа AI Act",
|
58 |
description="Питайте каквото пожелаете, но пишете на български.",
|
59 |
chatbot=gr.Chatbot(placeholder="<strong>Вашият личен AI Act помощник</strong><br>Питайте каквото пожелаете, но пишете на български."),
|
|
|
62 |
undo_btn="Назад",
|
63 |
clear_btn="Изчистете",
|
64 |
submit_btn="Изпрати",
|
65 |
+
additional_inputs=[
|
66 |
+
gr.Textbox(value="You are an expert assistant in Bulgarian regulations. Provide precise and clear answers. Always respond in Bulgarian, regardless of the language used in the question.", label="System Prompt"),
|
67 |
+
gr.Slider(minimum=1, maximum=10, value=4, step=1, label="Брой препратки"),
|
68 |
+
gr.Slider(minimum=0, maximum=2, value=0, label="Креативност на модела", info="Ако е много високо моделът си измисля, но може да напише интересни неща.")
|
69 |
+
],
|
70 |
additional_inputs_accordion=gr.Accordion("Допълнителни настройки", open=False),
|
71 |
)
|
72 |
|