How to debug chat API

When send a request, only got “INFO: 127.0.0.1:49598 - “POST /v1/chat/completions HTTP/1.1” 500 Internal Server Error” error, no stacktrace. Wondering if there is a way (like a flag or env var) to get the stacktrace printed on the server side.