def __init__(
        self,
        model_name: str,
        truncate: str = "END",
        input_type: Optional[str] = None,
        service_endpoint: Optional[str] = None,
        compartment_id: Optional[str] = None,
        auth_type: Optional[str] = "API_KEY",
        auth_profile: Optional[str] = "DEFAULT",
        auth_file_location: Optional[str] = "~/.oci/config",
        client: Optional[Any] = None,
        embed_batch_size: int = DEFAULT_EMBED_BATCH_SIZE,
        callback_manager: Optional[CallbackManager] = None,
    ):
        """
        Initializes the OCIGenAIEmbeddings class.

        Args:
            model_name (str): The name or ID of the model to be used for generating embeddings, e.g., "cohere.embed-english-light-v3.0".

            truncate (str): A string indicating the truncation strategy for long input text. Possible values
                            are 'START', 'END', or 'NONE'.

            input_type (Optional[str]): An optional string that specifies the type of input provided to the model.
                                        This is model-dependent and could be one of the following: "search_query",
                                        "search_document", "classification", or "clustering".

            service_endpoint (str): service endpoint url, e.g., "https://inference.generativeai.us-chicago-1.oci.oraclecloud.com"

            compartment_id (str): OCID of the compartment.

            auth_type (Optional[str]): Authentication type, can be: API_KEY (default), SECURITY_TOKEN, INSTANCEAL, RESOURCE_PRINCIPAL. If not specified, API_KEY will be used

            auth_profile (Optional[str]): The name of the profile in ~/.oci/config. If not specified , DEFAULT will be used

            auth_file_location (Optional[str]): Path to the config file, If not specified, ~/.oci/config will be used.

            client (Optional[Any]): An optional OCI client object. If not provided, the client will be created using the
                                    provided service endpoint and authentifcation method.

        """
        super().__init__(
            model_name=model_name,
            truncate=truncate,
            input_type=input_type,
            service_endpoint=service_endpoint,
            compartment_id=compartment_id,
            auth_type=auth_type,
            auth_profile=auth_profile,
            auth_file_location=auth_file_location,
            embed_batch_size=embed_batch_size,
            callback_manager=callback_manager,
        )
        if client is not None:
            self._client = client
        else:
            try:
                import oci

                client_kwargs = {
                    "config": {},
                    "signer": None,
                    "service_endpoint": service_endpoint,
                    "retry_strategy": oci.retry.DEFAULT_RETRY_STRATEGY,
                    "timeout": (
                        10,
                        240,
                    ),  # default timeout config for OCI Gen AI service
                }

                if auth_type == OCIAuthType(1).name:
                    client_kwargs["config"] = oci.config.from_file(
                        file_location=auth_file_location, profile_name=auth_profile
                    )
                    client_kwargs.pop("signer", None)
                elif auth_type == OCIAuthType(2).name:

                    def make_security_token_signer(oci_config):  # type: ignore[no-untyped-def]
                        pk = oci.signer.load_private_key_from_file(
                            oci_config.get("key_file"), None
                        )
                        with open(
                            oci_config.get("security_token_file"), encoding="utf-8"
                        ) as f:
                            st_string = f.read()
                        return oci.auth.signers.SecurityTokenSigner(st_string, pk)

                    client_kwargs["config"] = oci.config.from_file(
                        file_location=auth_file_location, profile_name=auth_profile
                    )
                    client_kwargs["signer"] = make_security_token_signer(
                        oci_config=client_kwargs["config"]
                    )
                elif auth_type == OCIAuthType(3).name:
                    client_kwargs["signer"] = (
                        oci.auth.signers.InstancePrincipalsSecurityTokenSigner()
                    )
                elif auth_type == OCIAuthType(4).name:
                    client_kwargs["signer"] = (
                        oci.auth.signers.get_resource_principals_signer()
                    )
                else:
                    raise ValueError(
                        f"Please provide valid value to auth_type, {auth_type} is not valid."
                    )

                self._client = oci.generative_ai_inference.GenerativeAiInferenceClient(
                    **client_kwargs
                )

            except ImportError as ex:
                raise ModuleNotFoundError(
                    "Could not import oci python package. "
                    "Please make sure you have the oci package installed."
                ) from ex
            except Exception as e:
                raise ValueError(
                    """Could not authenticate with OCI client.
                    If INSTANCE_PRINCIPAL or RESOURCE_PRINCIPAL is used, please check the specified
                    auth_profile, auth_file_location and auth_type are valid.""",
                    e,
                ) from e

        Initializes the OCIGenAIEmbeddings class.

        Args:
            model_name (str): The name or ID of the model to be used for generating embeddings, e.g., "cohere.embed-english-light-v3.0".

            truncate (str): A string indicating the truncation strategy for long input text. Possible values
                            are 'START', 'END', or 'NONE'.

            input_type (Optional[str]): An optional string that specifies the type of input provided to the model.
                                        This is model-dependent and could be one of the following: "search_query",
                                        "search_document", "classification", or "clustering".

            service_endpoint (str): service endpoint url, e.g., "https://inference.generativeai.us-chicago-1.oci.oraclecloud.com"

            compartment_id (str): OCID of the compartment.

            auth_type (Optional[str]): Authentication type, can be: API_KEY (default), SECURITY_TOKEN, INSTANCEAL, RESOURCE_PRINCIPAL. If not specified, API_KEY will be used

            auth_profile (Optional[str]): The name of the profile in ~/.oci/config. If not specified , DEFAULT will be used

            auth_file_location (Optional[str]): Path to the config file, If not specified, ~/.oci/config will be used.

            client (Optional[Any]): An optional OCI client object. If not provided, the client will be created using the
                                    provided service endpoint and authentifcation method.

        
llama-index-integrations/embeddings/llama-index-embeddings-oci-genai/llama_index/embeddings/oci_genai/base.py