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

[Draft] Add adversarial defense benchmark #694

Closed
wants to merge 18 commits into from

Conversation

yangheng95
Copy link

@yangheng95 yangheng95 commented Sep 29, 2022

What does this PR do?

Introduce an interface of adversarial defense to benchmark adversarial defense methods.

Summary

The test examples is available in https://github.com/yangheng95/TextAttack/blob/master/examples/reactive_defense/sst2_reactive_defense.py
Please contact me and help test if you are interested in this PR. @jxmorris12

This PR is related to #687

Additions

Changes

  • [1] Add **kwargs for many functions, see the source code.
  • [2] Modify the search_method()

Deletions

  • Example: Remove unnecessary files under textattack.models...

Checklist

  • The title of your pull request should be a summary of its contribution.
  • Please write detailed description of what parts have been newly added and what parts have been modified. Please also explain why certain changes were made.
  • If your pull request addresses an issue, please mention the issue number in the pull request description to make sure they are linked (and people consulting the issue know you are working on it)
  • To indicate a work in progress please mark it as a draft on Github.
  • Make sure existing tests pass.
  • Add relevant tests. No quality testing = no merge.
  • All public methods must have informative docstrings that work nicely with sphinx. For new modules/files, please add/modify the appropriate .rst file in TextAttack/docs/apidoc.'

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@yangheng95 yangheng95 closed this Sep 29, 2022
@yangheng95 yangheng95 changed the title merge [Draft] Add adversarial defense benchmark Sep 29, 2022
@yangheng95 yangheng95 reopened this Sep 30, 2022
@jxmorris12 jxmorris12 self-requested a review November 13, 2022 19:02
@yangheng95 yangheng95 closed this Nov 15, 2022
@yangheng95 yangheng95 reopened this Nov 15, 2022
@yangheng95
Copy link
Author

Hi there, @jxmorris12 Do you have any questions about this PR?

Copy link
Collaborator

@jxmorris12 jxmorris12 left a comment

Choose a reason for hiding this comment

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

please fix conflicts

@yangheng95
Copy link
Author

Hi @jxmorris12, this PR has been tested in my own environment.

@qiyanjun
Copy link
Member

qiyanjun commented Sep 11, 2023

@yangheng95 mind to add some unit tests / also please solve conflicts / and locally run "make test"

@qiyanjun
Copy link
Member

@yangheng95 do you mind to also add a Jupyter notebook under doc/2notebook to give good examples of your newly added features? Thanks..

@yangheng95
Copy link
Author

@yangheng95 do you mind to also add a Jupyter notebook under doc/2notebook to give good examples of your newly added features? Thanks..

Hi, that is ok. And I will push a PR recently, to show some examples and provide detailed documents.

@jxmorris12
Copy link
Collaborator

Closing as it's been over a year. Please feel free to reopen once you've resolved conflicts with the current version of TextAttack and improved the documentation + testing!

@jxmorris12 jxmorris12 closed this Mar 5, 2024
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.

3 participants