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

update openai, pydantic, and chromadb versions and examples to work with uniflow #96

Merged
merged 3 commits into from
Dec 23, 2023

Conversation

jojortz
Copy link
Contributor

@jojortz jojortz commented Dec 21, 2023

  • Update openai version to 1.2.4 to match uniflow
    • change to use OpenAI client.chat.completions instead of ChatCompletion reference
  • Update pydantic to 2.5.2 to match uniflow
    • required chromadb update as well to get around BaseSettings error
  • Tested and updated notebooks in these example folders
    • chatbot
    • comparator
    • data_generation
    • retrieval_qa
    • rlhf

@jojortz
Copy link
Contributor Author

jojortz commented Dec 22, 2023

Further updated datasets, transformers, peft, and trl

  • For datasets, updated to address this issue
    • Datasets upgrade required transformers upgrade to avoid conflicts
  • With updated torch, got use_reentrant ValueError ref
    • added gradient_checkpointing_kwargs to config and TrainingArguments
    • updated peft and trl
  • With updated trl, got CUDA out of memory, so updated per_device_train_batch_size to default to 1. Above 1, get out of memory error on 24GB GPU

Copy link
Owner

@CambioML CambioML left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, can you rerun isort and black for the entire pykoi folder.

@@ -68,7 +66,7 @@ class RLHFConfig:
# default=8,
# metadata={"help": "Batch size."})
per_device_train_batch_size: Optional[int] = field(
default=2, metadata={"help": "Batch size per device for training."}
default=1, metadata={"help": "Batch size per device for training."}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: could you please make a TODO here that for trl 0.7.4 there is a OOM issue and we need to come back to revisit.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added TODO

@jojortz jojortz merged commit 1dd54bc into main Dec 23, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants