After the subsequent operation f is set, within the second stage, we have to generate the arguments. As above, Chain-of-Desk considers three parts within the immediate as proven within the determine: (1) the query, (2) the chosen operation and its required arguments, and (3) the most recent intermediate desk.
As an illustration, when the operation f_group_by is chosen, it requires a header title as its argument.
The LLM selects an acceptable header inside the desk. Outfitted with the chosen operation and the generated arguments, Chain-of-Desk executes the operation and constructs a brand new intermediate desk for the next reasoning.
Chain-of-Desk iterates the earlier two levels to plan the subsequent operation and generate the required arguments. Throughout this course of, we create an operation chain performing as a proxy for the tabular reasoning steps. These operations generate intermediate tables presenting the outcomes of every step to the LLM. Consequently, the output desk accommodates complete details about the intermediate phases of tabular reasoning. In our last stage, we make use of this output desk in formulating the ultimate question and immediate the LLM together with the query for the ultimate reply.