FEAT: Add Local File Dataset Configuration for Dataset Tinkering - #2285
Open
ValbuenaVC wants to merge 7 commits into
Open
FEAT: Add Local File Dataset Configuration for Dataset Tinkering#2285ValbuenaVC wants to merge 7 commits into
ValbuenaVC wants to merge 7 commits into
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 34c04c70-cd29-4216-9321-65a3beedc523
Contributor
There was a problem hiding this comment.
Pull request overview
Adds file-backed YAML dataset configuration for rapid local scenario iteration without memory synchronization.
Changes:
- Adds asynchronous file-backed dataset resolution with validation and sampling.
- Adds unit coverage for reloads, grouping, validation, and memory isolation.
- Updates the RapidResponse notebook workflow.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
pyrit/scenario/core/dataset_configuration.py |
Implements local YAML-backed configuration. |
tests/unit/scenario/core/test_dataset_configuration.py |
Tests file-backed behavior. |
doc/scanner/airt.py |
Documents the local iteration workflow. |
doc/scanner/airt.ipynb |
Synchronizes notebook documentation. |
ValbuenaVC
marked this pull request as ready for review
July 29, 2026 19:43
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 7 out of 7 changed files in this pull request and generated no new comments.
Comments suppressed due to low confidence (1)
tests/unit/scenario/airt/test_rapid_response.py:257
- This new test omits explicit types for both mock fixtures and its return value. The repository requires every function parameter and return type to be annotated (
.github/instructions/style-guide.instructions.md:81-84); please useMagicMockfor these fixtures andNonefor the return.
mock_objective_target,
mock_objective_scorer,
):
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: 34c04c70-cd29-4216-9321-65a3beedc523
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
RapidResponse operators need a short local iteration loop: ask Copilot to create or edit YAML seeds, reinitialize the scenario, and run against the latest file contents without synchronizing those seeds to a database.
This change adds
DatasetAttackConfiguration.from_yaml_file(...), a file-backed inline source that:DatasetConstraintErrormessages.Because disk remains authoritative, successful local loads now warn users at every local provider boundary. These warnings explain that in-process seed mutations are not written back automatically and will be lost unless saved to disk. Failed loads do not emit false success warnings.
The standard RapidResponse example remains unchanged. A separate recipe demonstrates the Copilot edit/rerun workflow using
~/.pyrit/rapid_response_local.prompt, a fresh scenario instance per iteration, and visible persistence warnings.This intentionally does not add file watchers, dataset identifiers, revisioning, synchronization commands, or database schema changes.
Tests and Documentation
Developed in red-green TDD cycles covering:
Validation completed:
105 passedacross local provider and dataset-configuration suites.46 passedin the RapidResponse suite.typassed.git diff --checkpassed.