Google Gemini is a conversational AI chatbot, based initially on the LaMDA family of large language models and later the PaLM LLM.
This document provides information about the Google Gemini Connector, which facilitates automated interactions, with a Google Gemini server using FortiSOAR™ playbooks. Add the Google Gemini Connector as a step in FortiSOAR™ playbooks and perform automated operations with Google Gemini.
NOTE: This connector was previously known as Google Bard. For previous versions of this connector, refer to Google Bard connector documentation.
Connector Version: 2.0.0
FortiSOAR™ Version Tested on: 7.6.1-5275
Google Gemini API Version Tested On: v1beta2
Authored By: Fortinet
Certified: Yes
Following enhancements have been made to the Google Gemini connector in version 2.0.0:
Google Bard to Google Gemini.Use the Content Hub to install the connector. For the detailed procedure to install a connector, click here.
You can also use the yum command as a root user to install the connector:
yum install cyops-connector-google-bard
For the procedure to configure a connector, click here
In FortiSOAR™, on the Connectors page, click the Google Gemini connector row (if you are in the Grid view on the Connectors page) and in the Configurations tab enter the required configuration details:
| Parameter | Description |
|---|---|
| Server URL | Specify the URL of the Google Gemini server to connect and perform automated operations. |
| API Key | Specify the API key to access the endpoint to connect and perform the automated operations |
| Verify SSL | Specifies whether the SSL certificate for the server is to be verified. By default, this option is set to True. |
The following automated operations can be included in playbooks and you can also use the annotations to access operations:
| Function | Description | Annotation and Category |
|---|---|---|
| Get All Model List | Retrieves a list of all language models from Google Gemini based on the pagination criteria and other parameters you have specified. | list_models Investigation |
| Get Model Details | Retrieves information for a specific model from Google Gemini based on the model name you have specified. | get_model_details Investigation |
| Generate Text | Generates a response from the model based on the model name, text prompts, and other input parameters you have specified. | generate_text Investigation |
| Generate Embedding | Generates an embedding from the model based on the model name and text you have specified. | generate_embeddings Investigation |
| Count Message Token | Retrieves the number of tokens that the model creates from the prompt based on the model name, message, and other input parameter you have specified. | count_message_token Investigation |
| Generate Message | Generates an message from the model based on the model name, messages, and other input parameters you have specified. | generate_message Investigation |
| Parameter | Description |
|---|---|
| Page Size | (Optional) Specify the maximum count of records that this operation fetches from Google Gemini. By default, this option is set to 50. You can specify a maximum value of 1000 and minimum value of 1. |
| Page Token | (Optional) Specify the token for the next set of items to return. The previously returned response contains a nextPageToken element containing a PageToken parameter. Use this parameter as a starting point to get the next page of results. |
The output contains the following populated JSON schema:
{
"models": [
{
"name": "",
"topK": "",
"topP": "",
"version": "",
"description": "",
"displayName": "",
"temperature": "",
"inputTokenLimit": "",
"outputTokenLimit": "",
"supportedGenerationMethods": []
}
],
"nextPageToken": ""
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model whose details are to be retrieved from Google Gemini. |
The output contains the following populated JSON schema:
{
"name": "",
"topK": "",
"topP": "",
"version": "",
"description": "",
"displayName": "",
"temperature": "",
"inputTokenLimit": "",
"outputTokenLimit": "",
"supportedGenerationMethods": []
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to generate text in Google Gemini. |
| Text Prompt | Specify a free-form input text given to the model as a prompt based on which Google Gemini generates text. |
| Safety Settings | (Optional) Specify a list of unique SafetySetting instances for blocking unsafe content. |
| Stop Sequences | (Optional) Specify a set of character sequences (up to 5) that stop the output generation. |
| Temperature | (Optional) Specify the value of the temperature to control the randomness of the output. Values can range from [0.0,1.0], inclusive. A value closer to 1.0 produces responses that are more varied and creative, while a value closer to 0.0 typically results in a more straightforward responses from the model.
NOTE: The default value varies by model. |
| Candidate Count | (Optional) Specify the candidate count based on which the number of generated responses to return.
NOTE: This value must be between |
| Maximum Output Tokens | (Optional) Specify the maximum number of tokens to include in a candidate. If unset, defaults to 64. |
| Cumulative Probability (TopP) | (Optional) Specify the maximum cumulative probability of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
| Token (TopK) | (Optional) Specify the maximum number of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
The output contains the following populated JSON schema:
{
"candidates": [
{
"output": "",
"safetyRatings": [
{
"category": "",
"probability": ""
}
]
}
]
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to generate embedding in Google Gemini. |
| Text | Specify the free-form input text that the model turns into an embedding in Google Gemini. |
The output contains the following populated JSON schema:
{
"embedding": {
"value": []
}
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to retrieve token from Google Gemini. |
| Messages | Specify the list of messages based on which to retrieve token count from Google Gemini.
NOTE: If the total input size exceeds the model's |
| Context | (Optional) Specify the context of your prompt to the model to help provide context and guide the responses. If not empty, this context is given to the model first before the examples and messages. When using a context be sure to provide it with every request to maintain continuity. |
| Examples | (Optional) Specify a list of examples of what the model should generate in Google Gemini. This includes both user input and the response that the model should emulate.
NOTE: If the total input size exceeds the model's |
The output contains the following populated JSON schema:
{
"tokenCount": ""
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to generate message in Google Gemini. |
| Messages | Specify the list of messages based on which to generate message in Google Gemini.
NOTE: If the total input size exceeds the model's |
| Context | (Optional) Specify the context of your prompt to the model to help provide context and guide the responses. If not empty, this context is given to the model first before the examples and messages. When using a context be sure to provide it with every request to maintain continuity. |
| Examples | (Optional) Specify a list of examples of what the model should generate in Google Gemini. This includes both user input and the response that the model should emulate.
NOTE: If the total input size exceeds the model's |
| Temperature | (Optional) Specify the value of the temperature to control the randomness of the output. Values can range from [0.0,1.0], inclusive. A value closer to 1.0 produces responses that are more varied and creative, while a value closer to 0.0 typically results in a more straightforward responses from the model.
NOTE: The default value varies by model. |
| Candidate Count | (Optional) Specify the candidate count based on which the number of generated responses to return.
NOTE: This value must be between |
| Cumulative Probability (TopP) | (Optional) Specify the maximum cumulative probability of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
| Token (TopK) | (Optional) Specify the maximum number of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
The output contains the following populated JSON schema:
{
"messages": [
{
"author": "",
"content": ""
}
],
"candidates": [
{
"author": "",
"content": ""
}
]
}
The Sample - Google Gemini - 2.0.0 playbook collection comes bundled with the Google Gemini connector. These playbooks contain steps using which you can perform all supported actions. You can see bundled playbooks in the Automation > Playbooks section in FortiSOAR™ after importing the Google Gemini connector.
Note: If you are planning to use any of the sample playbooks in your environment, ensure that you clone those playbooks and move them to a different collection since the sample playbook collection gets deleted during connector upgrade and delete.
Google Gemini is a conversational AI chatbot, based initially on the LaMDA family of large language models and later the PaLM LLM.
This document provides information about the Google Gemini Connector, which facilitates automated interactions, with a Google Gemini server using FortiSOAR™ playbooks. Add the Google Gemini Connector as a step in FortiSOAR™ playbooks and perform automated operations with Google Gemini.
NOTE: This connector was previously known as Google Bard. For previous versions of this connector, refer to Google Bard connector documentation.
Connector Version: 2.0.0
FortiSOAR™ Version Tested on: 7.6.1-5275
Google Gemini API Version Tested On: v1beta2
Authored By: Fortinet
Certified: Yes
Following enhancements have been made to the Google Gemini connector in version 2.0.0:
Google Bard to Google Gemini.Use the Content Hub to install the connector. For the detailed procedure to install a connector, click here.
You can also use the yum command as a root user to install the connector:
yum install cyops-connector-google-bard
For the procedure to configure a connector, click here
In FortiSOAR™, on the Connectors page, click the Google Gemini connector row (if you are in the Grid view on the Connectors page) and in the Configurations tab enter the required configuration details:
| Parameter | Description |
|---|---|
| Server URL | Specify the URL of the Google Gemini server to connect and perform automated operations. |
| API Key | Specify the API key to access the endpoint to connect and perform the automated operations |
| Verify SSL | Specifies whether the SSL certificate for the server is to be verified. By default, this option is set to True. |
The following automated operations can be included in playbooks and you can also use the annotations to access operations:
| Function | Description | Annotation and Category |
|---|---|---|
| Get All Model List | Retrieves a list of all language models from Google Gemini based on the pagination criteria and other parameters you have specified. | list_models Investigation |
| Get Model Details | Retrieves information for a specific model from Google Gemini based on the model name you have specified. | get_model_details Investigation |
| Generate Text | Generates a response from the model based on the model name, text prompts, and other input parameters you have specified. | generate_text Investigation |
| Generate Embedding | Generates an embedding from the model based on the model name and text you have specified. | generate_embeddings Investigation |
| Count Message Token | Retrieves the number of tokens that the model creates from the prompt based on the model name, message, and other input parameter you have specified. | count_message_token Investigation |
| Generate Message | Generates an message from the model based on the model name, messages, and other input parameters you have specified. | generate_message Investigation |
| Parameter | Description |
|---|---|
| Page Size | (Optional) Specify the maximum count of records that this operation fetches from Google Gemini. By default, this option is set to 50. You can specify a maximum value of 1000 and minimum value of 1. |
| Page Token | (Optional) Specify the token for the next set of items to return. The previously returned response contains a nextPageToken element containing a PageToken parameter. Use this parameter as a starting point to get the next page of results. |
The output contains the following populated JSON schema:
{
"models": [
{
"name": "",
"topK": "",
"topP": "",
"version": "",
"description": "",
"displayName": "",
"temperature": "",
"inputTokenLimit": "",
"outputTokenLimit": "",
"supportedGenerationMethods": []
}
],
"nextPageToken": ""
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model whose details are to be retrieved from Google Gemini. |
The output contains the following populated JSON schema:
{
"name": "",
"topK": "",
"topP": "",
"version": "",
"description": "",
"displayName": "",
"temperature": "",
"inputTokenLimit": "",
"outputTokenLimit": "",
"supportedGenerationMethods": []
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to generate text in Google Gemini. |
| Text Prompt | Specify a free-form input text given to the model as a prompt based on which Google Gemini generates text. |
| Safety Settings | (Optional) Specify a list of unique SafetySetting instances for blocking unsafe content. |
| Stop Sequences | (Optional) Specify a set of character sequences (up to 5) that stop the output generation. |
| Temperature | (Optional) Specify the value of the temperature to control the randomness of the output. Values can range from [0.0,1.0], inclusive. A value closer to 1.0 produces responses that are more varied and creative, while a value closer to 0.0 typically results in a more straightforward responses from the model.
NOTE: The default value varies by model. |
| Candidate Count | (Optional) Specify the candidate count based on which the number of generated responses to return.
NOTE: This value must be between |
| Maximum Output Tokens | (Optional) Specify the maximum number of tokens to include in a candidate. If unset, defaults to 64. |
| Cumulative Probability (TopP) | (Optional) Specify the maximum cumulative probability of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
| Token (TopK) | (Optional) Specify the maximum number of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
The output contains the following populated JSON schema:
{
"candidates": [
{
"output": "",
"safetyRatings": [
{
"category": "",
"probability": ""
}
]
}
]
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to generate embedding in Google Gemini. |
| Text | Specify the free-form input text that the model turns into an embedding in Google Gemini. |
The output contains the following populated JSON schema:
{
"embedding": {
"value": []
}
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to retrieve token from Google Gemini. |
| Messages | Specify the list of messages based on which to retrieve token count from Google Gemini.
NOTE: If the total input size exceeds the model's |
| Context | (Optional) Specify the context of your prompt to the model to help provide context and guide the responses. If not empty, this context is given to the model first before the examples and messages. When using a context be sure to provide it with every request to maintain continuity. |
| Examples | (Optional) Specify a list of examples of what the model should generate in Google Gemini. This includes both user input and the response that the model should emulate.
NOTE: If the total input size exceeds the model's |
The output contains the following populated JSON schema:
{
"tokenCount": ""
}
| Parameter | Description |
|---|---|
| Model Name | Specify the name of the model based on which to generate message in Google Gemini. |
| Messages | Specify the list of messages based on which to generate message in Google Gemini.
NOTE: If the total input size exceeds the model's |
| Context | (Optional) Specify the context of your prompt to the model to help provide context and guide the responses. If not empty, this context is given to the model first before the examples and messages. When using a context be sure to provide it with every request to maintain continuity. |
| Examples | (Optional) Specify a list of examples of what the model should generate in Google Gemini. This includes both user input and the response that the model should emulate.
NOTE: If the total input size exceeds the model's |
| Temperature | (Optional) Specify the value of the temperature to control the randomness of the output. Values can range from [0.0,1.0], inclusive. A value closer to 1.0 produces responses that are more varied and creative, while a value closer to 0.0 typically results in a more straightforward responses from the model.
NOTE: The default value varies by model. |
| Candidate Count | (Optional) Specify the candidate count based on which the number of generated responses to return.
NOTE: This value must be between |
| Cumulative Probability (TopP) | (Optional) Specify the maximum cumulative probability of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
| Token (TopK) | (Optional) Specify the maximum number of tokens to consider when sampling.
NOTE: The default value varies by model, see the |
The output contains the following populated JSON schema:
{
"messages": [
{
"author": "",
"content": ""
}
],
"candidates": [
{
"author": "",
"content": ""
}
]
}
The Sample - Google Gemini - 2.0.0 playbook collection comes bundled with the Google Gemini connector. These playbooks contain steps using which you can perform all supported actions. You can see bundled playbooks in the Automation > Playbooks section in FortiSOAR™ after importing the Google Gemini connector.
Note: If you are planning to use any of the sample playbooks in your environment, ensure that you clone those playbooks and move them to a different collection since the sample playbook collection gets deleted during connector upgrade and delete.