<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/dialogflow/v2/generator.proto

namespace Google\Cloud\Dialogflow\V2;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\GPBUtil;
use Google\Protobuf\RepeatedField;

/**
 * LLM generator.
 *
 * Generated from protobuf message <code>google.cloud.dialogflow.v2.Generator</code>
 */
class Generator extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. Identifier. The resource name of the generator. Format:
     * `projects/<Project ID>/locations/<Location ID>/generators/<Generator ID>`
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $name = '';
    /**
     * Optional. Human readable description of the generator.
     *
     * Generated from protobuf field <code>string description = 2 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $description = '';
    /**
     * Optional. Inference parameters for this generator.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.InferenceParameter inference_parameter = 4 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $inference_parameter = null;
    /**
     * Optional. The trigger event of the generator. It defines when the generator
     * is triggered in a conversation.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.TriggerEvent trigger_event = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $trigger_event = 0;
    /**
     * Output only. Creation time of this generator.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $create_time = null;
    /**
     * Output only. Update time of this generator.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $update_time = null;
    /**
     * Optional. Resource names of the tools that the generator can choose from.
     * Format: `projects/<Project ID>/locations/<Location ID>/tools/<tool ID>`.
     *
     * Generated from protobuf field <code>repeated string tools = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = {</code>
     */
    private $tools;
    /**
     * Optional. Configuration for suggestion deduping. This is only applicable to
     * AI Coach feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.SuggestionDedupingConfig suggestion_deduping_config = 23 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    protected $suggestion_deduping_config = null;
    /**
     * Optional. List of CES toolset specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.ToolsetTool toolset_tools = 27 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $toolset_tools;
    /**
     * Optional. List of CES tool specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.CesToolSpec ces_tool_specs = 28 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $ces_tool_specs;
    /**
     * Optional. List of CES app specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.CesAppSpec ces_app_specs = 29 [(.google.api.field_behavior) = OPTIONAL];</code>
     */
    private $ces_app_specs;
    protected $context;
    protected $foundation_model;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $name
     *           Output only. Identifier. The resource name of the generator. Format:
     *           `projects/<Project ID>/locations/<Location ID>/generators/<Generator ID>`
     *     @type string $description
     *           Optional. Human readable description of the generator.
     *     @type \Google\Cloud\Dialogflow\V2\FreeFormContext $free_form_context
     *           Input of free from generator to LLM.
     *     @type \Google\Cloud\Dialogflow\V2\AgentCoachingContext $agent_coaching_context
     *           Input of prebuilt Agent Coaching feature.
     *     @type \Google\Cloud\Dialogflow\V2\SummarizationContext $summarization_context
     *           Input of prebuilt Summarization feature.
     *     @type \Google\Cloud\Dialogflow\V2\InferenceParameter $inference_parameter
     *           Optional. Inference parameters for this generator.
     *     @type int $trigger_event
     *           Optional. The trigger event of the generator. It defines when the generator
     *           is triggered in a conversation.
     *     @type string $published_model
     *           Optional. The published Large Language Model name.
     *           * To use the latest model version, specify the model name without version
     *             number. Example: `text-bison`
     *           * To use a stable model version, specify the version number as well.
     *             Example: `text-bison\@002`.
     *     @type \Google\Protobuf\Timestamp $create_time
     *           Output only. Creation time of this generator.
     *     @type \Google\Protobuf\Timestamp $update_time
     *           Output only. Update time of this generator.
     *     @type string[] $tools
     *           Optional. Resource names of the tools that the generator can choose from.
     *           Format: `projects/<Project ID>/locations/<Location ID>/tools/<tool ID>`.
     *     @type \Google\Cloud\Dialogflow\V2\SuggestionDedupingConfig $suggestion_deduping_config
     *           Optional. Configuration for suggestion deduping. This is only applicable to
     *           AI Coach feature.
     *     @type \Google\Cloud\Dialogflow\V2\ToolsetTool[] $toolset_tools
     *           Optional. List of CES toolset specs that the generator can choose from.
     *     @type \Google\Cloud\Dialogflow\V2\CesToolSpec[] $ces_tool_specs
     *           Optional. List of CES tool specs that the generator can choose from.
     *     @type \Google\Cloud\Dialogflow\V2\CesAppSpec[] $ces_app_specs
     *           Optional. List of CES app specs that the generator can choose from.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dialogflow\V2\Generator::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. Identifier. The resource name of the generator. Format:
     * `projects/<Project ID>/locations/<Location ID>/generators/<Generator ID>`
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Output only. Identifier. The resource name of the generator. Format:
     * `projects/<Project ID>/locations/<Location ID>/generators/<Generator ID>`
     *
     * Generated from protobuf field <code>string name = 1 [(.google.api.field_behavior) = IDENTIFIER, (.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * Optional. Human readable description of the generator.
     *
     * Generated from protobuf field <code>string description = 2 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * Optional. Human readable description of the generator.
     *
     * Generated from protobuf field <code>string description = 2 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * Input of free from generator to LLM.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.FreeFormContext free_form_context = 11;</code>
     * @return \Google\Cloud\Dialogflow\V2\FreeFormContext|null
     */
    public function getFreeFormContext()
    {
        return $this->readOneof(11);
    }

    public function hasFreeFormContext()
    {
        return $this->hasOneof(11);
    }

    /**
     * Input of free from generator to LLM.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.FreeFormContext free_form_context = 11;</code>
     * @param \Google\Cloud\Dialogflow\V2\FreeFormContext $var
     * @return $this
     */
    public function setFreeFormContext($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\FreeFormContext::class);
        $this->writeOneof(11, $var);

        return $this;
    }

    /**
     * Input of prebuilt Agent Coaching feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.AgentCoachingContext agent_coaching_context = 12;</code>
     * @return \Google\Cloud\Dialogflow\V2\AgentCoachingContext|null
     */
    public function getAgentCoachingContext()
    {
        return $this->readOneof(12);
    }

    public function hasAgentCoachingContext()
    {
        return $this->hasOneof(12);
    }

    /**
     * Input of prebuilt Agent Coaching feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.AgentCoachingContext agent_coaching_context = 12;</code>
     * @param \Google\Cloud\Dialogflow\V2\AgentCoachingContext $var
     * @return $this
     */
    public function setAgentCoachingContext($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\AgentCoachingContext::class);
        $this->writeOneof(12, $var);

        return $this;
    }

    /**
     * Input of prebuilt Summarization feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.SummarizationContext summarization_context = 13;</code>
     * @return \Google\Cloud\Dialogflow\V2\SummarizationContext|null
     */
    public function getSummarizationContext()
    {
        return $this->readOneof(13);
    }

    public function hasSummarizationContext()
    {
        return $this->hasOneof(13);
    }

    /**
     * Input of prebuilt Summarization feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.SummarizationContext summarization_context = 13;</code>
     * @param \Google\Cloud\Dialogflow\V2\SummarizationContext $var
     * @return $this
     */
    public function setSummarizationContext($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\SummarizationContext::class);
        $this->writeOneof(13, $var);

        return $this;
    }

    /**
     * Optional. Inference parameters for this generator.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.InferenceParameter inference_parameter = 4 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return \Google\Cloud\Dialogflow\V2\InferenceParameter|null
     */
    public function getInferenceParameter()
    {
        return $this->inference_parameter;
    }

    public function hasInferenceParameter()
    {
        return isset($this->inference_parameter);
    }

    public function clearInferenceParameter()
    {
        unset($this->inference_parameter);
    }

    /**
     * Optional. Inference parameters for this generator.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.InferenceParameter inference_parameter = 4 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param \Google\Cloud\Dialogflow\V2\InferenceParameter $var
     * @return $this
     */
    public function setInferenceParameter($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\InferenceParameter::class);
        $this->inference_parameter = $var;

        return $this;
    }

    /**
     * Optional. The trigger event of the generator. It defines when the generator
     * is triggered in a conversation.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.TriggerEvent trigger_event = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return int
     */
    public function getTriggerEvent()
    {
        return $this->trigger_event;
    }

    /**
     * Optional. The trigger event of the generator. It defines when the generator
     * is triggered in a conversation.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.TriggerEvent trigger_event = 5 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param int $var
     * @return $this
     */
    public function setTriggerEvent($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\Dialogflow\V2\TriggerEvent::class);
        $this->trigger_event = $var;

        return $this;
    }

    /**
     * Optional. The published Large Language Model name.
     * * To use the latest model version, specify the model name without version
     *   number. Example: `text-bison`
     * * To use a stable model version, specify the version number as well.
     *   Example: `text-bison\@002`.
     *
     * Generated from protobuf field <code>string published_model = 15 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return string
     */
    public function getPublishedModel()
    {
        return $this->readOneof(15);
    }

    public function hasPublishedModel()
    {
        return $this->hasOneof(15);
    }

    /**
     * Optional. The published Large Language Model name.
     * * To use the latest model version, specify the model name without version
     *   number. Example: `text-bison`
     * * To use a stable model version, specify the version number as well.
     *   Example: `text-bison\@002`.
     *
     * Generated from protobuf field <code>string published_model = 15 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param string $var
     * @return $this
     */
    public function setPublishedModel($var)
    {
        GPBUtil::checkString($var, True);
        $this->writeOneof(15, $var);

        return $this;
    }

    /**
     * Output only. Creation time of this generator.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getCreateTime()
    {
        return $this->create_time;
    }

    public function hasCreateTime()
    {
        return isset($this->create_time);
    }

    public function clearCreateTime()
    {
        unset($this->create_time);
    }

    /**
     * Output only. Creation time of this generator.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setCreateTime($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->create_time = $var;

        return $this;
    }

    /**
     * Output only. Update time of this generator.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getUpdateTime()
    {
        return $this->update_time;
    }

    public function hasUpdateTime()
    {
        return isset($this->update_time);
    }

    public function clearUpdateTime()
    {
        unset($this->update_time);
    }

    /**
     * Output only. Update time of this generator.
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setUpdateTime($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->update_time = $var;

        return $this;
    }

    /**
     * Optional. Resource names of the tools that the generator can choose from.
     * Format: `projects/<Project ID>/locations/<Location ID>/tools/<tool ID>`.
     *
     * Generated from protobuf field <code>repeated string tools = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = {</code>
     * @return RepeatedField<string>
     */
    public function getTools()
    {
        return $this->tools;
    }

    /**
     * Optional. Resource names of the tools that the generator can choose from.
     * Format: `projects/<Project ID>/locations/<Location ID>/tools/<tool ID>`.
     *
     * Generated from protobuf field <code>repeated string tools = 14 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = {</code>
     * @param string[] $var
     * @return $this
     */
    public function setTools($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->tools = $arr;

        return $this;
    }

    /**
     * Optional. Configuration for suggestion deduping. This is only applicable to
     * AI Coach feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.SuggestionDedupingConfig suggestion_deduping_config = 23 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return \Google\Cloud\Dialogflow\V2\SuggestionDedupingConfig|null
     */
    public function getSuggestionDedupingConfig()
    {
        return $this->suggestion_deduping_config;
    }

    public function hasSuggestionDedupingConfig()
    {
        return isset($this->suggestion_deduping_config);
    }

    public function clearSuggestionDedupingConfig()
    {
        unset($this->suggestion_deduping_config);
    }

    /**
     * Optional. Configuration for suggestion deduping. This is only applicable to
     * AI Coach feature.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.SuggestionDedupingConfig suggestion_deduping_config = 23 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param \Google\Cloud\Dialogflow\V2\SuggestionDedupingConfig $var
     * @return $this
     */
    public function setSuggestionDedupingConfig($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\SuggestionDedupingConfig::class);
        $this->suggestion_deduping_config = $var;

        return $this;
    }

    /**
     * Optional. List of CES toolset specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.ToolsetTool toolset_tools = 27 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return RepeatedField<\Google\Cloud\Dialogflow\V2\ToolsetTool>
     */
    public function getToolsetTools()
    {
        return $this->toolset_tools;
    }

    /**
     * Optional. List of CES toolset specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.ToolsetTool toolset_tools = 27 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param \Google\Cloud\Dialogflow\V2\ToolsetTool[] $var
     * @return $this
     */
    public function setToolsetTools($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dialogflow\V2\ToolsetTool::class);
        $this->toolset_tools = $arr;

        return $this;
    }

    /**
     * Optional. List of CES tool specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.CesToolSpec ces_tool_specs = 28 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return RepeatedField<\Google\Cloud\Dialogflow\V2\CesToolSpec>
     */
    public function getCesToolSpecs()
    {
        return $this->ces_tool_specs;
    }

    /**
     * Optional. List of CES tool specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.CesToolSpec ces_tool_specs = 28 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param \Google\Cloud\Dialogflow\V2\CesToolSpec[] $var
     * @return $this
     */
    public function setCesToolSpecs($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dialogflow\V2\CesToolSpec::class);
        $this->ces_tool_specs = $arr;

        return $this;
    }

    /**
     * Optional. List of CES app specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.CesAppSpec ces_app_specs = 29 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @return RepeatedField<\Google\Cloud\Dialogflow\V2\CesAppSpec>
     */
    public function getCesAppSpecs()
    {
        return $this->ces_app_specs;
    }

    /**
     * Optional. List of CES app specs that the generator can choose from.
     *
     * Generated from protobuf field <code>repeated .google.cloud.dialogflow.v2.CesAppSpec ces_app_specs = 29 [(.google.api.field_behavior) = OPTIONAL];</code>
     * @param \Google\Cloud\Dialogflow\V2\CesAppSpec[] $var
     * @return $this
     */
    public function setCesAppSpecs($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Dialogflow\V2\CesAppSpec::class);
        $this->ces_app_specs = $arr;

        return $this;
    }

    /**
     * @return string
     */
    public function getContext()
    {
        return $this->whichOneof("context");
    }

    /**
     * @return string
     */
    public function getFoundationModel()
    {
        return $this->whichOneof("foundation_model");
    }

}

