Predictor#

class superglm.Predictor(name: str, features: ~collections.abc.Mapping[str, ~superglm.types.FeatureSpec], link: str | ~superglm.links.Link | None = None, intercept: bool = True, interactions: tuple[tuple[str, str], ...] = (), interaction_specs: ~collections.abc.Mapping[str, ~typing.Any] = <factory>, interaction_order: tuple[str, ...] = (), offset: ~typing.Any = None)#

Bases: object

Immutable configuration for one natural-parameter predictor.

Feature specifications remain caller-owned configuration objects here. compile_predictor_design deep-clones their complete graph before any build-time mutation occurs.

offset normalizes to a tuple of column names and independently owned, read-only row arrays (indexed Series retain their labels). These are fixed link-scale additions with coefficient one, separate from estimated terms.