From 1657c6abc7f2061debb285797ecf8d1d52c0ddce Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Sat, 18 Nov 2023 22:59:26 -0500 Subject: [PATCH] add note to specify JSON in the prompt when using JSON mode --- docs/api.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/api.md b/docs/api.md index 6f34ed7f7..99378ac39 100644 --- a/docs/api.md +++ b/docs/api.md @@ -51,7 +51,9 @@ Advanced parameters (optional): ### JSON mode -Enable JSON mode by setting the `format` parameter to `json` and specifying the model should use JSON in the `prompt`. This will structure the response as valid JSON. See the JSON mode [example](#request-json-mode) below. +Enable JSON mode by setting the `format` parameter to `json`. This will structure the response as valid JSON. See the JSON mode [example](#request-json-mode) below. + +> Note: it's important to instruct the model to use JSON in the `prompt`. Otherwise, the model may generate large amounts whitespace. ### Examples