proteobench.validation.context module#

Validation context passed to every check.

A ValidationContext bundles all inputs a check might need behind a single, uniform object so that every check has the signature check(ctx) -> list[ValidationIssue]. This decouples individual checks from the orchestrator and from each other: a new check can read whatever it needs from the context without changing any call site.

The context carries the concrete inputs available today (standardized DataFrame, parsed parameters, reference FASTA, module config, selected tool) plus a generic reference slot and an extras dict so future module types can supply their own reference data (for example a de novo ground-truth table) without changing the context shape.

class proteobench.validation.context.ValidationContext(standard_df: DataFrame, parameters: Any = None, config: ModuleValidationConfig = <factory>, fasta: FastaReference | None = None, input_format: str | None = None, reference: Any = None, extras: Dict[str, ~typing.Any]=<factory>)[source]#

Bases: object

Inputs available to a validation check.

standard_df#

The standardized result DataFrame produced by the module parser.

Type:

pandas.DataFrame

parameters#

Parsed parameters (a ProteoBenchParameters or any object with the same attributes). None when no parameter file was provided.

Type:

Any, optional

config#

Module validation configuration (column names, flags, FASTA location, resolved profile).

Type:

ModuleValidationConfig

fasta#

Reference protein identifiers, for profiles that validate against a sequence database. None when unavailable or not applicable.

Type:

FastaReference, optional

input_format#

The selected software tool used to produce the results.

Type:

str, optional

reference#

Generic reference object for profiles whose reference is not a FASTA (for example a de novo ground-truth table). None when unused.

Type:

Any, optional

extras#

Escape hatch for additional, profile-specific inputs.

Type:

dict, optional

config: ModuleValidationConfig#
extras: Dict[str, Any]#
fasta: FastaReference | None = None#
input_format: str | None = None#
parameters: Any = None#
reference: Any = None#
standard_df: DataFrame#