From 686437d6714c6583661eae1d0c97497cb2870583 Mon Sep 17 00:00:00 2001 From: Xu Yang Date: Fri, 25 Apr 2025 04:29:14 -0600 Subject: [PATCH] add pipeline to hypothesis spec (#828) --- .../data_science/proposal/exp_gen/prompts_v2.yaml | 8 +++----- .../scenarios/data_science/proposal/exp_gen/proposal.py | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/rdagent/scenarios/data_science/proposal/exp_gen/prompts_v2.yaml b/rdagent/scenarios/data_science/proposal/exp_gen/prompts_v2.yaml index ae315e38..bbba4a8f 100644 --- a/rdagent/scenarios/data_science/proposal/exp_gen/prompts_v2.yaml +++ b/rdagent/scenarios/data_science/proposal/exp_gen/prompts_v2.yaml @@ -215,12 +215,10 @@ specification: - No phrases like "for example" or "eg.," should be used in the hypothesis. Give a clear decision in the hypothesis. 2. Each hypothesis should be testable and actionable. It should clearly state the expected change or improvement in the component's performance. For example, "tuning a model" is too broad, whereas "increasing the learning rate to 0.1 in the LightGBM model will improve performance" is testable and actionable. 3. Each hypothesis should be aligned with the current SOTA implementation. It should be a potential solution to the identified problem. - 4. All the changes in the hypothesis should be correlated and relvant to each other. Avoid proposing multiple independent ideas in a single hypothesis. - {% if not pipeline %} - 5. Each hypothesis should focus on a single direction per experiment. Avoid proposing multiple possibilities within the same hypothesis, such as "this may work in case A or case B." Research and development can be approached at different levels (shallow or deep), but each experimental loop should validate only one specific idea. + 4. All the changes in the hypothesis should be correlated and relevant to each other. Avoid proposing multiple independent ideas in a single hypothesis. + {% if not pipeline %}5. Each hypothesis should focus on a single direction per experiment. Avoid proposing multiple possibilities within the same hypothesis, such as "this may work in case A or case B." Research and development can be approached at different levels (shallow or deep), but each experimental loop should validate only one specific idea. 6. Each hypothesis should focus on one component. The components will be described in the evaluation stage. - {% else %} - 5. The hypothesis should focus on the whole pipeline. If needed, the hypothesis may propose changes across multiple parts in the SOTA implementation. + {% else %}5. The hypothesis should focus on the whole pipeline. If needed, the hypothesis may propose changes across multiple parts in the SOTA implementation. {% endif %} idea: |- diff --git a/rdagent/scenarios/data_science/proposal/exp_gen/proposal.py b/rdagent/scenarios/data_science/proposal/exp_gen/proposal.py index b560a885..15a63b98 100644 --- a/rdagent/scenarios/data_science/proposal/exp_gen/proposal.py +++ b/rdagent/scenarios/data_science/proposal/exp_gen/proposal.py @@ -283,7 +283,7 @@ class DSProposalV2ExpGen(ExpGen): sys_prompt = T(".prompts_v2:hypothesis_gen.system").r( component_desc=component_desc, - hypothesis_spec=T(".prompts_v2:specification.hypothesis").r(), + hypothesis_spec=T(".prompts_v2:specification.hypothesis").r(pipeline=pipeline), hypothesis_output_format=T(".prompts_v2:output_format.hypothesis").r( pipeline=pipeline, enable_idea_pool=enable_idea_pool ),