Muhammadidrees commited on
Commit
79f708f
·
verified ·
1 Parent(s): 59852e7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -3
app.py CHANGED
@@ -52,9 +52,15 @@ def analyze(
52
 
53
  prompt = system_prompt + "\n" + patient_input
54
 
55
- # Call LLM
56
- result = pipe(prompt, max_new_tokens=1800, do_sample=True, temperature=0.6)
57
- return result[0]["generated_text"]
 
 
 
 
 
 
58
 
59
 
60
  # Build Gradio UI
 
52
 
53
  prompt = system_prompt + "\n" + patient_input
54
 
55
+ # Call LLM (exclude echoed input)
56
+ result = pipe(
57
+ prompt,
58
+ max_new_tokens=800,
59
+ do_sample=True,
60
+ temperature=0.6,
61
+ return_full_text=False
62
+ )
63
+ return result[0]["generated_text"].strip()
64
 
65
 
66
  # Build Gradio UI