mintaeng commited on
Commit
a1ab50e
β€’
1 Parent(s): 36141e2

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -6
app.py CHANGED
@@ -39,9 +39,14 @@ terminators = [
39
  tokenizer.convert_tokens_to_ids("<|eot_id|>")
40
  ]
41
 
42
- SYS_PROMPT = """You are an assistant for answering questions.
43
- You are given the extracted parts of a long document and a question. Provide a conversational answer.
44
- If you don't know the answer, just say "I do not know." Don't make up an answer."""
 
 
 
 
 
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 : https://huggingface.co/docs/datasets/v2.18.0/en/package_reference/main_classes#datasets.Dataset.add_faiss_index
116
- * chatbot : https://huggingface.co/meta-llama/Meta-Llama-3-8B-Instruct
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=[["what's anarchy ? "]],
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