detect_direction
Analyze a string to determine if it's right-to-left, left-to-right, mixed, or neutral, returning the correct dir value for UI elements.
Instructions
Report whether a string is predominantly right-to-left, left-to-right, mixed or neutral, and what to set dir to. Use it when you need to decide the direction of a label, a database field or a block of user content.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"text": "<text>"
},
"name": "detect_direction"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | The text to inspect. |