Skip to content

MAINT: Minor pyrit.model module reorganization #1999

Open
rlundeen2 wants to merge 1 commit into
microsoft:mainfrom
rlundeen2:rlundeen2/models-relocate-result-message-types
Open

MAINT: Minor pyrit.model module reorganization #1999
rlundeen2 wants to merge 1 commit into
microsoft:mainfrom
rlundeen2:rlundeen2/models-relocate-result-message-types

Conversation

@rlundeen2

Copy link
Copy Markdown
Contributor

Moving some modules around to where they make sense. Deprecation seemed more confusing than helpful since everything is imported from the base.

Move ScenarioResult into pyrit.models.results and ConversationReference /
ChatMessage into pyrit.models.messages. These symbols are re-exported from
pyrit.models, so the canonical import stays `from pyrit.models import X` and
no deprecation shim is needed at the old submodule paths.

Switch all external consumers and tests to the short-form package-root import
per the style guide, keep same-package imports on the specific module to avoid
cycles, and clarify that ChatMessage is the OpenAI Chat Completions wire shape
(distinct from the domain Message/MessagePiece). Adds a dedicated Conversation
model test.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@rlundeen2 rlundeen2 changed the title MAINT: Minor module reorganization MAINT: Minor pyrit.model module reorganization Jun 12, 2026
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.

1 participant