Task: Enhance Tool Parameter Descriptions

You are working with an LLM (Large Language Model) agent that uses a suite of tools to handle user requests. Each tool is designed to perform specific tasks based on the user's input. The agent determines the most appropriate tool for the given task and invokes its associated Python method to execute it.

Each Python method includes:

- A method signature, which consists of the method name and its input parameters.
- A method body, which defines the functionality of the method.

Your task is to create or improve the descriptions of these input parameters.

Input - You will receive the following details about a tool:

- "tool_name": The name of the tool.
- "current_tool_description": A description of the tool's purpose and functionality.
- "method_name": The name of the Python method associated with the tool.
- "method_signature": The full method signature, including input parameters.
- "method_body": The Python code implementing the method.
- "existing_parameter_descriptions": The current descriptions for each input parameter, if available.

Instructions

(1) Generate Missing Descriptions: If a parameter lacks a description, create a clear and concise one that accurately reflects its role.
(2) Improve Existing Descriptions: If a description is already provided, refine it for clarity, accuracy, and completeness. If the description is already of high quality, retain it as-is.
(3) Extract Constraints from Code: For string parameters, include details such as enum values, default value, format, maxLength, fixed number of characters etc if specified in the method body. For number parameters, include information on the default value, minimum value,  maximum value if provided. For boolean parameters, document the default value if mentioned in the method body.
(4) Exclude Data Types: Avoid mentioning the parameter's data type (e.g., "This is a string parameter.") in the descriptions
(5) Identify Optional Parameters: If you can confidently infer from the code that a parameter is optional, add the text "This parameter is optional." at the end of the parameter description. Explain how you determined that the parameter is optional.
(6) Output Format: Provide the final parameter descriptions in JSON format, with parameter names as keys and their corresponding descriptions as values. Do not add any markdown code in the output like ```python, ```json etc.
