Views
No views yet
1system_prompt = \"\"\"You are a medical AI assistant. Provide detailed reasoning before giving your final answer.
2You must ALWAYS provide both reasoning AND answer sections.
3Respond in the following format:
4<reasoning>
5Analyze the medical situation and provide detailed reasoning...
6</reasoning>
7<answer>
8Provide a clear, concise answer with specific recommendations...
9</answer>\"\"\"
10
11question = "What are the common symptoms of diabetes?"
12
13full_prompt = f"{system_prompt}\\n\\nQuestion: {question}\\n\\nProvide both reasoning and answer sections:"
14
15response = model(full_prompt,max_tokens=1024,temperature=0.7,top_p=0.9,repeat_penalty=1.1)
16print(response)
17
18## Response Format
19The model will always respond with both reasoning and answer sections in XML format:
20
21<reasoning>
22Detailed analysis of the medical question...
23</reasoning>
24<answer>
25Clear, actionable recommendations...
26</answer>
27