pyrit 0.2.0__tar.gz → 0.2.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (293) hide show
  1. {pyrit-0.2.0 → pyrit-0.2.1}/LICENSE +21 -21
  2. {pyrit-0.2.0/pyrit.egg-info → pyrit-0.2.1}/PKG-INFO +7 -6
  3. {pyrit-0.2.0 → pyrit-0.2.1}/README.md +52 -51
  4. {pyrit-0.2.0 → pyrit-0.2.1}/pyproject.toml +160 -160
  5. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/__init__.py +1 -1
  6. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/analytics/__init__.py +7 -7
  7. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/analytics/conversation_analytics.py +89 -89
  8. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/auth/auth_config.py +7 -6
  9. pyrit-0.2.1/pyrit/auth/azure_auth.py +134 -0
  10. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/chat_message_normalizer/__init__.py +17 -17
  11. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/chat_message_normalizer/chat_message_nop.py +13 -13
  12. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/chat_message_normalizer/chat_message_normalizer.py +41 -41
  13. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/chat_message_normalizer/chat_message_normalizer_chatml.py +40 -40
  14. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/chat_message_normalizer/generic_system_squash.py +34 -34
  15. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/cache_helper.py +28 -28
  16. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/constants.py +5 -5
  17. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/default_values.py +47 -47
  18. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/inference.py +76 -76
  19. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/logger.py +23 -23
  20. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/net_utility.py +78 -78
  21. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/path.py +20 -20
  22. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/print.py +58 -58
  23. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/prompt_template_generator.py +54 -54
  24. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/singleton.py +22 -22
  25. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/orchestrators/benchmark/question_answer.yaml +23 -23
  26. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/orchestrators/red_teaming/end_token.yaml +25 -25
  27. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_converters/translation_converter.yaml +22 -22
  28. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_converters/variation_converter.yaml +21 -21
  29. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_converters/variation_converter_prompt_softener.yaml +23 -23
  30. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/aim.yaml +33 -33
  31. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/aligned.yaml +17 -17
  32. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/anti_gpt.yaml +15 -15
  33. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/apophis.yaml +84 -84
  34. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/axies.yaml +22 -22
  35. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/balakula.yaml +20 -20
  36. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/based_gpt_1.yaml +67 -67
  37. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/based_gpt_2.yaml +46 -46
  38. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/better_dan.yaml +29 -29
  39. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/bh.yaml +20 -20
  40. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/bish.yaml +42 -42
  41. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/burple.yaml +14 -14
  42. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/chad_gpt.yaml +22 -22
  43. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/coach_bobby_knight.yaml +55 -55
  44. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/cody.yaml +25 -25
  45. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/confronting_personalities.yaml +20 -20
  46. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/cooper.yaml +28 -28
  47. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/cosmos_dan.yaml +45 -45
  48. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dan_1.yaml +70 -70
  49. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dan_11.yaml +67 -67
  50. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dan_5.yaml +33 -33
  51. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dan_7.yaml +90 -90
  52. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dan_8.yaml +24 -24
  53. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dan_9.yaml +54 -54
  54. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/delta_gpt.yaml +16 -16
  55. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dev_mode_1.yaml +59 -59
  56. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dev_mode_2.yaml +59 -59
  57. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dev_mode_3.yaml +59 -59
  58. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dev_mode_compact.yaml +15 -15
  59. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dev_mode_ranti.yaml +69 -69
  60. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dude_1.yaml +40 -40
  61. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dude_2.yaml +40 -40
  62. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/dude_3.yaml +41 -41
  63. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/eva.yaml +17 -17
  64. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/evil_chad_2.yaml +43 -43
  65. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/evil_confidant.yaml +17 -17
  66. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/fr3d.yaml +39 -39
  67. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/gpt_4_real.yaml +15 -15
  68. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/gpt_4_simulator.yaml +46 -46
  69. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/hackerman.yaml +28 -28
  70. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/hypothetical_response.yaml +14 -14
  71. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/instructions.yaml +17 -17
  72. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/jailbreak_1.yaml +31 -31
  73. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/jailbreak_2.yaml +63 -63
  74. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/jb.yaml +24 -24
  75. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/jedi_mind_trick.yaml +24 -24
  76. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/john.yaml +13 -13
  77. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/kevin.yaml +19 -19
  78. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/khajiit.yaml +71 -71
  79. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/leo.yaml +57 -57
  80. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/live_gpt.yaml +29 -29
  81. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/m78.yaml +32 -32
  82. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/man.yaml +58 -58
  83. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/maximum.yaml +56 -56
  84. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/meanie.yaml +31 -31
  85. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/moralizing_rant.yaml +14 -14
  86. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/mr_blonde.yaml +17 -17
  87. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/neco.yaml +34 -34
  88. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/nraf.yaml +30 -30
  89. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/omega.yaml +76 -76
  90. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/omni.yaml +36 -36
  91. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/oppo.yaml +24 -24
  92. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/person_gpt.yaml +34 -34
  93. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/ranti.yaml +16 -16
  94. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/ron.yaml +44 -44
  95. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/security_researcher.yaml +10 -10
  96. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/sim.yaml +35 -35
  97. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/steve.yaml +27 -27
  98. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/superior_dan.yaml +73 -73
  99. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/switch.yaml +19 -19
  100. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/text_continuation.yaml +15 -15
  101. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/three_liner.yaml +17 -17
  102. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/translator_bot.yaml +23 -23
  103. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/tuo.yaml +19 -19
  104. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/ucar.yaml +56 -56
  105. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/un_gpt.yaml +39 -39
  106. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/violet.yaml +15 -15
  107. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompt_templates/jailbreak/void.yaml +47 -47
  108. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompts/gandalf.prompt +9 -9
  109. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/prompts/illegal.prompt +8 -8
  110. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/bias.yaml +11 -11
  111. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/grounded.yaml +20 -20
  112. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/harmful_content.yaml +21 -21
  113. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/prompt_injection_detector.yaml +5 -5
  114. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/question_answering.yaml +5 -5
  115. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/refusal.yaml +7 -7
  116. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/sentiment.yaml +51 -51
  117. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/sexual_content.yaml +9 -9
  118. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/harm.yaml +12 -12
  119. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/embedding/_text_embedding.py +54 -54
  120. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/embedding/azure_text_embedding.py +45 -45
  121. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/embedding/openai_text_embedding.py +22 -22
  122. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/interfaces.py +106 -106
  123. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/memory/__init__.py +12 -12
  124. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/memory/duckdb_memory.py +298 -298
  125. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/memory/memory_embedding.py +59 -59
  126. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/memory/memory_exporter.py +91 -91
  127. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/memory/memory_interface.py +271 -249
  128. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/memory/memory_models.py +157 -157
  129. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/__init__.py +35 -35
  130. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/chat_message.py +32 -32
  131. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/data_type_serializer.py +188 -188
  132. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/identifiers.py +14 -14
  133. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/literals.py +18 -18
  134. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/models.py +314 -314
  135. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/prompt_request_piece.py +104 -104
  136. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/models/prompt_request_response.py +110 -110
  137. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/__init__.py +24 -24
  138. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/end_token_red_teaming_orchestrator.py +81 -81
  139. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/orchestrator_class.py +80 -80
  140. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/prompt_sending_orchestrator.py +95 -95
  141. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/question_answer_benchmark_orchestrator.py +107 -107
  142. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/red_teaming_orchestrator.py +205 -205
  143. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/scoring_red_teaming_orchestrator.py +76 -76
  144. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/__init__.py +35 -35
  145. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/ascii_art_converter.py +31 -31
  146. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/azure_speech_text_to_audio_converter.py +119 -119
  147. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/base64_converter.py +24 -24
  148. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/leetspeak_converter.py +45 -45
  149. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/prompt_converter.py +55 -55
  150. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/random_capital_letters_converter.py +75 -75
  151. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/rot13_converter.py +21 -21
  152. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/search_replace_converter.py +36 -36
  153. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/string_join_converter.py +32 -32
  154. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/translation_converter.py +96 -96
  155. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/unicode_confusable_converter.py +48 -48
  156. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/unicode_sub_converter.py +25 -25
  157. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_converter/variation_converter.py +82 -82
  158. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_normalizer/__init__.py +12 -12
  159. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_normalizer/normalizer_request.py +73 -73
  160. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_normalizer/prompt_normalizer.py +211 -211
  161. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/__init__.py +33 -33
  162. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/azure_blob_storage_target.py +150 -137
  163. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/azure_openai_completion_target.py +163 -132
  164. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/dall_e_target.py +198 -185
  165. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/gandalf_target.py +86 -78
  166. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/prompt_chat_target/azure_ml_chat_target.py +246 -238
  167. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/prompt_chat_target/azure_openai_gptv_chat_target.py +334 -309
  168. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/prompt_chat_target/ollama_chat_target.py +138 -130
  169. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/prompt_chat_target/openai_chat_target.py +368 -339
  170. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/prompt_chat_target/prompt_chat_target.py +97 -97
  171. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/prompt_target.py +66 -60
  172. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/text_target.py +50 -39
  173. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/prompt_target/tts_target.py +129 -129
  174. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/engine.py +105 -105
  175. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/gandalf_classifier.py +127 -127
  176. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/gpt_classifier.py +162 -162
  177. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/markdown_injection.py +41 -41
  178. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/question_answer_scorer.py +136 -136
  179. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/substring_scorer.py +21 -21
  180. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/text.py +25 -25
  181. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/show_versions.py +83 -83
  182. {pyrit-0.2.0 → pyrit-0.2.1/pyrit.egg-info}/PKG-INFO +7 -6
  183. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit.egg-info/SOURCES.txt +1 -65
  184. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_attack_strategy.py +38 -38
  185. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_azure_auth.py +45 -38
  186. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_azure_text_embedding.py +53 -53
  187. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_chat_message_normalizer.py +71 -71
  188. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_chat_normalizer_chatml.py +82 -82
  189. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_common_default.py +23 -23
  190. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_common_net_utility.py +78 -78
  191. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_data_type_serializer.py +120 -120
  192. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_embedding_response.py +49 -49
  193. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_markdown_injection.py +27 -27
  194. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_models.py +68 -68
  195. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_normalizer_request.py +90 -90
  196. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_ollama_chat_target.py +123 -96
  197. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_prompt_converter.py +203 -203
  198. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_prompt_normalizer.py +152 -152
  199. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_prompt_request_piece.py +207 -207
  200. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_prompt_response.py +44 -44
  201. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_prompt_template_generator.py +62 -62
  202. pyrit-0.2.0/.env_example +0 -110
  203. pyrit-0.2.0/.flake8 +0 -19
  204. pyrit-0.2.0/.github/ISSUE_TEMPLATE/blank_template.md +0 -8
  205. pyrit-0.2.0/.github/ISSUE_TEMPLATE/bug_report.md +0 -54
  206. pyrit-0.2.0/.github/ISSUE_TEMPLATE/config.yml +0 -1
  207. pyrit-0.2.0/.github/ISSUE_TEMPLATE/doc_improvement.md +0 -20
  208. pyrit-0.2.0/.github/ISSUE_TEMPLATE/feature_request.md +0 -22
  209. pyrit-0.2.0/.github/PULL_REQUEST_TEMPLATE.md +0 -26
  210. pyrit-0.2.0/.github/workflows/build_and_test.yml +0 -64
  211. pyrit-0.2.0/.gitignore +0 -167
  212. pyrit-0.2.0/.pre-commit-config.yaml +0 -42
  213. pyrit-0.2.0/CODE_OF_CONDUCT.md +0 -9
  214. pyrit-0.2.0/Makefile +0 -26
  215. pyrit-0.2.0/SECURITY.md +0 -41
  216. pyrit-0.2.0/SUPPORT.md +0 -25
  217. pyrit-0.2.0/assets/aml_compute_cluster.png +0 -0
  218. pyrit-0.2.0/assets/aml_deployment_name.png +0 -0
  219. pyrit-0.2.0/assets/aml_deployment_resource_not_ready_error.png +0 -0
  220. pyrit-0.2.0/assets/aml_endpoint_deployment.png +0 -0
  221. pyrit-0.2.0/assets/aml_hf_model.png +0 -0
  222. pyrit-0.2.0/assets/aml_managed_online_endpoint_api_key.png +0 -0
  223. pyrit-0.2.0/assets/aml_model_endpoint_schema.png +0 -0
  224. pyrit-0.2.0/assets/aml_score_key.png +0 -0
  225. pyrit-0.2.0/assets/aml_score_uri.png +0 -0
  226. pyrit-0.2.0/assets/aml_ws_model.png +0 -0
  227. pyrit-0.2.0/assets/gandalf-demo-setup.png +0 -0
  228. pyrit-0.2.0/assets/gandalf-home-level-1.png +0 -0
  229. pyrit-0.2.0/assets/huggingface_model_id.png +0 -0
  230. pyrit-0.2.0/assets/operation-setup.jpg +0 -0
  231. pyrit-0.2.0/assets/pyrit_architecture.png +0 -0
  232. pyrit-0.2.0/assets/self-ask-prompting-example.png +0 -0
  233. pyrit-0.2.0/component-governance.yml +0 -17
  234. pyrit-0.2.0/doc/README.md +0 -27
  235. pyrit-0.2.0/doc/about_pyrit.md +0 -53
  236. pyrit-0.2.0/doc/code/orchestrator.ipynb +0 -369
  237. pyrit-0.2.0/doc/code/orchestrator.py +0 -122
  238. pyrit-0.2.0/doc/code/scoring.ipynb +0 -185
  239. pyrit-0.2.0/doc/code/scoring.py +0 -82
  240. pyrit-0.2.0/doc/contributing.md +0 -306
  241. pyrit-0.2.0/doc/demo/1_gandalf.ipynb +0 -280
  242. pyrit-0.2.0/doc/demo/1_gandalf.py +0 -106
  243. pyrit-0.2.0/doc/demo/2_multiturn_strategies.ipynb +0 -244
  244. pyrit-0.2.0/doc/demo/2_multiturn_strategies.py +0 -65
  245. pyrit-0.2.0/doc/deployment/deploy_hf_model_aml.ipynb +0 -350
  246. pyrit-0.2.0/doc/deployment/deploy_hf_model_aml.py +0 -230
  247. pyrit-0.2.0/doc/deployment/download_and_register_hf_model_aml.ipynb +0 -511
  248. pyrit-0.2.0/doc/deployment/download_and_register_hf_model_aml.py +0 -373
  249. pyrit-0.2.0/doc/deployment/hf_aml_model_endpoint_guide.md +0 -52
  250. pyrit-0.2.0/doc/deployment/score_aml_endpoint.ipynb +0 -168
  251. pyrit-0.2.0/doc/deployment/score_aml_endpoint.py +0 -121
  252. pyrit-0.2.0/doc/deployment/troubleshooting_guide_hf_azureml.md +0 -40
  253. pyrit-0.2.0/doc/faqs.md +0 -41
  254. pyrit-0.2.0/doc/glossary.md +0 -7
  255. pyrit-0.2.0/doc/how_to_guide.ipynb +0 -746
  256. pyrit-0.2.0/doc/how_to_guide.py +0 -237
  257. pyrit-0.2.0/doc/setup/install_pyrit.md +0 -17
  258. pyrit-0.2.0/doc/setup/setup_azure.md +0 -17
  259. pyrit-0.2.0/policheck.yml +0 -34
  260. pyrit-0.2.0/pyrit/auth/azure_auth.py +0 -116
  261. pyrit-0.2.0/tests/__init__.py +0 -2
  262. pyrit-0.2.0/tests/data/embedding_1.json +0 -1552
  263. pyrit-0.2.0/tests/data/embedding_2.json +0 -1552
  264. pyrit-0.2.0/tests/memory/test_memory_embedding.py +0 -84
  265. pyrit-0.2.0/tests/memory/test_memory_interface.py +0 -187
  266. pyrit-0.2.0/tests/mocks.py +0 -155
  267. {pyrit-0.2.0 → pyrit-0.2.1}/MANIFEST.in +0 -0
  268. {pyrit-0.2.0 → pyrit-0.2.1}/NOTICE.txt +0 -0
  269. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/auth/__init__.py +0 -0
  270. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/chat_message_normalizer/chat_message_normalizer_tokenizer.py +0 -0
  271. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/common/__init__.py +0 -0
  272. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/content_classifiers/current_events.yaml +0 -0
  273. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/cyber.yaml +0 -0
  274. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/fairness_bias.yaml +0 -0
  275. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/hate_speech.yaml +0 -0
  276. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/persuasion.yaml +0 -0
  277. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/phish_emails.yaml +0 -0
  278. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/political_misinfo.yaml +0 -0
  279. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/sexual.yaml +0 -0
  280. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/likert_scales/violence.yaml +0 -0
  281. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/scoring_instructions/classification_system_prompt.yaml +0 -0
  282. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/datasets/score/scoring_instructions/likert_system_prompt.yaml +0 -0
  283. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/embedding/__init__.py +0 -0
  284. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/orchestrator/xpia_orchestrator.py +0 -0
  285. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/__init__.py +0 -0
  286. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/score_class.py +0 -0
  287. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit/score/support_text_classification.py +0 -0
  288. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit.egg-info/dependency_links.txt +0 -0
  289. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit.egg-info/requires.txt +0 -0
  290. {pyrit-0.2.0 → pyrit-0.2.1}/pyrit.egg-info/top_level.txt +0 -0
  291. {pyrit-0.2.0 → pyrit-0.2.1}/setup.cfg +0 -0
  292. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_chat_normalizer_tokenizer.py +0 -0
  293. {pyrit-0.2.0 → pyrit-0.2.1}/tests/test_scorers.py +0 -0
