# coding: utf-8

"""
    Mixpeek API

    This is the Mixpeek API, providing access to various endpoints for data processing and retrieval.

    The version of the OpenAPI document: 1.3.0
    Contact: info@mixpeek.com
    Generated by OpenAPI Generator (https://openapi-generator.tech)

    Do not edit the class manually.
"""  # noqa: E501


from __future__ import annotations
import json
from enum import Enum
from typing_extensions import Self


class CovariateType(str, Enum):
    """
    Type of covariate/predictor variable for conversion analysis.  Different types enable different analysis strategies: - CATEGORICAL: String values, analyzed via grouping (e.g., sender_domain, priority) - NUMERIC: Continuous values, binned into quartiles/deciles (e.g., word_count, price) - EMBEDDING: Dense vectors, clustered for semantic analysis (e.g., CLIP embeddings) - CLUSTER_ID: Pre-computed cluster identifiers (e.g., topic_cluster, visual_cluster)  Examples:     ```python     # Categorical: Which email domains convert better?     CovariateConfig(field_path=\"sender_domain\", covariate_type=\"categorical\")      # Numeric: Do longer emails convert faster?     CovariateConfig(field_path=\"word_count\", covariate_type=\"numeric\")      # Embedding: Do visually similar images follow similar paths?     CovariateConfig(field_path=\"features.clip\", covariate_type=\"embedding\")      # Cluster: Which topic clusters have highest conversion?     CovariateConfig(field_path=\"metadata.topic_id\", covariate_type=\"cluster_id\")     ```
    """

    """
    allowed enum values
    """
    CATEGORICAL = 'categorical'
    NUMERIC = 'numeric'
    EMBEDDING = 'embedding'
    CLUSTER_ID = 'cluster_id'

    @classmethod
    def from_json(cls, json_str: str) -> Self:
        """Create an instance of CovariateType from a JSON string"""
        return cls(json.loads(json_str))


