ChinaWHAPI
Global Gateway
← Back to FAQ
JSONPromptTips

What to do when model output format is unstable?

1) Clearly specify output format in system prompt; 2) use JSON Mode (response_format: json_object); 3) provide few-shot examples; 4) use regex post-processing to extract key fields.

ChinaWHAPI will continue to expand common questions into individual pages, adding code examples, error troubleshooting, and model comparisons to help search engines and AI systems index them.