Profiles¶
Python-friendly profile declaration.
Profile
¶
Observation profile with a declarative assembly and feature metadata.
The assembly may be declared in a list or grouped in a mapping; mapping groups are flattened in insertion order. Subclasses replace inherited assemblies unless they explicitly include the base assembly. A ProfileFeatures instance may group feature declarations referenced by assembly outputs. Relations declare resolutions linking to other profiles without changing the observation grain.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
id
|
str | None
|
Globally unique profile identifier. |
None
|
assembly
|
Sequence[Operator] | Mapping[str, Sequence[Operator]] | None
|
Operators as a sequence or as named groups of operators. |
None
|
name
|
str | None
|
Human-readable profile name. |
None
|
description
|
str | None
|
Description of the profile. |
None
|
category
|
str | None
|
Free-form grouping label. |
None
|
scope
|
str | None
|
Free-form description of the observation scope. |
None
|
seed
|
str | None
|
ID of the assembly operator that initializes the dataset. The operator must have an explicit ID, return a complete dataframe containing the profile's grain keys, and use a compute binding without a merge. It cannot consume the target dataset. A source dataframe from another profile must be non-nullable. Other fragments merge after the seed. When omitted, accumulation follows the existing behavior. |
None
|
grain
|
Sequence[Resolution] | None
|
Resolutions identifying profile rows. |
None
|
relations
|
Sequence[Resolution] | None
|
Resolutions relating the profile to other profiles. |
None
|
order
|
Sequence[Order] | None
|
Logical ordering of profile observations. |
None
|
identifiers
property
¶
Return only the selected grain columns identifying profile rows.
identifier_types
property
¶
Return logical types for the selected grain identifiers.
relation_types
property
¶
Return logical types for declared relation columns.
key_types
property
¶
Return logical types for identifiers and relations together.
assembly
class-attribute
instance-attribute
¶
assembly: Sequence[Operator] | Mapping[str, Sequence[Operator]] = self._flatten_assembly(self.assembly if assembly is None else assembly)
to_model
¶
Build the canonical profile, rejecting duplicate feature producers.
function_catalog
¶
Collect reusable function contracts without executing implementations.