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

Conversational dataset support for Online DPO #2075

Merged
merged 24 commits into from
Sep 18, 2024
Merged
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
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
Prev Previous commit
Next Next commit
style
  • Loading branch information
qgallouedec committed Sep 16, 2024
commit 1d2c868511716fe0120bee1b51a7ad2e59ed2f39
1 change: 1 addition & 0 deletions examples/datasets/ultrafeedback-prompt.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ def to_unpaired_preference(example):
prompt = [{"role": "user", "content": example["instruction"]}]
return {"prompt": prompt}


def drop_long_prompt(example):
if len(example["prompt"][0]["content"]) > 768:
return False
Expand Down