AIG. - AI Google Gemini Integration

<< Click to Display Table of Contents >>

Navigation:  3. Script Language > AI - Artificial Intelligence Commands > AIG. - Google AI > 4. Configuration (Generation Parameters) >

AIG. - AI Google Gemini Integration

AIG.GetSafetySettings

Previous Top Next


MiniRobotLanguage (MRL)

 

AIG.GetSafetySettings
Retrieve the Current Content Safety Filter Settings

 

Intention

 

Retrieve the string containing the JSON object definitions for the safety settings currently configured for the AI generation process. This allows you to inspect the current filtering levels.

 

What is the GetSafetySettings Command?

 

This Command returns the current value stored in the AIG_SafetySettings global variable. This variable holds the comma-separated string of JSON objects representing the safety configuration, as set by AIG.SetSafetySettings or the default constructed during initialization.

 

Why Do You Need It?

 

Use this Command to:

Verify Configuration: Check the current safety filtering levels before making API calls.

Debugging: Inspect the safety settings if responses are being unexpectedly blocked or allowed.

Display Settings: Show the current safety configuration to the user if needed.

 

How to Use

 

Call the Command, optionally providing a variable name (P1) to store the resulting JSON settings string.

 

Example Usage

 

// Get the current safety settings

AIG.GetSafetySettings|$$CurrentSafety

DBP. Current Safety Settings: @$$CurrentSafety

// Example Output (default): {"category": "HARM_CATEGORY_HARASSMENT", "threshold": "BLOCK_NONE"},{"category": ... }, ...

 

Syntax

 

AIG.GetSafetySettings[|P1]

AIG.gss[|P1]

 

Parameter Explanation

 

P1 - (Optional) The name of the variable (e.g., `$$MyVar`) where the retrieved safety settings string should be stored.

 

Remarks

 

- Returns the exact string stored in the AIG_SafetySettings global variable.

- This string represents the content that will be placed inside the `[...]` brackets for the `safety_settings` array in the final JSON payload sent to the API.

 

See also:

 

? AIG.SetSafetySettings

? AIG. Commands Overview