p1_extraction_judge_runner

UC1-P1 extraction judge runner — evaluate P1 extraction output quality.

class prompt_risk.uc.uc1.p1_extraction_judge_runner.FieldError(*, field: str, issue: str)[source]
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class prompt_risk.uc.uc1.p1_extraction_judge_runner.P1ExtractionJudgeUserPromptData(*, input: str, output: str)[source]
model_config: ClassVar[ConfigDict] = {}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

class prompt_risk.uc.uc1.p1_extraction_judge_runner.P1ExtractionJudgeOutput(*, pass_: bool, reason: str, field_errors: list[~prompt_risk.uc.uc1.p1_extraction_judge_runner.FieldError] = <factory>)[source]

Structured output for the P1 extraction judge prompt.

model_config: ClassVar[ConfigDict] = {'populate_by_name': True, 'validate_by_alias': True, 'validate_by_name': True}

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].

prompt_risk.uc.uc1.p1_extraction_judge_runner.run_p1_extraction_judge(client: BedrockRuntimeClient, data: P1ExtractionJudgeUserPromptData, prompt_version: str = '01', model_id: str = 'us.amazon.nova-2-lite-v1:0') P1ExtractionJudgeOutput[source]

Execute the P1 extraction judge prompt and return validated output.

Follows the same caching and retry strategy as run_p1_extraction().