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

promptfoo / redteam #1114

Merged
merged 24 commits into from
Feb 10, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
4e84038
add redteam options
pelikhan Feb 9, 2025
ec80141
better support for promptfood reporting
pelikhan Feb 9, 2025
e420126
better promptfoo reporting
pelikhan Feb 9, 2025
ace7a05
adding more options
pelikhan Feb 10, 2025
dae8f68
added provider to cli
pelikhan Feb 10, 2025
aebee32
✨ feat: Add options parameter to callApi method
pelikhan Feb 10, 2025
9192f6f
updated test
pelikhan Feb 10, 2025
6aecf5c
add fileContent field support
pelikhan Feb 10, 2025
421c50d
a few more redteam values
pelikhan Feb 10, 2025
536d817
add red team
pelikhan Feb 10, 2025
16fadd1
a few more updates around default setup
pelikhan Feb 10, 2025
184be71
add more connection
pelikhan Feb 10, 2025
fec5743
:sparkles: Add redteam option in prompt configuration
pelikhan Feb 10, 2025
f80a2ac
add a few more options
pelikhan Feb 10, 2025
38035af
✨ feat: Enhance red team config with language targeting
pelikhan Feb 10, 2025
1a1d00e
refactor type
pelikhan Feb 10, 2025
13cb79c
add redteam option
pelikhan Feb 10, 2025
e697408
✨ feat: update options and concurrency settings for tests
pelikhan Feb 10, 2025
72b1a55
add redteam invocation
pelikhan Feb 10, 2025
74c558b
✨ Enhance redteam features and prompt handling
pelikhan Feb 10, 2025
61d47e8
✨ feat: add "eval" alias for "test" command
pelikhan Feb 10, 2025
55d2deb
revert adding provider to cli
pelikhan Feb 10, 2025
0fd588f
⚡️ refactor: streamline script by removing redteam config
pelikhan Feb 10, 2025
9b6cd48
✨ add CI awareness and confirmation prompts
pelikhan Feb 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
99 changes: 64 additions & 35 deletions THIRD_PARTY_LICENSES.md
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,9 @@ The following npm packages may be included in this product:

- @aws-crypto/[email protected]
- @aws-crypto/[email protected]
- @huggingface/[email protected].2
- flatbuffers@1.12.0
- long@5.2.4
- @huggingface/[email protected].3
- flatbuffers@25.1.24
- long@5.3.0

These packages each contain the following license:

Expand Down Expand Up @@ -1956,11 +1956,11 @@ Apache License

The following npm packages may be included in this product:

- @aws-sdk/client-cognito-identity@3.742.0
- @aws-sdk/client-sso@3.734.0
- @aws-sdk/credential-provider-cognito-identity@3.742.0
- @aws-sdk/client-cognito-identity@3.744.0
- @aws-sdk/client-sso@3.744.0
- @aws-sdk/credential-provider-cognito-identity@3.744.0
- @aws-sdk/[email protected]
- @aws-sdk/util-user-agent-node@3.734.0
- @aws-sdk/util-user-agent-node@3.744.0
- @smithy/[email protected]
- @smithy/[email protected]
- @smithy/[email protected]
Expand Down Expand Up @@ -2182,7 +2182,7 @@ Apache License

The following npm package may be included in this product:

- @aws-sdk/client-bedrock-runtime@3.741.0
- @aws-sdk/client-bedrock-runtime@3.744.0

This package contains the following license:

Expand Down Expand Up @@ -2394,7 +2394,7 @@ The following npm packages may be included in this product:

- @aws-sdk/[email protected]
- @aws-sdk/[email protected]
- @aws-sdk/middleware-user-agent@3.734.0
- @aws-sdk/middleware-user-agent@3.744.0
- @smithy/[email protected]
- @smithy/[email protected]
- @smithy/[email protected]
Expand Down Expand Up @@ -2862,7 +2862,7 @@ MIT License

The following npm package may be included in this product:

- genaiscript-vscode@1.101.1
- genaiscript-vscode@1.102.0

This package contains the following license:

Expand Down Expand Up @@ -4211,14 +4211,14 @@ Apache License

The following npm packages may be included in this product:

- @aws-sdk/credential-provider-env@3.734.0
- @aws-sdk/credential-provider-ini@3.741.0
- @aws-sdk/credential-provider-node@3.741.0
- @aws-sdk/credential-providers@3.742.0
- @aws-sdk/credential-provider-env@3.744.0
- @aws-sdk/credential-provider-ini@3.744.0
- @aws-sdk/credential-provider-node@3.744.0
- @aws-sdk/credential-providers@3.744.0
- @aws-sdk/[email protected]
- @aws-sdk/token-providers@3.734.0
- @aws-sdk/token-providers@3.744.0
- @aws-sdk/[email protected]
- @aws-sdk/util-endpoints@3.734.0
- @aws-sdk/util-endpoints@3.743.0
- @aws-sdk/[email protected]
- @aws-sdk/[email protected]
- @smithy/[email protected]
Expand Down Expand Up @@ -4471,9 +4471,9 @@ Apache License

The following npm packages may be included in this product:

- @aws-sdk/credential-provider-process@3.734.0
- @aws-sdk/credential-provider-sso@3.734.0
- @aws-sdk/credential-provider-web-identity@3.734.0
- @aws-sdk/credential-provider-process@3.744.0
- @aws-sdk/credential-provider-sso@3.744.0
- @aws-sdk/credential-provider-web-identity@3.744.0

