gregorlied commited on
Commit
2cde63b
Β·
verified Β·
1 Parent(s): 2283333

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -25,7 +25,7 @@ model = AutoModelForCausalLM.from_pretrained(
25
 
26
  checkpoint = "gregorlied/Llama-3.2-1B-Instruct-Medical-Report-Summarization"
27
  model = PeftModel.from_pretrained(model, checkpoint)
28
- model = model.merge_and_unload()
29
 
30
  class Person(BaseModel):
31
  life_style: str
@@ -116,7 +116,7 @@ def summarize(text):
116
  ]
117
 
118
  response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
119
- return response[0]
120
 
121
  with gr.Blocks() as demo:
122
  gr.Markdown("## πŸ“ Structured Information Extraction for Clinical Reports")
 
25
 
26
  checkpoint = "gregorlied/Llama-3.2-1B-Instruct-Medical-Report-Summarization"
27
  model = PeftModel.from_pretrained(model, checkpoint)
28
+ # model = model.merge_and_unload()
29
 
30
  class Person(BaseModel):
31
  life_style: str
 
116
  ]
117
 
118
  response = tokenizer.batch_decode(generated_ids, skip_special_tokens=True)
119
+ return response
120
 
121
  with gr.Blocks() as demo:
122
  gr.Markdown("## πŸ“ Structured Information Extraction for Clinical Reports")