selfevolveagent / examples /pubmedqa /debug /optimized_ourmethod_gpt4omini_10step_generate.json
iLOVE2D's picture
Upload 2846 files
5374a2d verified
{
"class_name": "SequentialWorkFlowGraph",
"goal": "Answer user questions accurately and concisely by decomposing the problem into analysis and generate.",
"tasks": [
{
"name": "generate_answer",
"description": "Draft an answer using the retrieved context.",
"inputs": [
{
"name": "question",
"type": "str",
"description": "The original question from the user.",
"required": true
}
],
"outputs": [
{
"name": "draft_answer",
"type": "str",
"description": "A concise, direct answer to the question.",
"required": true
}
],
"prompt": "\"\"\"\nYou can think to generate answers. First, generate a draft answer based on the question `{question}`. Then, assess the relevance and coherence of the draft answer with respect to the context provided. If the draft answer does not align well with the context or lacks clarity, refine it before proceeding. Finally, provide the final answer (Yes or No) in the 'answer' field. Format your answer in <answer>{final_answer}</answer>.\n\"\"\"",
"prompt_template": {
"class_name": "StringTemplate",
"instruction": "You can think to generate answers. You should provide the final answer (Yes or No) in the 'answer' field. Format your answer in <answer>xxx</answer>."
},
"system_prompt": "You are a helpful and highly intelligent assistant.",
"parse_mode": "xml",
"parse_func": null,
"parse_title": null,
"tool_names": null
},
{
"name": "validate_answer5329",
"description": "Task to validate_answer5329. Takes draft_answer, context as input. Produces validated_answer as output.",
"inputs": [
{
"name": "draft_answer",
"type": "str",
"description": "Input parameter draft_answer for validate_answer5329",
"required": false
},
{
"name": "context",
"type": "str",
"description": "Input parameter context for validate_answer5329",
"required": false
}
],
"outputs": [
{
"name": "validated_answer",
"type": "str",
"description": "Output parameter validated_answer from validate_answer5329",
"required": true
}
],
"prompt": "\"\"\"\nThink step by step to answer the question based on the context provided in `{context}`. You should integrate this context into your reasoning process to ensure accuracy and relevance in your answer. Explain your thought process clearly in the `<thought>` field, detailing how you arrived at your conclusion and how the context influenced your reasoning. Provide the final answer in the `<answer>` field, ensuring it directly addresses the user's question. If you encounter ambiguous or contradictory information in the context, acknowledge this in your thought process and clarify how it affects your answer.\n\"\"\"",
"prompt_template": {
"class_name": "StringTemplate",
"instruction": "Think step by step to answer the question based on the question context. You should integrate context for answering. You should explain your thinking process in the 'thought' field, and provide the final answer in the 'answer' field.\nFormat your output in xml format, such as <thought>xxx</thought> and <answer>xxx</answer>."
},
"system_prompt": "You are a helpful and highly intelligent assistant.",
"parse_mode": "xml",
"parse_func": null,
"parse_title": null,
"tool_names": null
},
{
"name": "handle_unanswerable4308",
"description": "Task to handle_unanswerable4308. Takes validated_answer as input. Produces final_answer as output.",
"inputs": [
{
"name": "validated_answer",
"type": "str",
"description": "Input parameter validated_answer for handle_unanswerable4308",
"required": false
}
],
"outputs": [
{
"name": "final_answer",
"type": "str",
"description": "Output parameter final_answer from handle_unanswerable4308",
"required": true
}
],
"prompt": "```xml\n\"\"\"\nThink step by step to answer the question based on the context provided in {context}. First, analyze the {draft_answer} for clarity, relevance, and accuracy. If the answer is ambiguous or lacks sufficient information, indicate that it is unanswerable. In the 'thought' field, explain your reasoning process, including any assumptions made and how you arrived at your conclusion. In the 'answer' field, provide the final answer, ensuring it is clear and directly addresses the user's question. If the answer is valid, present it; if it is unanswerable, state that clearly.\nFormat your output in xml format, such as <thought>xxx</thought> and <answer>xxx</answer>.\n\"\"\"\n```",
"prompt_template": {
"class_name": "StringTemplate",
"instruction": "Think step by step to answer the question based on the question context. You should integrate context for answering. You should explain your thinking process in the 'thought' field, and provide the final answer in the 'answer' field.\nFormat your output in xml format, such as <thought>xxx</thought> and <answer>xxx</answer>."
},
"system_prompt": "You are a helpful and highly intelligent assistant.",
"parse_mode": "xml",
"parse_func": null,
"parse_title": null,
"tool_names": null
},
{
"name": "evaluate_answer7495",
"description": "Task to evaluate_answer7495. Takes final_answer as input. Produces evaluation_metrics as output.",
"inputs": [
{
"name": "final_answer",
"type": "str",
"description": "Input parameter final_answer for evaluate_answer7495",
"required": false
}
],
"outputs": [
{
"name": "evaluation_metrics",
"type": "str",
"description": "Output parameter evaluation_metrics from evaluate_answer7495",
"required": true
}
],
"prompt": "\"\"\"\nThink step by step to answer the question based on the context provided in `{context}`. First, analyze the question `{question}` to identify key components and relevant information. Then, integrate this context into your reasoning process. Explain your thought process in the `<thought>` field, detailing how you arrived at your answer. Finally, provide the answer in the `<answer>` field, ensuring it is clear and concise.\nFormat your output in XML format, such as <thought>xxx</thought> and <answer>xxx</answer>.\n\"\"\"",
"prompt_template": {
"class_name": "StringTemplate",
"instruction": "Think step by step to answer the question based on the question context. You should integrate context for answering. You should explain your thinking process in the 'thought' field, and provide the final answer in the 'answer' field.\nFormat your output in xml format, such as <thought>xxx</thought> and <answer>xxx</answer>."
},
"system_prompt": "You are a helpful and highly intelligent assistant.",
"parse_mode": "xml",
"parse_func": null,
"parse_title": null,
"tool_names": null
}
]
}