Skip to content

FEAT add crescendo persona scenario techniques (movie director, history lecture, journalist interview)#1677

Merged
rlundeen2 merged 1 commit intomicrosoft:mainfrom
precognitivem0nk:feat/crescendo-scenario-techniques
May 1, 2026
Merged

FEAT add crescendo persona scenario techniques (movie director, history lecture, journalist interview)#1677
rlundeen2 merged 1 commit intomicrosoft:mainfrom
precognitivem0nk:feat/crescendo-scenario-techniques

Conversation

@precognitivem0nk
Copy link
Copy Markdown
Contributor

What

Adds three persona-driven YAML variants of the single_turn_crescendo technique landed in #1665 (movie director, history lecture, journalist interview), plus a new pyrit/setup/initializers/components/scenarios.py initializer (ScenarioTechniqueInitializer, registry name scenario_technique, execution_order 3) that registers them.

Why

Following @rlundeen2's guidance on the closed PR #1657: ship YAML variants on top of #1665 instead of a new attack primitive. The scenario-techniques pattern is more flexible and lets dataset diversity drive crescendo coverage without new code paths.

Refs #388.

Files

  • pyrit/datasets/executors/red_teaming/crescendo_movie_director.yaml (new, the persona @rlundeen2 specifically suggested)
  • pyrit/datasets/executors/red_teaming/crescendo_history_lecture.yaml (new)
  • pyrit/datasets/executors/red_teaming/crescendo_journalist_interview.yaml (new)
  • pyrit/setup/initializers/components/scenarios.py (new, slots into the existing target/scorer/scenario_technique 1-2-3 chain)
  • pyrit/setup/initializers/components/__init__.py (export)
  • pyrit/setup/initializers/__init__.py (re-export)
  • tests/unit/setup/test_scenarios_initializer.py (new, 26 tests covering YAML loading, schema, persona distinctness, registration, and the get_default_adversarial_target fallback)

Schema

Each persona YAML uses the same schema as crescendo_simulated.yaml from #1665: parameters [objective, max_turns], data_type: text, and a value block templated on {{ objective }} and {{ max_turns }}. num_turns defaults to 3, matching SeedSimulatedConversation's canonical default.

Opt-in by design

The personas live behind the new ScenarioTechniqueInitializer rather than in the core SCENARIO_TECHNIQUES list, matching @rlundeen2's note on #1657 ("I might put them in an additional scenario initializer vs the core"). Users opt in by including scenario_technique in their initializer config; out of the box, no Scenario auto-loads them. crescendo_simulated from #1665 remains the always-available default.

Verification

  • pytest tests/unit/setup/: 207 passed
  • pytest tests/unit/scenario/: 445 passed
  • pytest tests/unit/: 7075 passed, 102 skipped (env-gated live targets), 0 failures
  • ruff check, ruff format --check: clean on all new and modified files
  • No em-dashes or en-dashes in any shipped YAML or source file (the test file has two intentional needles for absence assertions, with an inline comment explaining)
  • Local rendering check on each YAML: loads via SeedPrompt.from_yaml_file, renders cleanly with render_template_value(objective=..., max_turns=3), no Jinja artifacts left
  • Initializer registration check: running ScenarioTechniqueInitializer.initialize_async() in isolation registers all 3 personas plus the core specs

Notes

  • DCO sign-off on the commit.
  • Branch is currently behind upstream/main by 5 unrelated commits. Trial merge is clean and conflict-free. Happy to rebase if preferred.

…ry lecture, journalist interview)

Builds on PR microsoft#1665 by adding three persona-driven YAML variants of single_turn_crescendo, wired through a new pyrit/setup/initializers/components/scenarios.py initializer per maintainer guidance on PR microsoft#1657. No new attack primitives.

Refs microsoft#388

Signed-off-by: precognitivem0nk <rextedgorman@gmail.com>
@rlundeen2 rlundeen2 self-assigned this May 1, 2026
rlundeen2

This comment was marked as off-topic.

@rlundeen2 rlundeen2 enabled auto-merge May 1, 2026 16:32
@rlundeen2
Copy link
Copy Markdown
Contributor

rlundeen2 commented May 1, 2026

This looks great, ty @precognitivem0nk!

We're building some easier benchmarks soon, and I'm stoked to see how these all compare

@rlundeen2 rlundeen2 added this pull request to the merge queue May 1, 2026
Merged via the queue into microsoft:main with commit 585c009 May 1, 2026
48 checks passed
@precognitivem0nk
Copy link
Copy Markdown
Contributor Author

Thanks for the quick review and merge. Looking forward to the new benchmarks. Happy to add more persona variants when the comparison surfaces gaps.

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.

2 participants