These packages each contain the following license:

Expand Down Expand Up @@ -5374,9 +5374,9 @@ END OF TERMS AND CONDITIONS

The following npm packages may be included in this product:

- @aws-sdk/core@3.734.0
- @aws-sdk/credential-provider-http@3.734.0
- @aws-sdk/nested-clients@3.734.0
- @aws-sdk/core@3.744.0
- @aws-sdk/credential-provider-http@3.744.0
- @aws-sdk/nested-clients@3.744.0
- [email protected]

These packages each contain the following license:
Expand Down Expand Up @@ -6547,6 +6547,36 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

-----------

The following npm package may be included in this product:

- @azure/[email protected]

This package contains the following license:

Copyright (c) Microsoft Corporation.

MIT License

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

-----------

The following npm packages may be included in this product:

- [email protected]
Expand Down Expand Up @@ -8009,24 +8039,24 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
The following npm packages may be included in this product:

- @esbuild/[email protected]
- @napi-rs/[email protected].66
- @napi-rs/[email protected].66
- @napi-rs/[email protected].67
- @napi-rs/[email protected].67
- @tokenizer/[email protected]
- [email protected]
- [email protected]
- genaiscript-core-internal@1.101.1
- genaiscript-sample@1.101.1
- genaiscript-web@1.101.1
- genaiscript@1.101.1
- genaiscript-core-internal@1.102.0
- genaiscript-sample@1.102.0
- genaiscript-web@1.102.0
- genaiscript@1.102.0
- [email protected]
- [email protected]
- [email protected]
- [email protected]
- [email protected]
- [email protected]
- [email protected].20241212-1f88284f96
- [email protected].20250206-d981b153d3
- [email protected]
- [email protected].20250114-228dd16893
- [email protected].20250206-d981b153d3
- [email protected]
- [email protected]
- [email protected]
Expand Down Expand Up @@ -8705,7 +8735,7 @@ SOFTWARE.

The following npm package may be included in this product:

- @napi-rs/[email protected].66
- @napi-rs/[email protected].67

This package contains the following license:

Expand Down Expand Up @@ -9361,7 +9391,7 @@ The following npm packages may be included in this product:
- [email protected]
- [email protected]
- [email protected]
- [email protected].5
- [email protected].6
- [email protected]
- [email protected]
- [email protected]
Expand All @@ -9384,7 +9414,7 @@ The following npm packages may be included in this product:
- [email protected]
- [email protected]
- [email protected]
- type-fest@4.33.0
- type-fest@4.34.1
- [email protected]
- [email protected]
- [email protected]
Expand Down Expand Up @@ -9666,7 +9696,7 @@ SOFTWARE.
The following npm packages may be included in this product:

- @octokit/[email protected]
- @octokit/[email protected].0
- @octokit/[email protected].1
- @octokit/[email protected]

These packages each contain the following license:
Expand Down Expand Up @@ -11735,7 +11765,6 @@ The following npm packages may be included in this product:
- @azure/[email protected]
- @azure/[email protected]
- @azure/[email protected]
- @azure/[email protected]
- @azure/[email protected]
- @azure/[email protected]
- @azure/[email protected]
Expand Down
4 changes: 3 additions & 1 deletion docs/src/content/docs/reference/cli/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@

## `test`

```

Check warning on line 87 in docs/src/content/docs/reference/cli/commands.md

View workflow job for this annotation

GitHub Actions / build

The command usage should be consistent. Consider using a single pipe symbol (`|`) to separate the commands for clarity.

Choose a reason for hiding this comment

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

The command usage should be consistent. Consider using a single pipe symbol (|) to separate the commands for clarity.

AI-generated content by pr-docs-review-commit command_usage may be incorrect

Usage: genaiscript test [options] [command]
Usage: genaiscript test|eval [options] [command]

Options:
-h, --help display help for command
Expand All @@ -106,9 +106,10 @@

Arguments:
script Script ids. If not provided, all scripts
are tested

Check warning on line 109 in docs/src/content/docs/reference/cli/commands.md

View workflow job for this annotation

GitHub Actions / build

Options should be grouped logically and consistently ordered. Consider moving `--redteam` options closer to their respective commands.

Choose a reason for hiding this comment

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

Options should be grouped logically and consistently ordered. Consider moving --redteam options closer to their respective commands.

AI-generated content by pr-docs-review-commit option_order may be incorrect


Options:
--redteam run red team tests
-p, --provider <string> Preferred LLM provider aliases (choices:
"openai", "azure", "azure_serverless",
"azure_serverless_models", "anthropic",
Expand Down Expand Up @@ -144,9 +145,10 @@
```
Usage: genaiscript test list [options]

List available tests in workspace

Check warning on line 148 in docs/src/content/docs/reference/cli/commands.md

View workflow job for this annotation

GitHub Actions / build

Options should be grouped logically and consistently ordered. Consider moving `--redteam` options closer to their respective commands.

Choose a reason for hiding this comment

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

Options should be grouped logically and consistently ordered. Consider moving --redteam options closer to their respective commands.

AI-generated content by pr-docs-review-commit option_order may be incorrect


Options:
--redteam list red team tests
-g, --groups <groups...> groups to include or exclude. Use :! prefix to
exclude
-h, --help display help for command
Expand Down
Loading
Loading