How to Debug Text Generation API Calls