bayesline.api.equity.RiskDatasetUploadedExposureSettings#

pydantic model bayesline.api.equity.RiskDatasetUploadedExposureSettings#

Settings for uploaded exposure data in a risk dataset.

This class defines settings for using exposure data from uploaded sources, with options for gaussianization, missing value filling, and factor group management.

Show JSON schema
{
   "title": "RiskDatasetUploadedExposureSettings",
   "description": "Settings for uploaded exposure data in a risk dataset.\n\nThis class defines settings for using exposure data from uploaded sources,\nwith options for gaussianization, missing value filling, and factor group management.",
   "type": "object",
   "properties": {
      "exposure_type": {
         "const": "uploaded",
         "default": "uploaded",
         "title": "Exposure Type",
         "type": "string"
      },
      "exposure_source": {
         "description": "The uploaded source of the exposures.",
         "title": "Exposure Source",
         "type": "string"
      },
      "continuous_factor_groups": {
         "description": "The continuous factor groups from the uploaded dataset to carry over.",
         "items": {
            "type": "string"
         },
         "title": "Continuous Factor Groups",
         "type": "array"
      },
      "categorical_factor_groups": {
         "description": "The categorical factor groups from the uploaded dataset to carry over.",
         "items": {
            "type": "string"
         },
         "title": "Categorical Factor Groups",
         "type": "array"
      },
      "factor_groups_gaussianize": {
         "description": "For which continuous groups to gaussianize the exposures.",
         "items": {
            "type": "string"
         },
         "title": "Factor Groups Gaussianize",
         "type": "array"
      },
      "factor_groups_gaussianize_maintain_zeros": {
         "description": "For which continuous groups to gaussianize the exposures and maintain zeros.",
         "items": {
            "type": "string"
         },
         "title": "Factor Groups Gaussianize Maintain Zeros",
         "type": "array"
      },
      "factor_groups_fill_miss": {
         "description": "For which continuous groups to fill missing values.",
         "items": {
            "type": "string"
         },
         "title": "Factor Groups Fill Miss",
         "type": "array"
      },
      "hierarchy_sources": {
         "additionalProperties": {
            "type": "string"
         },
         "description": "Mapping from factor group name to uploaded hierarchy dataset name. Factor groups not in this mapping use a flat hierarchy from factor names.",
         "title": "Hierarchy Sources",
         "type": "object"
      }
   },
   "additionalProperties": false,
   "required": [
      "exposure_source"
   ]
}

Config:
  • frozen: bool = True

  • extra: str = forbid

Fields:
  • categorical_factor_groups (list[str])

  • continuous_factor_groups (list[str])

  • exposure_source (str)

  • exposure_type (Literal['uploaded'])

  • factor_groups_fill_miss (list[str])

  • factor_groups_gaussianize (list[str])

  • factor_groups_gaussianize_maintain_zeros (list[str])

  • hierarchy_sources (dict[str, str])

Validators:
  • _validate_hierarchy_sources » all fields

field exposure_type: Literal['uploaded'] = 'uploaded'#
Validated by:
  • _validate_hierarchy_sources

field exposure_source: str [Required]#

The uploaded source of the exposures.

Validated by:
  • _validate_hierarchy_sources

field continuous_factor_groups: list[str] [Optional]#

The continuous factor groups from the uploaded dataset to carry over.

Validated by:
  • _validate_hierarchy_sources

field categorical_factor_groups: list[str] [Optional]#

The categorical factor groups from the uploaded dataset to carry over.

Validated by:
  • _validate_hierarchy_sources

field factor_groups_gaussianize: list[str] [Optional]#

For which continuous groups to gaussianize the exposures.

Validated by:
  • _validate_hierarchy_sources

field factor_groups_gaussianize_maintain_zeros: list[str] [Optional]#

For which continuous groups to gaussianize the exposures and maintain zeros.

Validated by:
  • _validate_hierarchy_sources

field factor_groups_fill_miss: list[str] [Optional]#

For which continuous groups to fill missing values.

Validated by:
  • _validate_hierarchy_sources

field hierarchy_sources: dict[str, str] [Optional]#

Mapping from factor group name to uploaded hierarchy dataset name. Factor groups not in this mapping use a flat hierarchy from factor names.

Validated by:
  • _validate_hierarchy_sources