abacusai.feature_group_template

Module Contents

Classes

FeatureGroupTemplate

A template for creating feature groups.

class abacusai.feature_group_template.FeatureGroupTemplate(client, featureGroupTemplateId=None, description=None, featureGroupId=None, name=None, templateSql=None, templateVariables=None, createdAt=None, updatedAt=None)

Bases: abacusai.return_class.AbstractApiClass

A template for creating feature groups.

Parameters
  • client (ApiClient) – An authenticated API Client instance

  • featureGroupTemplateId (str) – The unique identifier for this feature group template.

  • description (str) – A user-friendly text description of this feature group template.

  • featureGroupId (str) – The unique identifier for the feature group used to create this template.

  • name (str) – The user-friendly name of this feature group template.

  • templateSql (str) – SQL that can include variables which will be replaced by values from the template config to resolve this template SQL into a valid SQL query for a feature group.

  • templateVariables (dict) – A map, from template variable names to parameters for replacing those template variables with values (e.g. to values and metadata on how to resolve those values).

  • createdAt (str) – When the feature group template was created.

  • updatedAt (str) – When the feature group template was updated.

__repr__()

Return repr(self).

to_dict()

Get a dict representation of the parameters in this class

Returns

The dict value representation of the class parameters

Return type

dict

delete()

Delete an existing feature group template.

Parameters

feature_group_template_id (str) – The unique ID associated with the feature group template.

refresh()

Calls describe and refreshes the current object’s fields

Returns

The current object

Return type

FeatureGroupTemplate

describe()

Describe a Feature Group Template.

Parameters

feature_group_template_id (str) – The unique ID of a feature group template.

Returns

The feature group template object.

Return type

FeatureGroupTemplate

update(template_sql=None, template_variables=None)

Update a feature group template.

Parameters
  • template_sql (str) – If provided, the new value to use for the template sql.

  • template_variables (list) – If provided, the new value to use for the template variables.

Returns

The updated feature group template.

Return type

FeatureGroupTemplate

preview_resolution(template_bindings=None, template_sql=None, template_variables=None, should_validate=True)

Resolve template sql using template variables and template bindings.

Parameters
  • template_bindings (list) – Values that overide the template variable values specified by the template.

  • template_sql (str) – If specified, use this as the template sql instead of the feature group template’s sql.

  • template_variables (list) – Template variables to use. If a template is provided, this overrides the template’s template variables.

  • should_validate (bool) –

Returns

None

Return type

ResolvedFeatureGroupTemplate