Don't add sys instruction if empty
| @@ -433,7 +433,7 @@ async function sendMakerSuiteRequest(request, response) { | ||
| 433 | 433 | generationConfig: generationConfig, |
| 434 | 434 | }; |
| 435 | 435 | |
| 436 | - if (useSystemPrompt) { | |
| 436 | + if (useSystemPrompt && Array.isArray(prompt.system_instruction) && prompt.system_instruction.length) { | |
| 437 | 437 | body.systemInstruction = prompt.system_instruction; |
| 438 | 438 | } |
| 439 | 439 | |