Skip to content

Commit

Permalink
Medicine Recog Update
Browse files Browse the repository at this point in the history
  • Loading branch information
KalyanMurapaka45 committed Jan 4, 2024
1 parent bfbe4cf commit 1245293
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ def medrecog():
return render_template('medrecog.html', response=response)
else:
return render_template('medrecog.html', response="Please provide a valid medical image.")

return render_template('medrecog.html')

@app.route('/conditional', methods=['GET', 'POST'])
Expand All @@ -53,30 +52,25 @@ def conditional():
prompt = f"""Imagine you are a medical expert and you are giving accurate medical advice to a patient.
You are presented with a medical query and asked to provide a response with a detailed explanation.
Note that dont mention any inaccurate or misleading information.
Medical Query: {user_input}
Key Details:
- Provide precise information related to the patient's medical concern.
- Indicate if any diagnostic tests or examinations have been performed.
- Specify the current medications or treatments prescribed.
- The response should be in a paragraph format but not in point-wise.
- If only a specific disease name is mentioned, response must contain the symptoms, causes, and treatment of the disease with respective headings.
Guidelines:
- Use clear and concise language.
- The vocabulary should be appropriate for the medical context.
- Include specific parameters or considerations within the medical context.
- If the response contains a list of items, convert it into a paragraph format.
- Avoid using abbreviations or acronyms.
- Avoid Headings and Sub hheadings just give me the complete response in a paragraph format.
- Avoid Headings and Sub headings just give me the complete response in a paragraph format.
- Refrain from presenting inaccurate or ambiguous information.
- Ensure the query is focused and not overly broad."""

gemini_response = gen_from_text(prompt)

return render_template('index.html', user_input=user_input, response=gemini_response)

return render_template('index.html')


Expand Down

0 comments on commit 1245293

Please sign in to comment.