Task: Data-transform-reshape (source dataset: Auto-Tables)

Given a table, predict what python pandas transformation may be needed on the given input table. Valid choices for transformation include: {"stack", "wide_to_long", "transpose", "pivot", "explode", "ffill", "subtitles"}. Note that each of these is a common Python Pandas operator. Some transformations can have parameters. Each transformation and its parameters are describe as follows.
 
- stack: collapse homogeneous cols into rows.
@param (int): stack_start_idx: zero-based starting column index of the homogeneous column-group.
@param (int): stack_end_idx: zero-based ending column index of the homogeneous column-group.
 
- wide_to_long: collapse repeating col-groups into rows.
@param (int): wide_to_long_start_idx: zero-based starting column index of the repeating col-groups.
@param (int): wide_to_long_end_idx: zero-based ending column index of the repeating col-groups.
 
- transpose: convert rows to columns and vice versa.
 
- pivot: pivot repeating row-groups into cols.
@param (int): pivot_row_frequency: frequency of repeating row-groups.
 
- ffill: fill structurally empty cells in tables.
@param (int): ffill_end_idx: zero-based ending column index of the columns to be filled.
 
- explode: convert composite cells into atomic values
@param (int): explode_column_idx: zero-based column index of the column to be exploded.
 
- subtitle: convert table subtitles into a column.
 
OUTPUT the predicted transformation name along with its parameters for the given INPUT table in a JSON, e.g., {"transformation": "stack", "stack_start_idx": 1, "stack_end_idx": 5}. If the input table needs multi-step transformations (e.g, ffill followed by stack), list JSON of each transformation sequentially in a list, e.g., [{"transformation": "ffill", "ffill_end_idx": 1}, {"transformation": "stack", "stack_start_idx": 1, "stack_end_idx": 5}]. No explanation is needed.

## Input:
| Model # Final   | Colour1                                 |
|:----------------|:----------------------------------------|
| D1-A3621        | Natural                                 |
| D1-A3626        | Natural                                 |
| D1-A3629        | Black                                   |
| D1-AM5199       | Clear                                   |
| D1-B0003        | Silver                                  |
| D1-B0005        | Silver                                  |
| D1-B0020        | Silver                                  |
| D1-B1822        | Green/Red/Royal/White/Yellow            |
| D1-B4049        | Red/Black/Grey                          |
| D1-B4255        | Navy Plaid with Koskin pocket           |
| D1-B4394        | Black                                   |
| D1-B4878        | Black/Grey                              |
| D1-B4976        | Black                                   |
| D1-B5060        | Black                                   |
| D1-B6647        | Black/Grey                              |
| D1-B8074        | Black/White Gingham                     |
| D1-B9074        | Navy Blue/White Gingham                 |
| D1-BC0006       | Black                                   |
| D1-BL1991       | Black                                   |
| D1-BL3250       | Black                                   |
| D1-BL3264       | Black with White stitching              |
| D1-BL3275       | Black with Black stitching              |
| D1-BL3283       | Black/Black stitching                   |
| D1-BL3292       | Black with Black stitching              |
| D1-BL3711       | Black                                   |
| D1-BL3901       | Black with White stitching              |
| D1-BL5272       | Brown                                   |
| D1-BL6827       | Black                                   |
| D1-BL6953       | Brown                                   |
| D1-BL7261       | Brown                                   |
| D1-BL8590       | Brown                                   |
| D1-BQ4023       | Black/Silver (oven mitt) Silver (tools) |
| D1-BQ8875       | White/Black                             |
| D1-BQ9446       | Brown                                   |
| D1-BQ9535       | Brown                                   |
| D1-C3740        | Black                                   |
| D1-CA3499       | Black                                   |
| D1-CA3530       | Black                                   |
| D1-CA5988       | Brown                                   |
| D1-CA6499       | Black                                   |
| D1-CA6540       | Black                                   |
| D1-CA6625       | Black                                   |
| D1-CA8361       | Brown with white paper                  |
| D1-CA8634       | Brown                                   |
| D1-CA8677       | Black                                   |
| D1-CA8816       | Black                                   |
| D1-CA8993       | Black                                   |
| D1-CA8994       | Black                                   |
| D1-CA9224       | Black                                   |
| D1-CA9266       | White                                   |
| D1-CA9334       | Black                                   |
| D1-CA9394       | Black                                   |
| D1-CA9414       | Black                                   |
| D1-CA9429       | Black                                   |
| D1-CA9445       | Royal Blue                              |
| D1-CA9447       | Natural                                 |
| D1-CA9487       | Black                                   |
| D1-CA9511       | Black                                   |
| D1-CA9517       | Black                                   |
| D1-CA9530       | Black                                   |
| D1-CA9558       | Black                                   |
| D1-CA9563       | Natural                                 |
| D1-CA9633       | Black                                   |
| D1-CA9645       | Black                                   |
| D1-CA9788       | Brown/White                             |
| D1-CB2315       | Navy and Black with Black highlights    |
| D1-CB2466       | Black                                   |
| D1-CB2864       | Royal with Black highlights             |
| D1-CB290        | Black                                   |
| D1-CB297        | Navy                                    |
| D1-CB3103       | Black                                   |
| D1-CB4027       | Black                                   |
| D1-CB5027       | Black                                   |
| D1-CB5032       | Black with White Accents                |
| D1-CB5990       | Red/Black                               |
| D1-CB6544       | Grey/Black                              |
| D1-CB6657       | Grey/Black                              |
| D1-CB700        | Black with Black highlights             |
| D1-CB702        | Black                                   |
| D1-CB729        | Black with two-toned Grey/Black         |
| D1-CB730        | Black with Black trim                   |
| D1-CB734        | Black                                   |
| D1-CB790        | Black                                   |
| D1-CB800        | Heathered Grey                          |
| D1-CB800        | Black                                   |
| D1-CB801        | Black                                   |
| D1-CB847        | Black                                   |
| D1-CB8569       | Black                                   |
| D1-CB8759       | Black                                   |
| D1-CB9157       | Black                                   |
| D1-CB9178       | Black                                   |
| D1-CB9227       | Black/Grey                              |
| D1-CB9238       | Grey                                    |
| D1-CB9389       | Black                                   |
| D1-CB9391       | Light Grey/Black                        |
| D1-CB9406       | Black                                   |
| D1-CB9434       | Light Grey/Black                        |
| D1-CB9564       | Black                                   |
| D1-CB9570       | Black                                   |
| D1-CM1308       | White/Black                             |

## Output:


source: excel_forum
label: explode