krish10 commited on
Commit
2b7aa48
·
verified ·
1 Parent(s): 4404aff

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -15,12 +15,10 @@ model = AutoModelForCausalLM.from_pretrained(
15
  )
16
  model.eval()
17
 
18
- SYSTEM_PROMPT = "You are an expert biomedical assistant trained to identify randomized controlled trials (RCTs). Include RCTs and exclude non-RCTs."
19
-
20
  @spaces.GPU(duration=120)
21
  def stream_response(title_text, abstract_text):
22
  user_input = f"Title: {title_text.strip()}\nAbstract: {abstract_text.strip()}"
23
- prompt = f"<|system|>\n{SYSTEM_PROMPT.strip()}\n<|user|>\n{user_input}\n<|assistant|>\n"
24
 
25
  inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
26
  inputs.pop("token_type_ids", None)
 
15
  )
16
  model.eval()
17
 
 
 
18
  @spaces.GPU(duration=120)
19
  def stream_response(title_text, abstract_text):
20
  user_input = f"Title: {title_text.strip()}\nAbstract: {abstract_text.strip()}"
21
+ prompt = f"\n<|user|>\n{user_input}\n<|assistant|>\n"
22
 
23
  inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
24
  inputs.pop("token_type_ids", None)