pudl.extract.ferc714

Routines used for extracting the raw FERC 714 data.

Attributes

logger

FERC714_CSV_ENCODING

Dictionary mapping PUDL tables to FERC-714 CSV filenames and character encodings.

TABLE_NAME_MAP_FERC714

A mapping of PUDL DB table names to their XBRL and CSV source table names.

raw_ferc714_csv_assets

raw_ferc714_xbrl_assets

Functions

raw_ferc714_csv_asset_factory(→ dagster.AssetsDefinition)

Generates an asset for building the raw CSV-based FERC 714 dataframe.

raw_ferc714_xbrl__metadata_json(→ dict[str, dict[str, ...)

Extract the FERC 714 XBRL Taxonomy metadata we've stored as JSON.

create_raw_ferc714_xbrl_assets(→ list[dagster.SourceAsset])

Create SourceAssets for raw FERC 714 XBRL tables.

Module Contents

pudl.extract.ferc714.logger[source]
pudl.extract.ferc714.FERC714_CSV_ENCODING: collections.OrderedDict[str, dict[str, str]][source]

Dictionary mapping PUDL tables to FERC-714 CSV filenames and character encodings.

pudl.extract.ferc714.TABLE_NAME_MAP_FERC714: collections.OrderedDict[str, dict[str, str]][source]

A mapping of PUDL DB table names to their XBRL and CSV source table names.

pudl.extract.ferc714.raw_ferc714_csv_asset_factory(table_name: str) dagster.AssetsDefinition[source]

Generates an asset for building the raw CSV-based FERC 714 dataframe.

pudl.extract.ferc714.raw_ferc714_xbrl__metadata_json(context) dict[str, dict[str, list[dict[str, Any]]]][source]

Extract the FERC 714 XBRL Taxonomy metadata we’ve stored as JSON.

Returns:

A dictionary keyed by PUDL table name, with an instant and a duration entry for each table, corresponding to the metadata for each of the respective instant or duration tables from XBRL if they exist. Table metadata is returned as a list of dictionaries, each of which can be interpreted as a row in a tabular structure, with each row annotating a separate XBRL concept from the FERC 714 filings.

pudl.extract.ferc714.create_raw_ferc714_xbrl_assets() list[dagster.SourceAsset][source]

Create SourceAssets for raw FERC 714 XBRL tables.

SourceAssets allow you to access assets that are generated elsewhere. In our case, the XBRL database contains the raw FERC 714 assets from 2021 onward. Prior to that, the assets are distributed as CSVs and are extracted with the raw_ferc714_csv_asset_factory function.

Returns:

A list of FERC 714 SourceAssets.

pudl.extract.ferc714.raw_ferc714_csv_assets[source]
pudl.extract.ferc714.raw_ferc714_xbrl_assets[source]