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

Typos in example.ipynb #19

Open
Junjie-Chu opened this issue Nov 12, 2023 · 4 comments
Open

Typos in example.ipynb #19

Junjie-Chu opened this issue Nov 12, 2023 · 4 comments

Comments

@Junjie-Chu
Copy link

In the second code block, questions_set = pd.read_csv(seed_path)['question_path'].tolist() seems to be wrong.
Maybe questions_set = pd.read_csv(path_path)['text'].tolist()

@sherdencooper
Copy link
Owner

Thanks a lot! You are right, here is indeed a typo. I have fixed this in the master branch, plz let us know if there are further issues. Thanks again for your careful review!

@Junjie-Chu
Copy link
Author

Thanks a lot! You are right, here is indeed a typo. I have fixed this in the master branch, plz let us know if there are further issues. Thanks again for your careful review!

I have another question, about how to set the parameters.
If I have a forbidden-question dataset, it has 160 questions.
I would like to find 1 jailbreak prompt for each question, and budget allows 20 queries for each question.
In this case, I have to set --max_jailbreak 160 --max_query 3200, right?

@sherdencooper
Copy link
Owner

Hi Junjie, if you want to allocate 20 queries for each question, then you just need to set max query as 3200. The max jailbreak is counted as the total number of successful jailbreak attempts during fuzzing. It is also a stop condition and any one of the stop conditions is satisfied, the fuzzing loop will terminate. For example, if there are 5 questions in total, in iteration 1, the results are [0,1,1,1,0], then the jailbreak number is 3. In iteration 2, if the results are [1,0,0,1,0], then the jailbreak number is 5. After it reaches 160, the fuzzing process will be terminated. However, you could just set one stop condition while leaving others empty to satisfy your needs. If you would like to stop the fuzzing only until each question can be jailbroken at least once, you need some modification because current stop conditions cannot support that. Plz let me know if you have any questions about the parameters

@Junjie-Chu
Copy link
Author

Hi Junjie, if you want to allocate 20 queries for each question, then you just need to set max query as 3200. The max jailbreak is counted as the total number of successful jailbreak attempts during fuzzing. It is also a stop condition and any one of the stop conditions is satisfied, the fuzzing loop will terminate. For example, if there are 5 questions in total, in iteration 1, the results are [0,1,1,1,0], then the jailbreak number is 3. In iteration 2, if the results are [1,0,0,1,0], then the jailbreak number is 5. After it reaches 160, the fuzzing process will be terminated. However, you could just set one stop condition while leaving others empty to satisfy your needs. If you would like to stop the fuzzing only until each question can be jailbroken at least once, you need some modification because current stop conditions cannot support that. Plz let me know if you have any questions about the parameters

Thanks for your quick reply! Really thanks, for both this comment and e-mail.
I think to obtain my target, the best way is to run single question :) I have already made it run XD

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

No branches or pull requests

2 participants