Drobne poprawki
Browse files
app.py
CHANGED
@@ -41,7 +41,6 @@ def formatuj_historie_dla_promptu(history):
|
|
41 |
role = message["role"]
|
42 |
content = message["content"]
|
43 |
prompt += f"{content}\n"
|
44 |
-
print(prompt)
|
45 |
return prompt
|
46 |
|
47 |
|
@@ -67,11 +66,11 @@ def odp(message, history):
|
|
67 |
|
68 |
|
69 |
## Interfejs graficzny
|
70 |
-
with gr.Blocks() as demo:
|
71 |
-
chatbot = gr.Chatbot()
|
72 |
-
msg = gr.Textbox(label='
|
73 |
msg.submit(odp, [msg, chatbot], [msg, chatbot])
|
74 |
-
demo.launch(
|
75 |
|
76 |
|
77 |
# %%
|
|
|
41 |
role = message["role"]
|
42 |
content = message["content"]
|
43 |
prompt += f"{content}\n"
|
|
|
44 |
return prompt
|
45 |
|
46 |
|
|
|
66 |
|
67 |
|
68 |
## Interfejs graficzny
|
69 |
+
with gr.Blocks(title='Jacek AI') as demo:
|
70 |
+
chatbot = gr.Chatbot(type='messages', label='Jacek AI')
|
71 |
+
msg = gr.Textbox(autofocus=True, label='Pytaj', show_label=False)
|
72 |
msg.submit(odp, [msg, chatbot], [msg, chatbot])
|
73 |
+
demo.launch()
|
74 |
|
75 |
|
76 |
# %%
|