aeat.domain.calculations.registry._checker_oracle_flow module

Shared verdict-flow helpers for read-only checker oracles.

Provides the _CheckerBaseModel base, shared flow helpers, and the decode_replay_observation() convenience used by every BaseCheckerOracle subclass (GROI, NIF-IVA, and future sibling checkers).

normalize_verdict_mapping(values, *, blank_message)[source]

Normalize identifier/verdict mappings and reject blank entries.

Return type:

dict[str, str]

Parameters:
normalize_expected_verdicts(expected, *, blank_message)[source]

Normalize expected identifier/verdict mappings and reject blank entries.

Return type:

dict[str, str]

Parameters:
replay_parse_operation(action)[source]

Return the single local replay-parse RemoteOperation tuple.

Return type:

tuple[RemoteOperation, ...]

Parameters:

action (str)

decode_replay_observation(payload, *, surface_label, observation_type)[source]

Decode replay JSON into the requested observation model.

Return type:

TypeVar(ObservationT, bound= _CheckerBaseModel)

Parameters:
  • payload (bytes)

  • surface_label (str)

  • observation_type (type[ObservationT])

observed_verdict(values, key)[source]

Return the observed verdict for key after identifier normalization.

Return type:

str | None

Parameters:
compare_verdict_field(key, expected, *, observed)[source]

Compare one expected verdict against one observed verdict and return a ParityFieldComparison.

Return type:

ParityFieldComparison

Parameters:
  • key (str)

  • expected (str)

  • observed (str | None)