fix(redteam): suppress spurious multi_turn_error_message when multi_turn=false (#202)#215
Merged
cdot65 merged 1 commit intoMay 28, 2026
Conversation
…urn=false (#202) Adds sanitizeTargetMetadata() at the SDK normalizer boundary plus the probe path so targets probe / create / update / get no longer surface the "Multi turn configuration JSON not provided" message when the operator never opted into multi-turn. Field is preserved when multi_turn=true, where it reflects a real configuration error.
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.
Summary
Closes #202.
Adds
sanitizeTargetMetadata()at the SDK normalizer boundary plus theprobeTargetpath.airs redteam targets probe / create / update / getno longer surfacetarget_metadata.multi_turn_error_message: "Multi turn configuration JSON not provided"whenmulti_turn: false. The field is preserved whenmulti_turn: true, where it reflects a real configuration error.Single helper applied at two points:
normalizeTargetDetail()— coversget/create/updateprobeTarget()— raw response path, not normalizedTest plan
pnpm test— 666 tests, +5 new intests/unit/airs/redteam.spec.tscovering probe/get/create false-case suppression + true-case retentionpnpm lintpnpm tsc --noEmitpnpm docs:checkairs redteam targets probe --config target.jsonagainst a real tenant returns metadata withoutmulti_turn_error_messageairs redteam targets create --config target.jsonthenget <uuid>— same