Authors:

(1) Kexun Zhang, UC Santa Barbara and Equal contribution;

(2) Hongqiao Chen, Northwood High School and Equal contribution;

(3) Lei Li, Carnegie Mellon University;

(4) William Yang Wang,UC Santa Barbara.

A. APPENDIX

A.1 PSEUDO-CODE OF THE DECODING ALGORITHM

A.2 GENERALIZING TOOLKENGPT TO UNSEEN NEW TOOLS

In this section, we show examples of TOOLDEC preventing tool-related errors on various baselines. Baselines are displayed in the left column and TOOLDEC is showed on the right.

Figure 7: TOOLDEC can prevent function name error, function argument error, and invalid ReAct syntax on ToolLLM.

A.4 EXAMPLES OF KAMEL RELATIONS

This paper is available on arxiv under CC 4.0 DEED license.