Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: improve the framework's ability to adaptively adjust the model #629

Merged
merged 1 commit into from
Feb 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions rdagent/scenarios/data_science/proposal/exp_gen.py
Original file line number Diff line number Diff line change
Expand Up @@ -371,6 +371,7 @@ def gen(self, trace: DSTrace) -> DSExperiment:
)

user_prompt = T(".prompts:direct_exp_gen.user").r(
targets=component_info["target_name"],
sota_exp_and_feedback_list_desc=sota_exp_feedback_list_desc,
failed_exp_and_feedback_list_desc=failed_exp_feedback_list_desc,
last_exp_diff=last_exp_diff,
Expand Down
8 changes: 7 additions & 1 deletion rdagent/scenarios/data_science/proposal/prompts.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ hypothesis_and_feedback: |-
Did changing to this hypothesis work? (focus on the change): {{ feedback.decision }}
{% endfor %}

task_gen: # It is deprecated now, please refer to direct_exp_gen
task_gen:
system: |-
{% if hypothesis is not none %}
The user is trying to generate new {{ targets }} based on the hypothesis generated in the previous step.
Expand Down Expand Up @@ -107,6 +107,9 @@ task_gen: # It is deprecated now, please refer to direct_exp_gen
The user has made several task on this scenario but didn't get the expected result due to wrong implementation or just bad luck. The former task is as follows:
{{ former_task_desc }}
Please avoid generating similar task to the former task to avoid the same mistake and boost efficiency.
{% if targets == "Model" %}
If the previous failure was due to exceeding the time limit or memory constraints, you can try reducing the model size or opting for alternative algorithms with lower time or space complexity instead of using a neural network.
{% endif %}
{% endif %}

{% if hypothesis is not none %}
Expand Down Expand Up @@ -221,6 +224,9 @@ direct_exp_gen:
The user has made several hypothesis on this scenario and did several evaluation on them.
The former hypothesis and the corresponding feedbacks are as follows (focus on the last one & the new hypothesis that it provides and reasoning to see if you agree):
{{ failed_exp_and_feedback_list_desc }}
{% if targets == "Building model" %}
If the previous failure was due to exceeding the time limit or memory constraints, you can try reducing the model size or opting for alternative algorithms with lower time or space complexity instead of using a neural network.
{% endif %}

{% if last_exp_diff %}
# Here are the differences between the latest version of implementation and the current best version of implementation
Expand Down
Loading