@@ -2595,7 +2595,7 @@ class QuestionValidityShieldConfiguration(ConfigurationBase):
25952595
25962596 Attributes:
25972597 name: Unique, user-facing name identifying this shield instance.
2598- type : Discriminator identifying this as a question-validity shield.
2598+ provider_id : Discriminator identifying this as a question-validity shield.
25992599 config: Question-validity-specific configuration.
26002600 """
26012601
@@ -2605,9 +2605,9 @@ class QuestionValidityShieldConfiguration(ConfigurationBase):
26052605 description = "Unique, user-facing name identifying this shield instance." ,
26062606 )
26072607
2608- type : Literal ["question_validity" ] = Field (
2608+ provider_id : Literal ["question_validity" ] = Field (
26092609 ...,
2610- title = "Shield type " ,
2610+ title = "Shield provider id " ,
26112611 description = "Discriminator identifying this as a question-validity shield." ,
26122612 )
26132613
@@ -2623,7 +2623,7 @@ class RedactionShieldConfiguration(ConfigurationBase):
26232623
26242624 Attributes:
26252625 name: Unique, user-facing name identifying this shield instance.
2626- type : Discriminator identifying this as a redaction shield.
2626+ provider_id : Discriminator identifying this as a redaction shield.
26272627 config: Redaction-specific configuration.
26282628 """
26292629
@@ -2633,9 +2633,9 @@ class RedactionShieldConfiguration(ConfigurationBase):
26332633 description = "Unique, user-facing name identifying this shield instance." ,
26342634 )
26352635
2636- type : Literal ["redaction" ] = Field (
2636+ provider_id : Literal ["redaction" ] = Field (
26372637 ...,
2638- title = "Shield type " ,
2638+ title = "Shield provider id " ,
26392639 description = "Discriminator identifying this as a redaction shield." ,
26402640 )
26412641
@@ -2648,11 +2648,11 @@ class RedactionShieldConfiguration(ConfigurationBase):
26482648
26492649ShieldConfiguration = Annotated [
26502650 QuestionValidityShieldConfiguration | RedactionShieldConfiguration ,
2651- Field (discriminator = "type " ),
2651+ Field (discriminator = "provider_id " ),
26522652]
26532653"""Configuration for a single named guardrail shield (question validity or redaction).
26542654
2655- A discriminated union on ``type ``: Pydantic selects
2655+ A discriminated union on ``provider_id ``: Pydantic selects
26562656``QuestionValidityShieldConfiguration`` or ``RedactionShieldConfiguration``
26572657and validates ``config`` against the matching model.
26582658"""
@@ -2847,9 +2847,9 @@ class Configuration(ConfigurationBase):
28472847 default_factory = list ,
28482848 title = "Shields configuration" ,
28492849 description = "List of pydantic-ai-lightspeed agent guardrail shields "
2850- "(question validity and PII redaction). Each entry has a unique 'name', "
2851- "a 'type ' ('question_validity' or 'redaction'), and a type-specific "
2852- "'config'." ,
2850+ "(question validity and PII redaction). Each entry has a unique "
2851+ "'name', a 'provider_id ' ('question_validity' or 'redaction'), "
2852+ "and a type-specific 'config'." ,
28532853 )
28542854
28552855 @model_validator (mode = "after" )
0 commit comments