Skip to content

Commit

Permalink
nit
Browse files Browse the repository at this point in the history
  • Loading branch information
xianxl committed Sep 26, 2024
1 parent a5eb8da commit 2a24bcf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions projects/self_taught_evaluator/src/prepare_dpo_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ def get_input_key(response):
input_key = f"<|eot_id|><|start_header_id|>user<|end_header_id|>\n\n[User Question]{eval_example}"
return system_prompt, input_key


def prepare_dpo_data(
generation_dir: str,
output_dir: str,
Expand Down
1 change: 1 addition & 0 deletions projects/self_taught_evaluator/src/prepare_sft_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

random.seed(42)


def rejection_sampling(outputs, true_label, majority_voting=None):
random.shuffle(outputs)
positives = []
Expand Down

0 comments on commit 2a24bcf

Please sign in to comment.