Update app.py
Browse files
app.py
CHANGED
@@ -39,9 +39,14 @@ terminators = [
|
|
39 |
tokenizer.convert_tokens_to_ids("<|eot_id|>")
|
40 |
]
|
41 |
|
42 |
-
SYS_PROMPT = """
|
43 |
-
|
44 |
-
|
|
|
|
|
|
|
|
|
|
|
45 |
|
46 |
|
47 |
|
@@ -112,8 +117,8 @@ A rag pipeline with a chatbot feature
|
|
112 |
Resources used to build this project :
|
113 |
* embedding model : https://huggingface.co/mixedbread-ai/mxbai-embed-large-v1
|
114 |
* dataset : https://huggingface.co/datasets/not-lain/wikipedia
|
115 |
-
* faiss docs :
|
116 |
-
* chatbot :
|
117 |
* Full documentation : https://huggingface.co/blog/not-lain/rag-chatbot-using-llama3
|
118 |
"""
|
119 |
|
@@ -129,7 +134,7 @@ demo = gr.ChatInterface(
|
|
129 |
bubble_full_width=False,
|
130 |
),
|
131 |
theme="Soft",
|
132 |
-
examples=[["
|
133 |
title=TITLE,
|
134 |
description=DESCRIPTION,
|
135 |
|
|
|
39 |
tokenizer.convert_tokens_to_ids("<|eot_id|>")
|
40 |
]
|
41 |
|
42 |
+
SYS_PROMPT = """
|
43 |
+
"Below is an instruction that describes a task. Write a response that appropriately completes the request."\
|
44 |
+
"μ μνλ contextμμλ§ λλ΅νκ³ contextμ μλ λ΄μ©μ μμ±νμ§λ§"\
|
45 |
+
"make answer in korean. νκ΅μ΄λ‘ λλ΅νμΈμ"\
|
46 |
+
"\n\nContext:\n{context}\n;"\
|
47 |
+
"Question: {question}"\
|
48 |
+
"\n\nAnswer:"
|
49 |
+
"""
|
50 |
|
51 |
|
52 |
|
|
|
117 |
Resources used to build this project :
|
118 |
* embedding model : https://huggingface.co/mixedbread-ai/mxbai-embed-large-v1
|
119 |
* dataset : https://huggingface.co/datasets/not-lain/wikipedia
|
120 |
+
* faiss docs :
|
121 |
+
* chatbot :
|
122 |
* Full documentation : https://huggingface.co/blog/not-lain/rag-chatbot-using-llama3
|
123 |
"""
|
124 |
|
|
|
134 |
bubble_full_width=False,
|
135 |
),
|
136 |
theme="Soft",
|
137 |
+
examples=[["νμ΄ κ²½κΈ° κ·μΉμ΄ λμΌ? "]],
|
138 |
title=TITLE,
|
139 |
description=DESCRIPTION,
|
140 |
|