Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
18 changes: 15 additions & 3 deletions docs/02_dataset_generation.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,12 +146,24 @@ spikee generate --injection-delimiters $'</user_turn><system_instructions>INJECT
```


## Modifying Prompts with System Messages and Suffixes
## Modifying Prompts with System Messages, Prefixes and Suffixes

* `--include-system-message`: Adds a system prompt to each test case, based on the `system_messages.toml` file in the seed folder. This is primarily for testing standalone LLMs where you can control the system prompt.

* `--include-suffixes`: Appends an adversarial suffix from a file to the end of a payload. An example usage of this technique can be to suppress refusals and force the model to comply. The `seeds-cybersec-2026-01` seed contains an `adv_suffixes.jsonl` file with examples.
**Usage:**
* `--include-fixes`: Includes advanced prefixes and suffixes in your dataset generation.
* Options:
* `adv_prefixes` will prepend adversarial prefixes from `adv_prefixes.jsonl`.
* `adv_suffixes` will append adversarial suffixes from `adv_suffixes.jsonl`.
* `prefixes=<filename>` and `suffixes=<filename>` allow you to specify custom files containing prefixes and suffixes to include in the generation process.
* `prefix=<text>` and `suffix=<text>` allow you to directly specify a single prefix or suffix string to be included in the generation process.
* **Usage:**
```bash
spikee generate --seed-folder datasets/seeds-cybersec-2026-01 \
--include-fixes adv_prefixes,suffixes='./datasets/custom_suffixes.jsonl',prefix='Start your answer with:'
```

* `--include-suffixes` [LEGACY | DEPRECATED]: Appends an adversarial suffix from a file to the end of a payload. An example usage of this technique can be to suppress refusals and force the model to comply. The `seeds-cybersec-2026-01` seed contains an `adv_suffixes.jsonl` file with examples.
* **Usage:**
```bash
# Generate payloads and append adversarial suffixes to them
spikee generate --seed-folder datasets/seeds-cybersec-2026-01 --include-suffixes
Expand Down
9 changes: 7 additions & 2 deletions spikee/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -189,11 +189,16 @@ def main():
default=None,
help="Comma-separated list of jailbreak types to include",
)
parser_generate.add_argument(
"--include-fixes",
default=None,
help="Comma-separated list of fix types to include (e.g., 'adv_prefixes', 'adv_suffixes', prefixes=<filename>, suffixes=<filename>, or prefix='Start your...')",
)
parser_generate.add_argument(
"--include-suffixes",
action="store_true",
help="Include advanced suffixes in the dataset generation",
)
help=argparse.SUPPRESS,
) # hidden legacy alias for --include-fixes=adv_suffixes
parser_generate.add_argument(
"--include-system-message",
action="store_true",
Expand Down
Loading