@@ -1,21 +1,21 @@
1
- Copyright (c) Microsoft Corporation.
2
-
3
- MIT License
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ Copyright (c) Microsoft Corporation.
2
+
3
+ MIT License
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pyrit
3
- Version: 0.2.0
3
+ Version: 0.2.1
4
4
  Summary: The Python Risk Identification Tool for LLMs (PyRIT) is a library used to assess the robustness of LLMs
5
5
  Author: dlmgary, amandajean119, microsiska, rdheekonda, rlundeen2, romanlutz, jbolor21, nina-msft
6
6
  Author-email: Microsoft AI Red Team <airedteam@microsoft.com>
@@ -92,17 +92,18 @@ For example, at Microsoft we are using this tool to iterate on different
92
92
  versions of a product (and its metaprompt) so that we can more effectively
93
93
  protect against prompt injection attacks.
94
94
 
95
- ![PyRIT architecture](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/assets/pyrit_architecture.png)
95
+ ![PyRIT architecture](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.1/assets/pyrit_architecture.png)
96
+
96
97
 
97
98
  ## Where can I learn more?
98
99
 
99
100
  Microsoft Learn has a
100
101
  [dedicated page on AI Red Teaming](https://learn.microsoft.com/en-us/security/ai-red-team).
101
102
 
102
- Check out our [docs](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/README.md) for more information
103
- on how to [install PyRIT](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/setup/install_pyrit.md),
104
- our [How to Guide](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/how_to_guide.ipynb),
105
- and more, as well as our [demos](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/demo) folder.
103
+ Check out our [docs](https://github.com/Azure/PyRIT/blob/releases/v0.2.1/doc/README.md) for more information
104
+ on how to [install PyRIT](https://github.com/Azure/PyRIT/blob/releases/v0.2.1/doc/setup/install_pyrit.md),
105
+ our [How to Guide](https://github.com/Azure/PyRIT/blob/releases/v0.2.1/doc/how_to_guide.ipynb),
106
+ and more, as well as our [demos](https://github.com/Azure/PyRIT/tree/releases/v0.2.1/doc/demo) folder.
106
107
 
107
108
  ## Trademarks
108
109
 
@@ -1,51 +1,52 @@
1
- # Python Risk Identification Tool for generative AI (PyRIT)
2
-
3
- The Python Risk Identification Tool for generative AI (PyRIT) is an open
4
- access automation framework to empower security professionals and ML
5
- engineers to red team foundation models and their applications.
6
-
7
- ## Introduction
8
-
9
- PyRIT is a library developed by the AI Red Team for researchers and engineers
10
- to help them assess the robustness of their LLM endpoints against different
11
- harm categories such as fabrication/ungrounded content (e.g., hallucination),
12
- misuse (e.g., bias), and prohibited content (e.g., harassment).
13
-
14
- PyRIT automates AI Red Teaming tasks to allow operators to focus on more
15
- complicated and time-consuming tasks and can also identify security harms such
16
- as misuse (e.g., malware generation, jailbreaking), and privacy harms
17
- (e.g., identity theft).​
18
-
19
- The goal is to allow researchers to have a baseline of how well their model
20
- and entire inference pipeline is doing against different harm categories and
21
- to be able to compare that baseline to future iterations of their model.
22
- This allows them to have empirical data on how well their model is doing
23
- today, and detect any degradation of performance based on future improvements.
24
-
25
- Additionally, this tool allows researchers to iterate and improve their
26
- mitigations against different harms.
27
- For example, at Microsoft we are using this tool to iterate on different
28
- versions of a product (and its metaprompt) so that we can more effectively
29
- protect against prompt injection attacks.
30
-
31
- ![PyRIT architecture](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/assets/pyrit_architecture.png)
32
-
33
- ## Where can I learn more?
34
-
35
- Microsoft Learn has a
36
- [dedicated page on AI Red Teaming](https://learn.microsoft.com/en-us/security/ai-red-team).
37
-
38
- Check out our [docs](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/README.md) for more information
39
- on how to [install PyRIT](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/setup/install_pyrit.md),
40
- our [How to Guide](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/how_to_guide.ipynb),
41
- and more, as well as our [demos](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.0/doc/demo) folder.
42
-
43
- ## Trademarks
44
-
45
- This project may contain trademarks or logos for projects, products, or services.
46
- Authorized use of Microsoft trademarks or logos is subject to and must follow
47
- [Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
48
- Use of Microsoft trademarks or logos in modified versions of this project must
49
- not cause confusion or imply Microsoft sponsorship.
50
- Any use of third-party trademarks or logos are subject to those third-party's
51
- policies.
1
+ # Python Risk Identification Tool for generative AI (PyRIT)
2
+
3
+ The Python Risk Identification Tool for generative AI (PyRIT) is an open
4
+ access automation framework to empower security professionals and ML
5
+ engineers to red team foundation models and their applications.
6
+
7
+ ## Introduction
8
+
9
+ PyRIT is a library developed by the AI Red Team for researchers and engineers
10
+ to help them assess the robustness of their LLM endpoints against different
11
+ harm categories such as fabrication/ungrounded content (e.g., hallucination),
12
+ misuse (e.g., bias), and prohibited content (e.g., harassment).
13
+
14
+ PyRIT automates AI Red Teaming tasks to allow operators to focus on more
15
+ complicated and time-consuming tasks and can also identify security harms such
16
+ as misuse (e.g., malware generation, jailbreaking), and privacy harms
17
+ (e.g., identity theft).​
18
+
19
+ The goal is to allow researchers to have a baseline of how well their model
20
+ and entire inference pipeline is doing against different harm categories and
21
+ to be able to compare that baseline to future iterations of their model.
22
+ This allows them to have empirical data on how well their model is doing
23
+ today, and detect any degradation of performance based on future improvements.
24
+
25
+ Additionally, this tool allows researchers to iterate and improve their
26
+ mitigations against different harms.
27
+ For example, at Microsoft we are using this tool to iterate on different
28
+ versions of a product (and its metaprompt) so that we can more effectively
29
+ protect against prompt injection attacks.
30
+
31
+ ![PyRIT architecture](https://raw.githubusercontent.com/Azure/PyRIT/releases/v0.2.1/assets/pyrit_architecture.png)
32
+
33
+
34
+ ## Where can I learn more?
35
+
36
+ Microsoft Learn has a
37
+ [dedicated page on AI Red Teaming](https://learn.microsoft.com/en-us/security/ai-red-team).
38
+
39
+ Check out our [docs](https://github.com/Azure/PyRIT/blob/releases/v0.2.1/doc/README.md) for more information
40
+ on how to [install PyRIT](https://github.com/Azure/PyRIT/blob/releases/v0.2.1/doc/setup/install_pyrit.md),
41
+ our [How to Guide](https://github.com/Azure/PyRIT/blob/releases/v0.2.1/doc/how_to_guide.ipynb),
42
+ and more, as well as our [demos](https://github.com/Azure/PyRIT/tree/releases/v0.2.1/doc/demo) folder.
43
+
44
+ ## Trademarks
45
+
46
+ This project may contain trademarks or logos for projects, products, or services.
47
+ Authorized use of Microsoft trademarks or logos is subject to and must follow
48
+ [Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
49
+ Use of Microsoft trademarks or logos in modified versions of this project must
50
+ not cause confusion or imply Microsoft sponsorship.
51
+ Any use of third-party trademarks or logos are subject to those third-party's
52
+ policies.
@@ -1,160 +1,160 @@
1
- [project]
2
- name = "pyrit"
3
- version = "0.2.0"
4
- description = "The Python Risk Identification Tool for LLMs (PyRIT) is a library used to assess the robustness of LLMs"
5
- authors = [
6
- { name = "Microsoft AI Red Team", email = "airedteam@microsoft.com" },
7
- { name = "dlmgary" },
8
- { name = "amandajean119" },
9
- { name = "microsiska" },
10
- { name = "rdheekonda" },
11
- { name = "rlundeen2" },
12
- { name = "romanlutz" },
13
- { name = "jbolor21" },
14
- { name = "nina-msft" },
15
- ]
16
- readme = "README.md"
17
- license = { text = "MIT" }
18
- keywords = [
19
- "llm",
20
- "ai-safety",
21
- "ai-security",
22
- "ai-red-team",
23
- "ai-red-teaming",
24
- "ai-robustness",
25
- "ai-robustness-testing",
26
- "ai-risk-assessment",
27
- ]
28
- classifiers = [
29
- "Development Status :: 3 - Alpha",
30
- "License :: OSI Approved :: MIT License",
31
- "Programming Language :: Python :: 3.10",
32
- "Programming Language :: Python :: 3.11",
33
- ]
34
- requires-python = ">=3.10, <3.12"
35
- dependencies = [
36
- "aiofiles>=23.2.1",
37
- "aiohttp>=3.9.3",
38
- "aiosignal>=1.3.1",
39
- "art==6.1.0",
40
- "azure-cognitiveservices-speech>=1.36.0",
41
- "azure-core>=1.26.1",
42
- "azure-identity>=1.12.0",
43
- "azure-ai-ml==1.13.0",
44
- "azure-storage-blob>=12.19.0",
45
- "confusables==1.2.0",
46
- "duckdb==0.10.0",
47
- "duckdb-engine==0.11.2",
48
- "jsonpickle>=3.0.4",
49
- "jupyter>=1.0.0",
50
- "ipykernel>=6.29.4",
51
- "logzero>=1.7.0",
52
- "numpy>=1.26.4",
53
- "onnxruntime>=1.14.1",
54
- "onnx>=1.16.0",
55
- "openai>=1.23.2",
56
- "pydantic>=2.7.1",
57
- "python-dotenv>=1.0.1",
58
- "scikit-learn>=1.4.2",
59
- "semantic-kernel==0.9.4b1",
60
- "SQLAlchemy==2.0.28",
61
- "sqlalchemy-stubs==0.4",
62
- "termcolor>=2.4.0",
63
- "tenacity>=8.2.3",
64
- "tokenizers>=0.19.1",
65
- "torch==2.1.2",
66
- "transformers>=4.40.0",
67
- "types-requests>=2.31.0.20240406",
68
- ]
69
-
70
- [project.optional-dependencies]
71
- dev = [
72
- "black>=24.4.0",
73
- "flake8>=7.0.0",
74
- "flake8-copyright>=0.2.4",
75
- "jupytext>=1.16.1",
76
- "mypy>=1.9.0",
77
- "pillow>=10.3.0",
78
- "pre-commit>=3.3.3",
79
- "pytest>=7.3.1",
80
- "pytest-asyncio>=0.23.5",
81
- "pytest-cov>=4.0.0",
82
- "respx>=0.20.2",
83
- "types-PyYAML>=6.0.12.9",
84
- "types-PyYAML>=6.0.12.9",
85
- "azure-cognitiveservices-speech>=1.36.0",
86
- ]
87
-
88
- [tool.pytest.ini_options]
89
- pythonpath = ["."]
90
-
91
- [tool.mypy]
92
- plugins = []
93
- ignore_missing_imports = true
94
- strict = false
95
- follow_imports = "silent"
96
- strict_optional = false
97
- disable_error_code = ["empty-body"]
98
-
99
- [tool.black]
100
- target-version = ["py310"]
101
- line-length = 120
102
-
103
- [build-system]
104
- requires = ["setuptools", "wheel"]
105
- build-backend = "setuptools.build_meta"
106
-
107
- [tool.setuptools.packages.find]
108
- include = ["pyrit", "pyrit.*"]
109
-
110
- [tool.jupytext]
111
- formats = "ipynb,py:percent"
112
-
113
- [tool.ruff]
114
- line-length = 120
115
- fixable = [
116
- "A",
117
- "B",
118
- "C",
119
- "D",
120
- "E",
121
- "F",
122
- "G",
123
- "I",
124
- "N",
125
- "Q",
126
- "S",
127
- "T",
128
- "W",
129
- "ANN",
130
- "ARG",
131
- "BLE",
132
- "COM",
133
- "DJ",
134
- "DTZ",
135
- "EM",
136
- "ERA",
137
- "EXE",
138
- "FBT",
139
- "ICN",
140
- "INP",
141
- "ISC",
142
- "NPY",
143
- "PD",
144
- "PGH",
145
- "PIE",
146
- "PL",
147
- "PT",
148
- "PTH",
149
- "PYI",
150
- "RET",
151
- "RSE",
152
- "RUF",
153
- "SIM",
154
- "SLF",
155
- "TCH",
156
- "TID",
157
- "TRY",
158
- "UP",
159
- "YTT",
160
- ]
1
+ [project]
2
+ name = "pyrit"
3
+ version = "0.2.1"
4
+ description = "The Python Risk Identification Tool for LLMs (PyRIT) is a library used to assess the robustness of LLMs"
5
+ authors = [
6
+ { name = "Microsoft AI Red Team", email = "airedteam@microsoft.com" },
7
+ { name = "dlmgary" },
8
+ { name = "amandajean119" },
9
+ { name = "microsiska" },
10
+ { name = "rdheekonda" },
11
+ { name = "rlundeen2" },
12
+ { name = "romanlutz" },
13
+ { name = "jbolor21" },
14
+ { name = "nina-msft" },
15
+ ]
16
+ readme = "README.md"
17
+ license = { text = "MIT" }
18
+ keywords = [
19
+ "llm",
20
+ "ai-safety",
21
+ "ai-security",
22
+ "ai-red-team",
23
+ "ai-red-teaming",
24
+ "ai-robustness",
25
+ "ai-robustness-testing",
26
+ "ai-risk-assessment",
27
+ ]
28
+ classifiers = [
29
+ "Development Status :: 3 - Alpha",
30
+ "License :: OSI Approved :: MIT License",
31
+ "Programming Language :: Python :: 3.10",
32
+ "Programming Language :: Python :: 3.11",
33
+ ]
34
+ requires-python = ">=3.10, <3.12"
35
+ dependencies = [
36
+ "aiofiles>=23.2.1",
37
+ "aiohttp>=3.9.3",
38
+ "aiosignal>=1.3.1",
39
+ "art==6.1.0",
40
+ "azure-cognitiveservices-speech>=1.36.0",
41
+ "azure-core>=1.26.1",
42
+ "azure-identity>=1.12.0",
43
+ "azure-ai-ml==1.13.0",
44
+ "azure-storage-blob>=12.19.0",
45
+ "confusables==1.2.0",
46
+ "duckdb==0.10.0",
47
+ "duckdb-engine==0.11.2",
48
+ "jsonpickle>=3.0.4",
49
+ "jupyter>=1.0.0",
50
+ "ipykernel>=6.29.4",
51
+ "logzero>=1.7.0",
52
+ "numpy>=1.26.4",
53
+ "onnxruntime>=1.14.1",
54
+ "onnx>=1.16.0",
55
+ "openai>=1.23.2",
56
+ "pydantic>=2.7.1",
57
+ "python-dotenv>=1.0.1",
58
+ "scikit-learn>=1.4.2",
59
+ "semantic-kernel==0.9.4b1",
60
+ "SQLAlchemy==2.0.28",
61
+ "sqlalchemy-stubs==0.4",
62
+ "termcolor>=2.4.0",
63
+ "tenacity>=8.2.3",
64
+ "tokenizers>=0.19.1",
65
+ "torch==2.1.2",
66
+ "transformers>=4.40.0",
67
+ "types-requests>=2.31.0.20240406",
68
+ ]
69
+
70
+ [project.optional-dependencies]
71
+ dev = [
72
+ "black>=24.4.0",
73
+ "flake8>=7.0.0",
74
+ "flake8-copyright>=0.2.4",
75
+ "jupytext>=1.16.1",
76
+ "mypy>=1.9.0",
77
+ "pillow>=10.3.0",
78
+ "pre-commit>=3.3.3",
79
+ "pytest>=7.3.1",
80
+ "pytest-asyncio>=0.23.5",
81
+ "pytest-cov>=4.0.0",
82
+ "respx>=0.20.2",
83
+ "types-PyYAML>=6.0.12.9",
84
+ "types-PyYAML>=6.0.12.9",
85
+ "azure-cognitiveservices-speech>=1.36.0",
86
+ ]
87
+
88
+ [tool.pytest.ini_options]
89
+ pythonpath = ["."]
90
+
91
+ [tool.mypy]
92
+ plugins = []
93
+ ignore_missing_imports = true
94
+ strict = false
95
+ follow_imports = "silent"
96
+ strict_optional = false
97
+ disable_error_code = ["empty-body"]
98
+
99
+ [tool.black]
100
+ target-version = ["py310"]
101
+ line-length = 120
102
+
103
+ [build-system]
104
+ requires = ["setuptools", "wheel"]
105
+ build-backend = "setuptools.build_meta"
106
+
107
+ [tool.setuptools.packages.find]
108
+ include = ["pyrit", "pyrit.*"]
109
+
110
+ [tool.jupytext]
111
+ formats = "ipynb,py:percent"
112
+
113
+ [tool.ruff]
114
+ line-length = 120
115
+ fixable = [
116
+ "A",
117
+ "B",
118
+ "C",
119
+ "D",
120
+ "E",
121
+ "F",
122
+ "G",
123
+ "I",
124
+ "N",
125
+ "Q",
126
+ "S",
127
+ "T",
128
+ "W",
129
+ "ANN",
130
+ "ARG",
131
+ "BLE",
132
+ "COM",
133
+ "DJ",
134
+ "DTZ",
135
+ "EM",
136
+ "ERA",
137
+ "EXE",
138
+ "FBT",
139
+ "ICN",
140
+ "INP",
141
+ "ISC",
142
+ "NPY",
143
+ "PD",
144
+ "PGH",
145
+ "PIE",
146
+ "PL",
147
+ "PT",
148
+ "PTH",
149
+ "PYI",
150
+ "RET",
151
+ "RSE",
152
+ "RUF",
153
+ "SIM",
154
+ "SLF",
155
+ "TCH",
156
+ "TID",
157
+ "TRY",
158
+ "UP",
159
+ "YTT",
160
+ ]
@@ -6,4 +6,4 @@ from .show_versions import show_versions # noqa: F401
6
6
 
7
7
  __name__ = "pyrit"
8
8
  # Remove dev suffix when releasing and keep in sync with pyproject.toml
9
- __version__ = "0.2.0.dev0"
9
+ __version__ = "0.2.1"
@@ -1,7 +1,7 @@
1
- # Copyright (c) Microsoft Corporation.
2
- # Licensed under the MIT license.
3
-
4
- from pyrit.analytics.conversation_analytics import ConversationAnalytics
5
-
6
-
7
- __all__ = ["ConversationAnalytics"]
1
+ # Copyright (c) Microsoft Corporation.
2
+ # Licensed under the MIT license.
3
+
4
+ from pyrit.analytics.conversation_analytics import ConversationAnalytics
5
+
6
+
7
+ __all__ = ["ConversationAnalytics"]