-
Notifications
You must be signed in to change notification settings - Fork 1
init release #1
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
init release #1
Conversation
hnekoeiq
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added the high level comments. Will take a look later when these are addressed and approve it. Great Job!
README.md
Outdated
|
|
||
| ## 2- Train models | ||
|
|
||
| Codes for train models are in `/train`. Three models which are small LM are required to fine-tune: 1- action generator (executor), 2- sub-goal generator (contoroller), 3- first sub-goal generator. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Its a minor grammatical error but --> for "training the models" and "required to be fine-tuned"
Overal passing the text through ChatGPT or Grammarly could be a good idea.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
README.md
Outdated
|
|
||
| # Acknowledgements | ||
|
|
||
| We thank SwiftSage implementation, which this repo is based upon. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably you wanted to say "We thank the authors of SwiftSage repository"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
data/data_convert.py
Outdated
| task_id_to_actions = {} | ||
| task_id = args.task_id | ||
|
|
||
| for i in range(1): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why there is a for loop here if it is range(1)?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At some time we wanted to have an iteration. That is why. But I removed it
|
|
||
|
|
||
| def downsampling(task_idx_real, curr_task_seq): | ||
| # Downsampling Task 26 and 29 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This part of the code could have been written by the others but docstrings and comments should have been added for all nontrivial functions. E.g. Why Downsampling has been done only for task 26 and 29?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
because only these two have a lot of variations. In scienceworld the number of variations of the tasks are different. So it is ok.
subgoals/sg_generating.py
Outdated
|
|
||
|
|
||
| return steps_cp, subgoals_list_insteps | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is recommended to remove empty space.
subgoals/sg_generating.py
Outdated
| return actions_list, subgoal_action_index_list | ||
|
|
||
| def check_action_sg(actions_list, gold_path, sg_act_idx_list, task_desc, chatgpt_answer): | ||
| print(f'len goal path {len(gold_path)} ---- len action seq {len(actions_list)}') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
again, adding a short docstring could be helpful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added them.
evaluation/agent.py
Outdated
|
|
||
|
|
||
| def creat_semi_random_sg(first_subgoal, PossibleObjects, locations): | ||
| ### this function chnage the objects or locations in the subgoals to generates semi-random subgoals. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
hnekoeiq
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
This pull request is to release the code for our paper "SUB-GOAL DISTILLATION: A METHOD TO IMPROVE SMALL LANGUAGE AGENTS", accepted at CoLLAs 2024. The codebase is a modification and extension of the existing SwiftSage repository.