Skip to content

FEAT: Add round-robin adversarial target endpoints - #2439

Open
Adrian Gavrila (adrian-gavrila) wants to merge 5 commits into
microsoft:mainfrom
adrian-gavrila:adrian-gavrila-grok-adversarial-round-robin
Open

FEAT: Add round-robin adversarial target endpoints#2439
Adrian Gavrila (adrian-gavrila) wants to merge 5 commits into
microsoft:mainfrom
adrian-gavrila:adrian-gavrila-grok-adversarial-round-robin

Conversation

@adrian-gavrila

@adrian-gavrila Adrian Gavrila (adrian-gavrila) commented Aug 20, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add environment configuration for up to three adversarial chat endpoints
  • publish multiple configured endpoints as a RoundRobinTarget under the existing adversarial_chat name
  • preserve single-endpoint behavior and direct access to individual members
  • keep explicitly configured adversarial endpoints out of inferred auto-grouping
  • cover single, multiple, noncontiguous, incompatible, and auto_group=False configurations

Why

This allows adversarial workloads to rotate across regional deployments without requiring scenario changes.

Backward compatibility

Existing users do not need to update their configuration. When only the original ADVERSARIAL_CHAT_* endpoint is configured, adversarial_chat remains a direct OpenAIChatTarget; a round-robin target is created only when multiple endpoints are available.

Users configuring regional deployments with different deployment names should assign them the same ADVERSARIAL_CHAT_UNDERLYING_MODEL* value so PyRIT can verify that they are behaviorally compatible.

Testing

  • new and existing unit tests in affected code paths pass
  • pre-commit hooks pass

@hannahwestra25 hannahwestra25 self-assigned this Aug 20, 2026
Comment thread pyrit/setup/initializers/targets.py Outdated
Comment thread pyrit/setup/initializers/targets.py
Comment thread pyrit/setup/initializers/targets.py
Co-authored-by: hannahwestra25 <hannahwestra@microsoft.com>
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