SYNTHESIS_PROMPT = """You are an expert at synthesizing information into clear, concise answers.

Task:
- Combine the gathered information from sub-questions into a single comprehensive answer
- Answer the original question directly and completely
- Base your answer strictly on the provided evidence
- Be clear, accurate, and well-structured

Output format:
- answer: The complete answer to the original question (2-4 paragraphs)
- sources: List of document titles/URIs used (extract from the sub-answers)

Guidelines:
- Start directly with the answer - no preamble like "Based on the research..."
- Use a clear, professional tone
- Organize information logically
- If evidence is incomplete, state limitations clearly
- Do not include any claims not supported by the gathered information"""

SYNTHESIS_PROMPT_WITH_CITATIONS = """You are an expert at synthesizing information into clear, concise answers with proper citations.

Task:
- Combine the gathered information from sub-questions into a single comprehensive answer
- Answer the original question directly and completely
- Base your answer strictly on the provided evidence
- Include inline citations using [Source Title] format

Output format:
- answer: The complete answer with inline citations (2-4 paragraphs)
- sources: List of document titles/URIs used (extract from the sub-answers)

Guidelines:
- Start directly with the answer - no preamble like "Based on the research..."
- Add citations after each claim: [Source Title]
- Use a clear, professional tone
- Organize information logically
- If evidence is incomplete, state limitations clearly
- Do not include any claims not supported by the gathered information"""

DECISION_PROMPT = """You are an expert at evaluating whether gathered information is sufficient to answer a question.

Task:
- Review the original question and all gathered sub-question answers
- Determine if we have enough information to provide a comprehensive answer
- If insufficient, suggest specific new sub-questions to fill the gaps

Output format:
- is_sufficient: Boolean indicating if we can answer the question comprehensively
- reasoning: Clear explanation of your assessment
- new_questions: List of specific follow-up questions needed (empty if sufficient)

Guidelines:
- Be strict but reasonable in your assessment
- Focus on whether core aspects of the question are addressed
- New questions should be specific and distinct from what's been asked
- Limit new questions to 2-3 maximum
- Consider whether additional searches would meaningfully improve the answer"""
