In our system, the behavior of a conversational AI agent is guided by "guidelines". The agent makes use of these guidelines whenever it interacts with a user (also referred to as the customer).
Each guideline is composed of two parts: 
- "condition": This is a natural-language condition that specifies when a guideline should apply. We look at each conversation at any particular state, and we test against this condition to understand 
if we should have this guideline participate in generating the next reply to the user.
- "action": This is a natural-language instruction that should be followed by the agent whenever the "condition" part of the guideline applies to the conversation in its particular state.
Any instruction described here applies only to the agent, and not to the user.
Some of these guidelines are equipped with external tools—functions that enable the AI to access crucial information and execute specific actions. This means that when the specified condition is met,
the corresponding action should involve utilizing those tools. 

Your task is given a guideline's condition and a tool description (or a list of tools) to provide an action that shortly and concisely describe an action that aligns with the tool purpose.
You will receive a tool description that includes the tool signature, a description of the tool (if exists), and the types and descriptions of its parameters.
If available, use the tool description to incorporate any relevant information that may inform how the tool should be used.
Note that the tool name and description may be uninformative, so you may need to infer the tool's purpose from its parameters.




Examples:
1. 
Condition: Asked to get the weather forecast for a city  
Tool description:
{
    "tool_name": "local:get_weather",
    "description": "Get the current weather and forecast for a specific city",
    "optional_arguments": {
        "unit": {"schema": {"type": "string"}, "description": "Temperature unit: Celsius or Fahrenheit"}
    },
    "required_parameters": {
        "city": {"schema": {"type": "string"}, "description": "The city to get the weather for"}
    }
}
Action: Provide current weather and forecast

2.  
Condition: Asked to send an email  
Tool description:
{
    "tool_name": "local:send_email",
    "description": "Send an email to a recipient",
    "optional_arguments": {},
    "required_parameters": {
        "to": {"schema": {"type": "string"}, "description": "Recipient email address"},
        "subject": {"schema": {"type": "string"}, "description": "Subject of the email"},
        "body": {"schema": {"type": "string"}, "description": "Content of the email"}
    }
}
Action: Send the specified email

3.  
Condition: A recurring invoice has failed to process due to an expired payment method.  
Tool description:
{
    "tool_name": "local:send_payment_failure_notification",
    "description": "Notify the user that a payment attempt failed",
    "required_parameters": {
        "user_id": {"schema": {"type": "string"}, "description": "The ID of the user to notify"},
        "invoice_id": {"schema": {"type": "string"}, "description": "The invoice that failed to process"}
    }
}
Action: Notify the user that payment for their invoice could not be processed.

4.  
Condition: A scheduled backup did not complete within its expected time window.  
Tool descriptions:
[
  {
    "tool_name": "local:check_backup_status",
    "description": "Check the current or last-known status of a backup job",
    "required_parameters": {
        "job_id": {"schema": {"type": "string"}, "description": "Identifier of the backup job"}
    }
  },
  {
    "tool_name": "local:send_alert",
    "description": "Send an alert to system administrators",
    "required_parameters": {
        "message": {"schema": {"type": "string"}, "description": "The alert message"},
        "recipients": {"schema": {"type": "array", "items": {"type": "string"}}, "description": "List of recipient user IDs"}
    }
  }
]
Action: Check the status of the backup job and alert administrators if it failed.

5.  
Condition: A weather alert has been issued for a location where outdoor company events are scheduled.  
Tool descriptions:
[
  {
    "tool_name": "local:check_weather_alerts",
    "description": "Get current weather alerts for a region",
    "required_parameters": {
        "location": {"schema": {"type": "string"}, "description": "City or region to check"}
    }
  },
  {
    "tool_name": "local:reschedule_event",
    "description": "Reschedule or cancel an event based on external factors",
    "required_parameters": {
        "event_id": {"schema": {"type": "string"}, "description": "ID of the event"},
        "reason": {"schema": {"type": "string"}, "description": "Reason for rescheduling"}
    }
  }
]
Action: Check for severe weather and reschedule outdoor events if necessary.

--------------------------------------------------------------------------------



Guideline Condition:
--------------------------
the user wants to book a flight




Relevant Tools:
--------------
- built-in:check_if_seats_are_available: {'tool_name': 'built-in:check_if_seats_are_available', 'description': 'Check if seats are available on a flight. This should be called BEFORE booking.', 'optional_arguments': {}, 'required_parameters': {'flight_id': '{"schema": {"type": "string"}}'}}



Expected output (JSON):
```json
{
    "rationale": "<RATIONALE>"
    "action": "<SINGLE-LINE-INSTRUCTION>",
}
```