-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Fix for when prompt contains an odd num of apostrophes #4660
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The apostrophes in args.user_args are mixed with the single quotes used to enclose x in the parsing code. For example, `deepspeed --num_nodes 1 --num_gpus 8 --no_local_rank run_generation.py --model_name_or_path tiiuae/falcon-40b --max_new_tokens 128 --prompt "I'm a student"` instead of (which doesn't work): `deepspeed --num_nodes 1 --num_gpus 8 --no_local_rank run_generation.py --model_name_or_path tiiuae/falcon-40b --max_new_tokens 128 --prompt 'I'm a student'` To resolve this issue, we can make a change to enclose x in double quotes instead of single quotes.
loadams
approved these changes
Nov 9, 2023
lekurile
approved these changes
Nov 9, 2023
mrwyattii
suggested changes
Nov 9, 2023
mrwyattii
approved these changes
Nov 13, 2023
github-merge-queue
bot
removed this pull request from the merge queue due to failed status checks
Nov 15, 2023
This was referenced Dec 14, 2023
mrwyattii
added a commit
that referenced
this pull request
Dec 15, 2023
Splitting work from #4769 because we are still debugging transformers integration issues. Parsing was broken for user arguments (see #4795). Additionally, parsing of user arguments is tricky and there are lots of edge cases. For example: #4660, #4716, #3967. I've attempted to accommodate all of the possible types of string inputs and added unit tests.
mauryaavinash95
pushed a commit
to mauryaavinash95/DeepSpeed
that referenced
this pull request
Feb 17, 2024
The apostrophes in args.user_args are mixed with the single quotes used to enclose x in the parsing code. For example, `deepspeed --num_nodes 1 --num_gpus 8 --no_local_rank run_generation.py --model_name_or_path tiiuae/falcon-40b --max_new_tokens 128 --prompt "I'm a student"` instead of (which doesn't work): `deepspeed --num_nodes 1 --num_gpus 8 --no_local_rank run_generation.py --model_name_or_path tiiuae/falcon-40b --max_new_tokens 128 --prompt 'I'm a student'` To resolve this issue, we can make a change to enclose x in double quotes instead of single quotes. Co-authored-by: Logan Adams <[email protected]>
mauryaavinash95
pushed a commit
to mauryaavinash95/DeepSpeed
that referenced
this pull request
Feb 17, 2024
Splitting work from microsoft#4769 because we are still debugging transformers integration issues. Parsing was broken for user arguments (see microsoft#4795). Additionally, parsing of user arguments is tricky and there are lots of edge cases. For example: microsoft#4660, microsoft#4716, microsoft#3967. I've attempted to accommodate all of the possible types of string inputs and added unit tests.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The apostrophes in args.user_args are mixed with the single quotes used to enclose x in the parsing code.
For example,
deepspeed --num_nodes 1 --num_gpus 8 --no_local_rank run_generation.py --model_name_or_path tiiuae/falcon-40b --max_new_tokens 128 --prompt "I'm a student"
instead of (which doesn't work):
deepspeed --num_nodes 1 --num_gpus 8 --no_local_rank run_generation.py --model_name_or_path tiiuae/falcon-40b --max_new_tokens 128 --prompt 'I'm a student'
To resolve this issue, we can make a change to enclose x in double quotes instead of single quotes.