Mykes commited on
Commit
58b011a
1 Parent(s): 9f3c7a4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -3
app.py CHANGED
@@ -12,8 +12,10 @@ from llama_cpp import Llama
12
  @st.cache_resource
13
  def load_model():
14
  return Llama.from_pretrained(
15
- repo_id="Mykes/med_gemma7b_gguf",
16
- filename="*Q4_K_M.gguf",
 
 
17
  verbose=False,
18
  n_ctx=256,
19
  n_batch=256,
@@ -22,7 +24,8 @@ def load_model():
22
 
23
  llm = load_model()
24
 
25
- basic_prompt = "Below is the context which is your conversation history and the last user question. Write a response according the context and question. ### Context: user: Ответь мне на вопрос о моем здоровье. assistant: Конечно! Какой у Вас вопрос? ### Question: {question} ### Response:"
 
26
  input_text = st.text_input('text')
27
  model_input = basic_prompt.format(question=input_text)
28
 
 
12
  @st.cache_resource
13
  def load_model():
14
  return Llama.from_pretrained(
15
+ # repo_id="Mykes/med_gemma7b_gguf",
16
+ # filename="*Q4_K_M.gguf",
17
+ repo_id="Mykes/med_phi3-mini-4k-GGUF",
18
+ filename="*Q8_0.gguf",
19
  verbose=False,
20
  n_ctx=256,
21
  n_batch=256,
 
24
 
25
  llm = load_model()
26
 
27
+ # basic_prompt = "Below is the context which is your conversation history and the last user question. Write a response according the context and question. ### Context: user: Ответь мне на вопрос о моем здоровье. assistant: Конечно! Какой у Вас вопрос? ### Question: {question} ### Response:"
28
+ basic_prompt = "Q: {question}\nA:"
29
  input_text = st.text_input('text')
30
  model_input = basic_prompt.format(question=input_text)
31