sort_table
Sort table rows by column content, preserving header rows. Specify table index, column index, and sort order.
Instructions
Sort the non-header rows of a table by the text content of a column.
Header rows (marked with w:tblHeader) remain at the top. Rows with a missing cell at column_index sort as empty string.
Args: table_idx: 0-based table index. column_index: 0-based column to sort by. ascending: True for A→Z (default), False for Z→A.
Returns: {"sorted_rows": int, "column_index": int, "ascending": bool}
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": {
"table_idx": "<table_idx>",
"column_index": "<column_index>"
},
"name": "sort_table"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ascending | No | ||
| table_idx | Yes | ||
| column_index | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |